New

Creates a new instance of the same type of the cipher object. This function can be used as a generic means to clone a cipher object if two cipher operations must be carried out in parallel.

Synopsis

#include “fmciphobj.h”
struct CipherObj * (*New)(struct CipherObj * ctx);
Parameter Description
ctx The address of an existing cipher object. This parameter must not be NULL.

Return Value

Address of a new instance of the Cipher Object. If the system does not have enough memory to complete the operation, NULL is returned.

Comments

The returned Cipher Object should be freed by calling its Free() function (see Free).