• Home
  • The Song
  • The Avatar
  • The Cat
  • Contact the Cat

Gyp the Cat dot Com

How to Enable Squid Anonymous Stealth Mode
internet

How to Enable Squid Anonymous Stealth Mode

There are some times when you don’t want your proxy server announcing that it’s a proxy server to the world.  Getting Squid to anonymise the requests coming from behind it isn’t done out of the box.

Squid is RFC compliant in that it adds the appropriate headers into the HTTP conversation which is being a good internet neighbour and good for system admins.  Putting Squid in stealth mode will therefore make Squid not RFC compliant.  It is however very useful when you need to check geo services in other parts of the world, or when you need to make sure your users are secure.

What we are wanting to do is to make sure we don’t break websites we may wish to visit,but make sure our details are secure.

Log on to your Proxy box as per usual.

Edit the Squid configuration:

nano /etc/squid3/squid.conf

Add the following lines to the top of your config file:

follow_x_forwarded_for deny all
forwarded_for delete
via off
header_access From deny all
header_access Server deny all
header_access WWW-Authenticate deny all
header_access Link deny all
header_access Cache-Control deny all
header_access Proxy-Connection deny all
header_access X-Cache deny all
header_access X-Cache-Lookup deny all
header_access Via deny all
header_access Forwarded-For deny all
header_access X-Forwarded-For deny all
header_access Pragma deny all
header_access Keep-Alive deny all

[ctrl]+o to save, and [ctrl]+x to exit.

These lines are in the config file already, so you can either find them, change them accordingly or just paste the code above.

Now lets restart Squid, on Ubuntu we could use:

service squid3 restart

Any questions or problems comment below.  Or if you use any other controls I’d be very interested in learning!

Related

Written by gyp - September 13, 2012 - 9867 Views
Tags | internet, linux, proxy, squid, ubuntu

You Might Also Like

Mac SOCKS Server Panel

Using SSH as a SOCKS VPN on Mac OS

June 21, 2011

Public DNS Servers

September 26, 2015

Installing Nginx (LEMP) on Ubuntu 11.10

April 29, 2012

4 Comments

  • stylemessiah November 16, 2012 at 10:12 am

    My five cents worth and experience

    You will almost certainly run across auth/script errors if you use:

    header_access Link deny all

    If not others in the above list.

    But Link deny certainly causes issues.

    Also, better off using:

    forwarded_for off
    Than
    forwarded_for delete

    Also follow_x_forwarded_for deny all is the default setting so its not necessary to specify in squid.conf

    Reply
    • gyp November 25, 2012 at 9:24 pm

      Thanks for the tips! I’ve never had a problem with the header_access (I don’t think), but will change it on my proxy and see how I get on 🙂

      Reply
  • petertc June 4, 2013 at 1:45 am

    Hi,
    Why I need to set follow_x_forwarded_for deny all and header_access Via deny all?
    thanks

    Reply
    • gyp June 4, 2013 at 11:49 am

      Hi Petertc,

      If you don’t set the x forwarded for and header access then Squid will tell the websites it’s accessing on your behalf your real IP address, which isn’t Squid in stealth mode 🙂

      Gyp

      Reply

    Please Post Your Comments & Reviews
    Cancel reply

    Your email address will not be published. Required fields are marked *

    Previous Post
    Next Post

    Latest Posts

    • How to Convert CSV to Parquet Easily with Python on Linux Shell
    • Kusto Geolocation IP Lookup
    • Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
    • HTTP to HTTPS Redirect on Azure CDN
    • Strongswan IPSec (Including Cryptomap) to Microsoft Azure Virtual Network Gateway
    • Black Ops 3 NAT Type Strict & PS4 NAT Type 3 with pfSense Fixed!
    • Sorry for the lack of posts
    • How to Block Internet Access with Group Policy (GPO)
    • Enforcing Microsoft Office 365 and Azure Tennancy with McAfee Web Gateway (MWG)
    • Scanning Subnet for Issuing Certificate Authority with OpenSSL

    Top Posts & Pages

    • How to Block Internet Access with Group Policy (GPO)
      How to Block Internet Access with Group Policy (GPO)
    • How to Configure Windows 2012 NPS for Radius Authentication with Ubiquiti Unifi
      How to Configure Windows 2012 NPS for Radius Authentication with Ubiquiti Unifi
    • Kusto Geolocation IP Lookup
      Kusto Geolocation IP Lookup
    • Tinyproxy A Quick and Easy Proxy Server on Ubuntu
      Tinyproxy A Quick and Easy Proxy Server on Ubuntu
    • Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
      Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
    • How to DNSPerf on Ubuntu 14.04 with Installation and Quick Start
      How to DNSPerf on Ubuntu 14.04 with Installation and Quick Start
    • How to Add Different Disclaimers using alterMIME and Postfix based on Domain
      How to Add Different Disclaimers using alterMIME and Postfix based on Domain
    • Blocking Countries on Nginx without the GeoIP Module
      Blocking Countries on Nginx without the GeoIP Module
    • How to Enable Squid Anonymous Stealth Mode
      How to Enable Squid Anonymous Stealth Mode
    • Configuring Suite B, VPN-A and VPN-B in IPSec with Strongswan
      Configuring Suite B, VPN-A and VPN-B in IPSec with Strongswan

    Tags

    apache2 azure azure log analytics blops business centos cheating cissp cloudflare cryptography dns game google gyp internet iphone ipsec isc linux mac marketing microsoft mw2 mx mysql nginx pfsense postfix proxy ps3 qualification radius revision security seo smtp socks squid ssh strongswan tinyproxy ubuntu windows 2012 wordpress xdecrypt.com
    Gyp the Cat dot Com

    Some rights retained Gyp the Cat Dot Com