3v4l.org

run code in 300+ PHP versions simultaneously
<?php $password = 'test'; $salt = 'testtesttesttesttesttesttest'; // pre-calculated hash using PHP 5.4 and the new flag $2y$ $hash = '$2y$10$testtesttesttesttesttetsVhdqssnPoru2WOCEBbSFwYnOfjwmG'; $result = crypt($password, $hash); printf("Length: %d", strlen($result)); if ($hash === $result) { echo "OK!\n"; } else { echo "ERROR\n"; }
Finding entry points
Branch analysis from position: 0
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 = 62) Position 1 = -2
filename:       /in/RqsGt
function name:  (null)
number of ops:  19
compiled vars:  !0 = $password, !1 = $salt, !2 = $hash, !3 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'test'
    3     1        ASSIGN                                                   !1, 'testtesttesttesttesttesttest'
    6     2        ASSIGN                                                   !2, '%242y%2410%24testtesttesttesttesttetsVhdqssnPoru2WOCEBbSFwYnOfjwmG'
    8     3        INIT_FCALL                                               'crypt'
          4        SEND_VAR                                                 !0
          5        SEND_VAR                                                 !2
          6        DO_ICALL                                         $7      
          7        ASSIGN                                                   !3, $7
   10     8        INIT_FCALL                                               'printf'
          9        SEND_VAL                                                 'Length%3A+%25d'
         10        STRLEN                                           ~9      !3
         11        SEND_VAL                                                 ~9
         12        DO_ICALL                                                 
   12    13        IS_IDENTICAL                                             !2, !3
         14      > JMPZ                                                     ~11, ->17
   13    15    >   ECHO                                                     'OK%21%0A'
         16      > JMP                                                      ->18
   15    17    >   ECHO                                                     'ERROR%0A'
   16    18    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.02 ms | 1386 KiB | 17 Q