Opened 8 months ago

Closed 6 months ago

Last modified 4 months ago

#6619 closed defect (fixed)

Element hiding emulation injects incorrect CSS selector for :-abp-properties() when the selector in the document's style sheet is a compound selector

Reported by: mjethani Assignee: mjethani
Priority: P2 Milestone:
Module: Core Keywords: circumvention
Cc: kzar, hfiguiere, arthur, Ross, amrmak Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Ross Verified working: yes
Review URL(s):

https://codereview.adblockplus.org/29760699/

Description (last modified by kzar)

Environment

ABP 3.0.3 on Chrome 66

How to reproduce

  1. Browse to https://static.kzar.co.uk/6619-test.html
  2. Add this filter: static.kzar.co.uk#?#div:-abp-properties(font-weight: bold;)
  3. Refresh the page

Observed behaviour

Both divs (div#foo and div#bar) should be hidden.

Expected behaviour

Only div#foo is hidden.

Notes

This doesn't work because the element hiding emulation code adds the prefix div to the selector body #foo so we get divbody #foo.

Change History (13)

comment:1 Changed 8 months ago by mjethani

  • Summary changed from Element hiding emulation injects incorrect selector for :-abp-properties when the selector in the document's style sheet is a compound selector to Element hiding emulation injects incorrect CSS selector for :-abp-properties() when the selector in the document's style sheet is a compound selector

comment:2 Changed 8 months ago by mjethani

I'm not sure how we can address this by the way but it seems like something that should work. I'm hoping we can use more element hiding emulation filters to defeat circumvention where standard CSS doesn't work.

comment:3 Changed 8 months ago by arthur

  • Cc arthur added

comment:4 Changed 8 months ago by Ross

  • Cc Ross added

comment:5 Changed 8 months ago by mjethani

  • Sensitive set

comment:6 Changed 8 months ago by mjethani

  • Review URL(s) modified (diff)

comment:7 Changed 8 months ago by amrmak

  • Cc amrmak added

comment:8 Changed 7 months ago by kzar

  • Description modified (diff)
  • Priority changed from Unknown to P2
  • Ready set

comment:9 Changed 6 months ago by abpbot

comment:10 Changed 6 months ago by mjethani

  • Owner set to mjethani

comment:11 Changed 6 months ago by mjethani

  • Resolution set to fixed
  • Status changed from new to closed

comment:12 Changed 4 months ago by Ross

  • Tester changed from Unknown to Ross
  • Verified working set

Fixed.

ABP 3.2.0.2103
Chrome 68 / 55 / 49 / Windows 10
Firefox 61 / 55 / 51 / Windows 10

comment:13 Changed 4 months ago by sebastian

  • Sensitive unset
Note: See TracTickets for help on using tickets.