3v4l.org

run code in 300+ PHP versions simultaneously
<?php //Encryption: $textToEncrypt = "My Text to Encrypt"; $encryptionMethod = "AES-256-CBC"; $secretHash = "encryptionhash"; $iv = mcrypt_create_iv(16, MCRYPT_RAND); $encryptedText = openssl_encrypt($textToEncrypt,$encryptionMethod,$secretHash, 0, $iv); //Decryption: $decryptedText = openssl_decrypt($encryptedText, $encryptionMethod, $secretHash, 0, $iv); print "My Decrypted Text: ". $decryptedText;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/UdY15
function name:  (null)
number of ops:  28
compiled vars:  !0 = $textToEncrypt, !1 = $encryptionMethod, !2 = $secretHash, !3 = $iv, !4 = $encryptedText, !5 = $decryptedText
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'My+Text+to+Encrypt'
    4     1        ASSIGN                                                   !1, 'AES-256-CBC'
    5     2        ASSIGN                                                   !2, 'encryptionhash'
    6     3        INIT_FCALL_BY_NAME                                       'mcrypt_create_iv'
          4        SEND_VAL_EX                                              16
          5        FETCH_CONSTANT                                   ~9      'MCRYPT_RAND'
          6        SEND_VAL_EX                                              ~9
          7        DO_FCALL                                      0  $10     
          8        ASSIGN                                                   !3, $10
    7     9        INIT_FCALL_BY_NAME                                       'openssl_encrypt'
         10        SEND_VAR_EX                                              !0
         11        SEND_VAR_EX                                              !1
         12        SEND_VAR_EX                                              !2
         13        SEND_VAL_EX                                              0
         14        SEND_VAR_EX                                              !3
         15        DO_FCALL                                      0  $12     
         16        ASSIGN                                                   !4, $12
   10    17        INIT_FCALL_BY_NAME                                       'openssl_decrypt'
         18        SEND_VAR_EX                                              !4
         19        SEND_VAR_EX                                              !1
         20        SEND_VAR_EX                                              !2
         21        SEND_VAL_EX                                              0
         22        SEND_VAR_EX                                              !3
         23        DO_FCALL                                      0  $14     
         24        ASSIGN                                                   !5, $14
   11    25        CONCAT                                           ~16     'My+Decrypted+Text%3A+', !5
         26        ECHO                                                     ~16
   12    27      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.71 ms | 1394 KiB | 13 Q