URL: https://www.opennet.ru/cgi-bin/openforum/vsluhboard.cgi
Форум: vsluhforumID12
Нить номер: 3500
[ Назад ]

Исходное сообщение
"Запрет интернета средстави squid"

Отправлено Grab , 09-Сен-05 21:19 
Доброе время суток.
Есть сервак, Линуксы Мандрака 10.0
Сквид как прокся.
Задача - разрешить выходить в интернет только "избранным" с определенными ip адресами ,а остальных групо отрубать и всё.

Ниже приведен кусок конфига прокси.
======================================

http_port 192.168.2.2:3128
hierarchy_stoplist cgi-bin ?
cache_dir diskd /var/spool/squid 8000 128 256
pid_filename /var/run/squid.pid
cache_store_log none
auth_param basic children 5
auth_param basic realm Squid proxy-caching web server
auth_param basic credentialsttl 2 hours
refresh_pattern ^ftp:         &n... 1440    20%     10080
refresh_pattern ^gopher:        1440    0%      1440
refresh_pattern .               0       20%     4320
half_closed_clients off
acl all src 192.168.2.0/255.255.255.0
acl mamont src 192.168.2.23/255.255.255.255 192.168.2.77/255.255.255.255 192.168.2.33/255.255.255.255 192.168.2.35/255.255.255.255 192.168.2.36/255.255.255.255 192.168.2.64/255.255.255.255 192.168.2.66/255.255.255.255 192.168.2.67/255.255.255.255 192.168.2.56/255.255.255.255
http_access allow mamont
http_access deny all
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl to_localhost dst 127.0.0.0/8
acl SSL_ports port 443 563
acl Safe_ports port 80
acl Safe_ports port 21 23
acl Safe_ports port 443 563
acl Safe_ports port 70
acl Safe_ports port 8080
acl Safe_ports port 210
acl Safe_ports port 1025-65535
acl Safe_ports port 280
acl Safe_ports port 488
acl Safe_ports port 591
acl Safe_ports port 777
acl CONNECT method CONNECT

========================
непойму в чем грабли... вроде всё указано жестко.. как бы. но всерно "юзверы" лезут, а им низя.

Спасибо что откликнулись.


Содержание

Сообщения в этом обсуждении
"Запрет интернета средстави squid"
Отправлено antoshkin , 13-Сен-05 11:27 
Мне кажется неправильно немного.
http_access ставь после всех acl'ей, all - это все. Свою сетку надо описывать под другим именем (в принципе конечно не важно, но так будет удобней потом при более гибкой настройке) Например:

acl all src 0.0.0.0/0.0.0.0
acl my_lan src 192.168.0.0/255.255.255.0
acl vip_users src 192.168.0.23 192.168.0.45 192.168.0.34

...
...
...
...
...

http_access allow vip_users
http_access deny all


"Запрет интернета средстави squid"
Отправлено Grab , 13-Сен-05 19:31 
>Мне кажется неправильно немного.
>http_access ставь после всех acl'ей, all - это все. Свою сетку надо
>описывать под другим именем (в принципе конечно не важно, но так
>будет удобней потом при более гибкой настройке) Например:
>
>acl all src 0.0.0.0/0.0.0.0
>acl my_lan src 192.168.0.0/255.255.255.0
>acl vip_users src 192.168.0.23 192.168.0.45 192.168.0.34
>
>...
>...
>...
>...
>...
>
>http_access allow vip_users
>http_access deny all


Спасибо большое!!! Чётко, ясно и по делу!


"Запрет интернета средстави squid"
Отправлено igorzu , 14-Фев-12 17:17 
acl admin src 10.93.34.3-10.93.34.99/255.255.255.255, 10.93.34.106/32
acl prac src 10.93.34.128/32, 10.93.34.125/32, 10.93.34.126/32,  10.93.34.118/32, 10.93.34.136/32, 10.93.34.109/32
acl user src 10.93.34.124/32, 10.93.34.129/32, 10.93.34.135/32, 10.93.34.145/32, 10.93.34.120/32, 10.93.34.115/32, 10.93.34.138/32, 10.93.34.130/32, 10.93.34.122/32, 10.93.34.139/32, 10.93.34.136/32
acl porn url_regex -i odnoklassniki


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 admin
http_access allow prac
http_access allow user
http_access deny porn

а у меня никак не закривается odnoklassniki. Где тут пробоема