예제 #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)