From 8a2e94d4ba7d1316ff75162af61f3a12eebd2f16 Mon Sep 17 00:00:00 2001 From: Lukas Puehringer Date: Wed, 24 Feb 2021 13:13:36 +0100 Subject: [PATCH] Add EdDSA signature length constant EdDSA signatures must be 64 bytes long as per RFC 8032 5.1.6. (6). This commit adds a constant for this length which may be used to to pad shorter signatures. --- securesystemslib/gpg/eddsa.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/securesystemslib/gpg/eddsa.py b/securesystemslib/gpg/eddsa.py index 2d5eafc3..55df62d8 100644 --- a/securesystemslib/gpg/eddsa.py +++ b/securesystemslib/gpg/eddsa.py @@ -37,6 +37,8 @@ # EdDSA Point Format (see RFC4880-bis8 13.3.) ED25519_PUBLIC_KEY_LENGTH = 33 ED25519_PUBLIC_KEY_PREFIX = 0x40 +# EdDSA signature byte length (see RFC 8032 5.1.6. (6)) +ED25519_SIG_LENGTH = 64