3v4l.org

run code in 300+ PHP versions simultaneously
<?php $isAb = false; if(isset($_SERVER['HTTP_USER_AGENT'])){ $sessionLessUseragents = array( 'ApacheBench', 'http://www.majestic12.co.uk/bot.php', 'http://www.google.com/bot.html', 'http://yandex.com/bots', 'http://www.bing.com/bingbot.htm', 'http://search.msn.com/msnbot.htm', 'http://ahrefs.com/robot/', 'http://www.baidu.com/search/spider.html', 'http://www.projectwonderful.com/', 'http://webmeup-crawler.com/', 'http://OpenLinkProfiler.org/bot', 'http://www.pingdom.com', 'http://www.opensiteexplorer.org/dotbot', 'http://www.easou.com/search/spider.html', ); foreach($sessionLessUseragents as $sessionLessUseragent){ if(strrpos($_SERVER['HTTP_USER_AGENT'], $sessionLessUseragent) !== false){ $isAb = true; break; } } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 19
Branch analysis from position: 4
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 18
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 18
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 17
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 18
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 18
Branch analysis from position: 18
Branch analysis from position: 19
filename:       /in/JH0ls
function name:  (null)
number of ops:  20
compiled vars:  !0 = $isAb, !1 = $sessionLessUseragents, !2 = $sessionLessUseragent
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, <false>
    5     1        FETCH_IS                                         ~4      '_SERVER'
          2        ISSET_ISEMPTY_DIM_OBJ                         0          ~4, 'HTTP_USER_AGENT'
          3      > JMPZ                                                     ~5, ->19
    6     4    >   ASSIGN                                                   !1, <array>
   22     5      > FE_RESET_R                                       $7      !1, ->18
          6    > > FE_FETCH_R                                               $7, !2, ->18
   23     7    >   INIT_FCALL                                               'strrpos'
          8        FETCH_R                      global              ~8      '_SERVER'
          9        FETCH_DIM_R                                      ~9      ~8, 'HTTP_USER_AGENT'
         10        SEND_VAL                                                 ~9
         11        SEND_VAR                                                 !2
         12        DO_ICALL                                         $10     
         13        TYPE_CHECK                                  1018          $10
         14      > JMPZ                                                     ~11, ->17
   24    15    >   ASSIGN                                                   !0, <true>
   25    16      > JMP                                                      ->18
   22    17    > > JMP                                                      ->6
         18    >   FE_FREE                                                  $7
   28    19    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.63 ms | 1395 KiB | 15 Q