Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(2)  |  Derive(0)  |  Import(0)

src/c/r/crtauth-HEAD/crtauth/ssh.py   crtauth(Download)
    def __init__(self, priv_key):
        self.key = rsa.RSAPrivateKey(priv_key)
 
    def sign_challenge(self, challenge):
        return self.key.sign(challenge.serialize())

src/c/r/crtauth-HEAD/test/rsa_test.py   crtauth(Download)
    def __init__(self, *args, **kwargs):
        TestCase.__init__(self, *args, **kwargs)
        self.private_key = rsa.RSAPrivateKey(private_key)
        self.public_key = rsa.RSAPublicKey(public_key)