Search in sources :

Example 1 with KeyDigest

use of im.actor.runtime.crypto.primitives.digest.KeyDigest in project actor-platform by actorapp.

the class Crypto method keyHash.

public static String keyHash(byte[] publicKey) {
    KeyDigest keyDigest = new KeyDigest();
    keyDigest.update(publicKey, 0, publicKey.length);
    byte[] res = new byte[8];
    keyDigest.doFinal(res, 0);
    return Hex.toHex(res);
}
Also used : KeyDigest(im.actor.runtime.crypto.primitives.digest.KeyDigest)

Aggregations

KeyDigest (im.actor.runtime.crypto.primitives.digest.KeyDigest)1