Squid Proxy Server user authentication access, tcp_outgoing_address export IP random call

Source: Internet
Author: User
Tags squid proxy

Configured as follows

The code is as follows Copy Code

Http_port 142.4.106.1:3128
Http_port 142.4.106.xx:3128
Http_port 142.4.106.xx:3128
Auth_param Basic PROGRAM/USER/LIB/SQUID/LIBEXEC/NCSA_AUTH/ETC/SQUID/PASSWD
Auth_param Basic Children 5
Auth_param Basic Realm Squid proxy-caching Web server
Auth_param Basic Credentialsttl hours
Auth_param Basic CaseSensitive off
#使用用户或者用户组来确定出口的IP
#acl Wltony Proxy_auth Wltony
#acl wltony1 Proxy_auth Wltony1
#tcp_outgoing_address 142.4.106.xxx Wltony
#根据被访问服务器 IP to determine export IP
#acl No1 Myip 142.4.106.xxx
#tcp_outgoing_address 142.4.106.xxx No1
ACL src_73 src 142.4.106.xxx
ACL src_74 src 142.4.106.xxx
Tcp_outgoing_address 142.4.106.xxx src_73
Tcp_outgoing_address 142.4.106.xxx src_74
#first_req Primary Access IP
ACL first_req src 142.4.106.1
ACL second_req src 142.4.106.xxx
ACL second_req src 142.4.106.xxx
Cache_peer 142.4.106.xxx Parent 3128 0 Round-robin No-query login=wltony:xxx
Cache_peer 142.4.106.xxx Parent 3128 0 Round-robin No-query login=wltony:xxx
Cache_peer_access 142.4.106.xxx Allow First_req
Cache_peer_access 142.4.106.xxx Allow First_req
Cache_peer_access 142.4.106.xxx deny Second_req
Cache_peer_access 142.4.106.xxx deny Second_req
Never_direct Allow First_req
Never_direct Deny Second_req
#close Cache Www.111cn.net
ACL Ncache method get
No_cache Deny Ncache
ACL ncsa_users Proxy_auth REQUIRED
ACL all src all
Header_access Via deny all
Header_access X-forwarded-for deny all
Http_access Allow Ncsa_users
#http_access Allow Wltony
#http_access Allow Wltony1
Http_access Deny All

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.