【问题标题】:Tinyproxy Reverse Proxy "Access denied"Tinyproxy 反向代理“拒绝访问”
【发布时间】:2017-05-09 21:13:49
【问题描述】:

我正在使用tinyproxy 进行反向代理。我有三个子域指向同一个服务器,我们需要它们在内部指向特定的端口。也就是说,来自任何特定子域的端口 80,映射到特定端口。请参阅下面的配置示例。

配置如下:

Port 80
#Allow 127.0.0.1
#ReverseOnly yes
upstream 127.0.0.1:8115 "website.example.com"
upstream 127.0.0.1:3000 "api.example.com"
upstream 127.0.0.1:9000 "socket.example.com"

当我启动任何子域时,我得到的只是:

访问被拒绝
此代理的管理员尚未将其配置为处理来自您主机的请求。
由 tinyproxy 1.8.3 版本生成。


我在任何地方都找不到adequate documentation。我正在考虑联系维护人员。请帮忙。

【问题讨论】:

    标签: proxy reverse-proxy tinyproxy


    【解决方案1】:

    我希望你已经得到了答案,但如果你还没有,这里是允许客户端连接到你的代理的设置:

    #
    # Allow: Customization of authorization controls. If there are any
    # access control keywords then the default action is to DENY. Otherwise,
    # the default action is ALLOW.
    #
    # The order of the controls are important. All incoming connections are
    # tested against the controls based on order.
    #
    Allow 127.0.0.1
    #Allow 192.168.0.0/16
    #Allow 172.16.0.0/12
    #Allow 10.0.0.0/8
    Allow 0.0.0.0/0
    

    在我的示例中,我允许 0.0.0.0/0,因为我正在配置从 Internet 到我的其他 VPS 的反向代理。

    另外,您上面的配置是用于正向代理,而不是反向代理。

    要启用反向代理功能,您至少需要以下内容:

    ConnectPort 80
    ConnectPort 443
    ReversePath "/" "http://<your server IP>:8080/"
    ReverseOnly Yes
    ReverseMagic Yes
    

    【讨论】:

      猜你喜欢
      • 2022-09-30
      • 1970-01-01
      • 1970-01-01
      • 2021-10-21
      • 1970-01-01
      • 1970-01-01
      • 2016-03-08
      • 2021-12-13
      • 2012-05-31
      相关资源
      最近更新 更多