public class EncryptUtils extends Object
Constructor and Description |
---|
EncryptUtils() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
encrypt(byte[] source,
String algorithm)
Encrypt byte array.
|
static String |
encrypt(String source,
String algorithm)
Encrypt string
|
static String |
encryptMD5(String source)
Encrypt string using MD5 algorithm
|
static String |
encryptSHA(String source)
Encrypt string using SHA algorithm
|
public static final byte[] encrypt(byte[] source, String algorithm) throws NoSuchAlgorithmException
NoSuchAlgorithmException
public static final String encrypt(String source, String algorithm) throws NoSuchAlgorithmException
NoSuchAlgorithmException
Copyright © 2003–2016 The Apache Software Foundation. All rights reserved.