aquaballoon

/etc/squid3/squid.config

May 16th, 2012
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 2.56 KB | None | 0 0
  1. acl manager proto cache_object
  2. acl localhost src 127.0.0.1/32
  3. acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
  4.  
  5. acl SSL_ports port 443
  6. acl Safe_ports port 80      # http
  7. acl Safe_ports port 21      # ftp
  8. acl Safe_ports port 443     # https
  9. acl Safe_ports port 70      # gopher
  10. acl Safe_ports port 210     # wais
  11. acl Safe_ports port 1025-65535  # unregistered ports
  12. acl Safe_ports port 280     # http-mgmt
  13. acl Safe_ports port 488     # gss-http
  14. acl Safe_ports port 591     # filemaker
  15. acl Safe_ports port 777     # multiling http
  16.  
  17. acl CONNECT method CONNECT
  18.  
  19. http_access allow manager localhost
  20. http_access deny manager
  21.  
  22. http_access deny !Safe_ports
  23. http_access deny CONNECT !SSL_ports
  24. http_access allow localhost
  25.  
  26. icp_access deny all
  27. htcp_access deny all
  28.  
  29. hierarchy_stoplist cgi-bin ?
  30.  
  31. access_log /var/log/squid3/access.log squid
  32.  
  33. refresh_pattern ^ftp:       1440    20% 10080
  34. refresh_pattern ^gopher:    1440    0%  1440
  35. refresh_pattern (cgi-bin|\?)    0   0%  0
  36. refresh_pattern .       0   20% 4320
  37.  
  38. ###################  My Setting #########################
  39.  
  40. ## Listening port number ##
  41. http_port 3128 transparent
  42.  
  43. ## Visible hostname ##
  44. visible_hostname hureeict.edu.mn
  45.  
  46. ## Time Settings ##
  47. acl biz_hours time MTWHF 9:00-24:00
  48.  
  49. ## Unlimited Access Users ##
  50. #acl BIGBOSS src 192.168.15.19
  51. #http_access allow BIGBOSS
  52.  
  53. ## BLOCK MAC ##
  54. #acl mac_block arp 09:00:2b:23:45:67
  55.  
  56. ## BLOCK HTTPS ##
  57. acl https_block dstdomain .google.com .google.mn
  58. http_access deny CONNECT https_block biz_hours
  59. #http_reply_access deny https_block biz_hours
  60.  
  61. ## BLOCK Websites/Download/Ports ##
  62. acl website_block dstdom_regex -i facebook.com
  63. acl download_block urlpath_regex -i jason_torrent
  64. acl ports_block port 6969 6881-6899
  65. http_access deny website_block biz_hours
  66. http_access deny download_block biz_hours
  67. http_access deny ports_block biz_hours
  68.  
  69. ## Block Flash Videos ##
  70. #acl flash rep_mime_type video/x-flv
  71. #http_reply_access deny flash
  72.  
  73. ## OPEN Subnets ##
  74. acl lan_15 src 192.168.15.0/24 192.168.16.0/24
  75. acl localnet src 127.0.0.1/255.255.255.255
  76. http_access allow lan_15
  77. http_access allow localnet
  78. # http_access allow lan_15 biz_hours
  79. # http_access deny all
  80. # http_access deny !Safe_ports
  81.  
  82. ## Delay Pools - 100kb/s ##
  83. #delay_pools 1
  84. #delay_class 1 1
  85. #delay_parameters 1 84000/84000
  86. #delay_access 1 allow lan_15 biz_hours
  87.  
  88. #delay_access 1 allow lan_15
  89. #delay_access 1 deny lan_15 !biz_hours
  90. #delay_access 1 deny lan_15 all
  91.  
  92. ## Cache 20GB ##
  93. cache_dir ufs /var/spool/squid 20000 16 256
  94.  
  95. ## Limit maximum download file size ##
  96. reply_body_max_size 999 MB
  97.  
  98. ################# END #####################
Advertisement
Add Comment
Please, Sign In to add comment