Package com.goterl.lazysodium.interfaces
Interface ShortHash.Lazy
- All Known Implementing Classes:
LazySodium,LazySodiumJava
- Enclosing interface:
- ShortHash
public static interface ShortHash.Lazy
-
Method Summary
Modifier and TypeMethodDescriptioncryptoShortHash(byte[] in, Key key) Hash a short message using a key.cryptoShortHashHex(String hexIn, Key key) Hash a short hexadecimal string using a key.Generate a 64-bit key for short-input hashing.cryptoShortHashStr(String in, Key key) Hash a short string using a key.
-
Method Details
-
cryptoShortHashKeygen
Key cryptoShortHashKeygen()Generate a 64-bit key for short-input hashing.- Returns:
- Key.
-
cryptoShortHash
Hash a short message using a key.- Parameters:
in- The short message to hash.key- The key generated viacryptoShortHashKeygen().- Returns:
- Your message hashed of size
ShortHash.BYTES, as hexadecimal string. - Throws:
SodiumException
-
cryptoShortHashStr
Hash a short string using a key.- Parameters:
in- The short message to hash.key- The key generated viacryptoShortHashKeygen().- Returns:
- Your message hashed of size
ShortHash.BYTES, as hexadecimal string. - Throws:
SodiumException
-
cryptoShortHashHex
Hash a short hexadecimal string using a key.- Parameters:
hexIn- The short message to hash, represented as hexadecimal string.key- The key generated viacryptoShortHashKeygen().- Returns:
- Your message hashed of size
ShortHash.BYTES, as hexadecimal string. - Throws:
SodiumException
-