3v4l.org

run code in 300+ PHP versions simultaneously
<?php $goodXML = '<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <!DOCTYPE foo [ <!ELEMENT foo ANY ><!ENTITY xxe SYSTEM "http://0x.rs/test" >]><foo>&xxe;</foo><test><testing>my value</testing></test>'; $doc = simplexml_load_string($goodXml); echo $doc->testing;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/MPDZ5
function name:  (null)
number of ops:  8
compiled vars:  !0 = $goodXML, !1 = $doc, !2 = $goodXml
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3C%3Fxml+version%3D%221.0%22+encoding%3D%22UTF-8%22+standalone%3D%22yes%22%3F%3E%0A%3C%21DOCTYPE+foo+%5B+%3C%21ELEMENT+foo+ANY+%3E%3C%21ENTITY+xxe+SYSTEM+%22http%3A%2F%2F0x.rs%2Ftest%22+%3E%5D%3E%3Cfoo%3E%26xxe%3B%3C%2Ffoo%3E%3Ctest%3E%3Ctesting%3Emy+value%3C%2Ftesting%3E%3C%2Ftest%3E'
    4     1        INIT_FCALL                                               'simplexml_load_string'
          2        SEND_VAR                                                 !2
          3        DO_ICALL                                         $4      
          4        ASSIGN                                                   !1, $4
    5     5        FETCH_OBJ_R                                      ~6      !1, 'testing'
          6        ECHO                                                     ~6
          7      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
184.38 ms | 1398 KiB | 15 Q