Lines Matching refs:rsa
15 import rsa
16 import rsa.cli
17 import rsa.util
18 from rsa._compat import PY2
95 cls.pub_key, cls.priv_key = rsa.newkeys(512)
127 self.assertExits(1, rsa.cli.keygen)
132 rsa.cli.keygen()
145 rsa.cli.keygen()
155 rsa.PrivateKey.load_pkcs1(pemfile.read())
161 rsa.cli.keygen()
171 rsa.PrivateKey.load_pkcs1(derfile.read(), format='DER')
179 rsa.cli.keygen()
190 rsa.PublicKey.load_pkcs1(pemfile.read())
196 self.assertExits(1, rsa.cli.decrypt)
200 self.assertExits(1, rsa.cli.encrypt)
209 rsa.cli.encrypt()
213 rsa.cli.decrypt()
226 rsa.cli.encrypt()
235 self.assertRaises(rsa.DecryptionError, rsa.cli.decrypt)
241 self.assertExits(1, rsa.cli.verify)
245 self.assertExits(1, rsa.cli.sign)
254 rsa.cli.sign()
258 rsa.cli.verify()
269 rsa.cli.sign()
278 self.assertExits('Verification failed.', rsa.cli.verify)
289 rsa.util.private_to_public()
293 key = rsa.PublicKey.load_pkcs1(pemfile.read())