| Index: third_party/WebKit/Source/core/loader/MixedContentChecker.cpp
|
| diff --git a/third_party/WebKit/Source/core/loader/MixedContentChecker.cpp b/third_party/WebKit/Source/core/loader/MixedContentChecker.cpp
|
| index 31664e1fa04bda0e52033672b5925736dccd83ad..bd3f7385721335cabec4e71bea94bdd9241a535e 100644
|
| --- a/third_party/WebKit/Source/core/loader/MixedContentChecker.cpp
|
| +++ b/third_party/WebKit/Source/core/loader/MixedContentChecker.cpp
|
| @@ -28,6 +28,7 @@
|
|
|
| #include "core/loader/MixedContentChecker.h"
|
|
|
| +#include "bindings/core/v8/SourceLocation.h"
|
| #include "core/dom/Document.h"
|
| #include "core/frame/Frame.h"
|
| #include "core/frame/LocalFrame.h"
|
| @@ -256,7 +257,7 @@ void MixedContentChecker::logToConsoleAboutFetch(LocalFrame* frame, const KURL&
|
| mainResourceUrl.elidedString().utf8().data(), typeNameFromContext(requestContext), url.elidedString().utf8().data(),
|
| allowed ? "This content should also be served over HTTPS." : "This request has been blocked; the content must be served over HTTPS.");
|
| MessageLevel messageLevel = allowed ? WarningMessageLevel : ErrorMessageLevel;
|
| - frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, messageLevel, message));
|
| + frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, messageLevel, message, SourceLocation::capture(frame->document())));
|
| }
|
|
|
| // static
|
| @@ -395,7 +396,7 @@ void MixedContentChecker::logToConsoleAboutWebSocket(LocalFrame* frame, const KU
|
| mainResourceUrl.elidedString().utf8().data(), url.elidedString().utf8().data(),
|
| allowed ? "This endpoint should be available via WSS. Insecure access is deprecated." : "This request has been blocked; this endpoint must be available over WSS.");
|
| MessageLevel messageLevel = allowed ? WarningMessageLevel : ErrorMessageLevel;
|
| - frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, messageLevel, message));
|
| + frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, messageLevel, message, SourceLocation::capture(frame->document())));
|
| }
|
|
|
| // static
|
| @@ -457,7 +458,7 @@ bool MixedContentChecker::isMixedFormAction(LocalFrame* frame, const KURL& url,
|
| String message = String::format(
|
| "Mixed Content: The page at '%s' was loaded over a secure connection, but contains a form which targets an insecure endpoint '%s'. This endpoint should be made available over a secure connection.",
|
| mainResourceUrlForFrame(mixedFrame).elidedString().utf8().data(), url.elidedString().utf8().data());
|
| - frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, WarningMessageLevel, message));
|
| + frame->document()->addConsoleMessage(ConsoleMessage::create(SecurityMessageSource, WarningMessageLevel, message, SourceLocation::capture(frame->document())));
|
| }
|
|
|
| return true;
|
|
|