Pastebin

Paste #292:

< previous paste - next paste>

Pasted by Anonymous Coward

Download View as text

A friend of mine wanted to keep track of the other users on the UNIX systems of our university. There is a nice command "last" on UNIX which will list the last users to have logged in. So he wrote a script that'd log in to all workstations of the department by remote shell and run the "last" command, with the results sent back to the originating host, to be collected in aggregate form.

He called this little script "last" -- same name as the UNIX system command -- and put it in his home directory. His path was set up so his home directory had a higher precedence than the UNIX bin directories. So when he ran the "last" command, it would use his own script instead of the system command.

So he ran the script. It logged in to all the other workstations just fine. Then it ran the "last" command -- the one in his home directory, of course, not the system command. You can guess what happened. It got in an infinite loop that tried to log into every workstation an infinite number of times. This very effectively nuked off the whole department, and all workstations had to be shut down for it to stop. 

New Paste


Do not write anything in this field if you're a human.

Go to most recent paste.