-
Notifications
You must be signed in to change notification settings - Fork 53
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
Useragent spoof for navigator.userAgent #340
Comments
The link explains a way to modify the UA in the navigator object.
Moreover, the original Firefox browser seems to return different values in HTTP headers and the navigator object. Maybe return different values in the spoof as well to make the spoof more effective? |
@h6a8ke1k The userAgent property should automatically be spoofed by Firefox based on the headers. I can manually overwrite this property but I'm not sure why there are two different user agents present. Both values are the same for me on Linux + FF75 & FF76 and Windows 7 + FF 68. |
Sorry for the inaccurate information. For a clean firefox browser, the UA in HTTP headers and navigator object is the same, which is the following value: However, if I enable Chameleon and select "Real Profile", the navigator object UA does not change, but the HTTP header changes to: Also, I confirmed that changing to a different profile only changes the UA in HTTP headers, the navigator object always contains the real UA, at least in Firefox 68 ESR with Win10 x64. So I think overriding However, there are many ways to change the userAgent property in the navigator object (in the link I provided), and Thank you! |
Support needs to be added for the following User Agent detection methods if possible:
|
@Iquaridys, those properties are already spoofed. You can verify that by checking https://browserleaks.com/javascript. @h6a8ke1k I believe this bug is actually caused by the resist fingerprinting option. Can you check your settings to see if that's enabled? When it's enabled and you're using your real profile, Firefox spoofs the user agent in the header to There's also another issue. When resist fingerprint is enabled and spoofing a browser profile, the navigator properties are spoofed but the userAgent property persists when resist fingerprint is enabled. Overwriting that property should fix this. |
@sereneblue Thank you for your solution! That is exactly the reason. If I disable Chameleon and enable "resist fingerprinting" alone in However, I think the resist fingerprinting option by Firefox is very useful. It can effectively prevent canvas fingerprinting and lower the timer precision slightly. I will leave it on. I am not sure if there are better solutions. But thank you anyway for finding the reason! |
@h6a8ke1k I agree, resist fingerprint is useful to have. v0.20.3 will overwrite the navigator userAgent property when a browser profile is spoofed so you can still use profiles. However, if the real profile is selected, it's probably best to leave it alone so that it can mimic Firefox original behavior. |
Prerequisites
Please use issues for bugs only! Answer the following questions for yourself before submitting an issue: YOU MAY DELETE THE PREREQUISITES SECTION.
Expected Behavior
The useragent changed both in HTTP headers and navigator object through JavaScript after UA spoof.
Current Behavior
The navigator object contains real useragent through
navigator.userAgent
.Relevant settings
Context (Environment)
Firefox 68 ESR
The text was updated successfully, but these errors were encountered: