]>
git.saurik.com Git - apple/security.git/blob - SecurityTests/clxutils/p12Parse/pkcs12Utils.h
1 #ifndef _PKCS12_UTILS_H_
2 #define _PKCS12_UTILS_H_
4 #include <Security/cssmtype.h>
5 #include <CoreFoundation/CFString.h>
6 #include <security_pkcs12/pkcs12Templates.h>
12 /* CSSM_DATA --> uint32. Returns true if OK. */
14 const CSSM_DATA
&cdata
,
18 PW_None
, /* not comprehended */
19 PW_PKCS5_v1_5
, /* PKCS5 v1.5 */
20 PW_PKCS5_v2
, /* PKCS5 v2.0, not used by this module but parsed here */
21 PW_PKCS12
/* PKCS12 */
24 /* returns false if OID not found */
27 CSSM_ALGORITHMS
&keyAlg
, // e.g., CSSM_ALGID_DES
28 CSSM_ALGORITHMS
&encrAlg
, // e.g., CSSM_ALGID_3DES_3KEY_EDE
29 CSSM_ALGORITHMS
&pbeHashAlg
, // SHA1 or MD5
30 uint32
&keySizeInBits
,
31 uint32
&blockSizeInBytes
, // for IV, optional
32 CSSM_PADDING
&padding
, // CSSM_PADDING_PKCS7, etc.
33 CSSM_ENCRYPT_MODE
&mode
, // CSSM_ALGMODE_CBCPadIV8, etc.
34 PKCS_Which
&pkcs
); // PW_PKCS5_v1_5 or PW_PKCS12
36 const char *p12BagTypeStr(
37 NSS_P12_SB_Type type
);
38 const char *p7ContentInfoTypeStr(
45 #endif /* _PKCS12_UTILS_H_ */