Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(547)

Unified Diff: Source/platform/weborigin/SecurityOrigin.h

Issue 417153004: Treat reserved IP addresses as mixed content. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/platform/weborigin/SecurityOrigin.h
diff --git a/Source/platform/weborigin/SecurityOrigin.h b/Source/platform/weborigin/SecurityOrigin.h
index 7112208474fcb51d3926ef00043a085e1fae7de8..a2f595a613b7e1ccb516d3f8bbfb28b42f14eafc 100644
--- a/Source/platform/weborigin/SecurityOrigin.h
+++ b/Source/platform/weborigin/SecurityOrigin.h
@@ -164,6 +164,11 @@ public:
// Returns true if the host is one of 127.0.0.1/8, ::1/128, or "localhost".
bool isLocalhost() const;
+ // Returns true if the host is reserved, as per IANA's IPv4 and IPv6 registries:
+ // http://www.iana.org/assignments/ipv4-address-space/ipv4-address-space.xhtml and
+ // http://www.iana.org/assignments/ipv6-address-space/ipv6-address-space.xhtml
+ bool isReservedIPAddress() const;
+
// The origin is a globally unique identifier assigned when the Document is
// created. http://www.whatwg.org/specs/web-apps/current-work/#sandboxOrigin
//

Powered by Google App Engine
This is Rietveld 408576698