Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#573 closed defect (fixed)

Relative URLs aren't blocked in Safari

Reported by: sebastian Assignee: sebastian
Priority: P1 Milestone: Adblock-Plus-1.8.3-for-Chrome-Opera-Safari
Module: Platform Keywords:
Cc: smultron45@… Blocked By:
Blocking: Platform:
Ready: yes Confidential: no
Tester: Verified working: no
Review URL(s):



Safari 7

How to reproduce

Go to a website that uses relative URLs for resources that are supposed to be blocked.

For example:
Where following script is blocked by EasyList Germany: /tvtotal/includes/js/avt.js

Observed behaviour

Despite the filter ||^*/avt.js in Easy List Germany the scripts still loads and shows a preroll ad. That is because the code in the beforeload event handler assumes that the URL is always absolute, and ignores URLs that don't start with "http(s):".

Expected behaviour

Resources using relative URLs must also be blocked. Therefore the relative URL must be joined with the document's URL, to generate an absolute URL used for filter matching.

Change History (4)

comment:1 Changed 6 years ago by sebastian

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:2 Changed 6 years ago by mapx

  • Cc smultron45@… added

comment:3 Changed 6 years ago by sebastian

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

comment:4 Changed 6 years ago by sebastian

  • Ready set
Note: See TracTickets for help on using tickets.