3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = hex2bin("0ce33a87b3e8f3ede03b24d66cf50d88"); $key = "0123456789abcdef"; $size = mcrypt_get_iv_size(MCRYPT_RIJNDAEL_128, MCRYPT_MODE_CBC); $IV = substr($data, 0, $size); $data = substr($data, $size); $plain = mcrypt_decrypt(MCRYPT_RIJNDAEL_128, $key, $data, MCRYPT_MODE_CBC, $IV); printf("IV: %s\nData: %s\n", bin2hex($IV), bin2hex($data)); printf("Plain text: %s (%s)\n", $plain, bin2hex($plain));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/J0cnN
function name:  (null)
number of ops:  53
compiled vars:  !0 = $data, !1 = $key, !2 = $size, !3 = $IV, !4 = $plain
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'hex2bin'
          1        SEND_VAL                                                 '0ce33a87b3e8f3ede03b24d66cf50d88'
          2        DO_ICALL                                         $5      
          3        ASSIGN                                                   !0, $5
    3     4        ASSIGN                                                   !1, '0123456789abcdef'
    5     5        INIT_FCALL_BY_NAME                                       'mcrypt_get_iv_size'
          6        FETCH_CONSTANT                                   ~8      'MCRYPT_RIJNDAEL_128'
          7        SEND_VAL_EX                                              ~8
          8        FETCH_CONSTANT                                   ~9      'MCRYPT_MODE_CBC'
          9        SEND_VAL_EX                                              ~9
         10        DO_FCALL                                      0  $10     
         11        ASSIGN                                                   !2, $10
    6    12        INIT_FCALL                                               'substr'
         13        SEND_VAR                                                 !0
         14        SEND_VAL                                                 0
         15        SEND_VAR                                                 !2
         16        DO_ICALL                                         $12     
         17        ASSIGN                                                   !3, $12
    7    18        INIT_FCALL                                               'substr'
         19        SEND_VAR                                                 !0
         20        SEND_VAR                                                 !2
         21        DO_ICALL                                         $14     
         22        ASSIGN                                                   !0, $14
    9    23        INIT_FCALL_BY_NAME                                       'mcrypt_decrypt'
         24        FETCH_CONSTANT                                   ~16     'MCRYPT_RIJNDAEL_128'
         25        SEND_VAL_EX                                              ~16
         26        SEND_VAR_EX                                              !1
         27        SEND_VAR_EX                                              !0
         28        FETCH_CONSTANT                                   ~17     'MCRYPT_MODE_CBC'
         29        SEND_VAL_EX                                              ~17
         30        SEND_VAR_EX                                              !3
         31        DO_FCALL                                      0  $18     
         32        ASSIGN                                                   !4, $18
   10    33        INIT_FCALL                                               'printf'
         34        SEND_VAL                                                 'IV%3A+%25s%0AData%3A+%25s%0A'
         35        INIT_FCALL                                               'bin2hex'
         36        SEND_VAR                                                 !3
         37        DO_ICALL                                         $20     
         38        SEND_VAR                                                 $20
         39        INIT_FCALL                                               'bin2hex'
         40        SEND_VAR                                                 !0
         41        DO_ICALL                                         $21     
         42        SEND_VAR                                                 $21
         43        DO_ICALL                                                 
   11    44        INIT_FCALL                                               'printf'
         45        SEND_VAL                                                 'Plain+text%3A+%25s+%28%25s%29%0A'
         46        SEND_VAR                                                 !4
         47        INIT_FCALL                                               'bin2hex'
         48        SEND_VAR                                                 !4
         49        DO_ICALL                                         $23     
         50        SEND_VAR                                                 $23
         51        DO_ICALL                                                 
         52      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
181.55 ms | 1405 KiB | 21 Q