I have some code that computes a hash of a byte array using Guava's Hashing
class
private String getShaForFile(byte[] bytes) {
return Hashing.sha256().hashBytes(bytes).toString();
}
However, a linting tool is complaining that this class is unstable, so I'd like to replace this implementation with one that uses the JDK classes (I'd rather not add a dependency like Bouncy Castle just for the sake of this one method).