Subversion Repositories oidplus

Rev

Rev 730 | Rev 866 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 730 Rev 849
Line 28... Line 28...
28
                        $a = openssl_random_pseudo_bytes($len);
28
                        $a = openssl_random_pseudo_bytes($len);
29
                        if ($a) return $a;
29
                        if ($a) return $a;
30
                }
30
                }
31
 
31
 
32
                if (function_exists('mcrypt_create_iv')) {
32
                if (function_exists('mcrypt_create_iv')) {
33
                        $a = bin2hex(mcrypt_create_iv($len, MCRYPT_DEV_URANDOM));
33
                        $a = bin2hex(mcrypt_create_iv($len));
34
                        if ($a) return $a;
34
                        if ($a) return $a;
35
                }
35
                }
36
 
36
 
37
                if (function_exists('random_bytes')) {
37
                if (function_exists('random_bytes')) {
38
                        $a = random_bytes($len);
38
                        $a = random_bytes($len);