summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcfu <cfu@c9f7a03b-bd48-0410-a16d-cbbf54688b0b>2009-06-02 19:42:15 +0000
committercfu <cfu@c9f7a03b-bd48-0410-a16d-cbbf54688b0b>2009-06-02 19:42:15 +0000
commita78bc8a282a197821c9e7efb83ec9409e0bb3a40 (patch)
treed70603b7de33762e17707b4d2df2fb339d440090
parent17303ca864ad2e1d2ef3325fe24892449e589be6 (diff)
Bugzilla 500738 - (nethsm2k): KRA/TKS : Installation wizard fails
git-svn-id: svn+ssh://svn.fedorahosted.org/svn/pki/trunk@539 c9f7a03b-bd48-0410-a16d-cbbf54688b0b
-rw-r--r--pki/base/common/src/com/netscape/cms/servlet/csadmin/CertRequestPanel.java14
-rw-r--r--pki/base/common/src/com/netscape/cms/servlet/csadmin/WizardPanelBase.java14
2 files changed, 17 insertions, 11 deletions
diff --git a/pki/base/common/src/com/netscape/cms/servlet/csadmin/CertRequestPanel.java b/pki/base/common/src/com/netscape/cms/servlet/csadmin/CertRequestPanel.java
index 654c2f8db..a3df1647f 100644
--- a/pki/base/common/src/com/netscape/cms/servlet/csadmin/CertRequestPanel.java
+++ b/pki/base/common/src/com/netscape/cms/servlet/csadmin/CertRequestPanel.java
@@ -123,8 +123,8 @@ public class CertRequestPanel extends WizardPanelBase {
return true;
} catch (Exception ee) {
if (hardware) {
- CMS.debug("CertRequestPanel findCertificate: The certificate with the same nickname has been found on HSM. Please remove it before proceeding.");
- throw new IOException("The certificate with the same nickname has been found on HSM. Please remove it before proceeding.");
+ CMS.debug("CertRequestPanel findCertificate: The certificate with the same nickname: "+ fullnickname +" has been found on HSM. Please remove it before proceeding.");
+ throw new IOException("The certificate with the same nickname: "+ fullnickname +" has been found on HSM. Please remove it before proceeding.");
}
return true;
}
@@ -563,10 +563,11 @@ public class CertRequestPanel extends WizardPanelBase {
+ certTag);
} catch (Exception ee) {
CMS.debug(
- "CertRequestPanel configCert: Failed to import certificate "
+ "CertRequestPanel configCert: import certificate for certTag="
+ certTag + " Exception: "
+ ee.toString());
- hasErr = true;
+ CMS.debug("ok");
+// hasErr = true;
}
}
} else if (cert.getType().equals("remote")) {
@@ -639,10 +640,11 @@ public class CertRequestPanel extends WizardPanelBase {
+ certTag);
} catch (Exception ee) {
CMS.debug(
- "CertRequestPanel configCert: Failed to import certificate "
+ "CertRequestPanel configCert: import certificate for certTag="
+ certTag + " Exception: "
+ ee.toString());
- hasErr=true;
+ CMS.debug("ok");
+// hasErr=true;
}
} else {
CMS.debug("CertRequestPanel: in update() input null");
diff --git a/pki/base/common/src/com/netscape/cms/servlet/csadmin/WizardPanelBase.java b/pki/base/common/src/com/netscape/cms/servlet/csadmin/WizardPanelBase.java
index 529e493e8..1c51445b8 100644
--- a/pki/base/common/src/com/netscape/cms/servlet/csadmin/WizardPanelBase.java
+++ b/pki/base/common/src/com/netscape/cms/servlet/csadmin/WizardPanelBase.java
@@ -244,8 +244,10 @@ public class WizardPanelBase implements IWizardPanel {
tokenname = cs.getString("preop.module.token", "");
} catch (Exception e) {}
- if (!tokenname.equals("Internal Key Storage Token") && !tokenname.equals("internal")) {
- nickname = tokenname+":"+nickname;
+ if (!tokenname.equals("") &&
+ !tokenname.equals("Internal Key Storage Token") &&
+ !tokenname.equals("internal")) {
+ nickname = tokenname+":"+nickname;
}
CMS.debug("WizardPanelBase updateDomainXML nickname=" + nickname);
@@ -1440,9 +1442,10 @@ public class WizardPanelBase implements IWizardPanel {
CryptoToken tok = cm.getTokenByName(tokenname);
CryptoStore store = tok.getCryptoStore();
String fullnickname = nickname;
- if (tokenname.equals("Internal Key Storage Token") &&
- tokenname.equals("internal"))
- fullnickname = tokenname+":"+nickname;
+ if (!tokenname.equals("") &&
+ !tokenname.equals("Internal Key Storage Token") &&
+ !tokenname.equals("internal"))
+ fullnickname = tokenname+":"+nickname;
CMS.debug("WizardPanelBase deleteCert: nickname="+fullnickname);
org.mozilla.jss.crypto.X509Certificate cert = cm.findCertByNickname(fullnickname);
@@ -1451,6 +1454,7 @@ public class WizardPanelBase implements IWizardPanel {
CMS.debug("WizardPanelBase deleteCert: this is pk11store");
PK11Store pk11store = (PK11Store)store;
pk11store.deleteCertOnly(cert);
+ CMS.debug("WizardPanelBase deleteCert: cert deleted successfully");
}
} catch (Exception e) {
CMS.debug("WizardPanelBase deleteCert: Exception="+e.toString());