3v4l.org

run code in 300+ PHP versions simultaneously
<?php function deriveSP800108HmacSHA256Key($length, $array, $string, $array2) { $n = $n2 = 1; $allocate = ''; // length = $length while ($n < $length) { $mac = hash_init('sha256', HASH_HMAC, $array); $allocate2 = pack("L", $n2); hash_update($mac, $allocate2); hash_update($mac, $string); hash_update($mac, pack("L", 0)); hash_update($mac, $array2); $allocate2 = pack("L", $n * 8); hash_update($mac, $allocate2); $final = hash_final($mac, true); $allocate .= $final; $n2++; } return unpack('C*', $allocate); } var_dump(deriveSP800108HmacSHA256Key(32, 'array', 'foo', 'array2'));
Output for git.master

Process exited with code 137.
Output for git.master_jit
Fatal error: Out of memory (allocated 18874368 bytes) (tried to allocate 14680096 bytes) in /in/GMnbh on line 20 mmap() failed: [12] Cannot allocate memory mmap() failed: [12] Cannot allocate memory
Process exited with code 255.
Output for rfc.property-hooks
Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 31457312 bytes) in /in/GMnbh on line 20
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
57.94 ms | 401 KiB | 8 Q