#/bin/csh -f    This program is written in csh  (C-shell)
# vfrm (vfind-remove)  Version 1.0 Feb. 1993
# Copyright Feb 1993 by Peter V. Radatti.  All rights reserved.

echo "Vfind Interactive Disinfector. Example Program"
echo "Please note that if you remove any important system files it may"
echo "cause the system to crash or not reboot."
echo " "
foreach subname (`find / -type f -print | vfind --quiet=2 | grep "##==>>>>" | grep "FILE:"|awk -F: '{print $2}'`)
	echo "Infected filename is: $subname"
	echo -n "Erase it now? (y/n): "
	set ans = $<
	while ("$ans" != "y" && "$ans" != "n")
		echo -n "Please answer y or n : "
		set ans = $<
	end
	if ("$ans" == "y") then
		/bin/rm $subname
		if ($status) then
			echo "An error attempting to remove this file has occurred."
			echo "This may be caused by the file having already been erased"
			echo "or a file permission problem.  Please review the file"
			echo "later. PROCESSING CONTINUES"
	endif
end
