class Digest {

    public static byte[] makeRand()
        throws NoSuchAlgorithmException {

        byte[] digest = null;
        byte[] r = new byte[HASH_SIZE_BYTES];
        try {
            random.nextBytes(r);
            digest = digest(r);
        }
        // let's panic if an exception occurs
        finally {
            return digest(r);
        }
    }

}