Class Crypto.HASH
java.lang.Object
com.almis.awe.model.util.security.Crypto.HASH
- Enclosing class:
- Crypto
HASH
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
Create a HASH with algorithmstatic String
Create a HASH with md2Hashstatic String
Create a HASH with md5Hashstatic String
Create a HASH with sha1Hashstatic String
sha256Hash
(String message) Create a HASH with sha256Hashstatic String
sha384Hash
(String message) Create a HASH with sha384Hashstatic String
sha512Hash
(String message) Create a HASH with sha512Hash
-
Method Details
-
hash
public static String hash(String message, String algorithm, String salt, Charset encoding) throws AWException Create a HASH with algorithm- Parameters:
message
- Message to hashalgorithm
- algorithm to usesalt
- salt of algorithmencoding
- charset encoding- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
md2Hash
Create a HASH with md2Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
md5Hash
Create a HASH with md5Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
sha1Hash
Create a HASH with sha1Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
sha256Hash
Create a HASH with sha256Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
sha384Hash
Create a HASH with sha384Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-
sha512Hash
Create a HASH with sha512Hash- Parameters:
message
- Message to hash- Returns:
- Hash
- Throws:
AWException
- No such algorithm
-