How to use git over an HTTP proxy, with SOCAT?
Git passes the host and port as two arguments to the proxy command, but socat expects them in the syntax you see above, so you will need to wrap it in a script as I have done. I guess you could argue that this is a point in favour of corkscrew etc. 😉
Which is an example of a SOCAT connection?
Let’s get started with some basic examples of using socat for various connections. 1. Connect to TCP port 80 on the local or remote system: In this case, socat transfers data between STDIO (-) and a TCP4 connection to port 80 on a host named www.example.com.
Which is the best way to use SOCAT?
All data sent by the clients is appended to the file /tmp/test.log. If the file does not exist, socat creates it. The option reuseaddr allows an immediate restart of the server process. 4. Send a broadcast to the local network:
How to use SOCAT as a TCP port forwarder?
Use socat as a TCP port forwarder: For multiple connections, use the fork option as used in the examples below: This example listens on port 81, accepts connections, and forwards the connections to port 80 on the remote host.
What do you need to know about SOCAT port forwarding?
UPDATE: I need a single socat process between Firefox and remote server. socat is just a forwarder (proxy redirector), nothing more. Something like this: Normally https servers run on port 443, so maybe that is your issue?
What’s the best way to connect to proxy server?
The basic idea is that you will somehow invoke socat, which will negotiate with the HTTP (S) proxy server using the CONNECT method to get you a clean pipe to the server on the far side. However, do note that socat does have one disadvantage: the passwords to your proxy server are visible in to local users running ps -ef or something.
Is it possible to setup a MITM SOCAT proxy?
Note: It is possible to setup a MITM socat proxy, but this would require adding an artificial trusted CA. Good luck! Unfortunately, socat cannot be used for such a task.