From c08263d1c3d6444616f51643c409a4e2d7c02593 Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Wed, 19 Jun 2013 17:36:43 -0400 Subject: [PATCH] Updated patch --- SoObjects/SOGo/SOGoProxyAuthenticator.m | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/SoObjects/SOGo/SOGoProxyAuthenticator.m b/SoObjects/SOGo/SOGoProxyAuthenticator.m index 42d608f41..b054512e6 100644 --- a/SoObjects/SOGo/SOGoProxyAuthenticator.m +++ b/SoObjects/SOGo/SOGoProxyAuthenticator.m @@ -59,16 +59,15 @@ { NSString *remoteUser; - if ([[SOGoSystemDefaults sharedSystemDefaults] trustProxyAuthentication]) + + /* If such a header is not provided by the proxy, SOPE will attempt to + deduce it from the "Authorization" header. */ + remoteUser = [[context request] headerForKey: @"x-webobjects-remote-user"]; + + if ([remoteUser length] == 0 && [[SOGoSystemDefaults sharedSystemDefaults] trustProxyAuthentication]) { remoteUser = @"anonymous"; } - else - { - /* If such a header is not provided by the proxy, SOPE will attempt to - deduce it from the "Authorization" header. */ - remoteUser = [[context request] headerForKey: @"x-webobjects-remote-user"]; - } return remoteUser; }