Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Brave UA whitelist only applies to top level page loads #10800

Closed
kjozwiak opened this issue Sep 5, 2017 · 1 comment · Fixed by #10904
Closed

Brave UA whitelist only applies to top level page loads #10800

kjozwiak opened this issue Sep 5, 2017 · 1 comment · Fixed by #10904

Comments

@kjozwiak
Copy link
Member

kjozwiak commented Sep 5, 2017

Test plan

#10904 (comment)


- Did you search for similar issues before submitting this one?

Yes

- Describe the issue you encountered:

Brave's UA whitelist only applies to top level page loads and not sub resources. I believe it's this line in the code:

https://github.com/brave/browser-laptop/blob/master/js/data/siteHacks.js#L46

- Platform (Win7, 8, 10? macOS? Linux distro?):

macOS 10.12.16 x64 - Reproduced
Win 10 x64 - Reproduced

- Brave Version (revision SHA):

Brave: 0.18.26
rev: 67f2568
Muon: 4.3.15
libchromiumcontent: 60.0.3112.101

- Steps to reproduce:

  1. load adobe.com within Brave
  2. open the developer tools via "option + command + I"
  3. select the "Network" tab and reload adobe.com via "command + r"
  4. select on the first resource and you'll notice the correct Brave Chrome/60.0.3112.101 UA
  5. select another resource that's underneath the first one and is from Host:www.adobe.com

You'll notice that the incorrect UA is being used.

- Actual result:

Only the first resource (top level) is correctly using the UA.

- Expected result:

The correct UA should be applied to every resource that's from the whitelist domain.

- Will the steps above reproduce in a fresh profile? If not what other info can be added?

Yes

- Is this an issue in the currently released version?

#10614 was supposed to fix this issue, however it only partially fixed the problem.

- Can this issue be consistently reproduced?

Yes

- Screenshot if needed:

Correct Example:

good

Incorrect Example:

bad

- Any related issues:

#10614

@kjozwiak kjozwiak added this to the 0.20.x (Developer Channel) milestone Sep 5, 2017
@diracdeltas diracdeltas self-assigned this Sep 11, 2017
diracdeltas added a commit that referenced this issue Sep 11, 2017
fix #10800

Test Plan:
load adobe.com within Brave
open the developer tools via "option + command + I"
select the "Network" tab and reload adobe.com via "command + r"
select on the first resource and you'll notice the correct Brave Chrome/60.0.3112.101 UA
select another resource that's underneath the first one and is from Host:www.adobe.com
the Brave UA should be there
@LaurenWags
Copy link
Member

Verified on MacOS:
screen shot 2017-12-20 at 2 49 40 pm

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.