• 技术文章 >Rox proxy >Foreign proxy

    How does a reverse proxy work?

    饮醉不止马匹饮醉不止马匹2021-11-06 13:44:45原创635
    A reverse proxy server typically has two models: it can act as a stand-in for a content server or as a load balancer for a content server cluster.

    image.png

    1. Be a stand-in for the content server

    If your content server has sensitive information that must be kept secure, such as a credit card number database, you can set up a proxy server outside the firewall as a stand-in for the content server. When an external client tries to access the content server, it is sent to the proxy server. The actual content resides on the content server and is secured inside the firewall. The proxy server is located outside the firewall and looks like a content server to the client.

    When a client makes a request to the site, the request is forwarded to the proxy server. The proxy server then sends the client's request to the content server through a specific channel in the firewall. The content server then passes the results back to the proxy server over the channel. The proxy server sends the retrieved information to the client as if the proxy server were the actual content server (see Figure 2). If the content server returns an error message, the proxy server intercepts the message and changes any URLS listed in the header before sending the message to the client. This prevents external clients from getting the internal content server's redirected URL.

    In this way, the proxy server provides another barrier between the secure database and possible malicious attacks. Even if a fluke attack succeeds, the perpetrator is limited at best to accessing the information involved in a single transaction, as opposed to having access to the entire database. Unauthorized users cannot access the real content server because firewall access only allows proxy access.

    2.Act as a load balancer for the content server

    Multiple proxy servers can be used within an organization to balance network load among Web servers. In this model, you can leverage the caching features of proxy servers to create a pool of servers for load balancing. At this point, the proxy server can be on either side of the firewall. If the Web server receives a large number of requests every day, a proxy server can be used to share the load of the Web server and improve network access efficiency.

    The proxy server acts as a mediator for client requests to the real server. The proxy server caches the requested document. If there is more than one proxy server, the DNS can select the IP address of the proxy server using the cyclic multiplexing method to randomly select routes for requests. The client uses the same URL each time, but the route taken by the request may go through a different proxy server each time.

    Multiple proxy servers can be used to handle requests to a high-volume content server, with the benefit that the content server can handle a higher load and be more efficient than working alone. During the initial startup period, the proxy server first retrieves documents from the content server, after which the number of requests to the content server drops significantly.

    专题推荐:reverseproxy
    品易云
    上一篇:Why do I need a proxy server? 下一篇:Are free online proxy services safe?

    相关文章推荐

    • Why must Python crawler data collection use proxy technology?• What are the common scenarios for using proxy servers• Why use a reverse proxy?• Reasons for using proxies to crawl web pages• Why use a proxy server?

    全部评论我要评论

    © 2021 Python学习网 苏ICP备2021003149号-1

  • 取消发布评论
  • 

    Python学习网