<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>x83.net &#187; tcp_outgoing_address</title>
	<atom:link href="http://www.x83.net/tag/tcp_outgoing_address/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.x83.net</link>
	<description></description>
	<lastBuildDate>Sat, 24 Jul 2010 09:50:05 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Squid and password authentication</title>
		<link>http://www.x83.net/squid-and-password-authentication/</link>
		<comments>http://www.x83.net/squid-and-password-authentication/#comments</comments>
		<pubDate>Tue, 23 Jun 2009 09:00:53 +0000</pubDate>
		<dc:creator>Giany</dc:creator>
				<category><![CDATA[Centos]]></category>
		<category><![CDATA[Debian]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Redhat]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[acl]]></category>
		<category><![CDATA[authentication]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[generate]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[squid]]></category>
		<category><![CDATA[tcp_outgoing_address]]></category>
		<category><![CDATA[visible_hostname]]></category>

		<guid isPermaLink="false">http://www.x83.net/?p=274</guid>
		<description><![CDATA[yum install squid
Example of squid.conf
http_port 10000
hierarchy_stoplist cgi-bin ?
acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
auth_param basic casesensitive off
refresh_pattern ^ftp:           1440    20%     10080
refresh_pattern [...]]]></description>
			<content:encoded><![CDATA[<p>yum install squid</p>
<p>Example of squid.conf</p>
<blockquote><p>http_port 10000<br />
hierarchy_stoplist cgi-bin ?</p>
<p>acl QUERY urlpath_regex cgi-bin \?<br />
no_cache deny QUERY</p>
<p>auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/passwd<br />
auth_param basic children 5<br />
auth_param basic realm Squid proxy-caching web server<br />
auth_param basic credentialsttl 2 hours<br />
auth_param basic casesensitive off</p>
<p>refresh_pattern ^ftp:           1440    20%     10080<br />
refresh_pattern ^gopher:        1440    0%      1440<br />
refresh_pattern .               0       20%     4320</p>
<p>acl all src 0.0.0.0/0.0.0.0<br />
acl SSL_ports port 443 563<br />
acl Safe_ports port 80          # http<br />
acl Safe_ports port 21          # ftp<br />
acl Safe_ports port 443 563     # https, snews<br />
acl Safe_ports port 70          # gopher<br />
acl Safe_ports port 210         # wais<br />
acl Safe_ports port 1025-65535  # unregistered ports<br />
acl Safe_ports port 280         # http-mgmt<br />
acl Safe_ports port 488         # gss-http<br />
acl Safe_ports port 591         # filemaker<br />
acl Safe_ports port 777         # multiling http</p>
<p>acl ncsa_users proxy_auth REQUIRED<br />
http_access deny !Safe_ports<br />
http_access allow ncsa_users<br />
visible_hostname mysite.com<br />
coredump_dir /var/spool/squid</p></blockquote>
<blockquote><p>service squid start</p></blockquote>
<p>Setting proxy for wget:</p>
<blockquote><p>export http_proxy=http://anton:testinsg@mysite:10000</p></blockquote>
<p>If you want to make it anonymous add these lines:</p>
<blockquote><p>forwarded_for off</p>
<p>header_access Allow allow all<br />
header_access Authorization allow all<br />
header_access WWW-Authenticate allow all<br />
header_access Proxy-Authorization allow all<br />
header_access Proxy-Authenticate allow all<br />
header_access Cache-Control allow all<br />
header_access Content-Encoding allow all<br />
header_access Content-Length allow all<br />
header_access Content-Type allow all<br />
header_access Date allow all<br />
header_access Expires allow all<br />
header_access Host allow all<br />
header_access If-Modified-Since allow all<br />
header_access Last-Modified allow all<br />
header_access Location allow all<br />
header_access Pragma allow all<br />
header_access Accept allow all<br />
header_access Accept-Charset allow all<br />
header_access Accept-Encoding allow all<br />
header_access Accept-Language allow all<br />
header_access Content-Language allow all<br />
header_access Mime-Version allow all<br />
header_access Retry-After allow all<br />
header_access Title allow all<br />
header_access Connection allow all<br />
header_access Proxy-Connection allow all<br />
header_access Cookie allow all<br />
header_access Set-Cookie allow all<br />
header_access All deny all</p>
<p>acl ip4 myaclname yourip<br />
tcp_outgoing_address yourip myaclname</p></blockquote>
<p>Generate acl and tcp_outgoing_address:</p>
<blockquote><p>for f in {314..372}; do echo &#8220;acl ip$((f))&#8221; myip aaa.bbb.ccc.$((f-246)) >> &#8220;blah1&#8243;; done<br />
for f in {314..372}; do echo &#8220;tcp_outgoing_address aaa.bbb.ccc.$((f-246))&#8221; ip$((f)) >> &#8220;blah1&#8243;; done</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.x83.net/squid-and-password-authentication/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
