-
Notifications
You must be signed in to change notification settings - Fork 49
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
[Feature Request] add Cookie option to pass Cloudflare protection #33
Comments
Yeah, I'll try to do something today |
Thanks appreciate it. 🙂 |
Working on ability to add other sources for doijins and choose which one to use per-user in e-hentai branch. In the same update I'm going to add cookies options. I have not decided on how exactly to implement it. |
That would be great. 👍
How about we could reply to cookies.txt file (from the get cookie extension) that bot owner did send with a cmd like
I would appreciate it if only bot-owner could send it sir. We never know what users may send? |
I have been messing about with integrating nhentai to my exhentai/ehentai telegram bot and it's not exactly as easy as a 'Cookie' and off you go. From what i have seen during testing not only does the user agent needs to match the one you got the cookies with, but the IP/Region also needs to match. So this pretty much means you need to host the Bot on the same network that you got the cookies from at the minimum. Another option would be to use something like FlareSolverr . On my local dev setup i had it working , but I host my stuff somewhere else that's when I hit that particular wall. At the end of the day Nhentai mostly reposts what exhentai has, so i abandoned the idea of having Nhentai on my bot. |
So if were to use the bot on a vps, the bot owner could only send the right cookies with a vpn that is setup on the vps right? Since we need the same ip for the cookie to work?
Could you maybe please not abandon but add Nhentai in a different branch for those who want it to use the bot for private usage? İf it is possible sir please? |
Hmm, i suppose that could also work yes. As long as the cookies are used from the same place/ip they were issued at.
I am not part of this project, i was just following it's progress. |
O my bad sorry about that sir. |
Altough this isn't the place to discuss this. Eventually i am. Right now i have a complete stack for it. Bot / Api / Web front end. But since this might be too complicated for most people to setup im reworking my bot so it can be used standalone. |
Hi @trueimmortal, I appreciate your suggestion, I think I have enough RAM, so I will try to install FlareSolverr on my vps. For now, I’m using a mirror site of nhentai. What puzzles me is why they have cloudflare protection even for the /api/ route. |
Haven't got a clue, they got tired of being scraped probably, they don't get any revenue that way. Yeah i also saw you updated the source for an alternative. You also cut down on a lot of features it seems? I still post my stuff to telegraph for now but it can cause issues with larger galleries. I have a setting on it where i cap it at 75 currently. I had users trying to fetch 1000 images galleries lmao |
Hello if you would like to make the bot work with your own cookies you can edit the file nhentai.js like this :
Modify this code with your cookies and user agent (must be the user agent used to get the cookies) |
@jodu75 you can use triple back ticks to insert code in github btw console.Writeline("like this"); |
@sleroq maybe this repo will be useful for you or can you make features scraping my own nhentai api deployed from above repo. thank you:) |
Hi,
Firstly I want to thank you for your great project sir.👍
I'm having the same problem as you mentioned above Here and I would appreciate it if Could you add the
Cookie option
you were talking about?The text was updated successfully, but these errors were encountered: