Package com.googlecode.gwt.crypto.util

Examples of com.googlecode.gwt.crypto.util.SecureRandom


     */
    public static AsymmetricCipherKeyPair makeKeypairSlow(Strength strength) {
        RSAKeyPairGenerator generator = new RSAKeyPairGenerator();

        // see https://code.google.com/p/gwt-crypto/issues/detail?id=25
        SecureRandom random = SecureRandom.getInstance(null);
        BigInteger exponent = BigInteger.valueOf(65537);
        RSAKeyGenerationParameters params = new RSAKeyGenerationParameters(
                exponent,
                random,
                strength.strength,
View Full Code Here


        }
    }

    // TODO move out of AES
    public static String randomKey() {
        BigInteger exponent = new BigInteger(256, new SecureRandom());
        return exponent.toString();
    }
View Full Code Here

TOP

Related Classes of com.googlecode.gwt.crypto.util.SecureRandom

Copyright © 2018 www.massapicom. 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.