reference/openssl/certparams.xml
497c40ac164d5873fd87f622dfdeb5206392b446
...
...
@@ -5,10 +5,7 @@
5
5
<title>Key/Certificate parameters</title>
6
6
<para>
7
7
Quite a few of the openssl functions require a key or a certificate
8
-
parameter. PHP 4.0.5 and earlier have to use a key or certificate
9
-
<type>resource</type> returned by one of the
10
-
<literal>openssl_get_xxx()</literal> functions.
11
-
Later versions may use one of the following methods:
8
+
parameter. Following methods may be used to get them:
12
9
<itemizedlist>
13
10
<listitem>
14
11
<para>
...
...
@@ -16,19 +13,21 @@
16
13
<orderedlist>
17
14
<listitem>
18
15
<simpara>
19
-
An X.509 resource returned from
20
-
<function>openssl_x509_read</function>
16
+
An <classname>OpenSSLCertificate</classname> instance
17
+
(or prior to PHP 8.0.0, a &resource; of type <literal>OpenSSL X.509</literal>)
18
+
returned from <function>openssl_x509_read</function>
21
19
</simpara>
22
20
</listitem>
23
21
<listitem>
24
22
<simpara>A string having the format
25
23
<filename>file://path/to/cert.pem</filename>; the named file must
26
-
contain a PEM encoded certificate
24
+
contain a <acronym>PEM</acronym> encoded certificate
27
25
</simpara>
28
26
</listitem>
29
27
<listitem>
30
28
<simpara>
31
-
A string containing the content of a certificate, PEM encoded
29
+
A string containing the content of a certificate, <acronym>PEM</acronym>
30
+
encoded, may start with <literal>-----BEGIN CERTIFICATE-----</literal>
32
31
</simpara>
33
32
</listitem>
34
33
</orderedlist>
...
...
@@ -37,26 +36,61 @@
37
36

38
37
<listitem>
39
38
<para>
39
+
Certificate Signing Requests (CSRs)
40
+
<orderedlist>
41
+
<listitem>
42
+
<simpara>
43
+
An <classname>OpenSSLCertificateSigningRequest</classname> instance
44
+
(or prior to PHP 8.0.0, a &resource; of type <literal>OpenSSL X.509 CSR</literal>)
45
+
returned from <function>openssl_csr_new</function>
46
+
</simpara>
47
+
</listitem>
48
+
<listitem>
49
+
<simpara>A string having the format
50
+
<filename>file://path/to/csr.pem</filename>; the named file must
51
+
contain a <acronym>PEM</acronym> encoded <acronym>CSR</acronym>
52
+
</simpara>
53
+
</listitem>
54
+
<listitem>
55
+
<simpara>
56
+
A string containing the content of a <acronym>CSR</acronym>, <acronym>PEM</acronym> encoded,
57
+
may start with <literal>-----BEGIN CERTIFICATE REQUEST-----</literal>
58
+
</simpara>
59
+
</listitem>
60
+
</orderedlist>
61
+
</para>
62
+
</listitem>
63
+

64
+
65
+
<listitem>
66
+
<para>
40
67
Public/Private Keys
41
68
<orderedlist>
42
69
<listitem>
43
-
<simpara>A key resource returned from
44
-
<function>openssl_get_publickey</function> or
70
+
<simpara>
71
+
An <classname>OpenSSLAsymmetricKey</classname> instance
72
+
(or prior to PHP 8.0.0, a &resource; of type <literal>OpenSSL key</literal>)
73
+
returned from <function>openssl_get_publickey</function> or
45
74
<function>openssl_get_privatekey</function>
46
75
</simpara>
47
76
</listitem>
48
77
<listitem>
49
-
<simpara>For public keys only: an X.509 resource</simpara>
78
+
<simpara>
79
+
For public keys only: an <classname>OpenSSLCertificate</classname> instance
80
+
(or prior to PHP 8.0.0, a &resource; of type <literal>OpenSSL X.509</literal>)
81
+
</simpara>
50
82
</listitem>
51
83
<listitem>
52
84
<simpara>A string having the format
53
85
<filename>file://path/to/file.pem</filename> - the named file must
54
-
contain a PEM encoded certificate/private key (it may contain both)
86
+
contain a <acronym>PEM</acronym> encoded certificate/private key (it may contain both)
55
87
</simpara>
56
88
</listitem>
57
89
<listitem>
58
90
<simpara>
59
-
A string containing the content of a certificate/key, PEM encoded
91
+
A string containing the content of a certificate/key,
92
+
<acronym>PEM</acronym> encoded, may start with
93
+
<literal>-----BEGIN PUBLIC KEY-----</literal>
60
94
</simpara>
61
95
</listitem>
62
96
<listitem>
63
97