Yet Another M? Identd
YAMIdentd stands for Yet Another Mini Identd. It could also mean Yet Another Masquerading Identd. I just can’t make up my mind! This is my own attempt at a simple, small and functionnal ident daemon that can both process local requests and forward requests triggered by masqueraded hosts (when it is running on a Linux NAT gateway). It is loosely based on bidentd.
This daemon currently only runs on Linux (2.4 and 2.6; 2.2 untested). The daemon can forward to any ident daemon, i.e. masqueraded hosts can be running any RFC 1413 compliant ident daemon, provided that said daemon doesn’t perform the optional check “query host = connected host for the port queried” (i.e. that the daemon accepts forwarded queries). Of course, YAMIdentd can forward queries to itself. The drawback is that since this optional check is not performed, YAMIdentd will happily answer queries for ports the remote party isn’t connected to.
The code aims at being stable, fast and RFC 1413 compliant. It is meant to be run from inetd. It doesn’t use any configuration file: install it and (hopefully) forget it. It will do the right thing automagically. I’d consider it beta software but I’m using it without any problem (so far) on Linux 2.4 and 2.6.
The code is available for download here: yamidentd.c. It can be built with:
gcc -std=gnu99 -Wall -Wextra -pedantic -O2 -o yamidentd yamidentd.c
The warnings about printf not supporting “%m” are harmless (they’re coming from buggy syslog(3) headers).
It needs to be listed in inetd.conf, with e.g.:
ident stream tcp nowait root /path/to/yamidentd yamidentd