|
From: <pe...@us...> - 2003-12-19 00:31:19
|
Update of /cvsroot/neuclear/neuclear-commons/src/java/org/neuclear/commons/crypto
In directory sc8-pr-cvs1:/tmp/cvs-serv18953/src/java/org/neuclear/commons/crypto
Modified Files:
CryptoTools.java
Log Message:
Lots of usability changes through out all the passphrase agents and end user tools.
Index: CryptoTools.java
===================================================================
RCS file: /cvsroot/neuclear/neuclear-commons/src/java/org/neuclear/commons/crypto/CryptoTools.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** CryptoTools.java 18 Dec 2003 17:40:07 -0000 1.8
--- CryptoTools.java 19 Dec 2003 00:31:16 -0000 1.9
***************
*** 2,5 ****
--- 2,8 ----
* $Id$
* $Log$
+ * Revision 1.9 2003/12/19 00:31:16 pelle
+ * Lots of usability changes through out all the passphrase agents and end user tools.
+ *
* Revision 1.8 2003/12/18 17:40:07 pelle
* You can now create keys that get stored with a X509 certificate in the keystore. These can be saved as well.
***************
*** 224,227 ****
--- 227,231 ----
import org.bouncycastle.jce.X509Principal;
import org.bouncycastle.asn1.x509.X509Name;
+ import org.neuclear.commons.time.TimeTools;
import javax.crypto.Cipher;
***************
*** 251,254 ****
--- 255,260 ----
public final class CryptoTools {
+
+
/**
* Call this method at the beginning of an executable. To ensure that BouncyCastle gets installed properly.
***************
*** 785,788 ****
--- 791,795 ----
gen.setPublicKey(kp.getPublic());
gen.setNotBefore(new Date());
+ gen.setNotAfter(TimeTools.get2020());
gen.setSignatureAlgorithm("SHA1withRSA");
gen.setSerialNumber(new BigInteger( digest(kp.getPublic().getEncoded())));
***************
*** 806,809 ****
public final static String DEFAULT_KEYSTORE = System.getProperty("user.home") + "/.neuclear/keystore.jks";
public static final int RAND_BIT_LENGTH = 128;
!
}
--- 813,816 ----
public final static String DEFAULT_KEYSTORE = System.getProperty("user.home") + "/.neuclear/keystore.jks";
public static final int RAND_BIT_LENGTH = 128;
! private static final long YPLUS20 = 20*365*24*60*60;
}
|