php-doc-en/reference/openssl/functions/openssl-cipher-iv-length.xml

95 lines
2.2 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<refentry xml:id="function.openssl-cipher-iv-length" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>openssl_cipher_iv_length</refname>
<refpurpose>Gets the cipher iv length</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>int</type><methodname>openssl_cipher_iv_length</methodname>
<methodparam><type>string</type><parameter>method</parameter></methodparam>
</methodsynopsis>
<para>
Gets the cipher initialization vector (iv) length.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<variablelist>
<varlistentry>
<term><parameter>method</parameter></term>
<listitem>
<para>
The cipher method, see <function>openssl_get_cipher_methods</function> for a list of potential values.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Returns the cipher length on success, or &false; on failure.
</para>
</refsect1>
<refsect1 role="errors">
&reftitle.errors;
<para>
Emits an <constant>E_WARNING</constant> level error when the cipher algorithm
is unknown.
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<example xml:id="openssl-cipher-iv-length.example.basic">
<title><function>openssl_cipher_iv_length</function> example</title>
<programlisting role="php">
<![CDATA[
<?php
$method = 'AES-128-CBC';
$ivlen = openssl_cipher_iv_length($method);
echo $ivlen;
?>
]]>
</programlisting>
&example.outputs.similar;
<screen>
<![CDATA[
16
]]>
</screen>
</example>
</refsect1>
</refentry>
<!-- 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
-->