3v4l.org

run code in 300+ PHP versions simultaneously
<?php $message = 'Message'; $secret = 'secret'; $hash = hash_hmac('sha256', $message, $secret, true); $encoded = base64_encode($hash); var_dump(hash_equals($hash, $encoded));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/h6RTt
function name:  (null)
number of ops:  21
compiled vars:  !0 = $message, !1 = $secret, !2 = $hash, !3 = $encoded
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'Message'
    3     1        ASSIGN                                                   !1, 'secret'
    5     2        INIT_FCALL                                               'hash_hmac'
          3        SEND_VAL                                                 'sha256'
          4        SEND_VAR                                                 !0
          5        SEND_VAR                                                 !1
          6        SEND_VAL                                                 <true>
          7        DO_ICALL                                         $6      
          8        ASSIGN                                                   !2, $6
    6     9        INIT_FCALL                                               'base64_encode'
         10        SEND_VAR                                                 !2
         11        DO_ICALL                                         $8      
         12        ASSIGN                                                   !3, $8
    8    13        INIT_FCALL                                               'var_dump'
         14        INIT_FCALL                                               'hash_equals'
         15        SEND_VAR                                                 !2
         16        SEND_VAR                                                 !3
         17        DO_ICALL                                         $10     
         18        SEND_VAR                                                 $10
         19        DO_ICALL                                                 
         20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.25 ms | 1395 KiB | 21 Q