0
点赞
收藏
分享

微信扫一扫

linux下配置squid 代理

安装squid

1、官方网站为 ​​http://www.squid-cache.org/​​

[root@VM-12-13-centos ~]# yum install -y squid

Installed:

 squid-7:4.15-1.module_el8.5.0+860+303ccf92.x86_64  

[root@VM-12-13-centos ~]# squid -v

Squid Cache: Version 4.15

配置文件路径:

vi /etc/squid/squid.conf

根据以下内容做修改

# Only allow cachemgr access from localhost

http_access allow localhost manager

# http_access deny manager


# We strongly recommend the following be uncommented to protect innocent

# web applications running on the proxy server who think the only

# one who can access services on "localhost" is a local user

# http_access deny to_localhost


#

# INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS

#


# Example rule allowing access from your local networks.

# Adapt localnet in the ACL section to list your (internal) IP networks

# from where browsing should be allowed

http_access allow localnet

http_access allow localhost


# And finally deny all other access to this proxy

# http_access deny all


# Squid normally listens to port 3128

http_access allow all             #放在http_access deny all 之前,允许任意客户机使用代理服务,控制规则自上而下匹配

http_access deny all

http_port 3128                     #用来指定代理服务监听的地址和端口(默认的端口号为3128)



客户端应用使用代理

1、向日葵设置代理测试使用

linux下配置squid 代理_代理服务

举报

相关推荐

0 条评论