[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

ap at apple.com ap at apple.com
Wed Apr 7 23:49:24 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 0a64a351a866fb85cd37a4380f5fdbb972690a60
Author: ap at apple.com <ap at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Nov 19 17:43:30 2009 +0000

            Reviewed by Darin Adler.
    
            https://bugs.webkit.org/show_bug.cgi?id=31634
            Ignore realm for proxy protection spaces
    
            Only affects WebSocket proxy authentication, cannot be tested in DRT.
    
            * platform/network/ProtectionSpace.cpp:
            (WebCore::operator==):
            * platform/network/ProtectionSpaceHash.h:
            (WebCore::ProtectionSpaceHash::hash):
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51189 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index c4100c0..fe426ef 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,17 @@
+2009-11-19  Alexey Proskuryakov  <ap at apple.com>
+
+        Reviewed by Darin Adler.
+
+        https://bugs.webkit.org/show_bug.cgi?id=31634
+        Ignore realm for proxy protection spaces
+
+        Only affects WebSocket proxy authentication, cannot be tested in DRT.
+
+        * platform/network/ProtectionSpace.cpp:
+        (WebCore::operator==):
+        * platform/network/ProtectionSpaceHash.h:
+        (WebCore::ProtectionSpaceHash::hash):
+
 2009-11-19  Olivier Goffart  <ogoffart at trolltech.com>
 
         Reviewed by Simon Hausmann.
diff --git a/WebCore/platform/network/ProtectionSpace.cpp b/WebCore/platform/network/ProtectionSpace.cpp
index d04bcbe..26c258f 100644
--- a/WebCore/platform/network/ProtectionSpace.cpp
+++ b/WebCore/platform/network/ProtectionSpace.cpp
@@ -111,7 +111,8 @@ bool operator==(const ProtectionSpace& a, const ProtectionSpace& b)
         return false;
     if (a.serverType() != b.serverType())
         return false;
-    if (a.realm() != b.realm())
+    // Ignore realm for proxies
+    if (!a.isProxy() && a.realm() != b.realm())
         return false;
     if (a.authenticationScheme() != b.authenticationScheme())
         return false;
diff --git a/WebCore/platform/network/ProtectionSpaceHash.h b/WebCore/platform/network/ProtectionSpaceHash.h
index 6f68b5b..f8c84e8 100644
--- a/WebCore/platform/network/ProtectionSpaceHash.h
+++ b/WebCore/platform/network/ProtectionSpaceHash.h
@@ -37,11 +37,15 @@ struct ProtectionSpaceHash {
             protectionSpace.host().impl() ? protectionSpace.host().impl()->hash() : 0, 
             protectionSpace.port(), 
             protectionSpace.serverType(),
-            protectionSpace.realm().impl() ? protectionSpace.realm().impl()->hash() : 0,
-            protectionSpace.authenticationScheme()
+            protectionSpace.authenticationScheme(),
+            protectionSpace.realm().impl() ? protectionSpace.realm().impl()->hash() : 0
         };
 
-        return StringImpl::computeHash(reinterpret_cast<UChar*>(hashCodes), sizeof(hashCodes) / sizeof(UChar));    
+        unsigned codeCount = sizeof(hashCodes) / sizeof(UChar);
+        // Ignore realm for proxies.
+        if (protectionSpace.isProxy())
+            codeCount -= sizeof(hashCodes[0]) / sizeof(UChar);
+        return StringImpl::computeHash(reinterpret_cast<UChar*>(hashCodes), codeCount);
     }
     
     static bool equal(const ProtectionSpace& a, const ProtectionSpace& b) { return a == b; }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list