3v4l.org

run code in 300+ PHP versions simultaneously
<?php // username: admin $password = 12345678; // hashed password: $2y$12$$$$$$$$$$$$$$$$$$$$$$.ibwcWrMlgLR7y6B62/Vc8Dc54kecHHe$1$ZQhX9D2d$RexVJ.y2KWpfxMyY0tN9E1 $salt = 'HJsZ4yBWNbGQCw1Yi-7rGBunXym7AEIFatIHhaK_fQgY6I1ecqAEs7eAmJM88Zdn5VpdrKie2CN39~PjqSb3yoPCCzl4q8'; $vsalt = 'S2qXSXQUc-'; function hashing($password ,$salt ,$vsalt){ $check1 = crypt($password.$salt,'$2y$12$'.$vsalt); $check2 = crypt($password.$salt,$vsalt); //password will be: $check1.$check2 return($check1.' '.$check2); } var_dump(hashing(12345678, $salt, $vsalt), hashing('12345678', $salt, $vsalt)); //password: 12345678 // hashed password: *0S2k0u9.1hnFr. $salt = 'HJsZ4yBWNbGQCw1Yi-7rGBunXym7AEIFatIHhaK_fQgY6I1ecqAEs7eAmJM88Zdn5VpdrKie2CN39~PjqSb3yoPCCzl4q8'; $vsalt = 'S2qXSXQUc-'; var_dump(hashing(12345678, $salt, $vsalt), hashing('12345678', $salt, $vsalt));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/A2Oo1
function name:  (null)
number of ops:  34
compiled vars:  !0 = $password, !1 = $salt, !2 = $vsalt
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 12345678
    6     1        ASSIGN                                                   !1, 'HJsZ4yBWNbGQCw1Yi-7rGBunXym7AEIFatIHhaK_fQgY6I1ecqAEs7eAmJM88Zdn5VpdrKie2CN39%7EPjqSb3yoPCCzl4q8'
    7     2        ASSIGN                                                   !2, 'S2qXSXQUc-'
   16     3        INIT_FCALL                                               'var_dump'
          4        INIT_FCALL                                               'hashing'
          5        SEND_VAL                                                 12345678
          6        SEND_VAR                                                 !1
          7        SEND_VAR                                                 !2
          8        DO_FCALL                                      0  $6      
          9        SEND_VAR                                                 $6
         10        INIT_FCALL                                               'hashing'
         11        SEND_VAL                                                 '12345678'
         12        SEND_VAR                                                 !1
         13        SEND_VAR                                                 !2
         14        DO_FCALL                                      0  $7      
         15        SEND_VAR                                                 $7
         16        DO_ICALL                                                 
   20    17        ASSIGN                                                   !1, 'HJsZ4yBWNbGQCw1Yi-7rGBunXym7AEIFatIHhaK_fQgY6I1ecqAEs7eAmJM88Zdn5VpdrKie2CN39%7EPjqSb3yoPCCzl4q8'
   21    18        ASSIGN                                                   !2, 'S2qXSXQUc-'
   23    19        INIT_FCALL                                               'var_dump'
         20        INIT_FCALL                                               'hashing'
         21        SEND_VAL                                                 12345678
         22        SEND_VAR                                                 !1
         23        SEND_VAR                                                 !2
         24        DO_FCALL                                      0  $11     
         25        SEND_VAR                                                 $11
         26        INIT_FCALL                                               'hashing'
         27        SEND_VAL                                                 '12345678'
         28        SEND_VAR                                                 !1
         29        SEND_VAR                                                 !2
         30        DO_FCALL                                      0  $12     
         31        SEND_VAR                                                 $12
         32        DO_ICALL                                                 
         33      > RETURN                                                   1

Function hashing:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/A2Oo1
function name:  hashing
number of ops:  20
compiled vars:  !0 = $password, !1 = $salt, !2 = $vsalt, !3 = $check1, !4 = $check2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
   10     3        INIT_FCALL                                               'crypt'
          4        CONCAT                                           ~5      !0, !1
          5        SEND_VAL                                                 ~5
          6        CONCAT                                           ~6      '%242y%2412%24', !2
          7        SEND_VAL                                                 ~6
          8        DO_ICALL                                         $7      
          9        ASSIGN                                                   !3, $7
   11    10        INIT_FCALL                                               'crypt'
         11        CONCAT                                           ~9      !0, !1
         12        SEND_VAL                                                 ~9
         13        SEND_VAR                                                 !2
         14        DO_ICALL                                         $10     
         15        ASSIGN                                                   !4, $10
   13    16        CONCAT                                           ~12     !3, '+'
         17        CONCAT                                           ~13     ~12, !4
         18      > RETURN                                                   ~13
   14    19*     > RETURN                                                   null

End of function hashing

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
170.46 ms | 1403 KiB | 21 Q