Scripts, Programs and One Liners

Current ¦ Featured ¦ Reference ¦ Old ¦ Projects ¦ BSD ¦ Linux

I have written well over several hundred scripts and programs; most of which are so specific to a particular system, organization or function; they are utterly useless to the community at large. In this section of the site is a collection of programs/scripts that turned out to be useful or programs/scripts which I intentionally wrote for myself and decided to share. Not all of them are originally mine (or at least their original incarnation), in addition to these are source code examples in various languages.


Meaning currently maintained and progressively developed these bits and bytes may lie dormant for some period of time (in some cases up to a year or so) but they are still being worked on (just not every day.. or month).

NetSTR New Release!
Network strings is a portscanner and packet dumper all in one. It has some unique features compared to other programs of similar type.
I've wanted a good portable netcat for awhile that didn't require a ton of work to port around. Borrowing from the Debian port I cobbled together a version that works well.
IndySYN Updated
independent scan your (node, network, nostrils?) this program is an attempt at as simple and small a host port scanner as possible while still retaining some degree of usefulness.

These are programs I wrote or for whatever reason am sheparding for some forseeable time but are not being progressively developed. That means bugfix (and big bugs) only.

nettest-2.4 (download)
The original nettest from Cray research (now owned by SGI) and unmaintained. Although there are better (and more exotic to setup) tools out there, nettest does a good job of showing stats between two endpoints with very little muss and fuss. The current version is stable and runs on several platforms.
pwutils-0.6 (download)
A small set of user and group reporting utilities designed to demonstrate the flexibility of several languages for budding programmers and sysadmins alike.
etu-0.1.8 (download)
A utility that uses the Epeg and imlib2 API to create thumbnails (extraordinarily fast). It can also daemonize and refresh thumbnail directories making it a nice cli plugin for image scaling.
mmw-2.0 (download)
Utility to show memory information in intervals and periods.
BSDbench 2.2 (download)
A rewrite of the 4.4-BSD benchmark tools. Useful for creating loads on a BSD system which a lot of people still like to use from time to time .


Believe it or not (trust me even I am stunned) some of my own software has managed to creep its way out to other places. Following are some examples of where I found mention of it lurking about:


Reference Code (from texts/demos)

example qemu shlib
A set of shell routines I created for work in 2015. The management system we used for qemu (under Linux KVM) could not clone a virtual machine (although it does everything else) so I wrote a small set of shell libs for utils to do just that. It also can convert a vmdk formatted vm image to qcow2. Can easily be improved on, added to, changed for ones own purposes.
portcheck (download)
The micro single port single host portcheck program that was written (and is updated with) the series about writing said program at this site. This particular program is both useful to learn about network connection programming and a decent little utility.
uhttpd (download)
Tiny httpd server grokked from an IBM developer article. It is a neat little bit of demonstration code that budding programmers might be interested in playing with.
usniff (download)
Another text reference program this is a tiny tcpv4 ultra simple packet sniffer for the curious. Usniff is good for places where one might not want the overhead of tcpdump or for those simply interested in writing their own - it is great demonstration code.

Discontinued or Unmaintained

The following are scripts and programs that have either reached end of life, been superceded or just do not really require maintenance but are still useful.

netward-1.0 (download)
Psuedo-replacement for portsentry which sniffs out packets that are not specified on ports by the user as being valid and currently will log them. It works using a sample rate of packets and threshold.
dusage (view/download)
Simple disk usage script.
newsfetch-1.4 (download)
A small program that fetches netnews.
service-0.5 (download)
A multi-platform service start, stop and/or restart utility that is basically cloned from the redhat utility of the same name.
lscpu-1.8 (download)
Small utility to fetch processor information on Linux.
diskinfo-1.9 (download)
Gets information about specified ide disk.
user-0.2 (download)
A small collection of portable user reporting scripts and programs. The user tools have been migrated to the pwutils package.
puserinfo-2.1 (view/download)
BSD userinfo clone in Perl- superceded by the user package.
qtop (view/download)
A nicer top viewer - requires no maintenance.
whodo (view/download)
Who is doing what program - requires no maintenance.
nukems (view/download)
Get rid of CTRL-Ms from DOS files - redundant.
service-0.5 (download)
This is the original in Perl which I moved to scripts and redid in sh.

The Complete List

Following is a complete list of software worked on, some of which is hosted here, but definitely not all of it (kernel hacking comes to mind ...).

Dnet and Nmap

I was a committer for libdnet and have worked on Nmap as well. A few of the notable things I worked on are:

  • With a lot of help, migrated payloads from source into a file allowing simple addition/removal of UDP payloads
  • Integration of BSD patches into Nmap mainline
  • Socket size bugfix for Nmap
  • Integrating many Nmap changes to dnet into dnet mainline
  • various platform testing of both

Ever since Google code shutdown and dnet's maintainer moved on several forks of dnet exist (github) has several of these. I no longer am actively involved in either project but that could change at any time.


  • A rather difficult but surprisingly well working program that can add users and groups to the version of OpenLDAP floating around 2015 using LDIF templates plus lots and lots of regex in Perl. That program (and its wrappers) is in use by an entire staff. It isn't here because it is so site specific that I haven't come up with a way to make it portable ... yet. Why write it? We needed something that ran in the shell.
  • Updated and ported the nettest utility originally written by Cray Research (now SGI's Cray division... sort of). Basically it just had some stale API calls - not really a big deal.
  • Wrote a service utility to stop/restart services on NetBSD, Slackware Linux, HP-UX and SunOS. It also will print out where the real service scripts are located so as not to stupify the sysadmin.
  • Rewrote/updated the 4.4 BSD Benchmark tools. Surprisingly, a lot of people like to use these in tandem with profiling.
  • Original code for module now hosted at CPAN.
  •, e17 build and cvs script partially based on NetBSD's front end and my own iso creation scripts.
  • Tookover sheparding of the newsfetch program.


I am still an active NetBSD developer and occasionally work on bits here and there. I especially like build testing... I do not know why.

  • Added the capability to automatically create iso images from the build/make infrastructure using the build front end. This was a combination of shell scripting and make changes.
  • Co-wrote the verified executable NetBSD kernel modification based on proof of concept code; specifically the actual interface from the check_exec() routine over to all of the vexec routines and modularized the code.
  • Wrote enhancements to BSD file utilities such as verbosity and syncing (where reasonable) with the behavior of FreeBSD's utils.
  • Trouble-shot and patched network utility code for more correct handling of classless IPs.
  • Wholesale import of whois to replace a burgeoning version.
  • Backported ahc scsi drivers for a contractor who needed them on the 1.6 kernel series.
  • Did several code sweeps and test builds to get rid of older type declarations within the kernel where possible.


  • Forward ported a set of Broadcom network drivers from an older kernel to a newer one. Had to rewrite portions of the interface and framework glue to get it to work right.
  • Oracle on Linux patching for automatic parameter setting. This is now obsolete as the information is well documented.
  • A kernel module that gathered statistics regarding performance.
  • Wrote and maintain a set of utilities I found useful (listed above) such as cpuinfo, mmw and diskinfo.

Whats Missing?

Basically anything I cannot remember since the last time I updated this page. I have also written a lot of internal software I deemed pretty much useless to the outside world because it was so specific. Such projects ranged from archival systems to daemon processes.