3v4l.org

run code in 300+ PHP versions simultaneously
<?php $secret = 'a0a7e7997b6d5fcd55f4b5c32611b87c'; function encrypt128($str) { $block = 16; $pad = $block - (strlen($str) % $block); $str .= str_repeat(chr($pad), $pad); return base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_128, $secret, $str, MCRYPT_MODE_ECB)); } var_dump(encrypt128('small1'));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aBQoQ
function name:  (null)
number of ops:  8
compiled vars:  !0 = $secret
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'a0a7e7997b6d5fcd55f4b5c32611b87c'
   13     1        INIT_FCALL                                               'var_dump'
          2        INIT_FCALL                                               'encrypt128'
          3        SEND_VAL                                                 'small1'
          4        DO_FCALL                                      0  $2      
          5        SEND_VAR                                                 $2
          6        DO_ICALL                                                 
          7      > RETURN                                                   1

Function encrypt128:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aBQoQ
function name:  encrypt128
number of ops:  27
compiled vars:  !0 = $str, !1 = $block, !2 = $pad, !3 = $secret
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
    6     1        ASSIGN                                                   !1, 16
    7     2        STRLEN                                           ~5      !0
          3        MOD                                              ~6      ~5, !1
          4        SUB                                              ~7      !1, ~6
          5        ASSIGN                                                   !2, ~7
    8     6        INIT_FCALL                                               'str_repeat'
          7        INIT_FCALL                                               'chr'
          8        SEND_VAR                                                 !2
          9        DO_ICALL                                         $9      
         10        SEND_VAR                                                 $9
         11        SEND_VAR                                                 !2
         12        DO_ICALL                                         $10     
         13        ASSIGN_OP                                     8          !0, $10
   10    14        INIT_FCALL                                               'base64_encode'
         15        INIT_FCALL_BY_NAME                                       'mcrypt_encrypt'
         16        FETCH_CONSTANT                                   ~12     'MCRYPT_RIJNDAEL_128'
         17        SEND_VAL_EX                                              ~12
         18        SEND_VAR_EX                                              !3
         19        SEND_VAR_EX                                              !0
         20        FETCH_CONSTANT                                   ~13     'MCRYPT_MODE_ECB'
         21        SEND_VAL_EX                                              ~13
         22        DO_FCALL                                      0  $14     
         23        SEND_VAR                                                 $14
         24        DO_ICALL                                         $15     
         25      > RETURN                                                   $15
   11    26*     > RETURN                                                   null

End of function encrypt128

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.31 ms | 1399 KiB | 22 Q