Skip to content

Commit

Permalink
Fixed pki pkcs12-import.
Browse files Browse the repository at this point in the history
The pki pkcs12-import has been modified to parse the
pki pkcs12-cert-find output properly.

https://pagure.io/dogtagpki/issue/2945

Change-Id: I1bcdea496896a6f70156f7ca5bb2419c3966f132
  • Loading branch information
edewata committed Feb 26, 2018
1 parent 3e3a840 commit 881ab15
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion base/common/python/pki/cli/pkcs12.py
Expand Up @@ -180,7 +180,7 @@ def execute(self, argv):
certs.append(cert_info)
continue

match = re.match(r' Nickname: (.*)$', line)
match = re.match(r' Friendly Name: (.*)$', line)
if match:
cert_info['nickname'] = match.group(1)
continue
Expand Down
2 changes: 1 addition & 1 deletion base/server/cms/src/com/netscape/cms/realm/PKIRealm.java
Expand Up @@ -86,7 +86,7 @@ public Principal authenticate(String username, String password) {
}

@Override
public Principal authenticate(final X509Certificate certs[]) {
public Principal authenticate(final X509Certificate[] certs) {
logger.info("Authenticating certificate chain:");

// get the cert from the ssl client auth
Expand Down
Expand Up @@ -84,7 +84,7 @@ public Principal authenticate(String username, String password) {
}

@Override
public Principal authenticate(X509Certificate certs[]) {
public Principal authenticate(X509Certificate[] certs) {
if (realm == null) {
throw new ServiceUnavailableException("Subsystem unavailable");
}
Expand Down
2 changes: 1 addition & 1 deletion base/util/src/netscape/security/pkcs/PKCS12Util.java
Expand Up @@ -551,7 +551,7 @@ public PKCS12KeyInfo getKeyInfo(SafeBag bag, Password password) throws Exception
BMPString friendlyName = (BMPString) new BMPString.Template().decode(bis);

keyInfo.setFriendlyName(friendlyName.toString());
logger.debug(" Friendly Name: " + keyInfo.getFriendlyName());
logger.debug(" Friendly name: " + keyInfo.getFriendlyName());

} else if (oid.equals(SafeBag.LOCAL_KEY_ID)) {

Expand Down

0 comments on commit 881ab15

Please sign in to comment.