mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-10 01:47:03 +03:00
call correct Log class with 2 params instead of 1
see https://github.com/the-djmaze/snappymail/issues/657
This commit is contained in:
parent
a13bb9e930
commit
b14958a89d
1 changed files with 2 additions and 2 deletions
|
|
@ -99,14 +99,14 @@ abstract class Crypt
|
||||||
$nonce = \random_bytes(\SODIUM_CRYPTO_AEAD_XCHACHA20POLY1305_IETF_NPUBBYTES);
|
$nonce = \random_bytes(\SODIUM_CRYPTO_AEAD_XCHACHA20POLY1305_IETF_NPUBBYTES);
|
||||||
return ['sodium', $nonce, static::SodiumEncrypt($data, $nonce, $key)];
|
return ['sodium', $nonce, static::SodiumEncrypt($data, $nonce, $key)];
|
||||||
} catch (\Throwable $e) {
|
} catch (\Throwable $e) {
|
||||||
Log::error($e->getMessage());
|
\SnappyMail\Log::error('Crypt', $e->getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$iv = \random_bytes(\openssl_cipher_iv_length(static::$cipher));
|
$iv = \random_bytes(\openssl_cipher_iv_length(static::$cipher));
|
||||||
return ['openssl', $iv, static::OpenSSLEncrypt($data, $iv, $key)];
|
return ['openssl', $iv, static::OpenSSLEncrypt($data, $iv, $key)];
|
||||||
} catch (\Throwable $e) {
|
} catch (\Throwable $e) {
|
||||||
Log::error($e->getMessage());
|
\SnappyMail\Log::error('Crypt', $e->getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
$salt = \random_bytes(16);
|
$salt = \random_bytes(16);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue