ws-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cohei...@apache.org
Subject svn commit: r1755592 - /webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java
Date Tue, 09 Aug 2016 10:19:53 GMT
Author: coheigea
Date: Tue Aug  9 10:19:53 2016
New Revision: 1755592

URL: http://svn.apache.org/viewvc?rev=1755592&view=rev
Log:
NPE fix

Modified:
    webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java

Modified: webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java
URL: http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java?rev=1755592&r1=1755591&r2=1755592&view=diff
==============================================================================
--- webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java
(original)
+++ webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/saml/SamlAssertionWrapper.java
Tue Aug  9 10:19:53 2016
@@ -523,7 +523,10 @@ public class SamlAssertionWrapper {
         // prepare to sign the SAML token
         CryptoType cryptoType = new CryptoType(CryptoType.TYPE.ALIAS);
         cryptoType.setAlias(issuerKeyName);
-        X509Certificate[] issuerCerts = issuerCrypto.getX509Certificates(cryptoType);
+        X509Certificate[] issuerCerts = null;
+        if (issuerCrypto != null) {
+            issuerCerts = issuerCrypto.getX509Certificates(cryptoType);
+        }
         if (issuerCerts == null || issuerCerts.length == 0) {
             throw new WSSecurityException(WSSecurityException.ErrorCode.FAILURE, "empty",
                 new Object[] {



Mime
View raw message