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

To consider removing NavigatorUAData.getHighEntropyValues() #1781

Closed
uazo opened this issue Feb 9, 2022 · 16 comments · Fixed by #1869
Closed

To consider removing NavigatorUAData.getHighEntropyValues() #1781

uazo opened this issue Feb 9, 2022 · 16 comments · Fixed by #1869
Assignees

Comments

@uazo
Copy link
Collaborator

uazo commented Feb 9, 2022

Is your feature request related to privacy?

Yes

Is there a patch available for this feature somewhere?

No, but it's trivial

Describe the solution you would like

since even with ua reduction it is possible to obtain the browser version (see https://developer.mozilla.org/en-US/docs/Web/API/NavigatorUAData/getHighEntropyValues) is perhaps better completely remove the method from the idl

Describe alternatives you have considered

removing the method could lead to unmanaged errors in scripts. While it may be fair from a privacy standpoint, we may break some sites.
the alternative is to delete only the uaFullVersion

@csagan5
Copy link
Contributor

csagan5 commented Feb 13, 2022

since even with ua reduction it is possible to obtain the browser version (see https://developer.mozilla.org/en-US/docs/Web/API/NavigatorUAData/getHighEntropyValues)

Hiding the browser version is not a goal of Bromite and it is not possible anyways because of the adblock filters.

the alternative is to delete only the uaFullVersion

The client hint for model was disabled here: https://github.com/bromite/bromite/blob/master/CHANGELOG.md#9304577110

So we could also disable this one, or provide a dummy version.

@uazo
Copy link
Collaborator Author

uazo commented Feb 14, 2022

So we could also disable this one, or provide a dummy version.

perfect, I'll do so.

Hiding the browser version is not a goal of Bromite

ok

is not possible anyways because of the adblock filters.

can you explain to me why?

@csagan5
Copy link
Contributor

csagan5 commented Feb 14, 2022

is not possible anyways because of the adblock filters.

can you explain to me why?

It is possible to verify which ad filters are present by checking what resources do not get loaded. This allows to detect Bromite; it is not a secret and was discussed in multiple places; it is also the reason why Bromite does not try to look like any other browser.

@uazo
Copy link
Collaborator Author

uazo commented Feb 15, 2022

This allows to detect Bromite;

sure, i understand this, but the goal of the reduced ua was to not make people understand what the build version is for any unresolved security flaws?

@csagan5
Copy link
Contributor

csagan5 commented Feb 15, 2022

This allows to detect Bromite;

sure, i understand this, but the goal of the reduced ua was to not make people understand what the build version is for any unresolved security flaws?

Which reduced UA are you referring to, specifically?

@uazo
Copy link
Collaborator Author

uazo commented Feb 16, 2022

Which reduced UA are you referring to, specifically?

w3ctag/design-reviews#640
what are you referring to?

@csagan5
Copy link
Contributor

csagan5 commented Feb 17, 2022

Which reduced UA are you referring to, specifically?

w3ctag/design-reviews#640

Out of the list in https://developer.mozilla.org/en-US/docs/Web/API/NavigatorUAData/getHighEntropyValues model and uaFullVersion should not be provided by Bromite as they are useful for fingerprinting; the adblock filters provide another fingerprinting venue but regardless we should not make it easier by providing model and uaFullVersion.

@miketaylr
Copy link

You could also just always reject the Promise for any high-entropy hints you don't wish to support (or all of them). See step 2 in https://wicg.github.io/ua-client-hints/#getHighEntropyValues

@csagan5
Copy link
Contributor

csagan5 commented Feb 17, 2022

That sounds indeed like the correct way to handle this.

@csagan5
Copy link
Contributor

csagan5 commented Feb 19, 2022

You could also just always reject the Promise for any high-entropy hints you don't wish to support (or all of them). See step 2 in https://wicg.github.io/ua-client-hints/#getHighEntropyValues

I have been checking the Chromium code about this; it currently does not implement any NotAllowedError for the promise, but I expect something will be added once WICG/ua-client-hints#151 is resolved.

Until that I opt for providing fake values, which is consistent with past/current Bromite behavior and should reduce client-side breakage (there is currently no way to say NotAllowedError for a single permission from the array and client-side are following up with Chromium/Webkit until this becomes more stable).

Note: in Chromium the feature policy for client hints has been removed: chromium/chromium@9b85b2a

@miketaylr
Copy link

I have been checking the Chromium code about this; it currently does not implement any NotAllowedError for the promise, but I expect something will be added once WICG/ua-client-hints#151 is resolved.

Yep, that's correct.

@csagan5
Copy link
Contributor

csagan5 commented Mar 6, 2022

@uazo the headers part is now addressed, what is the behaviour of the Javascript side when headers are not provided?
Also: is there anything we should do to address this issue before upstream makes it more granular?

@uazo
Copy link
Collaborator Author

uazo commented Mar 7, 2022

what is the behaviour of the Javascript side when headers are not provided?

about what?

Also: is there anything we should do to address this issue before upstream makes it more granular?

yes, we could return the same version of the header instead of the complete one

@csagan5
Copy link
Contributor

csagan5 commented Mar 7, 2022

Also: is there anything we should do to address this issue before upstream makes it more granular?

yes, we could return the same version of the header instead of the complete one

Ok, let's go with that for now. Do you want to make a PR or shall I?

@uazo
Copy link
Collaborator Author

uazo commented Mar 7, 2022

Ok, let's go with that for now. Do you want to make a PR or shall I?

the first thing I have to do is merge my branch with yours, then I do.
obviously if you want to do it tell me.

@csagan5
Copy link
Contributor

csagan5 commented Mar 7, 2022

Please open a PR for it.

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

Successfully merging a pull request may close this issue.

4 participants