예제 #1
0
 def test_generate_key_pair(self):
     sk_b58, vk_b58 = ed25519_generate_key_pair()
     assert len(base58.b58decode(sk_b58)) == 32
     assert len(base58.b58decode(vk_b58)) == 32
     assert SigningKey.encode(SigningKey.decode(sk_b58)) == sk_b58
     assert VerifyingKey.encode(VerifyingKey.decode(vk_b58)) == vk_b58
예제 #2
0
 def test_signing_key_decode(self, sk_ilp):
     private_value = SigningKey.decode(sk_ilp['b58'])
     assert private_value == base64_add_padding(sk_ilp['b64'])