Linux / UNIX Tech Support Forum
This is a discussion on Problems With SQUID Proxy within the Linux software forums, part of the Linux Getting Started category; Cool. All you need to do is modify your iptables rules. Following rules will forward all http requests (coming to ...
|
|||||||
| Linux software General questions and discussion about Redhat/Fedora Core/Cent OS, Debian and Ubuntu Linux related to softwares should go here. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
| Sponsored Links | ||
|
|
|
|||
|
well thanks
i,e: when i go to www.ua.pt it gives me the squid access restriction error msg, aswell as when i go to www.av.it.pt (both these sites are internal websites (www.ua.pt is my provider and www.av.it.pt is my company site) it seems like the routing isnt letting me access internal websites, only external ones. |
|
||||
|
Just do not forward (DNAT) port 80 to 3128 request for www.ua.pt (193.136.173.1
Code:
iptables -t nat -A PREROUTING -i eth1 -p tcp -s \! 193.136.173.18 --dport 80 -j DNAT --to 192.168.1.1:3128 Code:
iptables -t nat -A PREROUTING -i eth1 -p tcp -s ! 193.136.173.18 --dport 80 -j DNAT --to 192.168.1.1:3128 Chk out above rules and let me know since i don't have setup like you, i cannot verify it right now.
__________________
Rocky Jr. What's wrong? I hope I am not making you uncomfortable... Never send a boy to do a mans job. |
|
|||
|
hey, thanks.
is it possible for the squid to do that automatically? for example if ur trying to access any .ua.pt or .av.it.pt it would not redirect? i've read something about never_direct do u know anything about that? |
|
|||
|
ok, the lastest.
i've tried working with the never_direct option from squid, wont work. i've tried working the iptables but stupidly enough it works when i try lynx www.ua.pt on my core router (previsouly stated as stan), but on a computer connected to that router it wont connect (previously stated as my laptop), no clue why (only way it might work is that the core router has an external ip, so its routing is own requests through that nic and not the internal requests from the lan) any ideas? |
|
||||
|
Iptables should work with all LAN system, I am not sure what iptables rules you are using. Also make sure iptables is not blocking lan access for your site.
__________________
Rocky Jr. What's wrong? I hope I am not making you uncomfortable... Never send a boy to do a mans job. |
|
|||
|
Ok, it works and through squid, thanks for the help guys
Here's how its done for future reference. 1st. create an acl for the domains that u dont want to go through the proxy acl directdomains dstdomain .av.it.pt acl directdomains dstdomain .ua.pt acl directdomains dstdomain .ieeta.pt 2nd. now lets deny access to the proxy for those domains never_direct deny directdomains restart squid and voilá we've got transparent proxying for both internal and external websites, via another proxy-server from our isp. took a week but got it done thanks again any questions let me know, if i need help i will surely post here |
|
|||
|
Cool
It is nice to know that it is working for you. I do keep visiting this forum as I learn something new everyday. Thanks for sharing back solution. Just one more question did you used iptables rules mentioned by rocky jr? |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to Squid 2.6 transparent proxy? | alex.inoa | Networking, Firewalls and Security | 5 | 30-10-2007 03:41 AM |
| Restrict number of simultaneous proxy connections in SQUID proxy | pkvmreddy | Getting started tutorials | 1 | 15-06-2007 03:52 PM |
| How to allow MSN messenger through squid proxy | bubloob_13 | Linux software | 4 | 08-04-2007 09:37 AM |
| Squid Proxy | bubloob_13 | Linux software | 4 | 03-12-2006 11:26 PM |
| problems starting squid for a rank newbie | scarletlancer | Linux software | 1 | 02-11-2006 04:20 PM |