http://piggledy.org/scripts/censor.py
Python script that search through files for clear password entered inadvertently and remove them (need to run as root).
On bash history:
$ censory.py -r .bash_history
Found password of dummy user
Check for weak password against a dictionnary:
$ censory.py /usr/share/dict/cracklib-small
http://piggledy.org/scripts/set_bg
http://piggledy.org/scripts/su_bg
http://piggledy.org/scripts/ssh_bg
This set of Bash scripts allows to change the background of the current terminal when issuing the su command, or setting specific background when ssh-ing to an other machine. Put your .xpm backgrounds in ~/.termbg/, with the following naming convention:
Make sure the set_bg script is in your $PATH as it's used by the 2 other scripts.
http://piggledy.org/scripts/horodate.py
Python script that prefix the current time on new lines received on stdin, quite useful when watching logfiles, running daemons ...
$ make|horodate.py
20 Dec 00:14:48 [ -d build ] || mkdir build; \
20 Dec 00:14:48 cd build && cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_VERBOSE_MAKEFILE=0 ..
20 Dec 00:14:49 make -C build all
20 Dec 00:14:49 make[1]: entrant dans le repertoire " /home/lds/Developpement/tools/wolfotrack/build "
20 Dec 00:14:49 Scanning dependencies of target sdlwolf3d
20 Dec 00:14:50 [ 4%] Building C object CMakeFiles/sdlwolf3d.dir/objs.o
20 Dec 00:14:51 [ 30%] Building C object CMakeFiles/sdlwolf3d.dir/wl_act2.o
20 Dec 00:14:51 [ 43%] Building C object CMakeFiles/sdlwolf3d.dir/wl_game.o
20 Dec 00:14:52 [ 56%] Building C object CMakeFiles/sdlwolf3d.dir/wl_play.o
http://piggledy.org/scripts/mhssh.py
http://piggledy.org/scripts/process.py
Python script that allows to connect by ssh to multiple hosts. Commands are then sent to all hosts and the output of all hosts is displayed in the same terminal (the output is factorized when all hosts give the same output). process.py is a dependancy of mhssh that was taken from NuFW test scripts and was written by Victor Stinner.
$ ./mhssh.py 10.8.0.6 10.8.0.1
(all) | ~ $ date
(all) |lun fev 11 19:28:38 CET 2008
(all) | ~ $ echo $RANDOM
10.8.0.6 |18932
10.8.0.1 |21726
(all) | ~ $
(all) |exit
Host 10.8.0.1 disconnected.
Host 10.8.0.6 disconnected.