3v4l.org

run code in 300+ PHP versions simultaneously
<?php function obfuscate($value) { $safe = ''; foreach (str_split($value) as $letter) { if (($ord = ord($letter)) > 128) { return $letter; } switch (rand(1, 3)) { case 1: $safe .= '&#'.$ord.';'; break; case 2: $safe .= '&#x'.dechex($ord).';'; break; case 3: $safe .= $letter; } } return $safe; } $url = 'http://www.p4rgaming.com/twitch-improves-stream-quality-by-forcing-streamers-to-find-a-better-streaming-service/'; echo '&lt;meta http-equiv="refresh" content="0;URL=\''.obfuscate($url).'\'"&gt;';
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4n03B
function name:  (null)
number of ops:  8
compiled vars:  !0 = $url
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   28     0  E >   ASSIGN                                                   !0, 'http%3A%2F%2Fwww.p4rgaming.com%2Ftwitch-improves-stream-quality-by-forcing-streamers-to-find-a-better-streaming-service%2F'
   29     1        INIT_FCALL                                               'obfuscate'
          2        SEND_VAR                                                 !0
          3        DO_FCALL                                      0  $2      
          4        CONCAT                                           ~3      '%26lt%3Bmeta+http-equiv%3D%22refresh%22+content%3D%220%3BURL%3D%27', $2
          5        CONCAT                                           ~4      ~3, '%27%22%26gt%3B'
          6        ECHO                                                     ~4
          7      > RETURN                                                   1

Function obfuscate:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 40
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 40
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 15
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 21, Position 2 = 26
Branch analysis from position: 21
2 jumps found. (Code = 44) Position 1 = 23, Position 2 = 30
Branch analysis from position: 23
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 37
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 38
Branch analysis from position: 38
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 37
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 38
Branch analysis from position: 38
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 38
Branch analysis from position: 38
Branch analysis from position: 40
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 40
filename:       /in/4n03B
function name:  obfuscate
number of ops:  43
compiled vars:  !0 = $value, !1 = $safe, !2 = $letter, !3 = $ord
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    4     1        ASSIGN                                                   !1, ''
    6     2        INIT_FCALL                                               'str_split'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $5      
          5      > FE_RESET_R                                       $6      $5, ->40
          6    > > FE_FETCH_R                                               $6, !2, ->40
    7     7    >   INIT_FCALL                                               'ord'
          8        SEND_VAR                                                 !2
          9        DO_ICALL                                         $7      
         10        ASSIGN                                           ~8      !3, $7
         11        IS_SMALLER                                               128, ~8
         12      > JMPZ                                                     ~9, ->15
    8    13    >   FE_FREE                                                  $6
         14      > RETURN                                                   !2
   11    15    >   INIT_FCALL                                               'rand'
         16        SEND_VAL                                                 1
         17        SEND_VAL                                                 3
         18        DO_ICALL                                         $10     
   12    19        CASE                                                     $10, 1
         20      > JMPNZ                                                    ~11, ->26
   16    21    >   CASE                                                     $10, 2
         22      > JMPNZ                                                    ~11, ->30
   20    23    >   CASE                                                     $10, 3
         24      > JMPNZ                                                    ~11, ->37
         25    > > JMP                                                      ->38
   13    26    >   CONCAT                                           ~12     '%26%23', !3
         27        CONCAT                                           ~13     ~12, '%3B'
         28        ASSIGN_OP                                     8          !1, ~13
   14    29      > JMP                                                      ->38
   17    30    >   INIT_FCALL                                               'dechex'
         31        SEND_VAR                                                 !3
         32        DO_ICALL                                         $15     
         33        CONCAT                                           ~16     '%26%23x', $15
         34        CONCAT                                           ~17     ~16, '%3B'
         35        ASSIGN_OP                                     8          !1, ~17
   18    36      > JMP                                                      ->38
   21    37    >   ASSIGN_OP                                     8          !1, !2
         38    >   FREE                                                     $10
    6    39      > JMP                                                      ->6
         40    >   FE_FREE                                                  $6
   25    41      > RETURN                                                   !1
   26    42*     > RETURN                                                   null

End of function obfuscate

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.15 ms | 1403 KiB | 22 Q