Fernando 🇮🇹🇨🇭
Fernando 🇮🇹🇨🇭

@Franc0Fernand0

10 Tweets 3 reads Feb 12, 2023
A proxy is a server acting as intermediary between a set of clients and a set of servers.
These are the differences between forward and reverse proxies:
{1/9} ↓
A forward proxy is a server configured to act on behalf of a client.
The client's requests go to the proxy instead of the server.
The proxy forwards the requests to the server and waits for responses sending them back to the client.
{2/9}
In this way, the server doesn't know who the client is.
It only knows the source IP address of the proxy.
So a forward proxy can secure and hide the identity of the client.
VPNs work according to the same principle.
{3/9}
Using a forward proxy, clients can access servers they wouldn't be supposed to access.
But using forward proxies also has advantages at the system level since they can:
• selectively send/block requests
• log or monitor requests
• cache responses
{4/9}
A reverse proxy is a server configured to act on behalf of another server.
The proxy receives the client's requests instead of the server.
The proxy forwards the requests to the server and waits for responses sending them back to the client.
{5/9}
The client has no idea that it is communicating with the reverse proxy.
The responses are returned to the client, appearing to originate from the server itself.
So a reverse proxy can secure and hide the identity of the server.
{6/9}
The main advantages of using reverse proxies are:
• Load balancing among a group of servers
• Anonymity and increased security for the servers
• Better performances, executing additional tasks in place of the servers
{7/9}
For example, reverse proxies can cache static content reducing the overall system latency.
Or they can take the load off of the servers performing additional tasks like:
• Data compression and decompression
• Data encryption and decryption
• HTTP authentication
{8/9}
Introducing reverse proxies in a system also has disadvantages:
• the system complexity increases
• reverse proxies redundancy is necessary to avoid single points of failure
As usual, using a reverse proxy layer in a system, it's a matter of trade-offs.
{9/9}
Thanks for reading so far!
If you liked it, please leave a like or retweet to make the thread reachable to more people.
For more similar content:
• follow @Franc0Fernand0
• subscribe to my newsletter polymathicengineer.com
Your support encourages me to keep writing!

Loading suggestions...