genshin.py
genshin.py copied to clipboard
Add cn tests
I have cn cookies but I still probably cannot fix issues with cn unless someone tells me how. Dunno how useful it would be.
It is now very difficult to test on cn because the cn api now has captcha. If the server determines any abnormal behavior on an account, most apis will be unusable and return 1034 status code (which requires passing geetest). and even if it passes the captcha, the normal status only last about half a day.
We currently don't know how "abnormal behavior" is defined. But we may be able to reduce the chance of running into the issue by:
- using the latest DS_SALT and User-Agent, and
- reduce the frequency of sending request to their API
I don't think it is practical to actually defeat geetest automatically.
Btw I have found an interesting header(X-Rpc-Device_id
) in mobile hoyolab application.
I believe this header is somehow related to abnormal traffic detection, which we don't send this header at all.
It might be a decent idea to add a bunch of non-essential query parameters and headers provided they are explicitly shown as non-essential in the code.