|
1 |
| -.\" $OpenBSD: X509_policy_check.3,v 1.4 2021/07/29 12:39:47 schwarze Exp $ |
| 1 | +.\" $OpenBSD: X509_policy_check.3,v 1.5 2021/07/30 15:01:40 schwarze Exp $ |
2 | 2 | .\"
|
3 | 3 | .\" Copyright (c) 2021 Ingo Schwarze <schwarze@openbsd.org>
|
4 | 4 | .\"
|
|
14 | 14 | .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
15 | 15 | .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
16 | 16 | .\"
|
17 |
| -.Dd $Mdocdate: July 29 2021 $ |
| 17 | +.Dd $Mdocdate: July 30 2021 $ |
18 | 18 | .Dt X509_POLICY_CHECK 3
|
19 | 19 | .Os
|
20 | 20 | .Sh NAME
|
|
44 | 44 | input argument contains the prospective certification path
|
45 | 45 | according to RFC 5280 paragraph 6.1.1(a), starting with the
|
46 | 46 | target certificate and ending with the trust anchor.
|
47 |
| -If a policy tree is returned, the reference count of each of the |
48 |
| -.Fa certs |
49 |
| -is incremented by 1. |
50 | 47 | .Pp
|
51 | 48 | The
|
52 | 49 | .Fa policy_oids
|
@@ -79,7 +76,14 @@ as defined by RFC 5280 paragraph 6.1.1(e).
|
79 | 76 | It disables policy mapping in the certification path.
|
80 | 77 | .El
|
81 | 78 | .Pp
|
82 |
| -Upon success, a pointer to the |
| 79 | +Upon success and in some cases of failure, the storage location pointed to by |
| 80 | +.Fa pexplicit_policy |
| 81 | +is set to 1 if |
| 82 | +.Dv X509_V_FLAG_EXPLICIT_POLICY |
| 83 | +was requested. |
| 84 | +Otherwise, it is set to 0. |
| 85 | +.Pp |
| 86 | +In many cases of success and in a few cases of failure, a pointer to the |
83 | 87 | .Vt valid_policy_tree
|
84 | 88 | output value mentioned in RFC 5280 section 6.1.6 is returned in
|
85 | 89 | .Pf * Fa ptree .
|
|
94 | 98 | and an empty
|
95 | 99 | .Fa qualifier_set .
|
96 | 100 | .Pp
|
97 |
| -Upon success and in some cases of failure, the storage location pointed to by |
98 |
| -.Fa pexplicit_policy |
99 |
| -is set to 1 if |
100 |
| -.Dv X509_V_FLAG_EXPLICIT_POLICY |
101 |
| -was requested. |
102 |
| -Otherwise, it is set to 0. |
103 |
| -.Pp |
| 101 | +If a policy tree is returned, the reference count of each of the |
| 102 | +.Fa certs |
| 103 | +is incremented by 1. |
| 104 | +In that case, the caller is responsible for calling |
104 | 105 | .Fn X509_policy_tree_free
|
105 |
| -releases all memory used by the |
| 106 | +to release all memory used by the |
106 | 107 | .Fa tree
|
107 |
| -and decrements the reference counts |
| 108 | +and to decrement the reference counts |
108 | 109 | of the certificates referenced from it by 1.
|
109 | 110 | If
|
110 | 111 | .Fa tree
|
111 | 112 | is a
|
112 | 113 | .Dv NULL
|
113 |
| -pointer, no action occurs. |
| 114 | +pointer, |
| 115 | +.Fn X509_policy_tree_free |
| 116 | +has no effect. |
114 | 117 | .Sh RETURN VALUES
|
115 | 118 | .Fn X509_policy_check
|
116 | 119 | returns these values:
|
|
0 commit comments