Return-Path: X-Original-To: apmail-cxf-commits-archive@www.apache.org Delivered-To: apmail-cxf-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 57B7010603 for ; Fri, 10 Jan 2014 16:51:49 +0000 (UTC) Received: (qmail 46717 invoked by uid 500); 10 Jan 2014 16:51:43 -0000 Delivered-To: apmail-cxf-commits-archive@cxf.apache.org Received: (qmail 46685 invoked by uid 500); 10 Jan 2014 16:51:42 -0000 Mailing-List: contact commits-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list commits@cxf.apache.org Received: (qmail 46673 invoked by uid 99); 10 Jan 2014 16:51:41 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Jan 2014 16:51:41 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 10 Jan 2014 16:51:36 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 2D1242388868; Fri, 10 Jan 2014 16:51:16 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1557189 - /cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java Date: Fri, 10 Jan 2014 16:51:16 -0000 To: commits@cxf.apache.org From: coheigea@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20140110165116.2D1242388868@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: coheigea Date: Fri Jan 10 16:51:15 2014 New Revision: 1557189 URL: http://svn.apache.org/r1557189 Log: Merged revisions 1557187 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/trunk ........ r1557187 | coheigea | 2014-01-10 16:47:47 +0000 (Fri, 10 Jan 2014) | 2 lines Potential NPE fix ........ Modified: cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java Modified: cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java?rev=1557189&r1=1557188&r2=1557189&view=diff ============================================================================== --- cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java (original) +++ cxf/branches/2.7.x-fixes/rt/rs/security/xml/src/main/java/org/apache/cxf/rs/security/common/TrustValidator.java Fri Jan 10 16:51:15 2014 @@ -36,7 +36,9 @@ public class TrustValidator { Credential trustCredential = new Credential(); trustCredential.setPublicKey(publicKey); - trustCredential.setCertificates(new X509Certificate[]{cert}); + if (cert != null) { + trustCredential.setCertificates(new X509Certificate[]{cert}); + } validator.validate(trustCredential, data); } }