API Reference | developer.brewmp.com API Reference | developer.brewmp.com

Developer

API Reference

ICIPHERFACTORY_QUERYCIPHER()

Brew Release
Brew MP 1.0.2
Description
Checks the factory to determine if a cipher with the specified characteristics can be created. This may be used, for example, by a service that needs to valid a database of available ciphers (such as SSL) without explicitly creating the cipher.
Params
pICipherFactory
[]:
Pointer to ICipherFactory interface object.
cipher
[]:
Class ID of requested cipher algorithm.
mode
[]:
Class ID of requested block chaining mode algorithm. For stream ciphers this parameter is ignored and should be 0.
padding
[]:
Type of padding to use for block ciphers. For stream ciphers or streaming block modes, this parameter is ignored.
keyLen
[]:
Required key length in bytes. Unless an unusual key length is required, this value may be 0 to skip this check.
Interface
Prototype
  •    int ICipherFactory_QueryCipher(ICipherFactory *pICipherFactory,
                       AEECLSID cipher, AEECLSID mode,
                       int padding, unsigned keyLen);
    
Return
  • AEE_SUCCESS: cipher can be created. AEE_ENOMEMORY: insufficient memory. AEE_ECLASSNOTSUPPORT: cipher is not supported as specified. This could mean that the algorithm is not available, the specific mode or padding is not supported or the key length is not supported.
Side Effect
  • None
Comments
None.