OpenNC

OpenBSD-Netcat-pseudo-portable

 

OpenBSD-NetCat is a portable package for Linux (or other's I suppose) users who want to build openbsd-netcat on their system for whatever reason (no package etc. - although this is becoming less so). This was done by using patches from distributions that support it as a package, applying them then building it.

 download opennc version 1.89

Building

I am a zillion percent sure it varies by distribution but I found I needed the following on my own system to build it:

  • gettext (0.19.3-2)
  • libbsd-dev:amd64 (0.7.0-2)
tar xzvf opennc-version.tgz
cd opennc-version
make 

This distribution currently does not install it - all one need do is copy the binary and manual page to where you would like them.

--usage

OpenBSD netcat )
usage: nc [-46DdhklnrStUuvzC] [-i interval] [-P proxy_username] [-p source_port]
          [-s source_ip_address] [-T ToS] [-w timeout] [-X proxy_protocol]
          [-x proxy_address[:port]] [hostname] [port[s]]
        Command Summary:
                -4              Use IPv4
                -6              Use IPv6
                -D              Enable the debug socket option
                -d              Detach from stdin
                -h              This help text
                -i secs         Delay interval for lines sent, ports scanned
                -k              Keep inbound sockets open for multiple connects
                -l              Listen mode, for inbound connects
                -n              Suppress name/port resolutions
                -P proxyuser    Username for proxy authentication
                -p port         Specify local port for remote connects
                -q secs         quit after EOF on stdin and delay of secs
                -r              Randomize remote ports
                -S              Enable the TCP MD5 signature option
                -s addr         Local source address
                -T ToS          Set IP Type of Service
                -C              Send CRLF as line-ending
                -t              Answer TELNET negotiation
                -U              Use UNIX domain socket
                -u              UDP mode
                -Z              DCCP mode
                -v              Verbose
                -w secs         Timeout for connects and final net reads
                -X proto        Proxy protocol: "4", "5" (SOCKS) or "connect"
                -x addr[:port]  Specify proxy address and port
                -z              Zero-I/O mode [used for scanning]
        Port numbers can be individual or ranges: lo-hi [inclusive]

Plans

Nothing solid; yet. I would like to re-integrate and ship OpenBSD code with it while somehow tracking this portable version along with the authoratative version myself and by leveraging porting patches from other places so I can see how that might be ... something of a challenge down the line; we shall see.