Security Scol plugin
Public Member Functions | Protected Member Functions | List of all members
SM4::Enc Class Reference

Encryption transformation. More...

#include <sm4.h>

Inheritance diagram for SM4::Enc:
SM4::Base BlockCipherImpl< SM4_Info > AlgorithmImpl< BASE, ALGORITHM_INFO >

Public Member Functions

std::string AlgorithmProvider () const
 
- Public Member Functions inherited from BlockCipherImpl< SM4_Info >
unsigned int BlockSize () const
 
- Public Member Functions inherited from AlgorithmImpl< BASE, ALGORITHM_INFO >
std::string AlgorithmName () const
 The algorithm name.
 

Protected Member Functions

void ProcessAndXorBlock (const byte *inBlock, const byte *xorBlock, byte *outBlock) const
 
- Protected Member Functions inherited from SM4::Base
void UncheckedSetKey (const byte *userKey, unsigned int keyLength, const NameValuePairs &params)
 

Additional Inherited Members

- Static Public Member Functions inherited from AlgorithmImpl< BASE, ALGORITHM_INFO >
static std::string CRYPTOPP_API StaticAlgorithmName ()
 The algorithm name.
 
- Protected Attributes inherited from SM4::Base
SecBlock< word32, AllocatorWithCleanup< word32 > > m_rkeys
 
SecBlock< word32, AllocatorWithCleanup< word32 > > m_wspace
 

Detailed Description

Encryption transformation.

Enc provides implementation for encryption transformation. All key sizes are supported.

SM4 encryption is accelerated on machines with AES-NI. Decryption is not accelerated because it is not profitable. Thanks to Markku-Juhani Olavi Saarinen.

Since
Crypto++ 6.0, AESNI encryption since Crypto++ 8.0

Definition at line 66 of file sm4.h.

Member Function Documentation

◆ AlgorithmProvider()

ANONYMOUS_NAMESPACE_END std::string SM4::Enc::AlgorithmProvider ( ) const

Definition at line 104 of file sm4.cpp.

◆ ProcessAndXorBlock()

void SM4::Enc::ProcessAndXorBlock ( const byte inBlock,
const byte xorBlock,
byte outBlock 
) const
protected

Definition at line 136 of file sm4.cpp.


The documentation for this class was generated from the following files: