[CalendarServer-changes] [8473] CalendarServer/trunk/twistedcaldav/client/reverseproxy.py

source_changes at macosforge.org source_changes at macosforge.org
Tue Dec 20 08:45:18 PST 2011


Revision: 8473
          http://trac.macosforge.org/projects/calendarserver/changeset/8473
Author:   cdaboo at apple.com
Date:     2011-12-20 08:45:15 -0800 (Tue, 20 Dec 2011)
Log Message:
-----------
Fix case-insensitive domain comparison.

Modified Paths:
--------------
    CalendarServer/trunk/twistedcaldav/client/reverseproxy.py

Modified: CalendarServer/trunk/twistedcaldav/client/reverseproxy.py
===================================================================
--- CalendarServer/trunk/twistedcaldav/client/reverseproxy.py	2011-12-19 19:09:47 UTC (rev 8472)
+++ CalendarServer/trunk/twistedcaldav/client/reverseproxy.py	2011-12-20 16:45:15 UTC (rev 8473)
@@ -1,5 +1,5 @@
 ##
-# Copyright (c) 2009-2010 Apple Inc. All rights reserved.
+# Copyright (c) 2009-2011 Apple Inc. All rights reserved.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -71,7 +71,7 @@
             x_server =  request.headers.getHeader("x-forwarded-server")
             if x_server:
                 for item in x_server:
-                    if item == config.ServerHostName:
+                    if item.lower() == config.ServerHostName.lower():
                         raise HTTPError(StatusResponse(responsecode.BAD_GATEWAY, "Too many x-forwarded-server hops"))
                 
             
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20111220/7f987070/attachment.html>


More information about the calendarserver-changes mailing list