Author: nextgens
Date: 2007-09-27 18:46:23 +0000 (Thu, 27 Sep 2007)
New Revision: 15366

Modified:
   branches/freenet-jfk/src/freenet/crypt/DiffieHellmanLightContext.java
Log:
logging

Modified: branches/freenet-jfk/src/freenet/crypt/DiffieHellmanLightContext.java
===================================================================
--- branches/freenet-jfk/src/freenet/crypt/DiffieHellmanLightContext.java       
2007-09-27 18:22:13 UTC (rev 15365)
+++ branches/freenet-jfk/src/freenet/crypt/DiffieHellmanLightContext.java       
2007-09-27 18:46:23 UTC (rev 15366)
@@ -39,16 +39,16 @@
        /*
         * Calling the following is costy; avoid
         */
-       public NativeBigInteger getHMACKey(NativeBigInteger peerExponential, 
DSAGroup group) {          
+       public NativeBigInteger getHMACKey(NativeBigInteger peerExponential, 
DSAGroup group) {
+               NativeBigInteger sharedSecret =
+                       (NativeBigInteger) peerExponential.modPow(myExponent, 
group.getP());
+               
                if(logMINOR) {
                        Logger.minor(this, "My exponent: 
"+myExponent.toHexString());
                        Logger.minor(this, "My exponential: 
"+myExponential.toHexString());
                        Logger.minor(this, "Peer's exponential: 
"+peerExponential.toHexString());
+                       Logger.minor(this, "g^ir mod p = " + 
sharedSecret.toHexString());
                }
-               NativeBigInteger sharedSecret =
-                       (NativeBigInteger) peerExponential.modPow(myExponent, 
group.getP());
-               if(logMINOR)
-                       Logger.minor(this, "g^ir mod p = " + 
sharedSecret.toHexString());

                return sharedSecret;
        }


Reply via email to