Misc python crypto stuff