Cleaned up create_rsa a bit

Took the functions for creating RSA primitives into a helper function. Basically trying to duplicate a switch-case statement in python. Somewhat new to python, so a better way to do this most definitely exists. Thoughts?