diff options
Diffstat (limited to 'src/lib/pubkey/pk_keys.h')
-rw-r--r-- | src/lib/pubkey/pk_keys.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/pubkey/pk_keys.h b/src/lib/pubkey/pk_keys.h index 0aa9caf54..e7e86d8fa 100644 --- a/src/lib/pubkey/pk_keys.h +++ b/src/lib/pubkey/pk_keys.h @@ -19,6 +19,11 @@ namespace Botan { class RandomNumberGenerator; /** +* The two types of signature format supported by Botan. +*/ +enum Signature_Format { IEEE_1363, DER_SEQUENCE }; + +/** * Public Key Base Class. */ class BOTAN_PUBLIC_API(2,0) Public_Key @@ -118,6 +123,11 @@ class BOTAN_PUBLIC_API(2,0) Public_Key */ virtual size_t message_part_size() const { return 0; } + virtual Signature_Format default_x509_signature_format() const + { + return (this->message_parts() >= 2) ? DER_SEQUENCE : IEEE_1363; + } + /** * This is an internal library function exposed on key types. * In almost all cases applications should use wrappers in pubkey.h |