-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
auth接口返回400 #92
Comments
Same here, started getting this error today.
Username and password are correct. |
I am seeing this exact error as well |
every projects I know (include myself's) that based on this auth api have the same problem so I think it probably not my problem but api's |
Yeah, looks like something will need to be updated to be compliant with whatever changed in the API. Hopefully it's nothing too difficult. |
验证的时候生成的X-Client-Hash和X-Client-Time不匹配,改一下local_time的格式就好啦(w change this: Line 84 in 0ca6d74
to local_time = datetime.utcnow().strftime( '%Y-%m-%dT%H:%M:%S+00:00' ) 相关细节 对 pixiv_v5.0.166 进行反编译 在 String format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZZZZZ", Locale.US).format(new Date());
StringBuilder sb = new StringBuilder();
sb.append(format);
sb.append("28c1fdd170a5204386cb1313c7077b34f83e4aaf4aa829ce78c231e05b0bae2c");
Request build = chain.request().newBuilder().addHeader(C3376a.HEADER_USER_AGENT, C4419d.f15143a).addHeader("Content-Type", "application/x-www-form-urlencoded;charset=UTF-8").addHeader(str2, Locale.getDefault().toString()).addHeader("App-OS", C3376a.ANDROID_CLIENT_TYPE).addHeader(str3, VERSION.RELEASE).addHeader("App-Version", "5.0.166").addHeader("X-Client-Time", format).addHeader("X-Client-Hash", C4469d.m14047a(sb.toString())).build(); 在 PixivOAuthResponse b = C4425h.m13976a(C4425h.f15154f).mo22048b("MOBrBDS8blbauoSck0ZfDbtuzpyT", "lsACyCD94FhDUtGTXi3QzcFE2uU1hqtDaKeqrdwj", "password", str2, password, ((C5687a) this.f13877b.mo24141a()).mo23205a(), true, true); 在 PixivOAuthResponse mo22048b(@C6525c(mo25561a = "client_id") String str, @C6525c(mo25561a = "client_secret") String str2, @C6525c(mo25561a = "grant_type") String str3, @C6525c(mo25561a = "username") String str4, @C6525c(mo25561a = "password") String str5, @C6525c(mo25561a = "device_token") String str6, @C6525c(mo25561a = "get_secure_url") boolean z, @C6525c(mo25561a = "include_policy") boolean z2); Auth Header为(暂时没有Android设备,用iOS做了测试)
Auth body为
|
emm等于说p站重新设置了X-Client-Time的格式吗emmm,这理由还蛮汗的(x |
see @Mikubill 's answer, you can change the code that generate the |
I haven't been able to access pixiv for about 12 hours with the following error message (When started with VSCODE). Please take care of it as soon as possible.
|
Merged #93 . Try install master from source to fix this git clone https://github.com/upbit/pixivpy.git
cd pixivpy/
pip uninstall pixivpy
pip install . |
read replies above, this problem has been solved |
Sorry for the late reply, please update to v3.5.1 to resolve this issue. |
说起来反编译时候是怎么解决混淆问题的...我反编译之后得到的都是一大堆混淆过的class |
吃饭前还好好的,吃饭后突然就变成400了
返回结果:
The text was updated successfully, but these errors were encountered: