First sorry for my English. Second I configured a squid in authentication mode on port 8888. and redirect my network traffic eq www via a route-map to squid server. and in server iptables redirect traffic on port 80 to 8888(squid port).

-A PREROUTING  -s -p tcp --dport 80 -j DNAT --to

but when i browse a web in ie this error present:

The requested URL could not be retrieved
The following error was encountered while trying to retrieve the URL: /
Invalid URL

And this messege present in access.log:

1281752166.811      0 NONE/400 1744 GET / - NONE/- text/html

But when I set every ip(not squid ip) in ie proxy setting with port 80 ;

present authentication window then my requested web.

P.S when configure squid via transparent mode , it work fine.

Here is my squid.conf:

visible_hostname black    
maximum_object_size 64000 KB    
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd    
acl ncsa_users proxy_auth REQUIRED
acl snmppublic snmp_community squiz    
acl manager proto cache_object    
acl localhost src    
acl SSL_ports port 443 563 8443    
acl Safe_ports port 80 1000 443 563 70 20-65535 280  488 591 777 5555 465  210 21    
acl CONNECT method CONNECT    
http_access allow  ncsa_users    
http_access allow manager localhost    
http_access deny manager    
http_access deny !Safe_ports    
http_port 8888    
cache_mem 20 MB
cache_dir ufs /var/spool/squid 100 16 256
access_log /log/access.log
cache_store_log none
cache_effective_user nobody
http_access deny all
  • 1
    Please put your config file and any relevant commands you ran within code tags like the example in this link meta.stackexchange.com/questions/22186/… – Prix Aug 14 '10 at 7:30
  • Isnt any idea Pls? – slevin Jan 21 '11 at 3:40
  • Have you read comment above your one?! – Ency Jan 30 '11 at 22:28

I guess it's conceptually impossible to be Transparent and Authenticated mode at the same time.

If you want authentitcation don't use transparent proxy. Users must configure proxy ip/user/pass manually.

If you want transparent proxying there's no place for user/password introduction there.

Your only solution would be to use a hotspot, but i don't think you could do that with Squid alone (you'd need something like Nocat).

  • Thanks. but i think when i set every ip with port 80 in explorer proxy setting,my planned process work properly and connect to port 80 proxy and it redirects to port 8888 squid,but without it,web request by explorer doesnt connect to proxy as port 80. – slevin Aug 14 '10 at 10:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy