D
D
Denis Sechin2017-01-19 17:08:10
linux
Denis Sechin, 2017-01-19 17:08:10

Squid3 keeps cutting http traffic?

Good afternoon, there is an office, ubuntu 14 serv acts as a gateway, squid3 is raised on it. Recently, squid has started blocking websites that work over http. Clearing the cache helped for a while, now nothing helps at all, only https sites work. What can be improved?
conf squid3


#url_rewrite_program / usr / bin / squidGuard
#url_rewrite_children 10
cache_mem 300 MB
maximum_object_size_in_memory 10 MB
memory_pools on
memory_pools_limit 30 MB
cache_dir ufs / var / spool / squid3 6000
16256 http_port 3128 transparent
acl office src 10.49.1.0/24
# ac1 NOCACHEDOMAIN dstdomain mafia. ua deny NOCACHEDOMAIN
acl manager proto cache_object
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
acl SSL_ports port 443
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 # https
acl Safe_ports port 70 # gopher
acl Safe_ports port 210 # wais
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 280 # http-mgmt
acl Safe_ports port 488 # gss-http
acl Safe_ports port 591 # filemaker
acl Safe_ports port 777 # multiling http
acl CONNECT method CONNECT
http_access allow office
http_access allow manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localhost
http_access deny all
hierarchy_stoplist cgi-bin ?
access_log /var/log/squid3/access.log squid
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern (cgi-bin|\?) 0 0% 0
refresh_pattern . 0 20% 4320
coredump_dir /var/spool/squid3

iptables conf

iptables -P FORWARD DROP
iptables -P INPUT DROP
iptables -P OUTPUT ACCEPT
iptables -A INPUT -i lo -j ACCEPT
iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
iptables -A INPUT -p tcp -- dport 4491 -j ACCEPT
iptables -A INPUT -p icmp -j ACCEPT
iptables -A INPUT -i $TUN_IF -j ACCEPT
iptables -A INPUT -i $INT_IF1 -j ACCEPT
iptables -A INPUT -i $GUEST_IF -s $GUEST_NET - j ACCEPT
iptables -A INPUT -j LOG --log-prefix INPUT_ -m limit --limit 5/min
iptables -A FORWARD -m state --state RELATED,ESTABLISHED -j ACCEPT
#socseti
# iptables -A FORWARD -m string --string "vk.com" --algo kmp --to 65535 -j DROP
# iptables -A FORWARD -m string --string "vkontakte.ru" --algo kmp --to 65535 -j DROP
# iptables -A FORWARD -m string --string "facebook.com" --algo kmp --to 65535 -j DROP
# for i in 87.240.128.0/18 217.20.144.0/20 173.194.113.0/24 173.252.64.0/18; do iptables -A FORWARD -i $INT_IF1 -s $INT_NET1 -d "$i" -j DROP; done
#socseti
iptables -A FORWARD -i $TUN_IF -o $INT_IF1 -j ACCEPT
iptables -A FORWARD -i $INT_IF1 -o $TUN_IF -j ACCEPT
iptables -A FORWARD -i $INT_IF1 -o $EXT_IF1 -j ACCEPT
iptables - A FORWARD -i $GUEST_IF -s $GUEST_NET -d mail.shf.com.
iptables -A FORWARD -d 10.49.1.2 -p tcp -m multiport --dports 8443 -j ACCEPT
iptables -t nat -A PREROUTING -i $INT_IF1 -s $INT_NET1 -p tcp --dport 80 ! -d 192.168/16 -j REDIRECT --to-port 3128
## NAT Prerouting
iptables -t nat -A PREROUTING -p tcp -d xx73.197 --dport 8443 -j DNAT --to-destination 10.49.1.2:8443
iptables -t nat -A POSTROUTING -s $INT_NET1 -o $EXT_IF1 -p icmp -j MASQUERADE iptables -t nat -A
POSTROUTING -s $INT_NET1 -o $EXT_IF1 -p tcp -j MASQUERADE
s $INT_NET1 -o $EXT_IF1 -p udp -j MASQUERADE
iptables -t nat -A POSTROUTING -s $GUEST_NET -o $EXT_IF1 -j MASQUERADE
#iptables -t nat -A POSTROUTING -o $EXT_IF1 -j SNAT --to- source $EXT_IP1
#iptables -t nat -A POSTROUTING -o $INT_IF1 -d 192.168.38.252 -j SNAT --to-source $INT_IP1
}

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry Aleksandrov, 2017-01-19
@jamakasi666

Is there anything suspicious in the logs?

P
post_ed, 2017-02-18
@post_ed

just like this:
http_port 3129 accel vhost allow-direct

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question