You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 10, 2024. It is now read-only.
We use aggressive cosmetic filtering in iOS. In order to make it non-aggressive we need to add a 1st party check on element urls. Currently the check in hard coded to return false except for some small edge cases like relative URLs. The difficulty in doing this is we have to do it asynchronously as we need to talk back to iOS to do a proper etld+1 check.
The idea is to
Add a mutation observer that looks for images and videos
Every time it gets one, extract the domain for it, and pass it async to iOS to get a yes/no isFirstParty value
Keep track of all the answers you’ve gotten for the current page in a Brave maintained Map
Check that map in the cosmetic filtering isFirstParty function
Re-check ads where isFirstParty() returns false every time you get a new answer from 2
Description:
We use aggressive cosmetic filtering in iOS. In order to make it non-aggressive we need to add a 1st party check on element urls. Currently the check in hard coded to return
false
except for some small edge cases like relative URLs. The difficulty in doing this is we have to do it asynchronously as we need to talk back to iOS to do a proper etld+1 check.The idea is to
isFirstParty
valueisFirstParty
functionisFirstParty()
returns false every time you get a new answer from 2Once this is done we need to remove the temporary exception we have added to https://github.com/brave/adblock-lists/blob/master/brave-lists/brave-ios-specific.txt
The text was updated successfully, but these errors were encountered: