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

Some Anti devtool scripts redirect to other domain, returning no cookie while challenge is correctly resolved #1000

Open
4 tasks done
FreeOoI opened this issue Dec 11, 2023 · 6 comments
Labels
help wanted Extra attention is needed needs investigation

Comments

@FreeOoI
Copy link

FreeOoI commented Dec 11, 2023

Have you checked our README?

  • I have checked the README

Have you followed our Troubleshooting?

  • I have followed your Troubleshooting

Is there already an issue for your problem?

  • I have checked older issues, open and closed

Have you checked the discussions?

  • I have read the Discussions

Environment

- FlareSolverr version: 3.3.11
- Last working FlareSolverr version: the one that doesn't open devtool
- Operating system: Ubuntu
- Are you using Docker: yes
- FlareSolverr User-Agent : Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
- Are you using a VPN: no
- Are you using a Proxy: no
- Are you using Captcha Solver: no
- URL to test this issue: doesn't matter

Description

If a website use a script like https://github.com/theajack/disable-devtool , it detects devtool window open and redirect to another domain resulting to unwanted values for ->solution (empty solution->cookie is the main problem).

It should keep the last values from the domain challenged or disabling client url redirection if the domain is different from the requested one.

Logged Error Messages

[solution] => 
(
	[url] => https://theajack.github.io/disable-devtool/404.html?h=<url-challenged>
	[status] => 200
	[cookies] => Array
	(
	)

	[userAgent] => Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
)

Screenshots

No response

@ilike2burnthing
Copy link
Contributor

While previously we opened devtools as part of a workaround (9c62410), that was reverted in f7e434c and 22ed3d3, so I don't know what that script is detecting, nor what you mean by the one that doesn't open devtool.

@ilike2burnthing ilike2burnthing added the more information needed Further information is requested label Dec 12, 2023
@FreeOoI
Copy link
Author

FreeOoI commented Dec 12, 2023

Ok, didn't know it was reverted, but this anti devtool detect as if.
Anyway. The important thing is, if a script (like this one) redirect to another domain, it removes values of what we are searching for to be returned (cf cookies / content).
This script can be an anti flaresolverr even if it was not built for.

@ilike2burnthing ilike2burnthing added needs investigation help wanted Extra attention is needed and removed more information needed Further information is requested labels Dec 12, 2023
@pokemaster974
Copy link

Ok, didn't know it was reverted, but this anti devtool detect as if. Anyway. The important thing is, if a script (like this one) redirect to another domain, it removes values of what we are searching for to be returned (cf cookies / content). This script can be an anti flaresolverr even if it was not built for.

Are you sure ? In my case, with latest version (3.3.15) my DevTools is always open (headless=false) :
image

@ilike2burnthing
Copy link
Contributor

800866d

@pokemaster974
Copy link

800866d

Do we have possibility to manually not adding the argument --auto-open-devtools-for-tabs (without changing the utils.py of course) ?
Because it seems that this fix @tadasgedgaudas focuses the windows almost every new POST request and I can't use my computer at the same time. With this option, I will try if FS could success or not to pass CF without the devtools opened.

If needed to open a new issue about this, I will open.

@ilike2burnthing
Copy link
Contributor

You can revert to the last release, but it's basically non-functional. Otherwise, just don't run as headless=false.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed needs investigation
Projects
None yet
Development

No branches or pull requests

3 participants