Package gnu.crypto.hash

Examples of gnu.crypto.hash.RipeMD160.digest()


    final byte[] ripemd160Hash(String p) {
        //ripemd 160 hash
        final RipeMD160 ripemd160 = new RipeMD160();
        final byte[] data = p.getBytes();
        ripemd160.update(data, 0, data.length);
        final byte[] hash = ripemd160.digest();
        return hash;
    }
   
    final byte[] md5Hash(String p) {
        //ripemd 160 hash
View Full Code Here


    // Run additional 16% faster using direct class versus
    // HashFactory.getInstance("RIPEMD-160").
    RipeMD160 hash = new RipeMD160();
    hash.update(buffer, 0, setLength);
    hash.update(buffer, setLength, keyLength + 1);
    return hash.digest();
  }
}
View Full Code Here

    // Run additional 16% faster using direct class versus
    // HashFactory.getInstance("RIPEMD-160").
    RipeMD160 hash = new RipeMD160();
    hash.update(buffer, 0, setLength);
    hash.update(buffer, setLength, keyLength + 1);
    return hash.digest();
  }
}
View Full Code Here

    // Run additional 16% faster using direct class versus
    // HashFactory.getInstance("RIPEMD-160").
    RipeMD160 hash = new RipeMD160();
    hash.update(buffer, 0, setLength);
    hash.update(buffer, setLength, keyLength + 1);
    return hash.digest();
  }
 
  @Override
  public String toString() {
    return this.namespace + ":" + this.setName + ":" + this.userKey + ":" + this.digest;
View Full Code Here

    // Run additional 16% faster using direct class versus
    // HashFactory.getInstance("RIPEMD-160").
    RipeMD160 hash = new RipeMD160();
    hash.update(buffer, 0, setLength);
    hash.update(buffer, setLength, keyLength + 1);
    return hash.digest();
  }
 
  @Override
  public String toString() {
    return this.namespace + ":" + this.setName + ":" + this.userKey + ":" + Buffer.bytesToHexString(this.digest);
View Full Code Here

    // Run additional 16% faster using direct class versus
    // HashFactory.getInstance("RIPEMD-160").
    RipeMD160 hash = new RipeMD160();
    hash.update(buffer, 0, setLength);
    hash.update(buffer, setLength, keyLength + 1);
    return hash.digest();
  }
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.