Cherokee Posted January 27, 2014 Share Posted January 27, 2014 (edited) I've been attempting to login to Instagram via the _WinHTTP functions all day with no succes. The response only loads the default login page, with no invalid/successful login notification. Here's my code. #include <WinHttp.au3> Global $host = 'instagram.com' $hOpen = _WinHttpOpen() $hConnect = _WinHttpConnect($hOpen, $host) $hLoginResult = _WinHttpSimpleFormFill($hConnect, "/accounts/login/", _ "login-form", _ "name:username", "theusername", _ "name:password", "thepassword") ConsoleWrite($hLoginResult & @CRLF) _WinHttpCloseHandle($hConnect) _WinHttpCloseHandle($hOpen) Any help would be appreciated, thanks. Edited January 27, 2014 by Cherokee Jangal 1 Link to comment Share on other sites More sharing options...
AutID Posted January 27, 2014 Share Posted January 27, 2014 I've been attempting to login to Instagram via the _WinHTTP functions all day with no succes. The response only loads the default login page, with no invalid/successful login notification. Here's my code. #include <WinHttp.au3> $host = 'instagram.com' $hOpen = _WinHttpOpen() $hConnect = _WinHttpConnect($hOpen, $host) $header = "Referer: https://instagram.com/accounts/login/" $sRead = _WinHttpSimpleFormFill($hConnect, "/accounts/login/", "login-form", "name:username", "theusername", "name:password", "thepassword", Default, $header) FileWrite('test.txt',$sRead) Any help would be appreciated, thanks. I have not an instagram account and i don't know how to create one, but maybe using an useragent could fool the server. Try it. It may work. https://iblockify.wordpress.com/ Link to comment Share on other sites More sharing options...
Cherokee Posted January 27, 2014 Author Share Posted January 27, 2014 (edited) I have not an instagram account and i don't know how to create one, but maybe using an useragent could fool the server. Try it. It may work. Already tried that, only thing the login script relies on is the referrer equal to https://instagram.com/accounts/login/ and the cookie csrfmiddlewaretoken equal to the assigned session token. I've edited the refer in winhttp.au3 and set it to https://instagram.com/accounts/login/ but still no luck. I've tested it on a PHP script on my server, also with SSL enabled and it works absolutely fine, just not on instagram. Edited January 27, 2014 by Cherokee Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now