diff options
author | awnuk <awnuk@c9f7a03b-bd48-0410-a16d-cbbf54688b0b> | 2009-06-12 20:01:17 +0000 |
---|---|---|
committer | awnuk <awnuk@c9f7a03b-bd48-0410-a16d-cbbf54688b0b> | 2009-06-12 20:01:17 +0000 |
commit | 74941f5d01739451666b4303dd1197451a62dc2d (patch) | |
tree | ace7b7e5e7d72095c175c51f51f689a56fb29d7f /pki/base/ca/src/com/netscape/ca | |
parent | 722bdee39d30fc6dfc8c29b41666ded48a3b1994 (diff) | |
download | pki-74941f5d01739451666b4303dd1197451a62dc2d.tar.gz pki-74941f5d01739451666b4303dd1197451a62dc2d.tar.xz pki-74941f5d01739451666b4303dd1197451a62dc2d.zip |
Bugzilla bug #502694.
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/pki/trunk@594 c9f7a03b-bd48-0410-a16d-cbbf54688b0b
Diffstat (limited to 'pki/base/ca/src/com/netscape/ca')
-rw-r--r-- | pki/base/ca/src/com/netscape/ca/CertificateAuthority.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/pki/base/ca/src/com/netscape/ca/CertificateAuthority.java b/pki/base/ca/src/com/netscape/ca/CertificateAuthority.java index 1a101ed53..0438bcbd2 100644 --- a/pki/base/ca/src/com/netscape/ca/CertificateAuthority.java +++ b/pki/base/ca/src/com/netscape/ca/CertificateAuthority.java @@ -173,6 +173,10 @@ public class CertificateAuthority implements ICertificateAuthority, ICertAuthori private boolean mByName = true; + private boolean mUseNonces = true; + private int mMaxNonces = 100; + private Nonces mNonces = null; + /** * Constructs a CA subsystem. */ @@ -245,6 +249,15 @@ public class CertificateAuthority implements ICertificateAuthority, ICertAuthori return maxNumberOfPublishingThreads; } + + public boolean noncesEnabled() { + return mUseNonces; + } + + public Nonces getNonces() { + return mNonces; + } + /** * Initializes this CA subsystem. * <P> @@ -279,6 +292,13 @@ public class CertificateAuthority implements ICertificateAuthority, ICertAuthori // init web gateway. initWebGateway(); + mUseNonces = mConfig.getBoolean("enableNonces", true); + mMaxNonces = mConfig.getInteger("maxNumberOfNonces", 100); + if (mUseNonces) { + mNonces = new Nonces(mMaxNonces); + CMS.debug("CertificateAuthority init: Nonces enabled. ("+mNonces.size()+")"); + } + // init request queue and related modules. CMS.debug("CertificateAuthority init: initRequestQueue"); initRequestQueue(); |