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 49D6FDCCF for ; Wed, 26 Sep 2012 17:07:47 +0000 (UTC) Received: (qmail 77450 invoked by uid 500); 26 Sep 2012 17:07:47 -0000 Delivered-To: apmail-cxf-commits-archive@cxf.apache.org Received: (qmail 77395 invoked by uid 500); 26 Sep 2012 17:07:47 -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 77388 invoked by uid 99); 26 Sep 2012 17:07:47 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Sep 2012 17:07:47 +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; Wed, 26 Sep 2012 17:07:46 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 75E54238890D; Wed, 26 Sep 2012 17:07:03 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1390608 - /cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java Date: Wed, 26 Sep 2012 17:07:03 -0000 To: commits@cxf.apache.org From: dkulp@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120926170703.75E54238890D@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: dkulp Date: Wed Sep 26 17:07:03 2012 New Revision: 1390608 URL: http://svn.apache.org/viewvc?rev=1390608&view=rev Log: Merged revisions 1390604 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/branches/2.6.x-fixes ........ r1390604 | dkulp | 2012-09-26 13:05:28 -0400 (Wed, 26 Sep 2012) | 10 lines Merged revisions 1390600 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/trunk ........ r1390600 | dkulp | 2012-09-26 12:56:17 -0400 (Wed, 26 Sep 2012) | 2 lines If the Basic auth stuff is not valid, but a principal was provided, use it. ........ ........ Modified: cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java Modified: cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java?rev=1390608&r1=1390607&r2=1390608&view=diff ============================================================================== --- cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java (original) +++ cxf/branches/2.5.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java Wed Sep 26 17:07:03 2012 @@ -165,9 +165,10 @@ public abstract class AbstractHTTPDestin policy.setAuthorizationType(authType); return policy; } catch (Base64Exception ex) { - // Invalid authentication => treat as not authenticated + // Invalid authentication => treat as not authenticated or use the Principal } - } else if (pp != null) { + } + if (pp != null) { AuthorizationPolicy policy = new PrincipalAuthorizationPolicy(pp); policy.setUserName(pp.getName()); policy.setAuthorization(credentials);