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

Manually-blocked script source shows as null in Shields' Blocked count section #29585

Closed
stephendonner opened this issue Apr 8, 2023 · 4 comments · Fixed by brave/brave-core#17979

Comments

@stephendonner
Copy link

stephendonner commented Apr 8, 2023

Description

Manually-blocked script source shows as null in Shields' Blocked count section

Steps to Reproduce

  1. installed 1.52.23
  2. launched Brave
  3. logged in to facebook.com (yes, sorry, this is a requirement for this issue)
  4. loaded https://apps.facebook.com/wordswithfriends
  5. clicked on the Shields icon in the URL bar
  6. clicked to toggle Block scripts to On / Enabled
  7. clicked on the blocked-count #
  8. clicked Allow beside https://apps.facebook.com
  9. looked at the resulting path(s), under 20 Blocked scripts

Actual result:

null type/value shows up:

Screenshot 2023-04-08 at 12 26 29 AM

example example example example example example
Screenshot 2023-04-08 at 12 26 12 AM Screenshot 2023-04-08 at 12 26 16 AM Screenshot 2023-04-08 at 12 26 22 AM Screenshot 2023-04-08 at 12 26 29 AM Screenshot 2023-04-08 at 12 26 34 AM Screenshot 2023-04-08 at 12 27 01 AM

null application/x-javascript; charset=utf-8;base64,Oy8qRkJfUEtHX0RFTElNKi8KCl9fYW5ub3RhdG9yPWZ1bmN0aW9uKGEpe3JldHVybiBhfSxfX2Rfc3R1Yj1bXSxfX2Q9ZnVuY3Rpb24oYSxiLGMsZCxlKXtfX2Rfc3R1Yi5wdXNoKFthLGIsYyxkLGVdKX0sX19ybF9zdHViPVtdLHJlcXVpcmVMYXp5PWZ1bmN0aW9uKCl7X19ybF9zdHViLnB1c2goYXJndW1lbnRzKX07Ci8vIyBzb3VyY2VVUkw9aHR0cHM6Ly9zdGF0aWMueHguZmJjZG4ubmV0L3JzcmMucGhwL3YzL3lYL3IvUkJDYnp3T0NsU3IuanM/X25jX3g9bkpGMUhzSTcxYkMK

Expected result:

Actual FQDN/script URL

Reproduces how often:

100%

Brave version (brave://version info)

Brave 1.52.23 Chromium: 112.0.5615.49 (Official Build) nightly (x86_64)
Revision bd2a7bcb881c11e8cfe3078709382934e3916914-refs/branch-heads/5615@{#936}
OS macOS Version 13.4 (Build 22F5027f)

Version/Channel Information:

  • Can you reproduce this issue with the current release? No
  • Can you reproduce this issue with the beta channel? Yes
  • Can you reproduce this issue with the nightly channel? Yes

/cc @MadhaviSeelam @spylogsster @rebron @pes10k @bsclifton

@stephendonner stephendonner changed the title Manually blocked script source shows as null in Shields' Blocked count section Manually-blocked script source shows as null in Shields' Blocked count section Apr 8, 2023
@stephendonner stephendonner added feature/shields The overall Shields feature in Brave. feature/shields/!scripts Blocking JavaScript with Shields labels Apr 8, 2023
@stephendonner
Copy link
Author

Also cc @fmarier

@spylogsster spylogsster self-assigned this Apr 8, 2023
@pes10k
Copy link
Contributor

pes10k commented Apr 8, 2023

Guessing this is what happens for scripts w/o sources? If thats the case, it should report the domain / site used for executing the frame (which most, but not all, of the time will just be from document.location)

@kjozwiak
Copy link
Member

The above requires 1.51.95 or higher for 1.51.x verification 👍

@stephendonner
Copy link
Author

Verified PASSED using

Brave 1.51.95 Chromium: 112.0.5615.121 (Official Build) beta (x86_64)
Revision 39cc4e45904ae9f1741c4fbaa866e629c96f2268-refs/branch-heads/5615_51@{#8}
OS macOS Version 11.7.6 (Build 20G1231)

Steps:

  1. installed 1.51.95
  2. launched Brave
  3. logged in to facebook.com (yes, sorry, this is a requirement for this issue)
  4. loaded https://apps.facebook.com/wordswithfriends
  5. clicked on the Shields icon in the URL bar
  6. clicked to toggle Block scripts to On / Enabled
  7. clicked on the blocked-count #
  8. clicked Allow beside https://apps.facebook.com
  9. looked at the resulting path(s), under 20 Blocked scripts

Confirmed there were no longer instances of null for either Allowed or Blocked scripts

example example example example
Screen Shot 2023-04-18 at 2 15 55 PM Screen Shot 2023-04-18 at 2 16 22 PM Screen Shot 2023-04-18 at 2 16 44 PM Screen Shot 2023-04-18 at 2 17 08 PM

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.

6 participants