diff options
author | Jeffrey Walton <noloader@gmail.com> | 2017-05-06 08:18:54 -0400 |
---|---|---|
committer | Jeffrey Walton <noloader@gmail.com> | 2017-05-06 08:18:54 -0400 |
commit | 6ad999ef2f1970837718c7cc52992f3895615da5 (patch) | |
tree | e4e50cc6b57ffb6821eaefb1faff2ab0bcee68f1 /kalyna.h | |
parent | a5c67cfdd6ad7eeb6e5414044ab3a992d3ce74b9 (diff) | |
download | cryptopp-git-6ad999ef2f1970837718c7cc52992f3895615da5.tar.gz |
Updated documentation
Diffstat (limited to 'kalyna.h')
-rw-r--r-- | kalyna.h | 18 |
1 files changed, 14 insertions, 4 deletions
@@ -97,10 +97,20 @@ public: class CRYPTOPP_NO_VTABLE Base : public VariableBlockCipherImpl<Kalyna_Info>
{
public:
- // Naming follows DSTU 7624:2014, where blocksize is specified first and then key length.
- // DSTU is a little more complex with more parameters, dashes, underscores. (Thanks RO).
- std::string AlgorithmName() const {return !BlockSize() ? StaticAlgorithmName() :
- "Kalyna-" + IntToString(BlockSize())+"("+IntToString(m_kl*8)+")";}
+ //! \brief Provides the name of this algorithm
+ //! \return the standard algorithm name
+ //! \details If the object is unkeyed, then the generic name "Kalyna" is returned
+ //! to the caller. If the algorithm is keyed, then a two or three part name is
+ //! returned to the caller. The name follows DSTU 7624:2014, where block size is
+ //! provided first and then key length. The library uses a dash to identify block size
+ //! and parenthesis to identify key length. For example, Kalyna-128(256) is Kalyna
+ //! with a 128-bit block size and a 256-bit key length. If a mode is associated
+ //! with the object, then it follows as expected. For example, Kalyna-128(256)/ECB.
+ //! DSTU is a little more complex with more parameters, dashes, underscores, but the
+ //! library does not use the delimiters or full convention.
+ std::string AlgorithmName() const {
+ return m_blocksize ? "Kalyna-" + IntToString(m_blocksize*8) + "(" + IntToString(m_kl*8) + ")" : StaticAlgorithmName();
+ }
unsigned int OptimalDataAlignment() const {
return GetAlignmentOf<word64>();
|