<div dir="ltr"><div>rdr pass inet proto tcp from <a href="http://10.0.0.0/8">10.0.0.0/8</a> to any port 80 -> 10.0.0.24 port 3129<br><br># block in<br>pass in log quick on bge0<br>pass out log quick on bge0<br>pass out keep state<br><br><br></div>Thanks<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 5, 2015 at 8:50 AM, Yuri Voinov <span dir="ltr"><<a href="mailto:yvoinov@gmail.com" target="_blank">yvoinov@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">-----BEGIN PGP SIGNED MESSAGE-----<br>
Hash: SHA1<br>
<br>
</span>Show complete pf.conf, please.<br>
<br>
05.03.15 19:45, Monah Baki пишет:<br>
<span class="">> In my squid.conf<br>
><br>
> http_port 3128 http_port 3129 intercept<br>
><br>
> Thanks<br>
><br>
> On Thu, Mar 5, 2015 at 8:44 AM, Yuri Voinov <<a href="mailto:yvoinov@gmail.com">yvoinov@gmail.com</a>><br>
> wrote:<br>
><br>
</span><div><div class="h5">> Squid access denied?<br>
><br>
> Look at this:<br>
><br>
> In my /etc/pf.conf rdr pass inet proto tcp from <a href="http://10.0.0.0/8" target="_blank">10.0.0.0/8</a> to any<br>
>>>>> port 80 -> 10.0.0.24 port 3129<br>
><br>
> Which port configured in Squid as intercept?<br>
><br>
> 3129?<br>
><br>
> and 3128 is forwarding?<br>
><br>
> 05.03.15 19:36, <a href="mailto:monahbaki@gmail.com">monahbaki@gmail.com</a> пишет:<br>
>>>> Yes that's what I followed and user is getting a "access<br>
>>>> denied" from the squid when he tries <a href="http://www.cnn.com" target="_blank">www.cnn.com</a><br>
>>>><br>
>>>> Sent from my BlackBerry 10 smartphone on the Verizon Wireless<br>
>>>> 4G LTE network. Original Message From: Yuri Voinov Sent:<br>
>>>> Thursday, March 5, 2015 8:22 AM To:<br>
>>>> <a href="mailto:squid-users@lists.squid-cache.org">squid-users@lists.squid-cache.org</a> Subject: Re: [squid-users]<br>
>>>> squid intercept config<br>
>>>><br>
>>>><br>
> <a href="http://wiki.squid-cache.org/ConfigExamples/Intercept/Cisco2501PolicyRoute" target="_blank">http://wiki.squid-cache.org/ConfigExamples/Intercept/Cisco2501PolicyRoute</a><br>
>>>><br>
>>>><br>
><br>
><br>
<a href="http://wiki.squid-cache.org/ConfigExamples/Intercept/FreeBsdPf" target="_blank">http://wiki.squid-cache.org/ConfigExamples/Intercept/FreeBsdPf</a><br>
>>>><br>
>>>> 05.03.15 18:19, Monah Baki пишет:<br>
>>>>> Hi all, can anyone verify if this is correct, need to make<br>
>>>>> ure that users will be able to access the internet via the<br>
>>>>> squid.<br>
>>>><br>
>>>>> Running FreeBSD with a single interface with Squid-3.5.2<br>
>>>><br>
>>>>> Policy based routing on Cisco with the following:<br>
>>>><br>
>>>><br>
>>>>> interface GigabitEthernet0/0/1.1<br>
>>>><br>
>>>>> encapsulation dot1Q 1 native<br>
>>>><br>
>>>>> ip address 10.0.0.9 255.255.255.0<br>
>>>><br>
>>>>> no ip redirects<br>
>>>><br>
>>>>> no ip unreachables<br>
>>>><br>
>>>>> ip nat inside<br>
>>>><br>
>>>>> standby 1 ip 10.0.0.10<br>
>>>><br>
>>>>> standby 1 priority 120<br>
>>>><br>
>>>>> standby 1 preempt<br>
>>>><br>
>>>>> standby 1 name HSRP<br>
>>>><br>
>>>>> ip policy route-map CFLOW<br>
>>>><br>
>>>><br>
>>>><br>
>>>>> ip access-list extended REDIRECT<br>
>>>><br>
>>>>> deny tcp host 10.0.0.24 any eq www<br>
>>>><br>
>>>>> permit tcp host 10.0.0.23 any eq www<br>
>>>><br>
>>>><br>
>>>><br>
>>>>> route-map CFLOW permit 10<br>
>>>><br>
>>>>> match ip address REDIRECT set ip next-hop 10.0.0.24<br>
>>>><br>
>>>>> In my /etc/pf.conf rdr pass inet proto tcp from <a href="http://10.0.0.0/8" target="_blank">10.0.0.0/8</a><br>
>>>>> to any port 80 -> 10.0.0.24 port 3129<br>
>>>><br>
>>>>> # block in pass in log quick on bge0 pass out log quick on<br>
>>>>> bge0 pass out keep state<br>
>>>><br>
>>>>> and finally in my squid.conf: http_port 3128 http_port<br>
>>>>> 3129 intercept<br>
>>>><br>
>>>><br>
>>>><br>
>>>>> And for testing purposes from the squid server:<br>
>>>>> ./squidclient -h 10.0.0.24 -p 3128 <a href="http://www.freebsd.org/" target="_blank">http://www.freebsd.org/</a><br>
>>>><br>
>>>>> If I replace -p 3128 with -p 80, I get a access denied, and<br>
>>>>> if I omit the -p 3128 completely, I can access the<br>
>>>>> websites.<br>
>>>><br>
>>>>> tcpdump with (-p 3128)<br>
>>>><br>
>>>>> 13:15:02.681106 IP ISN-PHC-CACHE.44017 ><br>
>>>>> wfe0.ysv.freebsd.org.http: Flags [.], ack 17377, win 1018,<br>
>>>>> options [nop,nop,TS val 985588797 ecr 1054387720], length<br>
>>>>> 0 13:15:02.681421 IP wfe0.ysv.freebsd.org.http ><br>
>>>>> ISN-PHC-CACHE.44017: Flags [.], seq 17377:18825, ack 289,<br>
>>>>> win 1040, options [nop,nop,TS val 1054387720 ecr<br>
>>>>> 985588501], length 1448 13:15:02.681575 IP<br>
>>>>> wfe0.ysv.freebsd.org.http > ISN-PHC-CACHE.44017: Flags [.],<br>
>>>>> seq 18825:20273, ack 289, win 1040, options [nop,nop,TS val<br>
>>>>> 1054387720 ecr 985588501], length 1448<br>
>>>><br>
>>>><br>
>>>><br>
>>>>> Did I miss anything?<br>
>>>><br>
>>>>> Thanks Monah<br>
>>>><br>
>>>><br>
>>>><br>
>>>>> _______________________________________________<br>
>>>>> squid-users mailing list <a href="mailto:squid-users@lists.squid-cache.org">squid-users@lists.squid-cache.org</a><br>
>>>>> <a href="http://lists.squid-cache.org/listinfo/squid-users" target="_blank">http://lists.squid-cache.org/listinfo/squid-users</a><br>
>>>><br>
>>>> _______________________________________________ squid-users<br>
>>>> mailing list <a href="mailto:squid-users@lists.squid-cache.org">squid-users@lists.squid-cache.org</a><br>
>>>> <a href="http://lists.squid-cache.org/listinfo/squid-users" target="_blank">http://lists.squid-cache.org/listinfo/squid-users</a><br>
>>>><br>
>><br>
><br>
-----BEGIN PGP SIGNATURE-----<br>
Version: GnuPG v2<br>
<br>
</div></div>iQEcBAEBAgAGBQJU+F8UAAoJENNXIZxhPexGUd0H/ikmReyo7lGbuMVZelLLdawa<br>
mtKS3N+dfyVWDT6LCGlgJaWFYV8N0Xqvf3dUv73xkrr3Gqoh6pQIVDdUJOObOC/7<br>
/yX9qIPfHxz8pic18Hm3/RCwoeSzXp75JgD8LMy2xkOxto+Gvx3pFBBfMyViBYz9<br>
VTCumGjDvx7pVlcO8MlmZ86jdSvBoEpLYi8J9rjD+11UKhA5mzy8gqzC8OCCTLvc<br>
mP9NcUfvIFPFIW//SyzS+X1DiM/fGJ/jFsJ6QVxU8oY///zpHWyXE9oYZzZ62DqA<br>
2VtPKduIu2NVZ/ibbnPI4CEU52Ct0uz2scbC1ZEvSqrkfYklg+RGDPj3ckcwGMU=<br>
=xmOu<br>
-----END PGP SIGNATURE-----<br>
</blockquote></div><br></div>