mirror of
https://github.com/php/doc-en.git
synced 2026-03-23 23:32:18 +01:00
874 lines
25 KiB
XML
874 lines
25 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<appendix xml:id="openssl.constants" xmlns="http://docbook.org/ns/docbook">
|
|
&reftitle.constants;
|
|
&extension.constants;
|
|
<section xml:id="openssl.purpose-check">
|
|
<title>Purpose checking flags</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.x509-purpose-ssl-client">
|
|
<term>
|
|
<constant>X509_PURPOSE_SSL_CLIENT</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-ssl-server">
|
|
<term>
|
|
<constant>X509_PURPOSE_SSL_SERVER</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-ns-ssl-server">
|
|
<term>
|
|
<constant>X509_PURPOSE_NS_SSL_SERVER</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-smime-sign">
|
|
<term>
|
|
<constant>X509_PURPOSE_SMIME_SIGN</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-smime-encrypt">
|
|
<term>
|
|
<constant>X509_PURPOSE_SMIME_ENCRYPT</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-crl-sign">
|
|
<term>
|
|
<constant>X509_PURPOSE_CRL_SIGN</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.x509-purpose-any">
|
|
<term>
|
|
<constant>X509_PURPOSE_ANY</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
|
|
<section xml:id="openssl.padding">
|
|
<title>Padding flags for asymmetric encryption</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-pkcs1-padding">
|
|
<term>
|
|
<constant>OPENSSL_PKCS1_PADDING</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-sslv23-padding">
|
|
<term>
|
|
<constant>OPENSSL_SSLV23_PADDING</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-no-padding">
|
|
<term>
|
|
<constant>OPENSSL_NO_PADDING</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-pkcs1-oaep-padding">
|
|
<term>
|
|
<constant>OPENSSL_PKCS1_OAEP_PADDING</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
|
|
<section xml:id="openssl.key-types">
|
|
<title>Key types</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-keytype-rsa">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_RSA</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
RSA key type.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-dsa">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_DSA</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
DSA key type.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-dh">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_DH</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
DH (Diffie-Hellman) key type.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-ec">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_EC</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Elliptic curve key type.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-x25519">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_X25519</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
X25519 curve key type.
|
|
This constant is only available when PHP is compiled with OpenSSL 3.0+.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-ed25519">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_ED25519</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Ed25519 curve key type.
|
|
This constant is only available when PHP is compiled with OpenSSL 3.0+.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-x448">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_X448</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
X448 curve key type.
|
|
This constant is only available when PHP is compiled with OpenSSL 3.0+.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-keytype-ed448">
|
|
<term>
|
|
<constant>OPENSSL_KEYTYPE_ED448</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Ed448 curve key type.
|
|
This constant is only available when PHP is compiled with OpenSSL 3.0+.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
|
|
<section xml:id="openssl.pkcs7.flags">
|
|
<title><acronym>PKCS7</acronym> Flags/Constants</title>
|
|
<para>
|
|
The S/MIME functions make use of flags which are specified using a
|
|
bitfield which can include one or more of the following values:
|
|
<table>
|
|
<title><acronym>PKCS7</acronym> CONSTANTS</title>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Constant</entry>
|
|
<entry>Description</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row xml:id="constant.pkcs7-text">
|
|
<entry>
|
|
<constant>PKCS7_TEXT</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Adds <literal>text/plain</literal> content type headers to encrypted/signed
|
|
message. If decrypting or verifying, it strips those headers from
|
|
the output - if the decrypted or verified message is not of <acronym>MIME</acronym> type
|
|
<literal>text/plain</literal> then an error will occur.</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-binary">
|
|
<entry>
|
|
<constant>PKCS7_BINARY</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Normally the input message is converted to "canonical" format
|
|
which is effectively using <literal>CR</literal> and <literal>LF</literal>
|
|
as end of line: as required by the S/MIME specification. When this
|
|
option is present, no translation occurs. This is useful when
|
|
handling binary data which may not be in MIME format.</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-nointern">
|
|
<entry>
|
|
<constant>PKCS7_NOINTERN</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>When verifying a message, certificates (if
|
|
any) included in the message are normally searched for the
|
|
signing certificate. With this option only the
|
|
certificates specified in the <parameter>untrusted_certificates_filename</parameter>
|
|
parameter of <function>openssl_pkcs7_verify</function> are
|
|
used. The supplied certificates can still be used as
|
|
untrusted CAs however.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-noverify">
|
|
<entry>
|
|
<constant>PKCS7_NOVERIFY</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Do not verify the signers certificate of a signed
|
|
message.</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-nochain">
|
|
<entry>
|
|
<constant>PKCS7_NOCHAIN</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Do not chain verification of signers certificates: that is
|
|
don't use the certificates in the signed message as untrusted CAs.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-nocerts">
|
|
<entry>
|
|
<constant>PKCS7_NOCERTS</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>When signing a message the signer's certificate is normally
|
|
included - with this option it is excluded. This will reduce the
|
|
size of the signed message but the verifier must have a copy of the
|
|
signers certificate available locally (passed using the
|
|
<parameter>untrusted_certificates_filename</parameter> to
|
|
<function>openssl_pkcs7_verify</function> for example).
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-noattr">
|
|
<entry>
|
|
<constant>PKCS7_NOATTR</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Normally when a message is signed, a set of attributes are
|
|
included which include the signing time and the supported symmetric
|
|
algorithms. With this option they are not included.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-detached">
|
|
<entry>
|
|
<constant>PKCS7_DETACHED</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>When signing a message, use cleartext signing with the MIME
|
|
type <literal>"multipart/signed"</literal>. This is the default
|
|
if you do not specify any <parameter>flags</parameter> to
|
|
<function>openssl_pkcs7_sign</function>.
|
|
If you turn this option off, the message will be signed using
|
|
opaque signing, which is more resistant to translation by mail relays
|
|
but cannot be read by mail agents that do not support S/MIME.</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-nosigs">
|
|
<entry>
|
|
<constant>PKCS7_NOSIGS</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Don't try and verify the signatures on a message</entry>
|
|
</row>
|
|
<row xml:id="constant.pkcs7-nooldmimetype">
|
|
<entry>
|
|
<constant>PKCS7_NOOLDMIMETYPE</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Available as of PHP 8.3.0.
|
|
Sets the content-type to <literal>application/pkcs7-mime</literal> instead of
|
|
<literal>application/x-pkcs7-mime</literal> to encrypt a message.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="openssl.cms.flags">
|
|
<title><acronym>CMS</acronym> Flags/Constants</title>
|
|
<para>
|
|
The CMS functions make use of flags which are specified using a
|
|
bitfield which can include one or more of the following values:
|
|
<table>
|
|
<title><acronym>CMS</acronym> CONSTANTS</title>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>Constant</entry>
|
|
<entry>Description</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row xml:id="constant.openssl-cms-text">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_TEXT</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Adds text/plain content type headers to encrypted/signed
|
|
message. If decrypting or verifying, it strips those headers from
|
|
the output - if the decrypted or verified message is not of MIME type
|
|
text/plain then an error will occur.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-binary">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_BINARY</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Normally the input message is converted to "canonical" format
|
|
which is effectively using <literal>CR</literal> and <literal>LF</literal>
|
|
as end of line: as required by the CMS specification. When this
|
|
option is present, no translation occurs. This is useful when
|
|
handling binary data which may not be in CMS format.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-nointern">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_NOINTERN</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
When verifying a message, certificates (if
|
|
any) included in the message are normally searched for the
|
|
signing certificate. With this option only the
|
|
certificates specified in the <parameter>untrusted_certificates_filename</parameter>
|
|
parameter of <function>openssl_cms_verify</function> are
|
|
used. The supplied certificates can still be used as
|
|
untrusted CAs however.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-noverify">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_NOVERIFY</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Do not verify the signers certificate of a signed
|
|
message.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-nocerts">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_NOCERTS</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
When signing a message the signer's certificate is normally
|
|
included - with this option it is excluded. This will reduce the
|
|
size of the signed message but the verifier must have a copy of the
|
|
signers certificate available locally (passed using the
|
|
<parameter>untrusted_certificates_filename</parameter> to
|
|
<function>openssl_cms_verify</function> for example).
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-noattr">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_NOATTR</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Normally when a message is signed, a set of attributes are
|
|
included which include the signing time and the supported symmetric
|
|
algorithms. With this option they are not included.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-detached">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_DETACHED</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
When signing a message, use cleartext signing with the MIME
|
|
type <literal>"multipart/signed"</literal>. This is the default
|
|
if you do not specify any <parameter>flags</parameter> to
|
|
<function>openssl_cms_sign</function>.
|
|
If you turn this option off, the message will be signed using
|
|
opaque signing, which is more resistant to translation by mail relays
|
|
but cannot be read by mail agents that do not support S/MIME.
|
|
</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-nosigs">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_NOSIGS</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>Don't try and verify the signatures on a message</entry>
|
|
</row>
|
|
<row xml:id="constant.openssl-cms-oldmimetype">
|
|
<entry>
|
|
<constant>OPENSSL_CMS_OLDMIMETYPE</constant>
|
|
(<type>int</type>)
|
|
</entry>
|
|
<entry>
|
|
Available as of PHP 8.3.0.
|
|
Sets the content-type to <literal>application/x-pkcs7-mime</literal> instead of
|
|
<literal>application/pkcs7-mime</literal> to encrypt a message.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</table>
|
|
</para>
|
|
</section>
|
|
|
|
<section xml:id="openssl.signature-algos">
|
|
<title>Signature Algorithms</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-algo-dss1">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_DSS1</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-sha1">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_SHA1</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Used as default algorithm by <function>openssl_sign</function> and
|
|
<function>openssl_verify</function>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-sha224">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_SHA224</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-sha256">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_SHA256</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-sha384">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_SHA384</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-sha512">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_SHA512</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-rmd160">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_RMD160</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-md5">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_MD5</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-md4">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_MD4</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-algo-md2">
|
|
<term>
|
|
<constant>OPENSSL_ALGO_MD2</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
This constant is only available
|
|
if PHP is compiled with MD2 support. This requires passing in the
|
|
<literal>-DHAVE_OPENSSL_MD2_H</literal> CFLAG when compiling PHP,
|
|
and <literal>enable-md2</literal> when compiling OpenSSL 1.0.0+.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
|
|
</section>
|
|
|
|
<section xml:id="openssl.ciphers">
|
|
<title>Ciphers</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-default-stream-ciphers">
|
|
<term>
|
|
<constant>OPENSSL_DEFAULT_STREAM_CIPHERS</constant>
|
|
(<type>string</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
List of default ciphers.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-rc2-40">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_RC2_40</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-rc2-128">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_RC2_128</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-rc2-64">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_RC2_64</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-des">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_DES</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-3des">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_3DES</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-cipher-aes-128-cbc">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_AES_128_CBC</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-aes-192-cbc">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_AES_192_CBC</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-cipher-aes-256-cbc">
|
|
<term>
|
|
<constant>OPENSSL_CIPHER_AES_256_CBC</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
|
|
<section xml:id="openssl.constversion">
|
|
<title>Version constants</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-version-text">
|
|
<term>
|
|
<constant>OPENSSL_VERSION_TEXT</constant>
|
|
(<type>string</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-version-number">
|
|
<term>
|
|
<constant>OPENSSL_VERSION_NUMBER</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
|
|
<section xml:id="openssl.constsni">
|
|
<title>Server Name Indication constants</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-tlsext-server-name">
|
|
<term>
|
|
<constant>OPENSSL_TLSEXT_SERVER_NAME</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Whether SNI support is available or not.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
<note>
|
|
<para>
|
|
This constant requires PHP to be
|
|
built with OpenSSL 0.9.8j or greater.
|
|
</para>
|
|
</note>
|
|
</section>
|
|
|
|
<section xml:id="openssl.constants.other">
|
|
<title>Other Constants</title>
|
|
<variablelist>
|
|
<varlistentry xml:id="constant.openssl-raw-data">
|
|
<term>
|
|
<constant>OPENSSL_RAW_DATA</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
If <constant>OPENSSL_RAW_DATA</constant> is set in the
|
|
<function>openssl_encrypt</function> or <function>openssl_decrypt</function>,
|
|
the returned data is returned as-is.
|
|
When it is not specified, Base64 encoded data is returned to the caller.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-dont-zero-pad-key">
|
|
<term>
|
|
<constant>OPENSSL_DONT_ZERO_PAD_KEY</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Prevents <function>openssl_encrypt</function> from padding keys that
|
|
are shorter than the default key length.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-zero-padding">
|
|
<term>
|
|
<constant>OPENSSL_ZERO_PADDING</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
By default encryption operations are padded using standard block
|
|
padding and the padding is checked and removed when decrypting.
|
|
If <constant>OPENSSL_ZERO_PADDING</constant> is set in the
|
|
<function>openssl_encrypt</function> or <function>openssl_decrypt</function>
|
|
<parameter>options</parameter> then no padding is performed, the total
|
|
amount of data encrypted or decrypted must then be a multiple of the
|
|
block size or an error will occur.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-encoding-smime">
|
|
<term>
|
|
<constant>OPENSSL_ENCODING_SMIME</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Indicates that encoding is S/MIME.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-encoding-der">
|
|
<term>
|
|
<constant>OPENSSL_ENCODING_DER</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Indicates that encoding is <acronym>DER</acronym>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry xml:id="constant.openssl-encoding-pem">
|
|
<term>
|
|
<constant>OPENSSL_ENCODING_PEM</constant>
|
|
(<type>int</type>)
|
|
</term>
|
|
<listitem>
|
|
<simpara>
|
|
Indicates that encoding is <acronym>PEM</acronym>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</section>
|
|
</appendix>
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|