Thu, 22 Jan 2015 13:21:57 +0100
Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4 /*
5 * pkix_policynode.h
6 *
7 * PolicyNode Type Definitions
8 *
9 */
11 #ifndef _PKIX_POLICYNODE_H
12 #define _PKIX_POLICYNODE_H
14 #include "pkix_tools.h"
16 #ifdef __cplusplus
17 extern "C" {
18 #endif
20 /* This structure reflects the contents of a policy node...
21 */
22 struct PKIX_PolicyNodeStruct {
23 PKIX_PL_OID *validPolicy;
24 PKIX_List *qualifierSet; /* CertPolicyQualifiers */
25 PKIX_Boolean criticality;
26 PKIX_List *expectedPolicySet; /* OIDs */
27 PKIX_PolicyNode *parent;
28 PKIX_List *children; /* PolicyNodes */
29 PKIX_UInt32 depth;
30 };
32 PKIX_Error *
33 pkix_SinglePolicyNode_ToString(
34 PKIX_PolicyNode *node,
35 PKIX_PL_String **pString,
36 void *plContext);
38 PKIX_Error *
39 pkix_PolicyNode_GetChildrenMutable(
40 PKIX_PolicyNode *node,
41 PKIX_List **pChildren, /* PolicyNodes */
42 void *plContext);
44 PKIX_Error *
45 pkix_PolicyNode_Create(
46 PKIX_PL_OID *validPolicy,
47 PKIX_List *qualifierSet, /* CertPolicyQualifiers */
48 PKIX_Boolean criticality,
49 PKIX_List *expectedPolicySet, /* OIDs */
50 PKIX_PolicyNode **pObject,
51 void *plContext);
53 PKIX_Error *
54 pkix_PolicyNode_AddToParent(
55 PKIX_PolicyNode *parentNode,
56 PKIX_PolicyNode *child,
57 void *plContext);
59 PKIX_Error *
60 pkix_PolicyNode_Prune(
61 PKIX_PolicyNode *node,
62 PKIX_UInt32 depth,
63 PKIX_Boolean *pDelete,
64 void *plContext);
66 PKIX_Error *
67 pkix_PolicyNode_RegisterSelf(
68 void *plContext);
70 #ifdef __cplusplus
71 }
72 #endif
74 #endif /* _PKIX_POLICYNODE_H */