diff options
-rw-r--r-- | src/main/java/at/knowcenter/wag/egov/egiz/ldap/api/LDAPAPIImpl.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/at/knowcenter/wag/egov/egiz/ldap/api/LDAPAPIImpl.java b/src/main/java/at/knowcenter/wag/egov/egiz/ldap/api/LDAPAPIImpl.java index 6f4ca72..d6f3e7c 100644 --- a/src/main/java/at/knowcenter/wag/egov/egiz/ldap/api/LDAPAPIImpl.java +++ b/src/main/java/at/knowcenter/wag/egov/egiz/ldap/api/LDAPAPIImpl.java @@ -109,7 +109,9 @@ public class LDAPAPIImpl implements LDAPAPI { try {
LDAPClient client = this.ldapClientFactory.createClient(issuer);
X509Certificate x509certificate = client.retrieveCertificate(new BigInteger(serialNumber));
- base64CertData = Util.Base64Encode(x509certificate.toByteArray());
+ if (x509certificate != null) {
+ base64CertData = Util.Base64Encode(x509certificate.toByteArray());
+ }
} catch (LDAPException e) {
this.log.error(e);
}
|