mcrypt_module_openPodręcznik PHPPoprzedniNastępnymcrypt_module_open (PHP 4 >= 4.0.2)mcrypt_module_open -- This function opens the module of the algorithm and the mode to be usedDescriptionresource mcrypt_module_open (string algorithm, string algorithm_directory, string mode, string mode_directory)
This function opens the module of the algorithm and the mode
to be used. The name of the algorithm is specified in algorithm,
eg "twofish" or is one of the MCRYPT_ciphername constants.
The library is closed by calling
mcrypt_module_close(), but there is no need
to call that function if mcrypt_generic_end()
is called. Normally it returns an encryption descriptor, or
FALSE on error.
The algorithm_directory and
mode_directory are used to locate the
encryption modules. When you supply a directory name, it is used.
When you set one of these to the empty string (""), the value set
by the mcrypt.algorithms_dir or
mcrypt.modes_dir ini-directive is used.
When these are not set, the default directory are used that are
compiled in into libmcrypt (usally /usr/local/lib/libmcrypt).
Przykład 1. mcrypt_module_open() Example<?php
$td = mcrypt_module_open (MCRYPT_DES, "", MCRYPT_MODE_ECB, "/usr/lib/mcrypt-modes");
?>
The above example will try to open the DES cipher
from the default directory and the EBC mode from the directory
/usr/lib/mcrypt-modes.
PoprzedniSpis treściNastępnymcrypt_decryptPoczątek rozdziałumcrypt_module_close
Wyszukiwarka
Podobne podstrony:
function mcrypt module openfunction mcrypt module get algo key sizefunction mcrypt module is block algorithm modefunction mcrypt module closefunction mcrypt module is block modefunction mcrypt module get algo block sizefunction mcrypt module self testfunction mcrypt module is block algorithmfunction mcrypt module get supported key sizesfunction mcrypt module get supported key sizeswięcej podobnych podstron