reference/openssl/functions/openssl-public-encrypt.xml
d1e3ea622e5d4f542cd36eca59a9f22aa0142633
...
...
@@ -1,6 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.openssl-public-encrypt">
3
+
<refentry xml:id="function.openssl-public-encrypt" xmlns="http://docbook.org/ns/docbook">
4
4
<refnamediv>
5
5
<refname>openssl_public_encrypt</refname>
6
6
<refpurpose>Encrypts data with public key </refpurpose>
...
...
@@ -11,14 +11,14 @@
11
11
<methodsynopsis>
12
12
<type>bool</type><methodname>openssl_public_encrypt</methodname>
13
13
<methodparam><type>string</type><parameter>data</parameter></methodparam>
14
-
<methodparam><type>string</type><parameter role="reference">crypted</parameter></methodparam>
15
-
<methodparam><type>mixed</type><parameter>key</parameter></methodparam>
16
-
<methodparam choice="opt"><type>int</type><parameter>padding</parameter><initializer>OPENSSL_PKCS1_PADDING</initializer></methodparam>
14
+
<methodparam><type>string</type><parameter role="reference">encrypted_data</parameter></methodparam>
15
+
<methodparam><type class="union"><type>OpenSSLAsymmetricKey</type><type>OpenSSLCertificate</type><type>array</type><type>string</type></type><parameter>public_key</parameter></methodparam>
16
+
<methodparam choice="opt"><type>int</type><parameter>padding</parameter><initializer><constant>OPENSSL_PKCS1_PADDING</constant></initializer></methodparam>
17
17
</methodsynopsis>
18
18
<para>
19
19
<function>openssl_public_encrypt</function> encrypts <parameter>data</parameter>
20
-
with public <parameter>key</parameter> and stores the result into
21
-
<parameter>crypted</parameter>. Encrypted data can be decrypted via
20
+
with public <parameter>public_key</parameter> and stores the result into
21
+
<parameter>encrypted_data</parameter>. Encrypted data can be decrypted via
22
22
<function>openssl_private_decrypt</function>.
23
23
</para>
24
24
<para>
...
...
@@ -40,7 +40,7 @@
40
40
</listitem>
41
41
</varlistentry>
42
42
<varlistentry>
43
-
<term><parameter>crypted</parameter></term>
43
+
<term><parameter>encrypted_data</parameter></term>
44
44
<listitem>
45
45
<para>
46
46
This will hold the result of the encryption.
...
...
@@ -48,7 +48,7 @@
48
48
</listitem>
49
49
</varlistentry>
50
50
<varlistentry>
51
-
<term><parameter>key</parameter></term>
51
+
<term><parameter>public_key</parameter></term>
52
52
<listitem>
53
53
<para>
54
54
The public key.
...
...
@@ -78,6 +78,31 @@
78
78
</para>
79
79
</refsect1>
80
80

81
+
<refsect1 role="changelog">
82
+
&reftitle.changelog;
83
+
<informaltable>
84
+
<tgroup cols="2">
85
+
<thead>
86
+
<row>
87
+
<entry>&Version;</entry>
88
+
<entry>&Description;</entry>
89
+
</row>
90
+
</thead>
91
+
<tbody>
92
+
<row>
93
+
<entry>8.0.0</entry>
94
+
<entry>
95
+
<parameter>public_key</parameter> accepts an <classname>OpenSSLAsymmetricKey</classname>
96
+
or <classname>OpenSSLCertificate</classname> instance now;
97
+
previously, a &resource; of type <literal>OpenSSL key</literal> or <literal>OpenSSL X.509</literal>
98
+
was accepted.
99
+
</entry>
100
+
</row>
101
+
</tbody>
102
+
</tgroup>
103
+
</informaltable>
104
+
</refsect1>
105
+

81
106
<refsect1 role="seealso">
82
107
&reftitle.seealso;
83
108
<para>
...
...
@@ -89,7 +114,6 @@
89
114
</refsect1>
90
115

91
116
</refentry>
92
-

93
117
<!-- Keep this comment at the end of the file
94
118
Local variables:
95
119
mode: sgml
96
120