Blocking Opera Ads using Squid

If you use Opera — like I do, on occasion — you’ll notice that it’s ad-sponsored software. Fortunately, since I use Squid as a proxy server (so that I can use Cameron Simpson’s very excellent adzapper to replace ads based on regular expressions), I just added ACLs for the Opera ad servers in order to stop the browser from downloading the ad database.

Add this ACL to your squid.conf:

# Opera browser spamvertisement access server
acl operaads dst
acl operaads-master dst

http_access deny operaads
http_access deny operaads-master

Then you can just squid -k reconfigure and away you go.

Incidentally I used this to block requests to Verisign’s much-maligned SiteFinder [dis]service:

# Trap and deny crock A records
acl sitefinder dst_as 30060

http_access deny sitefinder

SiteFinder has been suspended, but you might like to block that AS anyway in case they start it up again 🙂



I haven’t tried this yet, but it looks really cool. It’s basically an almost-SQL92 complete implementation of a database engine without a separate database process required — the databases are stored on disk as files. I’m hazarding a guess that this sprung from the limitations of Berkeley DB as a scalable, lightweight file-based database implementation.

Surprisingly the missing features list (that stop it short of full SQL92 compliance) is fairly short, which implies to me that even transactions are supported.

Seems like a great tool for small jobs where a full-blown PostgreSQL or MySQL database is just overkill.