Old school password cracker

This code was taken from the book Violent Python
Portscanner, host and list of ports

Code was taken from Violent Python book