Socket(1)

Socket(1) implements an interface to TCP sockets at shell level. Client and server sockets can be used from shell scripts or interactively. Socket can also run a program with stdin, stdout, and stderr connected to the socket connection. A number of sample shell scripts are included. The current version has been not tested thoroughly, but should run on some Linuxes (well, pick your favourite distribution and see if it runs), Solaris (9), and FreeBSD (5.x). It should be not too hard to port to similar platforms.

Version 1.5 (download) features IPv6 support, optional half close on eof, and optional connection reset on SIGINT and SIGTERM. Finally SIGHUP is handled correctly. Boris Nikolaus made most of these changes. Thanks, Boris! Prereleases of 1.5 have been running fine for me for a while now, so I don't expect major problems.

The previous version is 1.4; see the CHANGES for details. Get the gzipped tar file from here. Warning: This version is not thoroughly tested, but I suggest you give it a try.

Even older versions are 1.3, 1.2p1, 1.1.

There is a version 2 in the works which is a completely new implementation. It will feature an elaborate, reusable select loop module, UDP and Unix domain sockets, and lots of options. (The options are handled by a completely over-engineered hyper-generic option handler module. Kind of insane, but after all I'm doing this for fun, right? :-)

Version 2 is far from being complete and progressing very slowly, but I am still hopeful that it will some day reach a state of releasability. Basic functionality works for TCP, but most of the features are not yet implemented. See the usage message if you are curious.


Juergen Nickelsen <ni@jnickelsen.de>

Top