AES API
IntroductionAPIs and platform interfaces for using the Advanced Encryption Standard (AES). Support is provided for the following cryptographic libraries: - Brian Gladman's AES. (default) - OpenSSL. If one of these libraries is not available, these APIs will need to be implemented for your platform. GroupsAES 128-bit CBC Frame Mode APIAPI to encrypt or decrypt using AES-128 in CBC frame mode. DiscussionCall AES_CBCFrame_Init to initialize the context. Don't use the context until it has been initialized. Call AES_CBCFrame_Update to encrypt or decrypt N bytes of input and generate N bytes of output. Call AES_CBCFrame_Final to finalize the context. After finalizing, you must call AES_CBCFrame_Init to use it again. See the unit test for an example of using it. Group members:
AES 128-bit Counter Mode APIAPI to encrypt or decrypt using AES-128 in counter mode. DiscussionCall AES_CTR_Init to initialize the context. Don't use the context until it has been initialized. Call AES_CTR_Update to encrypt or decrypt N bytes of input and generate N bytes of output. Call AES_CTR_Final to finalize the context. After finalizing, you must call AES_CTR_Init to use it again. See the unit test for an example of using it. Group members:
Functions
AES_CBCFrame_FinalFinalizes a context for AES-128 in CBC frame mode when no longer needed. Context must not be used after this. void AES_CBCFrame_Final( AES_CBCFrame_Context *inContext ); ParametersAES_CBCFrame_InitInitializes a context for AES-128 in CBC frame mode. Must be called before other AES_CBCFrame_* functions. OSStatus AES_CBCFrame_Init( AES_CBCFrame_Context *inContext, const uint8_t inKey[ kAES_CBCFrame_Size ], const uint8_t inIV[ kAES_CBCFrame_Size ], Boolean inEncrypt ); ParametersReturn ValuekNoErr if successful or an error code indicating failure. AES_CBCFrame_UpdateEncrypts or decrypts N bytes of data using AES-128 in CBC frame mode. OSStatus AES_CBCFrame_Update( AES_CBCFrame_Context *inContext, const void *inSrc, size_t inLen, void *inDst ); Parameters
Return ValuekNoErr if successful or an error code indicating failure. AES_CBCFrame_Update2Encrypts or decrypts 2 chunnks of data, N bytes each using AES-128 in CBC frame mode. OSStatus AES_CBCFrame_Update2( AES_CBCFrame_Context *inContext, const void *inSrc1, size_t inLen1, const void *inSrc2, size_t inLen2, void *inDst ); Parameters
Return ValuekNoErr if successful or an error code indicating failure. AES_CTR_FinalFinalizes a context for AES-128 in counter mode when no longer needed. Context must not be used after this. void AES_CTR_Final( AES_CTR_Context *inContext ); ParametersAES_CTR_InitInitializes a context for AES-128 in counter mode. Must be called before other AES_CTR_* functions. OSStatus AES_CTR_Init( AES_CTR_Context *inContext, const uint8_t inKey[ kAES_CTR_Size ], const uint8_t inNonce[ kAES_CTR_Size ] ); ParametersReturn ValuekNoErr if successful or an error code indicating failure. AES_CTR_UpdateEncrypts or decrypts N bytes of data using AES-128 in counter mode. OSStatus AES_CTR_Update( AES_CTR_Context *inContext, const void *inSrc, size_t inLen, void *inDst ); Parameters
Return ValuekNoErr if successful or an error code indicating failure. |