AnanthVivekanand / spotify-adblock

Blocking ads on desktop Spotify, crazy code ahead
GNU General Public License v3.0
269 stars 32 forks source link

Allow unknown domains to fix Podcast functionality #78

Open imtherainman opened 1 year ago

imtherainman commented 1 year ago

I've noticed the current implementation breaks functionality for podcast audio. Looking into the logs, it appears to be due to some podcasts retrieving audio data directly from the publisher's domains.

For example, NPR podcasts send requests to edgeX.pod.npr.org, and New York Times uses nyt.simplecastaudio.com: image

Since these domains do not appear in either the whitelist or blacklist, they are blocked by mitm.js.

Seeing as there's no way to possibly whitelist every one of these publisher domains, the only workaround I can think of is to allow unknown domains by default, and update blacklist-mitm.js accordingly whenever an advertisement request slips through. I've added the following domains to the blacklist based on what was previously blocked as an unknown domain that would otherwise now be allowed:

I've been using this updated version for a few weeks now without issues, but welcome any feedback or alternative approach. Thanks so much for maintaining this project!