mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 02:44:53 +00:00
Generate longer more secure Key for logins
This commit is contained in:
4
ajax.php
4
ajax.php
@@ -239,8 +239,8 @@ if(isset($_GET['share_generate_link'])){
|
||||
|
||||
// Decrypt & re-encrypt password for sharing
|
||||
$login_password_cleartext = decryptLoginEntry($row['login_password']);
|
||||
$login_encryption_key = keygen();
|
||||
$iv = keygen();
|
||||
$login_encryption_key = bin2hex(random_bytes(8));
|
||||
$iv = bin2hex(random_bytes(8));
|
||||
$ciphertext = openssl_encrypt($login_password_cleartext, 'aes-128-cbc', $login_encryption_key, 0, $iv);
|
||||
|
||||
$item_encrypted_credential = $iv . $ciphertext;
|
||||
|
||||
Reference in New Issue
Block a user