Java 类org.bouncycastle.crypto.digests.GeneralDigest 实例源码

项目:bunkr    文件:PasswordProvider.java   
private byte[] hash(byte[] input)
{
    GeneralDigest digest = new SHA256Digest();
    digest.update(input, 0, input.length);
    byte[] buffer = new byte[digest.getDigestSize()];
    digest.doFinal(buffer, 0);
    Arrays.fill(input, (byte) 0);
    return buffer;
}
项目:bunkr    文件:TestBlockReaderInputStream.java   
public byte[] hashUp(byte[] input)
{
    GeneralDigest d = new SHA1Digest();
    d.update(input, 0, input.length);
    byte[] b = new byte[d.getDigestSize()];
    d.doFinal(b, 0);
    return b;
}
项目:warp10-platform    文件:DIGEST.java   
public DIGEST(String name, Class<? extends GeneralDigest> digestAlgo) {
  super(name);
  this.digestAlgo = digestAlgo;
}
项目:warp10-platform    文件:HMAC.java   
public HMAC(String name, Class<? extends GeneralDigest> digestAlgo) {
  super(name);
  this.digestAlgo = digestAlgo;
}
项目:LiquidDonkey    文件:SnapshotDirectory.java   
SnapshotDirectory(Path folder, GeneralDigest digest) {
    this.folder = folder;
    this.digest = digest;
}
项目:LiquidDonkey    文件:FileDecrypter.java   
FileDecrypter(BufferedBlockCipher cbcAes, GeneralDigest digest) {
    this.cbcAes = cbcAes;
    this.digest = digest;
}
项目:LiquidDonkey    文件:ChunkDecrypter.java   
ChunkDecrypter(StreamBlockCipher cfbAes, GeneralDigest digest) {
    this.cfbAes = Objects.requireNonNull(cfbAes);
    this.digest = Objects.requireNonNull(digest);
}