I need to authorize via link "https://mysite.sexy/sessionid?login=abc&password=abc" and I got TidHttp and TIdSSLIOHandlerSocketOpenSSL connected both.
I send a query:
http.get("https://mysite.sexy/sessionid?login=abc&password=abc");
but instead of getting any response, after some seconds, I get this exception: "HTTP/1.1 401 Unauthorized."
I had a search over web and got these solutions:
http.Request.UserName := 'abc';
http.Request.Password := 'abc';
http.Request.UserAgent := 'Mozilla/5.0 (X11; U; Linux i686; cs-CZ; rv:1.7.12) Gecko/20050929';
but still it doesn't help anyhow. However a response from a web-site via Chrome-browser doens't occur as an exception and just retrieve error code and description in JSON format:
{"Code":4,"Desc":"Invalid user login or password"}
So this response is what I'm waiting for, but get only exception and thread stops. Please, give directions! Delphi XE3.