Determining the Browser Operating Environment

Asked 1 years ago, Updated 1 years ago, 90 views

I would like to log in to a service using Python from the program.
However, it is skipped to the page "Operating environment is not covered".
The same thing happens when you disguise the User-Agent.
Is there anything else that determines the environment other than the User-Agent?
All necessary information is sent via POST.
By the way, the address to which the request will be sent is a .jsp file.
The data I am sending is Userid, password, UserId is an 8 digit number, and password is an 8 alphanumeric character.
By the way, I don't know how this service is implemented.
Status returns 200 OK.


import urllib.request
import urllib.parse

post_data={"UserId":12345678, "Password": "password"}
encoded_data=urllib.parse.urlencode(post_data).encode()
requ=urllib.request.Request("http://example.com/login", 
                             encoded_data,
                             headers={"User-Agent": "Mozilla/5.0 (Windows NT 6.3; Trident/7.0; rv:11.0)like Gecko"})
res=urllib.request.urlopen(req)
res_read=res.read().decode("shift-jis")#res_read contains the character "Operational Environment Not Included".

The operating environment required is as follows:

Windows Vista SP2 or higher
·Internet Explorer 7
·Internet Explorer 8
·Internet Explorer 9
·Google Chrome

Windows 7 ·Internet Explorer 8
·Internet Explorer 9
·Internet Explorer 10
·Internet Explorer 11
·Google Chrome

Windows 8 (Desktop UI)
·Internet Explorer 10

Windows 8.1 (Desktop UI)
·Internet Explorer 11

Mac OS X 10.6 ·Safari 5.1.7

Mac OS X 10.7 ·Safari 5.1.7

python http jsp

2022-09-30 20:34

1 Answers

Is there anything else that determines the environment other than the User-Agent?

UA is often sufficient for only that you want to determine your browser or operating system, but that doesn't necessarily mean you get an "operational environment not covered" error.

Therefore, there are many possible places that can cause errors, and the information you have provided so far does not tell you exactly what it is.

As long as you don't know how it's implemented, the communication you made when you were able to log in with your browser is the best reference.You'll be peeping into this with a variety of tools.

  • Browser Debugging (Developer Tool Network Tab in Chrome)
  • Debugging proxy such as Fiddler
  • Packet capture tools such as Wireshark

I think that would be a common answer, but in my personal imagination...

It's not safe to POST only with your ID and password even though you're on the login screen, so I don't think there are enough parameters to POST. Is there any HTML description like <input type="hidden">?I heard that cookies also include session IDs.


2022-09-30 20:34

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.