nmapstub-1.c (shell version) – This file reads in nmap (v2.x human) output, puts it into port and host structures, and then can call whatever routines you want (per host) to check for exploits, etc.
You can download it from the following link: https://packetstormsecurity.com/files/download/14086/nmapstub-1.c
Source: https://packetstormsecurity.com/files/14086/nmapstub-1.c.html

