public class SHA1Tools extends Object
Constructor and Description |
---|
SHA1Tools() |
Modifier and Type | Method and Description |
---|---|
static String |
getLowSHA1Str(byte[] bytes)
获得 字节数组 的SHA1加密值,结果为英文字母小写
20180315 通过了与Apache Commons codec 的计算结果比对 方法说明: getLowSHA1Str 输入参数说明: @param bytes @return @throws NoSuchAlgorithmException 输出参数说明: String |
static String |
getLowSHA1Str(File file)
获取文件的SHA1加密值,结果为英文字母小写
20180315 通过了与Apache Commons codec 的计算结果比对 方法说明: getLowSHA1Str 输入参数说明: @param file @return 输出参数说明: String |
static String |
getLowSHA1Str(InputStream inputStream)
获取输入流的SHA1加密值,结果为英文字母小写
20180315 通过了与Apache Commons codec 的计算结果比对 方法说明: getLowSHA1Str 输入参数说明: @param inputStream @return 输出参数说明: String |
static String |
getLowSHA1Str(String str)
获得 字符串 的SHA1加密值,结果为英文字母小写
20180315 通过了与Apache Commons codec 的计算结果比对 方法说明: getLowSHA1Str 输入参数说明: @param str @return @throws NoSuchAlgorithmException 输出参数说明: String |
static String |
getLowSHA1Str(String str,
Charset charset)
获得 字符串(指定字符编码) 的SHA1加密值,结果为英文字母小写
20180315 通过了与Apache Commons codec 的计算结果比对 方法说明: getLowSHA1Str 输入参数说明: @param str @param charset @return @throws NoSuchAlgorithmException 输出参数说明: String |
public static final String getLowSHA1Str(InputStream inputStream)
public static final String getLowSHA1Str(File file)
public static final String getLowSHA1Str(byte[] bytes)
public static final String getLowSHA1Str(String str, Charset charset)
Copyright © 2018. All rights reserved.