3v4l.org

run code in 300+ PHP versions simultaneously
<?php file_put_contents("#!/bin/sh\necho im a good guy.", '/tmp/hello'); echo `echo /tmp/*`; echo `chmod +x /tmp/hello`; echo `/tmp/hello`;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vKFCJ
function name:  (null)
number of ops:  17
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'file_put_contents'
          1        SEND_VAL                                                 '%23%21%2Fbin%2Fsh%0Aecho+im+a+good+guy.'
          2        SEND_VAL                                                 '%2Ftmp%2Fhello'
          3        DO_ICALL                                                 
    3     4        INIT_FCALL                                               'shell_exec'
          5        SEND_VAL                                                 'echo+%2Ftmp%2F%2A'
          6        DO_ICALL                                         $1      
          7        ECHO                                                     $1
    4     8        INIT_FCALL                                               'shell_exec'
          9        SEND_VAL                                                 'chmod+%2Bx+%2Ftmp%2Fhello'
         10        DO_ICALL                                         $2      
         11        ECHO                                                     $2
    5    12        INIT_FCALL                                               'shell_exec'
         13        SEND_VAL                                                 '%2Ftmp%2Fhello'
         14        DO_ICALL                                         $3      
         15        ECHO                                                     $3
         16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
144.99 ms | 1394 KiB | 17 Q