Blocking image with # in URL

Various discussions related to filter list maintenance

Moderator: njones

Blocking image with # in URL

Postby blockyblocky » Thu Feb 16, 2017 12:25 am

Hello,

I'm trying to add a custom rule to block images from an URL that looks like this:

||googleusercontent.com/proxy/<randomjunk>#<randomjunk><keyword><randomjunk>

I tried a few things including:

||googleusercontent/*keyword
||googleusercontent/proxy/*^*keyword

But I'm not having any luck. It seems like everything beyond the "#" is being ignored by AdBlock during the substring search. Is there an option to get access to the entire URL including the "intra-document" bookmark or link?

Thanks for any guidance.
blockyblocky
 
Posts: 5
Joined: Thu Feb 16, 2017 12:20 am

Re: Blocking image with # in URL

Postby mapx » Thu Feb 16, 2017 12:30 am

- provide an example page, explaining what do you want to block
- "allow some non intrusive advertising" is ON or OFF ?
User avatar
mapx
 
Posts: 20305
Joined: Thu Jan 06, 2011 3:01 pm

Re: Blocking image with # in URL

Postby blockyblocky » Thu Feb 16, 2017 12:46 am

The URL is incredibly long since its a google proxy image. But in particular it's a mailtrack.io signature for tracking when email is opened/loaded.

It looks like:

Code: Select all
https://ci4.googleusercontent.com/proxy/nYHC0Y6wjpp3us9QdVGymuqsjgPyobU6uTI5djEqn9PXuni4fzFP9WZdFwBs9A_EHD2Gr8g5loeOtftX92dkhl87ElPsQVjLaZ_1sQONR9_YJyBQJPnDfg89y62mSHN3NT9eGwO_nYOjAM3t=s0-d-e1-ft#<some identifying information plus the mailtrack.io url here>


It's that trailing identifying info I would like to use in my filter but everything past the "#" seems to be truncated when performing the match. For instance, going to the AdBlock tab in the chrome inspection window and using the "block this" button just adds the URL up to the pound sign to my custom filter list.
blockyblocky
 
Posts: 5
Joined: Thu Feb 16, 2017 12:20 am

Re: Blocking image with # in URL

Postby smed79 » Thu Feb 16, 2017 12:56 am

Should work

Code: Select all
||googleusercontent.com/proxy/*mailtrack.io$image


Reply to the second question of mapx :

"allow some non intrusive advertising" is ON or OFF ?
User avatar
smed79
 
Posts: 1221
Joined: Fri Jan 15, 2010 12:51 am
Location: EasyList Forum

Re: Blocking image with # in URL

Postby blockyblocky » Thu Feb 16, 2017 1:01 am

Oops, missed that second part. Yes, the "Allow some non-intrusive advertising" is currently ON. I'll try your suggestion and report back. Thanks.
blockyblocky
 
Posts: 5
Joined: Thu Feb 16, 2017 12:20 am

Re: Blocking image with # in URL

Postby mapx » Thu Feb 16, 2017 1:08 am

try disabling "allow some ..." and test again using one of your first filters
User avatar
mapx
 
Posts: 20305
Joined: Thu Jan 06, 2011 3:01 pm

Re: Blocking image with # in URL

Postby blockyblocky » Thu Feb 16, 2017 1:09 am

So this did not work:
||googleusercontent.com/proxy/*mailtrack.io$image

This does but has the side effect of blocking a lot of images I would rather load:

||googleusercontent.com/proxy/

I tried turning off the "Allow some non-intrusive advertising" but that does not change the behavior. From my black box observation, it seems like the data past the # is ignored. Here is the raw URL in its entirety:

Code: Select all
<img width="0" height="0" class="m_8426399240988564322mailtrack-img gmail_msg" src="https://ci4.googleusercontent.com/proxy/nYHC0Y6wjpp3us9QdVGymuqsjgPyobU6uTI5djEqn9PXuni4fzFP9WZdFwBs9A_EHD2Gr8g5loeOtftX92dkhl87ElPsQVjLaZ_1sQONR9_YJyBQJPnDfg89y62mSHN3NT9eGwO_nYOjAM3t=s0-d-e1-ft#https://mailtrack.io/trace/mail/90666113e742debc407fd183eac2573bfa8bb738.png?u=1003006">


When I click the "Block Item" in the chrome inspect/Adblock tab, adblock adds this rule:

Code: Select all
||ci4.googleusercontent.com/proxy/nYHC0Y6wjpp3us9QdVGymuqsjgPyobU6uTI5djEqn9PXuni4fzFP9WZdFwBs9A_EHD2Gr8g5loeOtftX92dkhl87ElPsQVjLaZ_1sQONR9_YJyBQJPnDfg89y62mSHN3NT9eGwO_nYOjAM3t=s0-d-e1-ft
blockyblocky
 
Posts: 5
Joined: Thu Feb 16, 2017 12:20 am

Re: Blocking image with # in URL

Postby mapx » Thu Feb 16, 2017 1:24 am

yeah, it seems to be a bug. In ABP for firefox is working fine, in ABP for chrome it does not.
User avatar
mapx
 
Posts: 20305
Joined: Thu Jan 06, 2011 3:01 pm

Re: Blocking image with # in URL

Postby mapx » Thu Feb 16, 2017 1:47 am

User avatar
mapx
 
Posts: 20305
Joined: Thu Jan 06, 2011 3:01 pm

Re: Blocking image with # in URL

Postby blockyblocky » Thu Feb 16, 2017 2:04 am

I'll go shotgun approach until that gets fixed. Thanks for your help.
blockyblocky
 
Posts: 5
Joined: Thu Feb 16, 2017 12:20 am

Re: Blocking image with # in URL

Postby SaraCampbell » Wed Aug 09, 2017 6:40 am

I think The URL is incredibly long since its a google proxy image. But in particular it's a mailtrack.io signature for tracking when email is opened/loaded.

https://www.sheerglass.com/
SaraCampbell
 
Posts: 1
Joined: Mon Aug 07, 2017 11:20 am

Re: Blocking image with # in URL

Postby lewisje » Sun Aug 13, 2017 9:50 pm

Technically, the bit after the # (the fragment identifier) is not needed to determine what resource to request, so it is not sent to the server with the rest of the URL; then in some Web apps, JS in the response looks at the fragment identifier to figure out what resource(s) to request, and then continues to request content.

You could record the Web traffic to figure out where the image ultimately comes from, but for all I know, it might be a different URL each time.
There's a buzzin' in my brain I really can't explain; I think about it before they make me go to bed.
lewisje
 
Posts: 2687
Joined: Mon Jun 14, 2010 12:07 pm


Return to Filter List Authors' Corner

Who is online

Users browsing this forum: No registered users and 1 guest