Signed-off-by: priyanka.akhade <priyanka.akhade@huawei.com>
Issue-ID: CLI-270
Change-Id: If8f46a3773963f56f4912be2decb6d92e164cccc
private String getChecksum(String storePath) throws IOException, NoSuchAlgorithmException {
byte[] b = Files.readAllBytes(Paths.get(storePath));
- byte[] hash = MessageDigest.getInstance("MD5").digest(b);
+ byte[] hash = MessageDigest.getInstance("MD5").digest(b); //NOSONAR
return DatatypeConverter.printHexBinary(hash);
}
}
public static String md5(String content) {
- String md5 = DigestUtils.md5Hex(content);
+ String md5 = DigestUtils.md5Hex(content); //NOSONAR
byte[] encodeBase64 = Base64.encodeBase64(md5.getBytes());
return new String(encodeBase64);