how to get hotmail's captcha image?

castielo

Newbie
Joined
Aug 17, 2011
Messages
19
Reaction score
1
since the recent hotmail's update, i can't save the captcha image to de-captcha it. can anyone help?
 
Been wondering about this too. Hotmail captcha seems tricky as fuck.
Will follow this thread for sure!
 
As soon as the captcha image is downloaded once, it gets deleted so you cannot load it again.

The response to this request (https://client.hip.live.com/GetHIP/GetHIPAMFE/HIPAMFE?..........................................)

contains the image url, E.G

Code:
imageurl:'https://client.hip.live.com/GetHIPData?hid=.xxxxxxxxxxxxxxxxxxxxxxxxx&fid=xxxxxx-xxxx-xxxx-xxxxxx-xxxxxxx&type=visual&hdid=0&rnd=xxxxxxxxxxxxxxxxxxxxxxxxxxxx'
Think of a solution ;)
 
Last edited:
i can't think a good solution
first is use http request to get the image link, but it's too hard
second is get the image from webbrowser but i don't know how to get it
can u help?
thanks u very much
 
Dim htmlDocument As HtmlDocument = Me.WebBrowser1.Document
Dim htmlElementCollection As HtmlElementCollection = htmlDocument.Images
For Each htmlElement As HtmlElement In htmlElementCollection
Dim imgUrl As String = htmlElement.GetAttribute("src")
If imgUrl.Contains("GetHIPData?hid=") Then

msgbox(imgurl)

'Download the file code goes here



End If
Next

Return Nothing
 
no, you can't do that. after you loaded the captcha in the browser, it got deleted
 
For something like this you are going to need to webrequets the HTML and regex out the key needed to get the image.

I didn't have time to write the entire thing for you but this will get you started.

2 Buttons
1 Richtextbox

Code for Button 1

Code:
[COLOR=#fff0f5][SIZE=2][SIZE=2][FONT=Verdana][COLOR=white][FONT=Verdana]Dim request As HttpWebRequest = HttpWebRequest.Create("https://signup.live.com/signup.aspx?wa=wsignin1.0&rpsnv=11&ct=1347983845&rver=6.1.6206.0&wp=MBI&wreply=http%3a%2f%2fmail.live.com%2fdefault.aspx&id=64855&cbcxt=mai&snsc=1&bk=1347983846&uiflavor=web&mkt=EN-US&lc=1033&lic=1")

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim response As HttpWebResponse

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]response = CType(request.GetResponse, HttpWebResponse)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim webstream As Stream = response.GetResponseStream

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim streamreader AsNew StreamReader(webstream, Encoding.UTF8)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim html AsString = streamreader.ReadToEnd

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim sourcecode AsString = html.ToString
'====================================================================================
'THIS GRABS THE SOURCE CODE OF A WEBSITE AND PLACES IT INTO A STRING

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim sitekey AsString

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim value AsString = "https://client.hip.live.com/GetHIP/GetHIPAMFE/HIPAMFE?id=15022&mkt=en-US&type=visual&fid=9a371e99-52ef-41df-afbb-46ac16a966f3"

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim m As Match = Regex.Match(sourcecode, "https\:\/\/client\.hip\.live\.com\/GetHIP\/GetHIPAMFE\/HIPAMFE\?id\=15022\&mkt\=en\-US\&type\=visual\&fid\=([\w_-]+)", RegexOptions.IgnoreCase)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]If (m.Success) Then

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim key AsString = m.Groups(1).Value
sitekey = (key.ToString)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]RichTextBox1.Text = (sitekey)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Else

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]MessageBox.Show("Wrong Code")

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]End If[/FONT][/COLOR]
[/FONT][/SIZE][/SIZE][/COLOR]

Code for Button 2

Code:
[COLOR=#fff0f5][SIZE=2][SIZE=2][FONT=Verdana][COLOR=white][FONT=Verdana]Dim URL AsString = "https://client.hip.live.com/GetHIP/GetHIPAMFE/HIPAMFE?id=15022&mkt=en-US&type=visual&fid=" & RichTextBox1.Text

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Dim filename AsString = "C:\test1.txt"

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]Using wc AsNew WebClient

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]wc.Headers.Add("user-agent", "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.12) Gecko/20101026 Firefox/3.6.12 (.NET CLR 3.5.30729)")

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]wc.DownloadFile(URL, filename)

[/FONT][/COLOR]
[COLOR=white][FONT=Verdana]End Using[/FONT][/COLOR]
[/FONT][/SIZE][/SIZE][/COLOR]

What this does is sends an Webrequest to the site to download the HTML and the HTML is then stored into memory. Next the app runs a regular Expression on that html and parses out just the unqiue key that changes.

Next you send a webrequest to the server using the download code & the key to the server. You are going to choose your download location before hand and the challenge is saved to a .txt file to where ever you choose.

From this part I haven't completed the code BUT you will pretty much rinse and repeat the process. you are going to need to find the key that changes and regex that out of the file, and then find what the final challenge download URL is to be for Hotmail and insert the challenge with the url.

That result will be what you pull into your picture box or to a text file. Returning the result will probably require the challenge key to be part of the response if using a webrequest POST so I would also store that into memory for later when you POST to the server to create the account.
 
Last edited:
You might need to use the previous saved cookies to retrieve the image as well havent tested it but might be needed in order to view the image.
 
Back
Top