| 
        php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits             
             [2005-09-18 09:50 UTC] skettler@php.net
  | 
    |||||||||||||||||||||||||||
            
                 
                Copyright © 2001-2025 The PHP GroupAll rights reserved.  | 
        Last updated: Tue Nov 04 15:00:01 2025 UTC | 
Description: ------------ I have tried to use the cracklib extension but I cannot get it to work. I everytime get the error message "Warning: crack_opendict() [function.crack-opendict]: Unable to open a crack dictionary in /home/svpe/secret/public_html/cracklib_test.php on line 2 ". The dictionary file exists and is readable by everyone: $ ls -l /usr/share/dict/cracklib-words -rw-r--r-- 1 root root 17003670 17. Sep 18:49 /usr/share/dict/cracklib-words I have tried the beta and the stable versions and both don't work. Reproduce code: --------------- <?php $d = crack_opendict('/usr/share/dict/cracklib-words') or die(); if(crack_check($d, 'password')) { echo 'good'; } else { printf('Not good: %s', crack_getlastmessage()); } crack_closedict($d); ?> Expected result: ---------------- The script should read the dictionary and either displays 'good' or 'Not good [reason]'. Actual result: -------------- I just get the error message "Warning: crack_opendict() [function.crack-opendict]: Unable to open a crack dictionary in /home/svpe/secret/public_html/cracklib_test.php on line 2 "