diff options
author | lloyd <[email protected]> | 2013-12-05 02:12:29 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2013-12-05 02:12:29 +0000 |
commit | 37609eba0f730fdcb0daf84d5f9c239b27fb010c (patch) | |
tree | b0786f016b5b34ca3f3b9a59b6bfc6dd3ad329e6 /src/algo_base/key_spec.h | |
parent | 8fedb5ba83acc84c62f8f20ac962c0acf643e3a8 (diff) |
Add key length multiple
Diffstat (limited to 'src/algo_base/key_spec.h')
-rw-r--r-- | src/algo_base/key_spec.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/algo_base/key_spec.h b/src/algo_base/key_spec.h index 73cd9126f..15881c1a6 100644 --- a/src/algo_base/key_spec.h +++ b/src/algo_base/key_spec.h @@ -79,6 +79,13 @@ class BOTAN_DLL Key_Length_Specification return keylen_mod; } + Key_Length_Specification multiple(size_t n) const + { + return Key_Length_Specification(n * min_keylen, + n * max_keylen, + n * keylen_mod); + } + private: size_t min_keylen, max_keylen, keylen_mod; }; |