Answer the question
In order to leave comments, you need to log in
How to configure squid proxy server correctly?
squid3 config
acl CONNECT method CONNECT
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 210 # wais
acl Safe_ports port 21 # ftp
acl Safe_ports port 280 # http-mgmt
acl Safe_ports port 443 # https
acl Safe_ports port 488 # gss-http
acl Safe_ports port 591 # filemaker
acl Safe_ports port 70 # gopher
acl Safe_ports port 777 # multiling http
acl Safe_ports port 80 # http
acl SSL_ports port 443
coredump_dir /var/spool/squid3
http_access allow localhost
http_access allow localhost manager
http_access allo all
http_access deny CONNECT !SSL_ports
http_access deny manager
http_access deny !Safe_ports
http_port 3128
refresh_pattern . 0 20% 4320
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
url_rewrite_program /usr/bin/squidGuard -c /etc/squid3/squidGuard.conf
url_rewrite_children 500
dns_nameservers 8.8.8.8 8.8.4.4
# ICAP Configurations
icap_enable on
icap_preview_enable on
icap_service service_req reqmod_precache bypass=0 icap://127.0.0.1:1344/reqmod
adaptation_access service_req allow all
icap_service service_resp respmod_precache bypass=0 icap://127.0.0.1:1344/respmod
adaptation_access service_resp allow all
iptables -t nat -D OUTPUT -p tcp --dport 80 -j DNAT --to-destination %PROXY_IP%:3128
ERROR
The requested URL could not be retrieved
While trying to retrieve the URL: /
The following error was encountered:
* Invalid URL
Some aspect of the requested URL is incorrect. Possible problems:
* Missing or incorrect access protocol (should be `http://'' or similar)
* Missing hostname
* Illegal double-escape in the URL-Path
* Illegal character in hostname; underscores are not allowed
Answer the question
In order to leave comments, you need to log in
habrahabr.ru/sandbox/39160
keyword:
http_port 3128 transparent
If you write a proxy in the browser on Ubuntu, then everything will work too
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question