Added RSA toggle and some minor bug fixes