Skip to content
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

Login Issues - December 2022 #1209

Open
PerseusRex opened this issue Dec 16, 2022 · 108 comments
Open

Login Issues - December 2022 #1209

PerseusRex opened this issue Dec 16, 2022 · 108 comments
Labels

Comments

@PerseusRex
Copy link

PerseusRex commented Dec 16, 2022

Description

Can't login, receiving this error
pixiv

I already tried changing password, updating cookies, and changing useragent.

@Revemohl
Copy link

Revemohl commented Dec 16, 2022

Reporting to say that I just got it too. Having no issues with pixiv itself on my browser.

@RighteousAnger
Copy link

Glad I'm not the only one, tried inputting cookies values from Chrome and Firefox, it gives the same error. Can log in just fine on both browsers.

@criperro
Copy link

Same here, updated my password, PHPID and useragent still having the issue

@Hecatom
Copy link

Hecatom commented Dec 16, 2022

Same.
Question, do you use vpns or does the problem happen by trying to login normally with the app?

@xlibun
Copy link

xlibun commented Dec 16, 2022

there's a pinned issue stating that matching the useragent with the browser's might help
tho it may just be an issue because pixiv has introduced something

@xlibun
Copy link

xlibun commented Dec 16, 2022

okay, adjusting useragent and changing password with cookie didn't work at all. pixiv did something for sure

@Revemohl
Copy link

there's a pinned issue stating that matching the useragent with the browser's might help tho it may just be an issue because pixiv has introduced something

Changed my password and did everything the wiki suggested but it didn't work either, hopefully this can be figured out soon enough.

@xlibun
Copy link

xlibun commented Dec 16, 2022

Looks like this is what happened today https://www.pixiv.net/info.php?id=8986

doesn't look like this would be the cause, but anyway

@sgghostrider
Copy link

Probably pixiv updated their webpage/services and broke the utility, it was working fine several hours ago, it just suddenly stopped working overnight, so an update with a fix is required to adapt it to the changes i suppose... 😞

@Soonbum
Copy link

Soonbum commented Dec 16, 2022

Oh, I saw this issue too.

@524144
Copy link

524144 commented Dec 16, 2022

Same here
Error at doLogin(): (<class 'mechanize._response.get_seek_wrapper_class..httperror_seek_wrapper'>, <httperror_seek_wrapper (urllib.error.HTTPError instance) at 0x38a66a0 whose wrapped object = <HTTPError 403: 'Forbidden'>>, <traceback object at 0x0389E488>)
Cannot Login!
I followed https://github.com/Nandaka/PixivUtil2/wiki#pixiv-login-using-cookie and changed my password, updating cookies, etc and still doesn't work.
I also tried switching from chrome to firefox, updated my cookies and nope, the same.
like, what on earth is happening...

@gnarf1975
Copy link

Same here....

@shinji257
Copy link

shinji257 commented Dec 16, 2022

Was just getting ready to come here and report the same. Had to kill it since link to network drive went down and I didn't want it throwing a ton of errors client side. Finally fixed that and the app wouldn't login again even after updating user agent and cookies. Good to know I'm not alone.

Looks like cloudflare getting in the way. May be temporary (sometimes it is).
https://gist.github.com/shinji257/2bff4ae230322ee44debc32f87708057
https://gist.github.com/shinji257/3151d94ad8f17f6200a03406e7ca6539

header: Server: cloudflare
header: CF-RAY: 77a927a4fb612004-IAD

@beathero
Copy link

Same issue here, I hope it's fixed soon :(

@anonymous721
Copy link

For what it's worth, gallery-dl is still capable of downloading from Pixiv, including login authentication. Hopefully that implies that a fix here will be relatively straightforward.

@shinji257
Copy link

This was discussed in #814 as well.

@cocokakao
Copy link

still???

@southernbear
Copy link

southernbear commented Dec 17, 2022

I tried the curl command below and got 200:

curl 'https://www.pixiv.net/' --output - -I -H 'Cookie: PHPSESSID=your_sesson' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:108.0) Gecko/20100101 Firefox/108.0' -H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8' -H 'Accept-Language: zh-TW,zh-CN;q=0.8,zh;q=0.7,en-US;q=0.5,en;q=0.3,ja;q=0.2'

and capture packets then I found curl use HTTP/2 and we still use HTTP/1.1

When I add --http1.1 to curl, it return 403.

Note: Accept-Charset need to be replaced with Accept-Language or you will get 403.


Edit: It seems need Accept to work.

@pablotron8
Copy link

Oh no! Same issue here...

@hatabbich
Copy link

oh... glad that it not my stuff only, was ready to reinstall Win already :D

@TechnoMasterBoy
Copy link

TechnoMasterBoy commented Dec 17, 2022

I'm also getting the same issue. I thought it was because I was using outdated version pixivutil20211104
But then I updated to pixivutil20221029 (Latest as of right now) and the issue was still there.

@ytoaa
Copy link

ytoaa commented Dec 17, 2022

This issue is not resolved

@Nandaka
Copy link
Owner

Nandaka commented Dec 17, 2022

see #814, I don't plan to fix the login as cookie method is working.
I do accept Pull Request if someone know how to do it.

EDIT: looks like due to Cloudflare http/2, I have no idea how to bypass it beside using proxy for now

@Hamuko
Copy link
Contributor

Hamuko commented Dec 17, 2022

The cookie method is working?

@skulkexpert
Copy link

The cookie method is definitely not working for me. I get the same problem as in the image posted by OP.

@TechnoMasterBoy
Copy link

see #814, I don't plan to fix the login as cookie method is working. I do accept Pull Request if someone know how to do it.

No it doesn't... I've tried with and without cookies, aswell as with and without useragent, same exact error as OP.

@KuroChloe
Copy link

KuroChloe commented Dec 17, 2022

Reporting in too, getting this error and nothing gets rids of it. Did whole dance with password change and stuff, no dice.
Everything worked fine yesterday.

@anonymous721
Copy link

The cookie method is exactly what I've been using and it is not working.

@MarqFJA87
Copy link

MarqFJA87 commented Dec 17, 2022

Same for me. I've already been using the cookie method for what's seemingly forever, and now it's stopped working.

I should also note that the OP had clearly stated that the cookie method wasn't working for them, and several early replies reported the same problem.

Currently making do with gallery-dl until this is fixed.

@Nanoka
Copy link

Nanoka commented Dec 17, 2022

see #814, I don't plan to fix the login as cookie method is working. I do accept Pull Request if someone know how to do it.

Neither of the PHPSESSID value alone or the full cookie string works.
However removing the "ID_" from PHPSESSID in either of these will result in a "Login successful." message, followed by the "Unable to get User Id, please check your cookie." error, so I don't really know if its a successful login or just a mistake from the program.
Yes that is a mistake from the program and any invalid cookie will return that.

@AgentThirteen
Copy link

AgentThirteen commented Dec 20, 2022

With the plethora of 5xx errors that preceded the changes, it was predictable there was some kind of panic or mass bot activity that forced pixiv to take action.

@Nandaka 2fe5bb1 does not work with pixiv here, it fatals immediately with:

Traceback (most recent call last):
  File "pixivutil2.py", line 1772, in <module>
    main()
  File "pixivutil2.py", line 1626, in main
    __br__ = PixivBrowserFactory.getBrowser(config=__config__)
  File "PixivBrowserFactory.py", line 1304, in getBrowser
    _browser = PixivBrowser(defaultConfig, defaultCookieJar)
  File "PixivBrowserFactory.py", line 114, in __init__
    cookies = (dict(i.split('=', 1) for i in self._config.cookie.split('; ')))
ValueError: dictionary update sequence element #0 has length 1; 2 is required

Any cookie changes to config.ini required? Thank you.

edit: b65b3f6 works fine without touching User-Agent (from master branch).

edit 2: thanks Nandaka, I now used the entire curl cookie string and it seems to work fine. I haven't tested fanbox because I stopped supporting everyone after the problem showed up. Verbose information:
200 return url 200 200 200 Skipped getting remote file size because local file not exists Start downloading... 200 Download done

@Nandaka
Copy link
Owner

Nandaka commented Dec 20, 2022

ah, need to paste the full cookie string, not only the session id.
image

@bluerthanever
Copy link
Contributor

@bluerthanever wont it fix the HTTP/2 issue, as far as I know this is part of cloudflare feature?

it's also based on python, and i don't see any http2 modules or anything that says it supports http2....
so i guess it's not about http2?

i tried it this afternoon with fiddler and it worked.

@Hamuko
Copy link
Contributor

Hamuko commented Dec 20, 2022

API endpoints might have less strict Cloudflare protections than non-API endpoints.

@Nandaka
Copy link
Owner

Nandaka commented Dec 20, 2022

yeah, in my current place, I got cloudflare security check when I visiting pixiv, so I need to use cloudscraper module to bypass it, else I might use httpx module for HTTP/2 support.

@gnarf1975
Copy link

gnarf1975 commented Dec 20, 2022

I've just tried . Deleted Cookies, new Login. Now all of a sudden it works again.

2022-12-20

@Hamuko
Copy link
Contributor

Hamuko commented Dec 20, 2022

Same for me. Downloading files right now. Haven't done anything to my local environment. Guessing it's a configuration change with Pixiv/Cloudflare.

@DarkKuroi
Copy link

Suddenly it works again. I only refresh cookie in ini file 4 days ago (it won't helped) and just waited 4 days. Din't do anything else.

@Revemohl
Copy link

Revemohl commented Dec 20, 2022

Didn't suddenly start working here though, neither with my old password/cookie nor with the ones I just got.
[EDIT] Refreshing my config.ini seems to have made it work. Maybe it just didn't like me trying to use a different useragent?

@MarqFJA87
Copy link

It's working for me again, and I haven't changed a single thing in my settings or files. I guess Pixiv has downgraded their Cloudflare security setting to the previous normal.

@TechnoMasterBoy
Copy link

Works here too all of a sudden.

@biggestsonicfan
Copy link
Contributor

Wtf is pixiv doing, lol

@QPUNeptune
Copy link

ayyy lmao it really works again bruh

@KamenReader
Copy link
Contributor

KamenReader commented Dec 21, 2022

@KamenReader can you also check https://github.com/Nandaka/PixivUtil2/tree/http2 branch with fanbox? At least the pixiv side is working so far.

Tried out the http2 branch. Looks like it's being blocked by Cloudflare version 2, which cloudscraper doesn't work with. I've attached the log.
pixivutil.log

This problem, even if it seems to be working again for some people, seems to perfectly mirror an issue that gallery-dl had with Patreon, right down to the "suddenly working again" and going "back to not working" (and various people reporting sucess with proxies and others having no success with proxies, etc.): gallery-dl Issue #1922 It's marked as fixed now, but I don't know that it ever really was "fixed" entirely. An alternative downloader for Patreon, https://github.com/AlexCSDev/PatreonDownloader, uses a small Chromium instance to complete the Cloudflare Captcha challenge. Something similar may be required here.

Edit: @anonymous721 mentioned earlier that gallery-dl is still working for Pixiv in general. Looks like they're using an OAuth token, just like Fanbox uses in PixivUtil2 in its workaround, so using OAuth for Pixiv in general is probably unavoidable.

@baraghiffari
Copy link

Can confirm, it's working again suddenly without doing anything after the last one

@shinji257
Copy link

@KamenReader can you also check https://github.com/Nandaka/PixivUtil2/tree/http2 branch with fanbox? At least the pixiv side is working so far.

Tried out the http2 branch. Looks like it's being blocked by Cloudflare version 2, which cloudscraper doesn't work with. I've attached the log. pixivutil.log

This problem, even if it seems to be working again for some people, seems to perfectly mirror an issue that gallery-dl had with Patreon, right down to the "suddenly working again" and going "back to not working" (and various people reporting sucess with proxies and others having no success with proxies, etc.): gallery-dl Issue #1922 It's marked as fixed now, but I don't know that it ever really was "fixed" entirely. An alternative downloader for Patreon, https://github.com/AlexCSDev/PatreonDownloader, uses a small Chromium instance to complete the Cloudflare Captcha challenge. Something similar may be required here.

Edit: @anonymous721 mentioned earlier that gallery-dl is still working for Pixiv in general. Looks like they're using an OAuth token, just like Fanbox uses in PixivUtil2 in its workaround, so using OAuth for Pixiv in general is probably unavoidable.

Yup. I remember the issue with PatreonDownloader but I kind of figured that this was some kind of bot protect that triggered and they were flagging all the connections for a while. Even still we should probably setup some kind of fallback for Pixiv to go and use OAuth when the standard login flow fails or in situations where it gets a 403 error.

@beathero
Copy link

Just checked, it's working for me again too.

@NamelessDummy
Copy link

Sadly, It's still not working for me currently.

@hehequya
Copy link

any one know how to fix this: <HTTPError 429: 'Too Many Requests'>>

@PatrickL546
Copy link
Contributor

@hehequya Just slow down the download, downloadDelay = 5 or more

Nandaka pushed a commit that referenced this issue Jan 2, 2023
* Added mkv ugoira packing without encoding

* Add back 'temp fix? #1209' commit

* Update PixivBrowserFactory.py

* Update PixivBrowserFactory.py

* Update readme

* Update readme.md

* Update readme.md

* Added mkv params to make it usable with args

Update readme.md

* Update readme.md
@Nandaka Nandaka added the Monitor label Jan 2, 2023
@Nandaka
Copy link
Owner

Nandaka commented Jan 2, 2023

Looks like it works again using master branch for me.

@Nandaka Nandaka changed the title Login Issues Login Issues - December 2022 Jan 2, 2023
@Nandaka Nandaka mentioned this issue Jan 2, 2023
@PatrickL546
Copy link
Contributor

@Nandaka Will This be reverted? I've been using the release before that and when login worked again, never had a problem.

@Nandaka
Copy link
Owner

Nandaka commented Jan 2, 2023

well, I don't see any differences so I think I'll leave it there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests