#!/bin/bash # Example for a KILL_RUN_CMD in /etc/portsentry/portsentry.conf # by Peter Gerhardt # and Guido Guenther # # $Id: kill_cmd,v 1.3 2001/07/19 21:02:34 agx Exp $ # grep into /etc/services to check which port was scanned MODE=${3/[sa]/} # get rid of s and a SERVICEINFO=`grep "[[:space:]]$2/$MODE" /etc/services` # can we get some info about the attacker? FINGERINFO=`/usr/sbin/safe_finger -l @$1 2>/dev/null` cat <