Package org.bouncycastle.crypto.agreement.srp

Examples of org.bouncycastle.crypto.agreement.srp.SRP6Client


        BigInteger N = new BigInteger(1, NByte);
        BigInteger g = new BigInteger(1, gByte);
        byte[] s = sByte;
        BigInteger B = new BigInteger(1, BByte);
   
        SRP6Client srpClient = new SRP6Client();
        srpClient.init(N, g, new SHA1Digest(), random);

        this.SRP_A = srpClient.generateClientCredentials(s, this.SRP_identity,
            this.SRP_password);
   
        try
        {
            BigInteger S = srpClient.calculateSecret(B);
            this.pms = BigIntegers.asUnsignedByteArray(S);
        }
        catch (CryptoException e)
        {
            this.failWithError(AL_fatal, AP_illegal_parameter);
View Full Code Here

TOP

Related Classes of org.bouncycastle.crypto.agreement.srp.SRP6Client

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.