#ifndef _PKCS12_UTILS_H_
#define _PKCS12_UTILS_H_
#include <Security/cssmtype.h>
#include <CoreFoundation/CFString.h>
#include <security_pkcs12/pkcs12Templates.h>
#ifdef __cplusplus
extern "C" {
#endif
bool p12DataToInt(
const CSSM_DATA &cdata,
uint32 &u);
typedef enum {
PW_None,
PW_PKCS5_v1_5,
PW_PKCS5_v2,
PW_PKCS12
} PKCS_Which;
bool pkcsOidToParams(
const CSSM_OID *oid,
CSSM_ALGORITHMS &keyAlg, CSSM_ALGORITHMS &encrAlg, CSSM_ALGORITHMS &pbeHashAlg, uint32 &keySizeInBits,
uint32 &blockSizeInBytes, CSSM_PADDING &padding, CSSM_ENCRYPT_MODE &mode, PKCS_Which &pkcs);
const char *p12BagTypeStr(
NSS_P12_SB_Type type);
const char *p7ContentInfoTypeStr(
NSS_P7_CI_Type type);
#ifdef __cplusplus
}
#endif
#endif