1--TEST-- 2Test hash_algos() function : basic functionality 3--SKIPIF-- 4<?php extension_loaded('hash') or die('skip: hash extension not loaded.'); ?> 5--FILE-- 6<?php 7 8/* Prototype : array hash_algos (void) 9 * Description: Return a list of registered hashing algorithms 10 * Source code: ext/hash/hash.c 11 * Alias to functions: 12*/ 13 14echo "*** Testing hash_algos() : basic functionality ***\n"; 15var_dump(hash_algos()); 16 17?> 18===Done=== 19--EXPECTF-- 20*** Testing hash_algos() : basic functionality *** 21array(52) { 22 [%d]=> 23 string(3) "md2" 24 [%d]=> 25 string(3) "md4" 26 [%d]=> 27 string(3) "md5" 28 [%d]=> 29 string(4) "sha1" 30 [%d]=> 31 string(6) "sha224" 32 [%d]=> 33 string(6) "sha256" 34 [%d]=> 35 string(6) "sha384" 36 [%d]=> 37 string(10) "sha512/224" 38 [%d]=> 39 string(10) "sha512/256" 40 [%d]=> 41 string(6) "sha512" 42 [%d]=> 43 string(8) "sha3-224" 44 [%d]=> 45 string(8) "sha3-256" 46 [%d]=> 47 string(8) "sha3-384" 48 [%d]=> 49 string(8) "sha3-512" 50 [%d]=> 51 string(9) "ripemd128" 52 [%d]=> 53 string(9) "ripemd160" 54 [%d]=> 55 string(9) "ripemd256" 56 [%d]=> 57 string(9) "ripemd320" 58 [%d]=> 59 string(9) "whirlpool" 60 [%d]=> 61 string(10) "tiger128,3" 62 [%d]=> 63 string(10) "tiger160,3" 64 [%d]=> 65 string(10) "tiger192,3" 66 [%d]=> 67 string(10) "tiger128,4" 68 [%d]=> 69 string(10) "tiger160,4" 70 [%d]=> 71 string(10) "tiger192,4" 72 [%d]=> 73 string(6) "snefru" 74 [%d]=> 75 string(9) "snefru256" 76 [%d]=> 77 string(4) "gost" 78 [%d]=> 79 string(11) "gost-crypto" 80 [%d]=> 81 string(7) "adler32" 82 [%d]=> 83 string(5) "crc32" 84 [%d]=> 85 string(6) "crc32b" 86 [%d]=> 87 string(6) "fnv132" 88 [%d]=> 89 string(7) "fnv1a32" 90 [%d]=> 91 string(6) "fnv164" 92 [%d]=> 93 string(7) "fnv1a64" 94 [%d]=> 95 string(5) "joaat" 96 [%d]=> 97 string(10) "haval128,3" 98 [%d]=> 99 string(10) "haval160,3" 100 [%d]=> 101 string(10) "haval192,3" 102 [%d]=> 103 string(10) "haval224,3" 104 [%d]=> 105 string(10) "haval256,3" 106 [%d]=> 107 string(10) "haval128,4" 108 [%d]=> 109 string(10) "haval160,4" 110 [%d]=> 111 string(10) "haval192,4" 112 [%d]=> 113 string(10) "haval224,4" 114 [%d]=> 115 string(10) "haval256,4" 116 [%d]=> 117 string(10) "haval128,5" 118 [%d]=> 119 string(10) "haval160,5" 120 [%d]=> 121 string(10) "haval192,5" 122 [%d]=> 123 string(10) "haval224,5" 124 [%d]=> 125 string(10) "haval256,5" 126} 127===Done=== 128