Пример #1
0
 def test_object(self):
     key = object()
     with pytest.raises(JOSEError):
         ECKey(key, ALGORITHMS.ES256)
Пример #2
0
 def test_string_secret(self):
     key = 'secret'
     with pytest.raises(JOSEError):
         ECKey(key, ALGORITHMS.ES256)
Пример #3
0
 def test_EC_key(self):
     ECKey(private_key, ALGORITHMS.ES256)
Пример #4
0
 def test_EC_key(self):
     key = ecdsa.SigningKey.from_pem(private_key)
     ECKey(key, ALGORITHMS.ES256)
Пример #5
0
def alg():
    return ECKey(ECKey.SHA256)