Failed to connect to the WISPr client

I am trying to make a WISPr client. For this, I read the WISPr 1.0, 1.2, and 2.0 specifications.

Given the 1.0 WISPr client, I analyzed LoginURL on the login page in hotspot and tried to execute an authentication request (login = test, password = pass):

 POST : http://hotspot.server.com/login Parameters : button=Login&UserName=test&Password=pass&FNAME=0&OriginatingServer=http://www.google.com 

My credentials are good because I use them through the HTML form of the web page.

With an HTTP POST request, authentication was always failing:

 <AuthenticationReply> <MessageType>120</MessageType> <ResponseCode>100</ResponseCode> <ReplyMessage>Authentication Failure</ReplyMessage> </AuthenticationReply> 

I tried with different access points of other networks with other good credentials.

Do you have an idea when my error occurs in my authentication request?

+4
source share
2 answers

Try using GET. it worked for me

+3
source

In the past, I have used some WISPr client tools, and this seems rather strange, at least from the data provided. The best approach I would suggest is to use Wireshark to capture the login session traffic through the browser and compare it with the session processed by your code. If the browser also uses POST for missing headers, garbled data, etc. If the browser actually uses GET, you should try to stick with this scenario as suggested. Perhaps the hotspot supports only one kind of method, for example. notification. However, without the details of Wireshark, it's hard to guess. Also remember that there are some differences between WISPr 1.0 and WISPr 2.0, and you did not specify which version of the hotspot you are entering.

+1
source

Source: https://habr.com/ru/post/1498853/


All Articles