rsz_load_balancing_

Full Proxy

Full Proxy

In today's fast-paced digital world, ensuring a seamless web experience while securing user data is paramount. This is where the concept of Full Proxy comes into play. Full Proxy enables organizations to optimize web performance and enhance security by acting as an intermediary between clients and servers.

In this blog post, we will dive deeper into the world of Full Proxy, exploring its functionalities, benefits, and how it can revolutionize how we interact with the internet.

Full Proxy, or Reverse Proxy, is a network infrastructure component that acts as an intermediary between clients and servers, unlike traditional forward proxies, which primarily focus on routing requests, Full Proxy intercepts and analyzes incoming requests, providing additional functionalities such as load balancing, caching, and security features

Table of Contents

Highlights: Full Proxy

Full Proxy Mode

A full proxy mode is a proxy server that acts as an intermediary between a user and a destination server. The proxy server acts as a gateway between the user and the destination server, handling all requests and responses on behalf of the user. A full proxy mode aims to provide users with added security, privacy, and performance by relaying traffic between two or more locations.

In full proxy mode, the proxy server takes on the client role, initiating requests and receiving responses from the destination server. All requests are made on behalf of the user, and the proxy server handles the entire process and provides the user with the response. This provides the user with an added layer of security, as the proxy server can authenticate the user before allowing them access to the destination server.

Increase in Privacy

The full proxy mode also increases privacy, as the proxy server is the only point of contact between the user and the destination server. All requests sent from the user are relayed through the proxy server, ensuring that the user’s identity remains hidden. Additionally, the full proxy mode can improve performance by caching commonly requested content, reducing lag times, and improving the user experience.

Related: Before you proceed, you may find the following helpful information

  1. Load Balancer Scaling
  2. TCP IP Optimizer
  3. Kubernetes Networking 101
  4. Nested Hypervisors
  5. Routing Control
  6. CASB Tools



LTM Load Balancer.

Key Full Proxy Discussion Points:


  • Introduction to load balancing with the LTM load balancer.

  • Discussion on full proxy vs half proxy.

  • Discussion on the full proxy architecture and the components involved.

  • BIG-IP traffic processing.

  • Source Address Translation (SNAT).

  • A final note load balancing and health monitoring.

 

Back to Basics: What is a proxy server

The term ‘Proxy’ is a contraction from the middle English word procuracy, a legal term meaning to act on behalf of another. For example, you may have heard of a proxy vote. You submit your choice, and someone else votes the ballot on your behalf. In networking and web traffic, a proxy is a device or server that acts on behalf of other devices. It sits between two entities and performs a service. Proxies are hardware or software solutions that sit between the client and the server and do something to request and sometimes respond.

A proxy server sits between the client requesting a web document and the target server. A proxy server facilitates communication between the sending client and the receiving target server in its most straightforward form without modifying requests or replies.

When a client initiates a request for a resource from the target server, a webpage, or a document, the proxy server hijacks our connection. It represents itself as a client to the target server, requesting the resource on our behalf. If a reply is received, the proxy server returns it to us, giving a feeling that we have communicated with the target server.

Example product: Local Traffic Manager

Local Traffic Manager (LTM) is part of a suite of BIG-IP products that adds intelligence to connections by intercepting, analyzing, and redirecting traffic. Its architecture is based on full proxy mode, meaning the LTM load balancer completely understands the connection, enabling it to be an endpoint and originator of client and server-side connections.

All kinds of full or standard proxies act as a gateway from one network to another. They sit between two entities and mediate connections. The difference in F5 full proxy architecture becomes apparent with their distinctions in flow handling. So the main difference in the full proxy vs. half proxy debate is how connections are handled.

  • Enhancing Web Performance:

One of the critical advantages of Full Proxy is its ability to enhance web performance. By employing techniques like caching and compression, Full Proxy servers can significantly reduce the load on origin servers and improve the overall response time for clients. Caching frequently accessed content at the proxy level reduces latency and bandwidth consumption, resulting in a faster and more efficient web experience.

  • Load Balancing:

Full Proxy also provides load balancing capabilities, distributing incoming requests across multiple servers to ensure optimal resource utilization. By intelligently distributing the load, Full Proxy helps prevent server overload, improving scalability and reliability. This is especially crucial for high-traffic websites or applications with many concurrent users.

  • Security and Protection:

In the age of increasing cyber threats, Full Proxy plays a vital role in safeguarding sensitive data and protecting web applications. Acting as a gatekeeper, Full Proxy can inspect, filter, and block malicious traffic, protecting servers from distributed denial-of-service (DDoS) attacks, SQL injections, and other standard web vulnerabilities. Additionally, Full Proxy can enforce SSL encryption, ensuring secure data transmission between clients and servers.

  • Granular Control and Flexibility:

Full Proxy offers organizations granular control over web traffic, allowing them to define access policies and implement content filtering rules. This enables administrators to regulate access to specific websites, control bandwidth usage, and monitor user activity. By providing a centralized control point, Full Proxy empowers organizations to enforce security measures and maintain compliance with data protection regulations.

Full proxy vs half proxy

When considering full proxy vs half proxy. The half-proxy sets up a call, and the client and server do their thing. Half-proxies are known to be suitable for Direct Server Return (DSR). You’ll have the initial setup for streaming protocols, but instead of going through the proxy for the rest of the connections, the server will bypass the proxy and go straight to the client.

This is so you don’t waste resources on the proxy for something that can be done directly from server to client. A full proxy, on the other hand, handles all the traffic. A full proxy creates a client connection and a separate server connection with a little gap in the middle.

Full proxy vs half proxy
Diagram: Full proxy vs half proxy. The source is F5.

The full proxy intelligence is in that OSI Gap. With a half-proxy, it is primarily client-side traffic on the way in during a request and then does what it needs…with a full proxy, you can manipulate, inspect, drop, and do what you need to the traffic on both sides and in both directions. Whether a request or response, you can manipulate traffic on the client-side request, the server-side request, the server-side response or the client-side response. So you get a lot more power with a full proxy than you would with a half proxy.

Highlighting F5 full proxy architecture

Full proxy architecture offers much more granularity than a half proxy ( full proxy vs half proxy )  by implementing dual network stacks for client and server connections and creating two separate entities with two different session tables – one on the client side and another on the server side. The BIG-IP LTM load balancer manages the two sessions independently.

The connections between the client and the LTM are different and independent of the connections between the LTM and the backend server. You will notice this from the diagram below. Again, there is a client-side connection and a server-side connection.  The result is that each connection has its TCP behaviors and optimizations.

Different profiles for different types of clients

Generally, client connections have longer paths to take and are exposed to higher latency levels than server-side connections. It’s more than likely that the majority of client connections will experience higher latency. A full proxy addresses these challenges by implementing different profiles and properties to server and client connections and allowing more advanced traffic management. Traffic flow through a standard proxy is end-to-end; usually, the proxy cannot simultaneously optimize for both connections.

full proxy vs half proxy
Diagram: Full proxy architecture with different load-balancing profiles.

F5 full proxy architecture: Default BIP-IP traffic processing

Clients send a request to the Virtual IP address that represents backend pool members. Once a load-balancing decision is made, a second connection is opened to the pool member. We now have two connections, one for the client and the server. The source IP address is still that of the original sending client, but the destination IP address changes to the pool member, which is known as destination-based NAT. The response is the reverse.

The source address is the pool member and the original client’s destination. This process requires that all traffic passes through the LTM, enabling these requests to be undone. The source address is translated from the pool member to the Virtual Server IP address.

Response traffic must flow back through the LTM load balancer to ensure the translation can be undone. For this to happen, servers (pool members) use LTM as their Default Gateway. Any off-net traffic flows through the LTM. What happens if requests come through the BIG-IP, but the response goes through a different default gateway?

  • A key point: Source address translation (SNAT)

The source address will be the responding pool member, but the sending client does not have a connection with the pool member; it has a connection to the VIP located on the LTM. In addition to doing destination address translation, the LTM can do Source address translation (SNAT). This forces the response back to the LTM, and the transitions are undone. It is expected to use the Auto Map Source Address Selection feature- the BIG-IP selects one of its “IP” addresses as the IP for the SNAT.

 

F5 full proxy architecture and virtual server types

Virtual servers have independent packet handling techniques that vary by virtual server type. The following are examples of some of the available virtual servers. Standard virtual server with Layer 7 functionality, Performance Layer 4 Virtual Server, Performance HTTP virtual server, Forwarding Layer 2 virtual server, Forwarding IP virtual server, Reject virtual server, Stateless, DHCP Relay, Message Routing. The example below displays the TCP connection setup for a Virtual server with Layer 7 functionality.

full proxy vs half proxy
Diagram: Load balancing operations.

Stage

Details of Stage

Load Balancing Step 1

The client sends an SYN request to LTM Virtual Server

Load Balancing Step 2

LTM sends back an SYN-ACK TCP segment

Load Balancing Step 3

The client responds with an ACK to acknowledge receiving the SYN-ACK

Load Balancing Step 4

The client sends an HTTP GET request to the LTM

Load Balancing Step 5

The LTM sends ACK to acknowledge receiving the GET request

Load Balancing Step 6

The LTM sends an SYN request to the pool member

Load Balancing Step 7

The pool member sends an SYN-ACK to the LTM

Load Balancing Step 8

LTM sends an ACK packet to acknowledge receiving the SYN-ACK
 

LMT forwards the HTTP GET requests to the Pool member

When the client-to-LTM handshake is complete, it waits for the initial HTTP request (HTTP_GET) before making a load-balancing decision. Then, it does a full TCP session with the pool member, but this time, the LTM is the client in the TCP session. For the client connection, the LTM was the server. The BIG-IP waits for the initial traffic flow to set up the load balancing to mitigate against DoS attacks and preserve resources.

As discussed, all virtual servers have different packet-handling techniques. For example, clients send initial SYN to the LTM with the performance virtual server. The LTM system makes the load-balancing decision and passes the SYN request to the pool member without completing the full TCP handshake.

 

Load balancing and health monitoring

The client requests the destination IP address in the IPv4 or IPv6 header. However, this destination IP address could get overwhelmed by large requests. Therefore, the LTM distributes client requests (based on a load balancing method) to multiple servers instead of to the single specified destination IP address. The load balancing method determines the pattern or metric used to distribute traffic.

These methods are categorized as either Static or Dynamic. Dynamic load balancing considers real-time events and includes least connections, fastest, observed, predictive, etc. Static load balancing includes both round-robin and ratio-based systems. Round-robin-based load balancing works well if servers are equal (homogeneous), but what if you have nonhomogeneous servers? 

Ratio load balancing 

In this case, Ratio load balancing can distribute traffic unevenly based on predefined ratios. For example, Ratio 3 is assigned to servers 1 and 2, and Ratio 1 is assigned to servers 3. This configuration results in that for every 1 packet assigned to server 3, both servers 1 and 2 will get 3. Initially, it starts with a round-robin, but subsequent flows are differentiated based on the ratios.

A feature known as priority-based member activation allows you to configure pool members into priority groups. High priority gets more traffic. For example, you group the two high-spec servers (server 1 and server 2) in a high-priority group and a low-spec server (server 3) in a low-priority group. The old server will not be used unless there is a failure in priority group 1.

F5 full proxy architecture: Health and performance monitors

Health and performance monitors are associated with a pool to determine if servers are operational and can receive traffic. The type of health monitor used depends on the type of traffic you want to monitor. There are several predefined monitors, and you can customize your own. For example, LTM attempts FTP to download a specified file to the /var/tmp directory, and the check is successful if the file is retrieved.

Some HTTP monitors permit the inclusion of a username and password to retrieve a page on the website. You also have LDAP, MYSQL, ICMP, HTTPS, NTP, Oracle, POP3, Radius, RPC, and many others. iRules allows you to manage traffic based on business logic. For example, you can direct customers to the correct server based on language preference in their browsers. An iRule can be the trigger to inspect this header (accept language) and select the right pool of application servers based on the value specified in the header.

 

Increase backend server performance.

It’sIt’says computationally more exhausting to set up a new connection rather than receive requests over an existing OPEN connection. That’s HTTP keepalives invented and made standard in HTTP v1. LTM has a feature known as “One connect” that leverages HTTP keepalives to reuse connections for multiple clients, not just a single client. It works with HTTP keepalives to make existing connections available for other clients, not just a single client. Fewer open connection means lower resource consumption per server.

When the LTM receives the HTTP request from the client, it makes the load-balancing decision before the “One connect” is considered. If there are no OPEN or IDLE server-side connections, the BIP-IP creates a new TCP connection to the server. When the server responds with the HTTP response, the connection is left open on the BIP-IP for reuse. The connection is held in a table buffer called the connection reuse pool.

New requests from other clients can reuse the OPEN IDLE connection, not needing to set up a new TCP connection. The source mask on the OC profile determines which clients can reuse open and idle server-side connections. Using SNAT, the source address is translated before applying the OC profile.

Summary: Full Proxy

In today’s digital age, connectivity is the lifeblood of our society. The Internet has become an indispensable tool for communication, information sharing, and business transactions. However, numerous barriers still hinder universal access to the vast realm of online resources. One promising solution that has emerged in recent years is the concept of fully proxy networks. In this blog post, we delved into the world of fully proxy networks, exploring their potential to revolutionize internet accessibility.

Section 1: Understanding Fully Proxy Networks

Fully proxy networks, also known as reverse proxy networks, are innovative systems designed to enhance internet accessibility for users. Unlike traditional networks that rely on direct connections between users and online resources, fully proxy networks act as intermediaries between the user and the internet. They intercept requests from users and fetch the requested content on their behalf, optimizing the delivery process and bypassing potential obstacles.

Section 2: Overcoming Geographical Restrictions

One of the primary benefits of fully proxy networks is their ability to overcome geographical restrictions imposed by content providers. With these networks, users can access websites and online services that are typically inaccessible due to regional limitations. By routing traffic through proxy servers located in different regions, fully proxy networks enable users to bypass geo-blocking and enjoy unrestricted access to online content.

Section 3: Enhanced Security and Privacy

Another significant advantage of fully proxy networks lies in their ability to enhance security and privacy. By acting as intermediaries, these networks add an extra layer of protection between users and online resources. The proxy servers can mask users’ IP addresses, making it more challenging for malicious actors to track their online activities. Additionally, fully proxy networks can encrypt data transmissions, safeguarding sensitive information from potential threats.

Section 4: Accelerating Internet Performance

In addition to improving accessibility and security, fully proxy networks can significantly enhance internet performance. By caching and optimizing content delivery, these networks can reduce latency and speed up web page loading times. Users can experience faster and more responsive browsing experiences, especially for frequently accessed websites. Moreover, fully proxy networks can alleviate bandwidth constraints during peak usage periods, ensuring a seamless online experience for users.

Conclusion:

Fully proxy networks offer a promising solution to the challenges of internet accessibility. By bypassing geographical restrictions, enhancing security and privacy, and accelerating internet performance, these networks can unlock a new era of online accessibility for users worldwide. As technology continues to evolve, fully proxy networks are poised to play a crucial role in bridging the digital divide and creating a more inclusive internet landscape.