public static function ParagonIE_Sodium_Core_XSalsa20::xsalsa20_xor in Automatic Updates 8
Same name and namespace in other branches
- 7 vendor/paragonie/sodium_compat/src/Core/XSalsa20.php \ParagonIE_Sodium_Core_XSalsa20::xsalsa20_xor()
Encrypt a string with XSalsa20. Doesn't provide integrity.
@internal You should not use this directly from another application
Parameters
string $message:
string $nonce:
string $key:
Return value
string
Throws
SodiumException
TypeError
1 call to ParagonIE_Sodium_Core_XSalsa20::xsalsa20_xor()
- ParagonIE_Sodium_Compat::crypto_stream_xor in vendor/
paragonie/ sodium_compat/ src/ Compat.php - DANGER! UNAUTHENTICATED ENCRYPTION!
File
- vendor/
paragonie/ sodium_compat/ src/ Core/ XSalsa20.php, line 46
Class
- ParagonIE_Sodium_Core_XSalsa20
- Class ParagonIE_Sodium_Core_XSalsa20
Code
public static function xsalsa20_xor($message, $nonce, $key) {
return self::xorStrings($message, self::xsalsa20(self::strlen($message), $nonce, $key));
}