public class CryptoUtil extends Object
public static String encrypt(String inputText, String algorithmName) throws UnsupportedEncodingException, NoSuchAlgorithmException
inputText - 要加密的内容algorithmName - 加密算法名称:md5或者sha-1以及其他,不区分大小写UnsupportedEncodingException - 无法支持的编码类型NoSuchAlgorithmException - 不支持的协议IllegalArgumentException - 不支持的参数Copyright © 2019. All rights reserved.