3v4l.org

run code in 300+ PHP versions simultaneously
<?php function decrypt($a) { $tmp = strtolower(strrev($a)); $tmps = hexdec(substr($tmp,0, 4)) ^ hexdec('BFF') ^ hexdec('D77D'); } echo decrypt("tarunkant"); define('__FLAG__', 'flag{hidden_flag}'); if(decrypt($_REQUEST['pass']) == 'pwning_the_phpreverse!') { __FLAG__; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 17
filename:       /in/m7euI
function name:  (null)
number of ops:  18
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   INIT_FCALL                                               'decrypt'
          1        SEND_VAL                                                 'tarunkant'
          2        DO_FCALL                                      0  $0      
          3        ECHO                                                     $0
   18     4        INIT_FCALL                                               'define'
          5        SEND_VAL                                                 '__FLAG__'
          6        SEND_VAL                                                 'flag%7Bhidden_flag%7D'
          7        DO_ICALL                                                 
   19     8        INIT_FCALL                                               'decrypt'
          9        FETCH_R                      global              ~2      '_REQUEST'
         10        FETCH_DIM_R                                      ~3      ~2, 'pass'
         11        SEND_VAL                                                 ~3
         12        DO_FCALL                                      0  $4      
         13        IS_EQUAL                                                 $4, 'pwning_the_phpreverse%21'
         14      > JMPZ                                                     ~5, ->17
   21    15    >   FETCH_CONSTANT                                   ~6      '__FLAG__'
         16        FREE                                                     ~6
   23    17    > > RETURN                                                   1

Function decrypt:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m7euI
function name:  decrypt
number of ops:  26
compiled vars:  !0 = $a, !1 = $tmp, !2 = $tmps
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    4     1        INIT_FCALL                                               'strtolower'
          2        INIT_FCALL                                               'strrev'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $3      
          5        SEND_VAR                                                 $3
          6        DO_ICALL                                         $4      
          7        ASSIGN                                                   !1, $4
    5     8        INIT_FCALL                                               'hexdec'
          9        INIT_FCALL                                               'substr'
         10        SEND_VAR                                                 !1
         11        SEND_VAL                                                 0
         12        SEND_VAL                                                 4
         13        DO_ICALL                                         $6      
         14        SEND_VAR                                                 $6
         15        DO_ICALL                                         $7      
         16        INIT_FCALL                                               'hexdec'
         17        SEND_VAL                                                 'BFF'
         18        DO_ICALL                                         $8      
         19        BW_XOR                                           ~9      $7, $8
         20        INIT_FCALL                                               'hexdec'
         21        SEND_VAL                                                 'D77D'
         22        DO_ICALL                                         $10     
         23        BW_XOR                                           ~11     $10, ~9
         24        ASSIGN                                                   !2, ~11
    6    25      > RETURN                                                   null

End of function decrypt

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.26 ms | 1403 KiB | 25 Q