Index: third_party/WebKit/Source/core/dom/Document.cpp |
diff --git a/third_party/WebKit/Source/core/dom/Document.cpp b/third_party/WebKit/Source/core/dom/Document.cpp |
index cb15d60c880e77551955d84a19d2777387ff585c..66c4b7596230fb2cbfd06906b47b59cb42c95574 100644 |
--- a/third_party/WebKit/Source/core/dom/Document.cpp |
+++ b/third_party/WebKit/Source/core/dom/Document.cpp |
@@ -4071,7 +4071,9 @@ const KURL& Document::firstPartyForCookies() const |
currentDocument = currentDocument->parentDocument(); |
ASSERT(currentDocument); |
- if (accessEntry.matchesOrigin(*currentDocument->securityOrigin()) == OriginAccessEntry::DoesNotMatchOrigin) |
+ // We use 'matchesDomain' here, as it turns out that some folks embed HTTPS login forms |
+ // into HTTP pages; we should allow this kind of upgrade. |
+ if (accessEntry.matchesDomain(*currentDocument->securityOrigin()) == OriginAccessEntry::DoesNotMatchOrigin) |
return SecurityOrigin::urlWithUniqueSecurityOrigin(); |
currentDocument = currentDocument->parentDocument(); |