did you try idleout ? It's a logout script for idling shells
its a unix command but there is linux port :
http://rpm.pbone.net/index.php3/stat....i386.rpm.html
other alternatives :
http://aplawrence.com/Unix/piddle.html ftp://ftp.armory.com/pub/admin/nidleout
ismail