Update of /cvsroot/freenet/freenet/src/freenet/client
In directory sc8-pr-cvs1:/tmp/cvs-serv15619/src/freenet/client

Modified Files:
        ClientSVK.java 
Log Message:
Some optimizations wrt encryption:
Dont generate pubkey from privkey when we already have it available.
Dont generate hextrings from BigInteger:s when we already have them and the other way 
around.

Index: ClientSVK.java
===================================================================
RCS file: /cvsroot/freenet/freenet/src/freenet/client/ClientSVK.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- ClientSVK.java      1 Jul 2003 18:39:17 -0000       1.4
+++ ClientSVK.java      8 Oct 2003 22:48:38 -0000       1.5
@@ -43,8 +43,8 @@
     protected SVK svk;
     protected byte[] cryptoKey;
     protected String docName;
-    protected DSAPrivateKey sk;
-    protected DSAPublicKey pk;
+    protected DSAPrivateKey sk; //Should always be set to the private key for the 
public key below 
+    protected DSAPublicKey pk;  //Should always be set to the public key for the 
private key above
 
     public ClientSVK(byte[] val, byte[] cryptoKey, String docName) 
        throws KeyException {
@@ -137,7 +137,7 @@
             storables.setDocumentName(Util.hashString(SHA1.getInstance(), 
                                                      getDocumentName()));
         }
-        storables.sign(r, sk, pk.getGroup());
+        storables.sign(r, sk, pk);
         svk = new SVK(storables, SVK.SVK_LOG2_MAXSIZE);
         return ret;
     }

_______________________________________________
cvs mailing list
[EMAIL PROTECTED]
http://dodo.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to