3v4l.org

run code in 300+ PHP versions simultaneously
<?php function decrypt($a) { $tmp = strtolower(strrev($a)); $tmps = substr($tmp, 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/rlgTv
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/rlgTv
function name:  decrypt
number of ops:  22
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                                               'substr'
          9        SEND_VAR                                                 !1
         10        SEND_VAL                                                 4
         11        DO_ICALL                                         $6      
         12        INIT_FCALL                                               'hexdec'
         13        SEND_VAL                                                 'BFF'
         14        DO_ICALL                                         $7      
         15        BW_XOR                                           ~8      $6, $7
         16        INIT_FCALL                                               'hexdec'
         17        SEND_VAL                                                 'D77D'
         18        DO_ICALL                                         $9      
         19        BW_XOR                                           ~10     $9, ~8
         20        ASSIGN                                                   !2, ~10
    6    21      > RETURN                                                   null

End of function decrypt

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.13 ms | 1403 KiB | 25 Q