From 77cd0a655872a5bd64b890102127d256235e7cc3 Mon Sep 17 00:00:00 2001 From: John-Mark Gurney Date: Sat, 3 Dec 2022 12:51:40 -0800 Subject: [PATCH] support generating a private/public key pair by running this... Need to think a bit more as it requires the test library, which isn't immediately available... Likely need to make this a proper package and put the library there.. --- syote_comms.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/syote_comms.py b/syote_comms.py index 07f9ed1..d8bd667 100644 --- a/syote_comms.py +++ b/syote_comms.py @@ -225,6 +225,12 @@ def comms_process_wrap(state, input): return outbuf._from() +if __name__ == '__main__': + key = X25519.gen() + + print(key.getpriv().hex()) + print(key.getpub().hex()) + class TestX25519(unittest.TestCase): PUBLIC_BYTES = EC_PUBLIC_BYTES PRIVATE_BYTES = EC_PRIVATE_BYTES