3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* Based on: // ------------------------------------------------------------------- quick script to grab a random BOFH excuse. - Peter Lowe // pgl@yoyo.org // http://pgl.yoyo.org/bofh/ credit to Jeff Ballard <ballard@NOSPAMcs.wisc.edu> for the original bofh excuse server: http://www.cs.wisc.edu/~ballard/bofh/ ------------------------------------------------------------------- [2004-08-28] odd: http://wiki.asleep.net/BOFHInetdPHP?show_comments=1 http://pgl.yoyo.org/bofh/ripoff.html (local copy) someone's ripped off this code and signed it with "author A.Sleep <a.sleep@asleep.net>" it's not exactly the same, but it's definitely based off this code. how strange. oh well. ------------------------------------------------------------------- // Secure, memorizable password generator */ $adj = dirname(__FILE__).'/adj.lst'; $noun = dirname(__FILE__).'/noun.lst'; for ($turn = 1; $turn <= $_POST["itr"]; $turn++){ if (!$adj = @file($adj)){ echo "couldn't read adjective file '$adj'"; } echo $adj[mt_rand(0, count($adj)-1)]; if (!$noun = @file($noun)){ echo "couldn't read adjective file '$noun'"; } echo $noun[mt_rand(0, count($noun)-1)]; } ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 53
Branch analysis from position: 53
2 jumps found. (Code = 44) Position 1 = 57, Position 2 = 12
Branch analysis from position: 57
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
2 jumps found. (Code = 43) Position 1 = 20, Position 2 = 24
Branch analysis from position: 20
2 jumps found. (Code = 43) Position 1 = 40, Position 2 = 44
Branch analysis from position: 40
2 jumps found. (Code = 44) Position 1 = 57, Position 2 = 12
Branch analysis from position: 57
Branch analysis from position: 12
Branch analysis from position: 44
Branch analysis from position: 24
filename:       /in/ehSjY
function name:  (null)
number of ops:  58
compiled vars:  !0 = $adj, !1 = $noun, !2 = $turn
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   29     0  E >   INIT_FCALL                                               'dirname'
          1        SEND_VAL                                                 '%2Fin%2FehSjY'
          2        DO_ICALL                                         $3      
          3        CONCAT                                           ~4      $3, '%2Fadj.lst'
          4        ASSIGN                                                   !0, ~4
   30     5        INIT_FCALL                                               'dirname'
          6        SEND_VAL                                                 '%2Fin%2FehSjY'
          7        DO_ICALL                                         $6      
          8        CONCAT                                           ~7      $6, '%2Fnoun.lst'
          9        ASSIGN                                                   !1, ~7
   31    10        ASSIGN                                                   !2, 1
         11      > JMP                                                      ->53
   32    12    >   BEGIN_SILENCE                                    ~10     
         13        INIT_FCALL                                               'file'
         14        SEND_VAR                                                 !0
         15        DO_ICALL                                         $11     
         16        END_SILENCE                                              ~10
         17        ASSIGN                                           ~12     !0, $11
         18        BOOL_NOT                                         ~13     ~12
         19      > JMPZ                                                     ~13, ->24
   33    20    >   ROPE_INIT                                     3  ~15     'couldn%27t+read+adjective+file+%27'
         21        ROPE_ADD                                      1  ~15     ~15, !0
         22        ROPE_END                                      2  ~14     ~15, '%27'
         23        ECHO                                                     ~14
   35    24    >   INIT_FCALL                                               'mt_rand'
         25        SEND_VAL                                                 0
         26        COUNT                                            ~17     !0
         27        SUB                                              ~18     ~17, 1
         28        SEND_VAL                                                 ~18
         29        DO_ICALL                                         $19     
         30        FETCH_DIM_R                                      ~20     !0, $19
         31        ECHO                                                     ~20
   37    32        BEGIN_SILENCE                                    ~21     
         33        INIT_FCALL                                               'file'
         34        SEND_VAR                                                 !1
         35        DO_ICALL                                         $22     
         36        END_SILENCE                                              ~21
         37        ASSIGN                                           ~23     !1, $22
         38        BOOL_NOT                                         ~24     ~23
         39      > JMPZ                                                     ~24, ->44
   38    40    >   ROPE_INIT                                     3  ~26     'couldn%27t+read+adjective+file+%27'
         41        ROPE_ADD                                      1  ~26     ~26, !1
         42        ROPE_END                                      2  ~25     ~26, '%27'
         43        ECHO                                                     ~25
   40    44    >   INIT_FCALL                                               'mt_rand'
         45        SEND_VAL                                                 0
         46        COUNT                                            ~28     !1
         47        SUB                                              ~29     ~28, 1
         48        SEND_VAL                                                 ~29
         49        DO_ICALL                                         $30     
         50        FETCH_DIM_R                                      ~31     !1, $30
         51        ECHO                                                     ~31
   31    52        PRE_INC                                                  !2
         53    >   FETCH_R                      global              ~33     '_POST'
         54        FETCH_DIM_R                                      ~34     ~33, 'itr'
         55        IS_SMALLER_OR_EQUAL                                      !2, ~34
         56      > JMPNZ                                                    ~35, ->12
   44    57    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
157.27 ms | 1400 KiB | 19 Q