Lines Matching refs:file
9 $file = __DIR__ . "hash_hmac_file.txt";
10 /* Creating a temporary file file */
11 if (($fp = fopen( $file, "w+")) == FALSE) {
12 echo "Cannot create file ($file)";
16 /* Writing into file */
18 if (is_writable($file)) {
20 echo "Cannot write to file ($file)";
31 echo "gost: " . hash_hmac_file('gost', $file, $key) . "\n";
32 echo "haval128,3: " . hash_hmac_file('haval128,3', $file, $key) . "\n";
33 echo "md2: " . hash_hmac_file('md2', $file, $key) . "\n";
34 echo "md4: " . hash_hmac_file('md4', $file, $key) . "\n";
35 echo "md5: " . hash_hmac_file('md5', $file, $key) . "\n";
36 echo "ripemd128: " . hash_hmac_file('ripemd128', $file, $key) . "\n";
37 echo "ripemd160: " . hash_hmac_file('ripemd160', $file, $key) . "\n";
38 echo "ripemd256: " . hash_hmac_file('ripemd256', $file, $key) . "\n";
39 echo "ripemd320: " . hash_hmac_file('ripemd320', $file, $key) . "\n";
40 echo "sha1: " . hash_hmac_file('sha1', $file, $key) . "\n";
41 echo "sha256: " . hash_hmac_file('sha256', $file, $key) . "\n";
42 echo "sha384: " . hash_hmac_file('sha384', $file, $key) . "\n";
43 echo "sha512: " . hash_hmac_file('sha512', $file, $key) . "\n";
44 echo "snefru: " . hash_hmac_file('snefru', $file, $key) . "\n";
45 echo "tiger192,3: " . hash_hmac_file('tiger192,3', $file, $key) . "\n";
46 echo "whirlpool: " . hash_hmac_file('whirlpool', $file, $key) . "\n";
48 echo "md5(raw): " . bin2hex(hash_hmac_file('md5', $file, $key, TRUE)). "\n";
49 echo "sha256(raw): " . bin2hex(hash_hmac_file('sha256', $file, $key, TRUE)). "\n";
51 unlink($file);