1

What's my goal: know what employee are looking in Internet (what pages, how long etc; no caching).

What I did: install squid on openBSD

Problem: I see whole traffic (tcpdump), but I can't redirect it to squid

How I connected it:

         [ internet ]
              |
[ switch with port mirroring ]  => [ squid server ]
              |
           [ LAN ]

My squid server have two NIC: sis0 with IP address 10.0.0.100 (management connection) and rl0 without IP address and with promisc mode (no bridge; whole traffic is going to that interface).

My pf.conf:

pass            # establish keep-state
block in on ! lo0 proto tcp to port 6000:6010
pass in on rl0 proto tcp from any to any port {80 443 3128 8080} rdr-to 10.2.0.247 port 3128

I have nothing in /var/squid/log/access.log. nc -l 3128 print nothing.

My squid.conf:

cat /etc/squid/squid.conf | grep -v ^$ | grep -v ^#                                                                                                       
acl all src all
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 localnet src 10.0.0.0/24    # RFC1918 possible internal network
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 manager localhost
http_access deny manager
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localnet
http_access deny all
icp_access allow localnet
icp_access deny all
http_port 10.0.0.100:3128
hierarchy_stoplist cgi-bin ?
cache_dir null /tmp
maximum_object_size 20480 KB
access_log /var/squid/logs/access.log squid
refresh_pattern ^ftp:           1440    20%     10080
refresh_pattern ^gopher:        1440    0%      1440
refresh_pattern -i (/cgi-bin/|\?) 0     0%      0
refresh_pattern .               0       20%     4320
acl shoutcast rep_header X-HTTP09-First-Line ^ICY.[0-9]
upgrade_http0.9 deny shoutcast
acl apache rep_header Server ^Apache
broken_vary_encoding allow apache
coredump_dir /var/squid/cache
Ducker
  • 11
  • 2

1 Answers1

1

Your localnet in squid.conf is wrong: acl localnet src 10.0.0.0/24

Must be acl localnet src 10.2.0.0/24