socat | bidirectional data transfer between two independent data | TCP library

 by   anaelorlinski C Version: Current License: Non-SPDX

kandi X-RAY | socat Summary

kandi X-RAY | socat Summary

socat is a C library typically used in Networking, TCP applications. socat has no bugs and it has low support. However socat has 7 vulnerabilities and it has a Non-SPDX License. You can download it from GitHub.

socat is a relay for bidirectional data transfer between two independent data channels. Each of these data channels may be a file, pipe, device (serial line etc. or a pseudo terminal), a socket (UNIX, IP4, IP6 - raw, UDP, TCP), an SSL socket, proxy CONNECT connection, a file descriptor (stdin etc.), the GNU line editor (readline), a program, or a combination of two of these. These modes include generation of "listening" sockets, named pipes, and pseudo terminals. socat can be used, e.g., as TCP port forwarder (one-shot or daemon), as an external socksifier, for attacking weak firewalls, as a shell interface to UNIX sockets, IP6 relay, for redirecting TCP oriented programs to a serial line, to logically connect serial lines on different computers, or to establish a relatively secure environment (su and chroot) for running client or server shell scripts with network connections. Many options are available to refine socats behaviour: terminal parameters, open() options, file permissions, file and process owners, basic socket options like bind address, advanced socket options like IP source routing, linger, TTL, TOS (type of service), or TCP performance tuning. More capabilities, like daemon mode with forking, client address check, "tail -f" mode, some stream data processing (line terminator conversion), choosing sockets, pipes, or ptys for interprocess communication, debug and trace options, logging to syslog, stderr or file, and last but not least precise error messages make it a versatile tool for many different purposes. In fact, many of these features already exist in specialized tools; but until now, there does not seem to exists another tool that provides such a generic, flexible, simple and almost comprehensive (UNIX) byte stream connector.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              socat has a low active ecosystem.
              It has 2 star(s) with 2 fork(s). There are 1 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              socat has no issues reported. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of socat is current.

            kandi-Quality Quality

              socat has 0 bugs and 0 code smells.

            kandi-Security Security

              socat has 7 vulnerability issues reported (0 critical, 1 high, 4 medium, 2 low).
              socat code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              socat has a Non-SPDX License.
              Non-SPDX licenses can be open source with a non SPDX compliant license, or non open source licenses, and you need to review them closely before use.

            kandi-Reuse Reuse

              socat releases are not available. You will need to build from source code and install.
              Installation instructions, examples and code snippets are available.
              It has 900 lines of code, 0 functions and 5 files.
              It has low code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of socat
            Get all kandi verified functions for this library.

            socat Key Features

            No Key Features are available at this moment for socat.

            socat Examples and Code Snippets

            No Code Snippets are available at this moment for socat.

            Community Discussions

            QUESTION

            Passing parameter with special characters to Socat exec script
            Asked 2022-Mar-22 at 20:58

            I have a RNDIS USB modem that allows AT commands through a telnet port (5510). I want to use it to read and send SMS messages from a script. I've used a variant of a similar question posted here but I'm using socat instead of netcat.

            1. I have a helper script called atread.sh:
            ...

            ANSWER

            Answered 2022-Mar-22 at 20:58

            Socats address parser interpretes a few characters specially, these are for example:

            Source https://stackoverflow.com/questions/71544121

            QUESTION

            DPDK l3fwd-acl application is unable to send or receive using net_tap PMD using namespaces
            Asked 2022-Mar-10 at 02:09

            I compiled dpdk 19.11.11 version to test l3fwd-acl. After starting it in a VirtualBox instance with 2 CPUs and 2 ports I have used 2 TAP interfaces to simulate 2 network interfaces for putting traffic over one and getting that back over another. I have used the following command (and get the following output):

            ...

            ANSWER

            Answered 2022-Mar-09 at 07:45

            L3fwd-acl works with IP packets only, for all non IP packets it drops. Hence with TAP PMD I had to follow the changes as

            1. Disable any NIC PCIe device using --no-pci
            2. Use new commands as sudo ./build/l3fwd-acl --file-prefix=mytest -l 2-4 --vdev=net_tap0 --vdev=net_tap1 --no-pci -- -P -p 3 --config="(0,0,4),(1,0,3)" --rule_ipv4=ipv4-sample.db --rule-ipv6=ipv6-sample.db --eth-dest=0, --eth-dest=1,
            3. edit ip-sample.db file with the entries to be assigned for dtap0 and dtap1.
            4. refer section 24.1.3 to identify the format and for default drop rule
            5. start the application and use the following netns commands.

            Source https://stackoverflow.com/questions/71345975

            QUESTION

            How to configure virtual serial port's baud rate
            Asked 2022-Mar-02 at 11:46

            I created a serial port by using socat PTY,link=/tmp/ttys0,raw,echo=0 PTY,link=/tmp/ttys1,raw,echo=0 & I think it created 2 PTY under /dev and let /tmp/ttys0 and /tmp/ttys1 pointing to them.

            % ls -ltr /tmp/

            lrwxr-xr-x 1 hankboyu wheel 12 Mar 1 13:22 ttys0 -> /dev/ttys009

            lrwxr-xr-x 1 hankboyu wheel 12 Mar 1 13:22 ttys1 -> /dev/ttys010

            Now I want to change the baud rate of the serial ports from default value 9600 to 115200, how do I do that?

            Also, do I need to change the baud rate on all 4 file descriptors?

            The virtual serial port was created for 2 micro-services to communicates with each other, each micro-service listens on different PTY.

            ...

            ANSWER

            Answered 2022-Mar-02 at 11:46

            You may apply Socat option b115200 when creating the PTYs.

            With something like

            stty -f /dev/ttys009 115200

            it might be possible to change the speed afterwards.

            Source https://stackoverflow.com/questions/71313222

            QUESTION

            Integration of GPG-signed Git commits in VSCode Dev Container (WSL2 Ubuntu v20)
            Asked 2022-Feb-18 at 11:24

            I am using Windows10 WSL2(running with Ubuntu v20) with VSCode.

            I want to send GPG-signed Git Commit to GitHub in VSCode Dev Container.

            I try with the setup like below:

            1. Install Gpg4win in Windows

            2. install packages in WSL2

            ...

            ANSWER

            Answered 2022-Feb-17 at 13:28

            It turns out I should not install gnupg2 in my Dev Container instance.

            Source https://stackoverflow.com/questions/71155464

            QUESTION

            Socat hangs when piping stdin to tcp server
            Asked 2022-Feb-16 at 22:23

            I have an embedded linux system running a tcp server. Telnet can connect to and use the tcp server interactively just fine.

            I am trying to use socat to make the same connection, by linking stdin to the tcp server, like so:

            socat - tcp:localhost:8088

            I get the initial response from the server, and I can type, but as soon as I press enter, the terminal hangs (I can get out of this with Ctrl + C as long as I am not using the raw socat option.)

            If I do the same thing but with readline, everything mostly works as expected:

            socat readline tcp:localhost:8088

            However, with readline, the terminal echoes my input, and then the response from the server also echoes it. This is more than just an annoyance, since things like passwords (which should not even be echoed once) are now visible.

            Ideally, I would just use stdin instead of readline, so that I could send each character as soon as I type it, and turn off stdin echo. That way, when I type a character, the tcp server receives it and echoes it immediately, but only if it is supposed to.

            But socat is hanging with the stdin option for reasons I don't understand.

            I'm looking for an explanation as to why stdin is locking up the thread, or a workaround possibly using readline or similar.

            EDIT: Here is the dddd debug output from the socat command when I use stdin:

            sh-5.0# socat -d -d -d -d -lu - tcp:localhost:8088

            2022/02/04 01:34:58.805536 socat[1074] D getpid()

            2022/02/04 01:34:58.807631 socat[1074] D getpid() -> 1074

            2022/02/04 01:34:58.807667 socat[1074] D setenv("SOCAT_PID", "1074", 1)

            2022/02/04 01:34:58.807687 socat[1074] D setenv() -> 0

            2022/02/04 01:34:58.807704 socat[1074] D setenv("SOCAT_PPID", "1074", 1)

            2022/02/04 01:34:58.807724 socat[1074] D setenv() -> 0

            2022/02/04 01:34:58.807737 socat[1074] I socat by Gerhard Rieger and contributors - see www.dest-unreach.org

            2022/02/04 01:34:58.807752 socat[1074] I This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/)

            2022/02/04 01:34:58.807767 socat[1074] I This product includes software written by Tim Hudson (tjh@cryptsoft.com)

            2022/02/04 01:34:58.807781 socat[1074] D socat version 1.7.3.3 on May 25 2021 13:47:29

            2022/02/04 01:34:58.807795 socat[1074] D setenv("SOCAT_VERSION", "1.7.3.3", 1)

            2022/02/04 01:34:58.807811 socat[1074] D setenv() -> 0

            2022/02/04 01:34:58.807827 socat[1074] D running on Linux version #1 SMP Mon Jan 31 20:48:32 UTC 2022, release 5.4.0, machine aarch64

            2022/02/04 01:34:58.807845 socat[1074] D argv[0]: "socat"

            2022/02/04 01:34:58.807857 socat[1074] D argv[1]: "-d"

            2022/02/04 01:34:58.807870 socat[1074] D argv[2]: "-d"

            2022/02/04 01:34:58.807883 socat[1074] D argv[3]: "-d"

            2022/02/04 01:34:58.807895 socat[1074] D argv[4]: "-d"

            2022/02/04 01:34:58.807907 socat[1074] D argv[5]: "-lu"

            2022/02/04 01:34:58.807920 socat[1074] D argv[6]: "-"

            2022/02/04 01:34:58.807932 socat[1074] D argv[7]: "tcp:localhost:8088"

            2022/02/04 01:34:58.807945 socat[1074] D sigaction(1, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.807960 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.807973 socat[1074] D sigaction(2, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.807987 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808000 socat[1074] D sigaction(3, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808014 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808026 socat[1074] D sigaction(4, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808040 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808053 socat[1074] D sigaction(6, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808067 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808079 socat[1074] D sigaction(7, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808092 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808105 socat[1074] D sigaction(8, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808119 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808132 socat[1074] D sigaction(11, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808146 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808158 socat[1074] D sigaction(15, 0xffffc8d63a18, 0x0)

            2022/02/04 01:34:58.808172 socat[1074] D sigaction() -> 0

            2022/02/04 01:34:58.808185 socat[1074] D signal(13, 0x1)

            2022/02/04 01:34:58.808200 socat[1074] D signal() -> 0x0

            2022/02/04 01:34:58.808213 socat[1074] D atexit(0xaaaaba73c4a0)

            2022/02/04 01:34:58.808226 socat[1074] D atexit() -> 0

            2022/02/04 01:34:58.808267 socat[1074] D calloc(1, 848)

            2022/02/04 01:34:58.808284 socat[1074] D calloc() -> 0xaaaadd2cc680

            2022/02/04 01:34:58.808304 socat[1074] D malloc(1024)

            2022/02/04 01:34:58.808318 socat[1074] D malloc() -> 0xaaaadd2cca00

            2022/02/04 01:34:58.808333 socat[1074] D calloc(1, 848)

            2022/02/04 01:34:58.808350 socat[1074] D calloc() -> 0xaaaadd2cce10

            2022/02/04 01:34:58.808364 socat[1074] D calloc(1, 848)

            2022/02/04 01:34:58.808377 socat[1074] D calloc() -> 0xaaaadd2cd170

            2022/02/04 01:34:58.808391 socat[1074] D isatty(0)

            2022/02/04 01:34:58.808411 socat[1074] D isatty() -> 1

            2022/02/04 01:34:58.808424 socat[1074] D tcgetattr(0, 0xaaaadd2ccf6c)

            2022/02/04 01:34:58.808461 socat[1074] D tcgetattr(, {00005400,00000005,00001cb2,0000083b, 4098,4098, 03,1c,7f,15,04,00,01,00,11,13,1a,00,12,0f,17,16,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00}) -> 0

            2022/02/04 01:34:58.808480 socat[1074] D isatty(1)

            2022/02/04 01:34:58.808494 socat[1074] D isatty() -> 1

            2022/02/04 01:34:58.808507 socat[1074] D tcgetattr(1, 0xaaaadd2cd2cc)

            2022/02/04 01:34:58.808542 socat[1074] D tcgetattr(, {00005400,00000005,00001cb2,0000083b, 4098,4098, 03,1c,7f,15,04,00,01,00,11,13,1a,00,12,0f,17,16,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00}) -> 0

            2022/02/04 01:34:59.141868 socat[1074] D malloc(128)

            2022/02/04 01:34:59.141888 socat[1074] D malloc() -> 0xaaaadd2cd4d0

            2022/02/04 01:34:59.141903 socat[1074] D malloc(128)

            2022/02/04 01:34:59.141916 socat[1074] D malloc() -> 0xaaaadd2cd560

            2022/02/04 01:34:59.141931 socat[1074] N reading from and writing to stdio

            2022/02/04 01:34:59.141946 socat[1074] D calloc(1, 848)

            2022/02/04 01:34:59.141959 socat[1074] D calloc() -> 0xaaaadd2cd5f0

            2022/02/04 01:34:59.141983 socat[1074] D malloc(1024)

            2022/02/04 01:34:59.141997 socat[1074] D malloc() -> 0xaaaadd2cd9b0

            2022/02/04 01:34:59.142015 socat[1074] D getaddrinfo("localhost", NULL, {1,0,1,6,0,0x0,0x0,0x0}, 0xffffc8d63538)

            2022/02/04 01:34:59.142789 socat[1074] D getaddrinfo(,,,{{AF=10 [0000:0000:0000:0000:0000:0000:0000:0001]:0, }) -> 0

            2022/02/04 01:34:59.142815 socat[1074] D malloc(128)

            2022/02/04 01:34:59.142830 socat[1074] D malloc() -> 0xaaaadd2ce610

            2022/02/04 01:34:59.142847 socat[1074] N opening connection to AF=2 127.0.0.1:8088

            2022/02/04 01:34:59.142861 socat[1074] I starting connect loop

            2022/02/04 01:34:59.142876 socat[1074] D socket(2, 1, 6)

            2022/02/04 01:34:59.142900 socat[1074] I socket(2, 1, 6) -> 5

            2022/02/04 01:34:59.142919 socat[1074] D fcntl(5, 2, 1)

            2022/02/04 01:34:59.142935 socat[1074] D fcntl() -> 0

            2022/02/04 01:34:59.142954 socat[1074] D connect(5, {2,AF=2 127.0.0.1:8088}, 16)

            2022/02/04 01:34:59.145199 socat[1074] D connect() -> 0

            2022/02/04 01:34:59.145246 socat[1074] D getsockname(5, 0xffffc8d635b8, 0xffffc8d6359c{112})

            2022/02/04 01:34:59.145269 socat[1074] D getsockname(, {AF=2 127.0.0.1:46294}, {16}) -> 0

            2022/02/04 01:34:59.145286 socat[1074] N successfully connected from local address AF=2 127.0.0.1:46294

            2022/02/04 01:34:59.145306 socat[1074] I resolved and opened all sock addresses

            2022/02/04 01:34:59.145321 socat[1074] D malloc(16385)

            2022/02/04 01:34:59.145344 socat[1074] D malloc() -> 0xaaaadd2cf400

            2022/02/04 01:34:59.145360 socat[1074] N starting data transfer loop with FDs [0,1] and [5,5]

            2022/02/04 01:34:59.145375 socat[1074] D data loop: sock1->eof=0, sock2->eof=0, closing=0, wasaction=1, total_to={0.000000}

            2022/02/04 01:34:59.145395 socat[1074] D select(6, &0x21, &0x22, &0x0, NULL/0.000000)

            2022/02/04 01:34:59.145426 socat[1074] D select -> (, 0x0, 0x20, 0x0, NULL/0.000000), 1

            2022/02/04 01:34:59.145443 socat[1074] D data loop: sock1->eof=0, sock2->eof=0, closing=0, wasaction=1, total_to={0.000000}

            2022/02/04 01:34:59.145461 socat[1074] D select(6, &0x21, &0x2, &0x0, NULL/0.000000)

            2022/02/04 01:34:59.157132 socat[1074] D select -> (, 0x20, 0x0, 0x0, NULL/0.000000), 1

            2022/02/04 01:34:59.157178 socat[1074] D data loop: sock1->eof=0, sock2->eof=0, closing=0, wasaction=1, total_to={0.000000}

            2022/02/04 01:34:59.157198 socat[1074] D select(2, &0x1, &0x2, &0x0, NULL/0.000000)

            2022/02/04 01:34:59.401692 socat[1074] D select -> (, 0x0, 0x2, 0x0, NULL/0.000000), 1

            2022/02/04 01:34:59.401732 socat[1074] D read(5, 0xaaaadd2cf400, 8192)

            2022/02/04 01:34:59.401765 socat[1074] D read -> 48

            2022/02/04 01:34:59.401782 socat[1074] D write(1, 0xaaaadd2cf400, 48)

            ÿûÿû

            Connect to IP address 169.254.12.16

            2022/02/04 01:34:59.401809 socat[1074] D write -> 48

            2022/02/04 01:34:59.401823 socat[1074] I transferred 48 bytes from 5 to 1

            2022/02/04 01:34:59.401838 socat[1074] D data loop: sock1->eof=0, sock2->eof=0, closing=0, wasaction=1, total_to={0.000000}

            2022/02/04 01:34:59.401856 socat[1074] D select(6, &0x21, &0x2, &0x0, NULL/0.000000)

            2022/02/04 01:34:59.462969 socat[1074] D select -> (, 0x0, 0x2, 0x0, NULL/0.000000), 1

            2022/02/04 01:34:59.463017 socat[1074] D data loop: sock1->eof=0, sock2->eof=0, closing=0, wasaction=1, total_to={0.000000}

            2022/02/04 01:34:59.463036 socat[1074] D select(6, &0x21, &0x0, &0x0, NULL/0.000000)

            At this point, I can still type, but no matter what I do, I get nothing in response.

            ...

            ANSWER

            Answered 2022-Feb-09 at 00:04

            Probably it is not Socat that hangs but the server. Use options -v -x to see what data Socat transfers in both situations and compare; maybe there are different line termination characters involved.

            Source https://stackoverflow.com/questions/71041261

            QUESTION

            Does socat support SOCK_SEQPACKET for Unix domain socket?
            Asked 2022-Feb-06 at 14:15

            Consider the following setup where one instance of socat pipes data from stdin to a unix domain socket, and the other instance reads that data from the unix domain socket and writes it to stdout:

            Client:

            ...

            ANSWER

            Answered 2022-Feb-06 at 14:15

            Upon further investigation of the man page, I learned that SOCK_SEQPACKET is supported by socat:

            socktype= Sets the type of the socket, specified as second argument to the socket() or socketpair() calls, to [int]. Address resolution is not affected by this option. Under Linux, 1 means stream oriented socket, 2 means datagram socket, 3 means raw socket, and 5 seqpacket (stream keeping packet boundaries).

            Client:

            Source https://stackoverflow.com/questions/70964956

            QUESTION

            Bidirectional UDP tunnel with socat on Linux
            Asked 2022-Jan-24 at 10:20

            Is it possible to create a bidirectional UDP tunnel with socat? The starting point is a client (C) that communicates with a server (S) and receives a reply, so C⟷S. Of course, C and S are on different networks with a relay (R) between them, hence the need for C⟷R⟷S. The relay is running Ubuntu Linux.

            Using socat for example per this:

            sudo nohup socat UDP-LISTEN:1194,fork,reuseaddr UDP:IP-ADDRESS-OF-HOME-ROUTER:1194 &

            apparently results in all packets received by the relay (R) to be forwarded to IP-ADDRESS-OF-HOME-ROUTER, including the reply packets from the server, or C⟶R⟷S.

            So my question is, would it be possible to make socat wait for reply packets from the server, and forward them back to the client? Is there perhaps another way to accomplish this goal?

            ...

            ANSWER

            Answered 2022-Jan-24 at 10:20

            The second method (datagram with UDP-RECVFROM/UDP-SENDTO) works only in a query/answer mode; a second answer in sequence from the OpenVPN server will not be passed back to the client; and for each query packet a sub process will be forked.

            The first method forks a subprocess per "connection" (determined by source port), and - after an initial packet from the client - forwards in both directions. Sub processes will hang "forever", so it is advisable to use the timeout option -T 3600 or so.

            Source https://stackoverflow.com/questions/70356603

            QUESTION

            How to relay outbound request from docker container to modify headers?
            Asked 2022-Jan-04 at 09:19

            I have an application that is running in Docker configured with an NGINX reverse proxy. The application is a binary, I don't have source code and there's no way to modify the header of an HTTP request from the app itself. My goal is to append a header field before the request is dispatched out of the host machine:

            ...

            ANSWER

            Answered 2021-Nov-09 at 08:52

            You could use Traefik reverse proxy v2.4+ with Traefik Pilot enabled and a plugin like Header transformation.

            You run Traefik as a container which routes the traffic to the other containers. You can then link your instance to Traefik Pilot using a token, which enables plugins. If you use labels in a docker-compose.yml file:

            Source https://stackoverflow.com/questions/69894775

            QUESTION

            Systemd not starting dependent service on slow device
            Asked 2022-Jan-03 at 17:11

            I have an interesting problem that I have a reproducer for. Using a container to compartmentalize this system and make it reproducible, I can have it run successfully on my powerful laptop, but when running on a slow raspberry Pi it fails.

            ...

            ANSWER

            Answered 2022-Jan-03 at 16:42

            I have discovered that service has an interesting "feature":

            Source https://stackoverflow.com/questions/70438705

            QUESTION

            Receiving DHCPv6 messages in Rust
            Asked 2022-Jan-02 at 11:40

            I'm trying to receive dhcp6 messages in rust. This is the code I have right now:

            ...

            ANSWER

            Answered 2022-Jan-02 at 11:40

            The problem was the following line:

            Source https://stackoverflow.com/questions/70545820

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install socat

            Get the tarball and extract it: tar xzf socat.tar.gz cd socat-1.7.3.0 ./configure make su make install # installs socat, filan, and procan in /usr/local/bin. For compiling socat, gcc (or egc) is recommended. If gcc is not available, the configure script will fail to determine some features; then you'd better begin with one of the Makefiles and config.h's from the Config directory. If you have problems with the OpenSSL library, you can apply the option "--disable-openssl" to configure. If you have problems with the readline library or (n)curses, you can apply the option "--disable-readline" to configure. If you have problems with the tcp wrappers library, you can apply the option "--disable-libwrap" to configure. If you still get errors or a tremendous amount of warnings you can exclude the features for system call tracing and file descriptor analyzing by applying the options "--disable-sycls --disable-filan" to configure. You still need the functions vsnprintf and snprintf that are in the GNU libc, but might not be available with some proprietary libc's. The configure script looks for headers and libraries of openssl, readline, and tcp wrappers in the OS'es standard places and in the subdirectories include/ and lib/ of the following places: /sw/ /usr/local/ /opt/freeware/ /usr/sfw/ and for openssl also in: /usr/local/ssl/ In case of unexpected behaviour it is important to understand that configure first searches for the appropriate include file and then expects to find the library in the associated lib directory. That means, when e.g. a OpenSSL installation resides under /usr/local and there is a symbolic link from /usr/include/ssl/ssl.h to /usr/local/ssl/include/ssl/ssl.h, configure will find the /usr/include/... header and will therefore expect libssl in /usr/lib instead of /usr/local/... If configure does not find a header file or library but you know where it is, you can specify additional search locations, e.g.: export LIBS="-L$HOME/lib" export CPPFLAGS="-I$HOME/include" before running configure and make. For other operating systems, if socat does not compile without errors, refer to the file PORTING.

            Support

            These files reside in the doc subdirectory:. socat.1 is the man page, socat.html is the HTML based man page. It is actual, but describes only the more useful options. xio.help is an older, but more exact description in text form; with socat version 1.6.0 it is outdated. doc/socat-openssltunnel.html is a simple tutorial for a private SSL connection. doc/socat-multicast.html is a short tutorial for multicast and broadcast communications. doc/socat-tun shows how to build a virtual network between two hosts. socat.1 and socat.html can be generated from socat.yo (which is released with socat 1.6.0.1 and later) using the yodl document language package. Maintenance of yodl had been discontinued by its author (http://www.xs4all.nl/~jantien/yodl/) (there seems to be a revival at http://yodl.sourceforge.net/ though). For socat, the old version 1.31 is used; an rpm is still distributed with recent OpenSuSE versions (confirmed for OpenSuSE 10.1 in suse/i586/yodl-1.31.18-1142.i586.rpm). It appears to install smoothly also under RedHat Linux. After yodl 1.31 installation, the following correction must be performed in /usr/share/yodl/shared.yo in two places: < whenhtml(htmlcommand(<!)ARG1+htmlcommand(>))).
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/anaelorlinski/socat.git

          • CLI

            gh repo clone anaelorlinski/socat

          • sshUrl

            git@github.com:anaelorlinski/socat.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular TCP Libraries

            masscan

            by robertdavidgraham

            wait-for-it

            by vishnubob

            gnet

            by panjf2000

            Quasar

            by quasar

            mumble

            by mumble-voip

            Try Top Libraries by anaelorlinski

            OpenWrt-NanoPi-R2S-R4S-Builds

            by anaelorlinskiShell

            OpenWrt-NanoPi-R5S-Builds

            by anaelorlinskiC

            monkey47

            by anaelorlinskiGo