new blog 2.0


bash kick - A quick way to get rid of unwanted users from the system.

If you play cyber wargames you may feel a necessity to quickly and efficiently kill other users sessions. This has to be done within seconds and the hit must be precise. "kill -9 $(ps -o pid= -u user)" would be enough to get the user away but it is a bit longish (= not suitable for a stressful time-critical situation). Ideally, you should use a short and simple word, like kick, and have an ability to eliminate your enemy from the system by their username or their TTY. This can be achieved by a simple extension to root's local .bashrc file.

Installation (as root):
tar xjvf kick.tar.bz2
append ". ~/.kick/bashrc.include" to root's .bashrc
type "bash" to restart the shell

kick - if you want to kill all processes of the user , e.g. kick dummy

kick tty - if you want to kill only one particular teletype session, e.g. kick tty pts/0


Axel Werner said...

Very sweet solution!! Thanks a lot for sharing!

again..i learned something new.

mitch said...

Cool, my old ascii art in action :-)