Skip to main content

Posts

Showing posts from January, 2010

originalip option in dansguardian

I upgraded my firewall on Mandriva 2009.1 to 2010 and got into problem with dansguardian. Client computers got DansGuardian 400 - Bad Request, url is malformed for certain sites such as google and facebook. I suspected it must be related to new option introduced by newly installed dansguardian (2.10.1.1). In changelog, I got this:


Jan 21 17:18:39 firewall6 dansguardian[1090]: Destination host of dnl-15.geo.kaspersky.com did not match the original destination IP of 95.211.85.42
Jan 21 17:18:40 firewall6 dansguardian[1111]: Destination host of www.google-analytics.com did not match the original destination IP of 72.14.213.113
Jan 21 17:18:40 firewall6 dansguardian[1074]: Destination host of us.bc.yahoo.com did not match the original destination IP of 216.252.124.30���������������������������������������������������������������������������…

Stripping comments from a file

You can run this command to strip comments (line starting with a #) and empty lines from a file in Linux:

cat /etc/squid/squid.conf | grep -v ^# | grep -v ^$
I usually run this command on squid.conf, a file heavily commented.

To save the lines to file squiD.conf, you can run:

cat /etc/squid/squid.conf | grep -v ^# | grep -v ^$ > squiD.conf
Have fun!...

Nat Friedman leaves Novell

Nat Friedman and Miguel de Icaza were the founders of Ximian project. They both were known for their famous GNOME project where Ximian bornt. You can read what Nat will do next in his blog.