From 006e6d3b6f52e193b14dc17db4502e14f9ffeb82 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Tue, 26 Aug 2014 21:35:25 -0400 Subject: Another ed25519 tweak: store secret keys in expanded format This will be needed/helpful for the key blinding of prop224, I believe. --- src/test/test_crypto.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/test') diff --git a/src/test/test_crypto.c b/src/test/test_crypto.c index 8b04bc8e50..a4ca609247 100644 --- a/src/test/test_crypto.c +++ b/src/test/test_crypto.c @@ -1318,10 +1318,12 @@ test_crypto_ed25519_test_vectors(void *arg) for (i = 0; items[i].pk; ++i) { ed25519_keypair_t kp; ed25519_signature_t sig; + uint8_t sk_seed[32]; uint8_t *msg; size_t msg_len; - base16_decode((char*)kp.seckey.seckey, sizeof(kp.seckey.seckey), + base16_decode((char*)sk_seed, sizeof(sk_seed), items[i].sk, 64); + ed25519_secret_key_from_seed(&kp.seckey, sk_seed); tt_int_op(0, ==, ed25519_public_key_generate(&kp.pubkey, &kp.seckey)); test_memeq_hex(kp.pubkey.pubkey, items[i].pk); -- cgit v1.2.3-54-g00ecf