My system administrator placed in urgent call to my
cell phone this morning as I was travelling to work.
He had noticed a suspicious looking Perl process
running under my account on the server. Unlike a normal
script, the whole contents of the script showed up in
'ps'. It could create and rename files and many other
file system operations. It had basically no comments.
It looked like a cracker script.
I didn't recognize any such such script and said I
would be in right away to look at it.
It turned out part of shfs.
To save some stress like this in the future, please
accept the first part of the attached patch, which
simply adds a comment to the top of the script
explaining what it is:
# part of the shfs package. See http://shfs.sf.net/
The second part of the patch is a very lightly tested
refactoring of some of the Perl code. It replaces a
very long if/else chain with a couple of lines which I
think should work compatibly. My version does like the
feature of comparing the command name against a list of
known commands before it's executed. That could be
added with a simple hash table lookup. Let me know if
you are interested in further help with that.
improvements to Perl script.