3v4l.org

run code in 300+ PHP versions simultaneously
<?php $merchant = 'VB-USA'; $secretKey = '6c5e27ca-fe94-4e2d-a940-ac7ba4fedd49'; $data = \json_encode(['order_id' => 1000001067]); echo base64_encode( hash_hmac('sha512', $merchant . $data . $merchant, $secretKey) ); // NDg3OGU3MmRiZDM1YjRlMTRjNDRjNDdjMjcwNjAxYmE1OTc2NjViMmFlNjhlOTFjZTBmOTUyMDBkMDRlOTFjMTM1YWU4MzQ0ODUzODYwOTZhYjRhMWNiMzI0NTE5MTQzMDlmZmFiMzNjYmU4OThjODg3NDI1ZDE2MWEzNjRhZGU=
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/t845h
function name:  (null)
number of ops:  18
compiled vars:  !0 = $merchant, !1 = $secretKey, !2 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'VB-USA'
    4     1        ASSIGN                                                   !1, '6c5e27ca-fe94-4e2d-a940-ac7ba4fedd49'
    6     2        INIT_FCALL                                               'json_encode'
          3        SEND_VAL                                                 <array>
          4        DO_ICALL                                         $5      
          5        ASSIGN                                                   !2, $5
    8     6        INIT_FCALL                                               'base64_encode'
    9     7        INIT_FCALL                                               'hash_hmac'
          8        SEND_VAL                                                 'sha512'
   10     9        CONCAT                                           ~7      !0, !2
         10        CONCAT                                           ~8      ~7, !0
         11        SEND_VAL                                                 ~8
   11    12        SEND_VAR                                                 !1
         13        DO_ICALL                                         $9      
         14        SEND_VAR                                                 $9
         15        DO_ICALL                                         $10     
         16        ECHO                                                     $10
   16    17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.92 ms | 1394 KiB | 19 Q