Import random in both python and python3

This is completely untested... I did it from the github online editor even since it doesn't support ecdsa keys and screw making more keys :p