raptor Posted February 13, 2008 Report Share Posted February 13, 2008 Cannot get mcrypt to load in appollo. I have : 1. download libmcrypt.dll and place it in \usr\local\php\extensions (also in windows\system32 and \usr\local\php) 2. added "extension=libmcrypt.dll" to php.ini 3. reboot help! or other encrypt-decrypt options. Quote Link to comment Share on other sites More sharing options...
Ric Posted February 13, 2008 Report Share Posted February 13, 2008 There are a few things wrong! Some are now of your making this is no reflection on you because it extends from a missing extension. You understand what I mean after following these steps to get it working: 1) Reverse what you have done: a) Delete libmcrypt.dll from system32 folder. libmcrypt.dll is in the correct folder *\Uniform Server\udrive\usr\local\php d) Open php.ini and delete the line you added "extension=libmcrypt.dll"2) Locate the line ;extension=php_mcrypt.dll and un-comment to give extension=php_mcrypt.dll3) Its this file (php_mcrypt.dll) you are missing and may have lead to the confusion. To save you legwork I have attached the file, download (double click to extract file) and save it to folder *\Uniform Server\udrive\usr\local\php\extensions4) Restart the servers and it should work! I have never used this function though I would give it a bash and run the examples from http://uk2.php.net/mcrypt This code: <?php$key = "this is a secret key";$input = "Let us meet at 9 o'clock at the secret place.";$encrypted_data = mcrypt_ecb (MCRYPT_3DES, $key, $input, MCRYPT_ENCRYPT);?> Promptly produced this error:Warning: mcrypt_ecb() [function.mcrypt-ecb]: Attempt to use an empty IV, which is NOT recommend I do not have an issue with that, show the modules work. Interestingly this works: <?php $key = "this is a secret key"; $input = "Let us meet at 9 o'clock at the secret place."; $td = mcrypt_module_open('tripledes', '', 'ecb', ''); $iv = mcrypt_create_iv (mcrypt_enc_get_iv_size($td), MCRYPT_RAND); mcrypt_generic_init($td, $key, $iv); $encrypted_data = mcrypt_generic($td, $input); mcrypt_generic_deinit($td); mcrypt_module_close($td); echo $encrypted_data;?> Makes for an interesting display (Note IV in this example has been defined). Have fun All the bestRic double_click_to_extract.exe Quote Link to comment Share on other sites More sharing options...
raptor Posted February 13, 2008 Author Report Share Posted February 13, 2008 Ric, Thanks, thanks, thanks!!! I did a clean install on another computer and all is fine. I spent almost a full day chasing over the 'net looking for mcrypt-windows solutions. One was to put in windows/system32 folder; another to use mcrypt.exe. Where did you find php_mcrypt.dll? Thanks again for your prompt help. This is my first request for help and I have been using uniformserver for about 3 years - and never needed help as it works so flawlessly- and it is great! To help support uniform server I just made a contribution via paypal and I urge all satisfied uses to do the same in support of such a great effort. -raptor There are a few things wrong! Some are now of your making this is no reflection on you because it extends from a missing extension. You understand what I mean after following these steps to get it working: 1) Reverse what you have done: a) Delete libmcrypt.dll from system32 folder. libmcrypt.dll is in the correct folder *\Uniform Server\udrive\usr\local\php d) Open php.ini and delete the line you added "extension=libmcrypt.dll"2) Locate the line ;extension=php_mcrypt.dll and un-comment to give extension=php_mcrypt.dll3) Its this file (php_mcrypt.dll) you are missing and may have lead to the confusion. To save you legwork I have attached the file, download (double click to extract file) and save it to folder *\Uniform Server\udrive\usr\local\php\extensions4) Restart the servers and it should work! I have never used this function though I would give it a bash and run the examples from http://uk2.php.net/mcrypt This code: <?php$key = "this is a secret key";$input = "Let us meet at 9 o'clock at the secret place.";$encrypted_data = mcrypt_ecb (MCRYPT_3DES, $key, $input, MCRYPT_ENCRYPT);?> Promptly produced this error:Warning: mcrypt_ecb() [function.mcrypt-ecb]: Attempt to use an empty IV, which is NOT recommend I do not have an issue with that, show the modules work. Interestingly this works: <?php $key = "this is a secret key"; $input = "Let us meet at 9 o'clock at the secret place."; $td = mcrypt_module_open('tripledes', '', 'ecb', ''); $iv = mcrypt_create_iv (mcrypt_enc_get_iv_size($td), MCRYPT_RAND); mcrypt_generic_init($td, $key, $iv); $encrypted_data = mcrypt_generic($td, $input); mcrypt_generic_deinit($td); mcrypt_module_close($td); echo $encrypted_data;?> Makes for an interesting display (Note IV in this example has been defined). Have fun All the bestRic Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.