Developer Reference

Contents

MGF

Generates a pseudorandom mask of the specified length using a selected hash algorithm.

Syntax

IppStatus ippsMGF(const Ipp8u
*pSeed
, int
seedLen
, Ipp8u*
pMask
, int
maskLen
,
IppHashAlgId
hashAlg
);
Include Files
ippcp.h
Parameters
pSeed
Pointer to the input octet string.
seedLen
Length of the input string.
pMask
Pointer to the output pseodorandom mask.
maskLen
Desired length of the output.
hashAlg
Identifier of the hash algorithm.
Description
The function generates a pseudorandom mask of the specified length using the hash algorithm defined by
algID
. The
hashAlg
parameter
can take one of the values listed in table Supported Hash Algorithms.
Return Values
ippStsNoErr
Indicates no error. Any other value indicates an error or warning.
ippStsNullPtrErr
Indicates an error condition if
pMask
pointer is
NULL
.
ippStsLengthErr
Indicates an error condition if any of the specified lengths is negative or zero.
ippStsNotSupportedModeErr
Indicates an error condition if the
hashAlg
parameter does not match any
value of
IppHashAlg
listed in table Supported Hash Algorithms
.

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804