[#PKCS12_gen_mac] = PKCS12_gen_mac :mrdocs: Generate the HMAC for a PKCS#12 object using configured MAC parameters. == Synopsis Declared in `<openssl/pkcs12.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int PKCS12_gen_mac( xref:PKCS12.adoc[PKCS12]* p12, char const* pass, int passlen, unsigned char* mac, unsigned int* maclen); ---- == Return Value 1 on success, 0 on error. == Parameters [cols="1,4"] |=== | Name| Description | *p12* | PKCS#12 structure with MAC parameters already set. | *pass* | Passphrase for the HMAC. | *passlen* | Length of `pass,` or ‐1 to use strlen(). | *mac* | Buffer to receive the MAC value. | *maclen* | Address to receive MAC length in bytes on input and output. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#