Camyllo

Squid.conf

Sep 6th, 2011
204
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.40 KB | None | 0 0
  1. http_port 3128 transparent
  2.  
  3. #Recommended minimum configuration:
  4. acl all src all
  5. acl manager proto cache_object
  6. acl localhost src 127.0.0.1/32
  7. acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
  8.  
  9. acl localnet src 192.168.1.0/24
  10.  
  11. acl SSL_ports port 443 # https
  12. acl SSL_ports port 563 # snews
  13. acl SSL_ports port 873 # rsync
  14. acl Safe_ports port 80 # http
  15. acl Safe_ports port 21 # ftp
  16. acl Safe_ports port 443 # https
  17. acl Safe_ports port 70 # gopher
  18. acl Safe_ports port 210 # wais
  19. acl Safe_ports port 1025-65535 # unregistered ports
  20. acl Safe_ports port 280 # http-mgmt
  21. acl Safe_ports port 488 # gss-http
  22. acl Safe_ports port 591 # filemaker
  23. acl Safe_ports port 777 # multiling http
  24. acl Safe_ports port 631 # cups
  25. acl Safe_ports port 873 # rsync
  26. acl Safe_ports port 901 # SWAT
  27. acl purge method PURGE
  28. acl CONNECT method CONNECT
  29.  
  30. #Recommended minimum configuration:
  31. #
  32. # Only allow cachemgr access from localhost
  33. http_access allow manager localhost
  34. #http_access deny manager
  35. # Only allow purge requests from localhost
  36. http_access allow purge localhost
  37. http_access deny purge
  38. # Deny requests to unknown ports
  39. http_access deny !Safe_ports
  40. # Deny CONNECT to other than SSL ports
  41. http_access deny CONNECT !SSL_ports
  42.  
  43. # INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
  44. #ACLs criadas por Camyllo:
  45. acl LiberadasFull src "/etc/squid/LiberadasFull"
  46. acl bloqueados url_regex -i "/etc/squid/Sites_Bloqueados"
  47. acl liberadosSGD url_regex -i "/etc/squid/Sites_Liberados_SGD"
  48. acl IPSRestritosSGD src "/etc/squid/IPSRestritosSGD"
  49. acl IPSRedePermitidos src "/etc/squid/IPSRedePermitidos"
  50.  
  51.  
  52. http_access allow LiberadasFull
  53. http_access deny bloqueados
  54. http_access allow liberadosSGD
  55. http_access deny IPSRestritosSGD
  56. http_access allow IPSRedePermitidos
  57.  
  58. http_access allow localhost
  59.  
  60. # And finally deny all other access to this proxy
  61. http_access deny all
  62.  
  63.  
  64. #Allow ICP queries from local networks only
  65. icp_access allow localnet
  66. icp_access deny all
  67.  
  68. hierarchy_stoplist cgi-bin ?
  69.  
  70. cache_mem 64 MB
  71.  
  72. maximum_object_size_in_memory 64 KB
  73.  
  74. cache_dir ufs /var/spool/squid 2048 16 256
  75.  
  76. maximum_object_size 4096 KB
  77.  
  78. cache_swap_low 90
  79.  
  80. cache_swap_high 95
  81.  
  82. mime_table /usr/share/squid/mime.conf
  83.  
  84. refresh_pattern ^ftp: 1440 20% 10080
  85. refresh_pattern ^gopher: 1440 0% 1440
  86. refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
  87. refresh_pattern (Release|Packages(.gz)*)$ 0 20% 2880
  88. refresh_pattern . 0 20% 4320
Advertisement
Add Comment
Please, Sign In to add comment