[Pkg-mozext-commits] [requestpolicy] 34/100: use www.otherdomain.test instead of 127.0.0.1 and localhost

David Prévot taffit at moszumanska.debian.org
Fri Dec 12 22:56:53 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository requestpolicy.

commit f6f6e6bf01db5c676f449895a5d5f77ed7d5d6b0
Author: myrdd <myrdd at users.noreply.github.com>
Date:   Fri Sep 26 17:56:31 2014 +0200

    use www.otherdomain.test instead of 127.0.0.1 and localhost
    
    www.otherdomain.test must be an alias for 127.0.0.1 (e.g. in /etc/hosts)
---
 tests/css_and_js.html                | 14 +++++++-------
 tests/form_1.html                    |  2 +-
 tests/form_2.html                    | 31 ++++++++++++++++---------------
 tests/form_3.html                    |  5 ++---
 tests/iframe_1.html                  |  2 +-
 tests/iframe_2.html                  | 18 +++++++++---------
 tests/img_1.html                     |  4 ++--
 tests/js_1.html                      |  4 ++--
 tests/js_document_location_auto.html |  2 +-
 tests/js_document_location_link.html |  2 +-
 tests/js_link_1.html                 |  6 +++---
 tests/link_1.html                    |  8 ++++----
 tests/metarefresh_1.html             |  2 +-
 tests/metarefresh_11.html            |  2 +-
 tests/metarefresh_2.html             |  2 +-
 tests/metarefresh_4.html             |  2 +-
 tests/metarefresh_5.html             |  6 +++---
 tests/other_origins_1.html           |  2 +-
 tests/popup_1.html                   |  4 ++--
 tests/popup_2.html                   | 13 +++----------
 tests/prefetch_1.html                |  2 +-
 21 files changed, 63 insertions(+), 70 deletions(-)

diff --git a/tests/css_and_js.html b/tests/css_and_js.html
index 7dc504c..6af0b77 100644
--- a/tests/css_and_js.html
+++ b/tests/css_and_js.html
@@ -5,19 +5,19 @@
 
 <p>On this page there are:</p>
 <ul>
-	<li>CSS-initiated @import requests</li>
-	<li>JavaScript-initiated non-XHR requests</li>
+  <li>CSS-initiated @import requests</li>
+  <li>JavaScript-initiated non-XHR requests</li>
 </ul>
 
 <style>
-	@import "local-css-imported-file.css";
-	@import "http://127.0.0.1/remote-css-imported-file.css";
+  @import "local-css-imported-file.css";
+  @import "http://www.otherdomain.test/remote-css-imported-file.css";
 </style>
 
 <script>
-	img = new Image();
-	img.src = "local-javascript-loaded-image.jpg";
-	img.src = "http://127.0.0.1/remote-javascript-loaded-image.jpg";
+  img = new Image();
+  img.src = "local-javascript-loaded-image.jpg";
+  img.src = "http://www.otherdomain.test/remote-javascript-loaded-image.jpg";
 </script>
 
 </body>
diff --git a/tests/form_1.html b/tests/form_1.html
index 1fd7ed1..bca84bc 100644
--- a/tests/form_1.html
+++ b/tests/form_1.html
@@ -3,7 +3,7 @@
 </head>
 <body onload="document.getElementById('fm').submit()">
 
-<form action="http://127.0.0.1/cross-site-form-submission" method="get" id="fm">
+<form action="http://www.otherdomain.test/cross-site-form-submission" method="get" id="fm">
 <input type="hidden" name="a" value="1" />
 <input type="submit" value="submit" />
 </form>
diff --git a/tests/form_2.html b/tests/form_2.html
index e242edf..448d4c2 100644
--- a/tests/form_2.html
+++ b/tests/form_2.html
@@ -9,42 +9,43 @@
 for manual submission.</p>
 
 <form action="automatically-submitted-form.html" method="get"
-	target="loadingframe_same" id="autoform_same"><input
-	type="submit" value="Don't click me. I'm the auto-submit form." /></form>
+      target="loadingframe_same" id="autoform_same"><input
+      type="submit" value="Don't click me. I'm the auto-submit form." /></form>
 
 <br />
 
 <form action="manually-submitted-form.html" method="get"
-	target="loadingframe_same"><input type="submit"
-	value="Click me for manual form submission." /></form>
+      target="loadingframe_same"><input type="submit"
+      value="Click me for manual form submission." /></form>
 
 <iframe id="loadingframe_same" name="loadingframe_same"></iframe>
 
 <script>
-	document.getElementById("autoform_same").submit();
+  document.getElementById("autoform_same").submit();
 </script>
 
 <h2>Different hosts</h2>
 
-<form action="http://127.0.0.1/automatically-submitted-form.html"
-	method="get" target="loadingframe_different" id="autoform_different">
+<form action="http://www.otherdomain.test/automatically-submitted-form.html"
+      method="get" target="loadingframe_different" id="autoform_different">
 <input type="submit" value="Don't click me. I'm the auto-submit form." />
 </form>
 
 <br />
 
-<form action="http://127.0.0.1/manually-submitted-form.html"
-	method="get" target="loadingframe_different"><input
-	type="submit" value="Click me for manual form submission." /></form>
+<form action="http://www.otherdomain.test/manually-submitted-form.html"
+      method="get" target="loadingframe_different">
+<input type="submit" value="Click me for manual form submission." />
+</form>
 
 <iframe id="loadingframe_different" name="loadingframe_different"></iframe>
 
 <script>
-	// This may cause the following error to show in the error console when the request gets blocked.
-	// Error: Component returned failure code: 0x805e000a [nsIDOMHTMLFormElement.submit] = <unknown>
-	// Source file: http://localhost/csrpolicy/tests/test6.html
-	// Line: 47
-	document.getElementById("autoform_different").submit();
+  // This may cause the following error to show in the error console when the request gets blocked.
+  // Error: Component returned failure code: 0x805e000a [nsIDOMHTMLFormElement.submit] = <unknown>
+  // Source file: http://localhost/csrpolicy/tests/test6.html
+  // Line: 47
+  document.getElementById("autoform_different").submit();
 </script>
 
 </body>
diff --git a/tests/form_3.html b/tests/form_3.html
index 11ab917..3ce3c0b 100644
--- a/tests/form_3.html
+++ b/tests/form_3.html
@@ -1,9 +1,8 @@
-<html>
-<head>
+<html> <head>
 </head>
 <body>
 
-<form action="http://127.0.0.1/cross-site-form-submission" method="get">
+<form action="http://www.otherdomain.test/cross-site-form-submission" method="get">
 <input type="hidden" name="a" value="1" />
 <input type="submit" value="submit" />
 </form>
diff --git a/tests/iframe_1.html b/tests/iframe_1.html
index 48897ef..4b8624e 100644
--- a/tests/iframe_1.html
+++ b/tests/iframe_1.html
@@ -3,7 +3,7 @@
 </head>
 <body>
 
-<iframe src="http://127.0.0.1/cross-domain-iframe-src"></iframe>
+<iframe src="http://www.otherdomain.test/cross-domain-iframe-src"></iframe>
 
 </body>
 </html>
\ No newline at end of file
diff --git a/tests/iframe_2.html b/tests/iframe_2.html
index f8a1e3b..80333e7 100644
--- a/tests/iframe_2.html
+++ b/tests/iframe_2.html
@@ -2,13 +2,13 @@
 <head>
 
 <script language="JavaScript" type="text/javascript">
-	function makeFrame(url) {
-		ifrm = document.createElement("iframe");
-		ifrm.setAttribute("src", url);
-		ifrm.style.width = 300 + "px";
-		ifrm.style.height = 200 + "px";
-		document.body.appendChild(ifrm);
-	}
+  function makeFrame(url) {
+    ifrm = document.createElement("iframe");
+    ifrm.setAttribute("src", url);
+    ifrm.style.width = 300 + "px";
+    ifrm.style.height = 200 + "px";
+    document.body.appendChild(ifrm);
+  }
 </script>
 </head>
 <body>
@@ -17,14 +17,14 @@
 with a cross-site url.</p>
 
 <script>
-	makeFrame("same-site-request-from-javascript-generated-iframe.html");
+  makeFrame("same-site-request-from-javascript-generated-iframe.html");
 </script>
 
 <br />
 <br />
 
 <script>
-	makeFrame("http://127.0.0.1/cross-site-request-from-javascript-generated-iframe.html");
+  makeFrame("http://www.otherdomain.test/cross-site-request-from-javascript-generated-iframe.html");
 </script>
 
 </body>
diff --git a/tests/img_1.html b/tests/img_1.html
index 430357a..cce0bba 100644
--- a/tests/img_1.html
+++ b/tests/img_1.html
@@ -3,11 +3,11 @@
 </head>
 <body>
 
-<p><img src="http://127.0.0.1/cross-site-image.png"/>
+<p><img src="http://www.otherdomain.test/cross-site-image.png"/>
 
 <p><img src="same-site-image.png"/>
 
-<p><a href="http://127.0.0.1/cross-site-link">cross-site link</a>
+<p><a href="http://www.otherdomain.test/cross-site-link">cross-site link</a>
 
 <p><a href="same-site-link">same-site link</a>
 
diff --git a/tests/js_1.html b/tests/js_1.html
index 94bfe76..03e0837 100644
--- a/tests/js_1.html
+++ b/tests/js_1.html
@@ -1,8 +1,8 @@
 <script>
 location = "javascript:' \
 <html><body onload=\"document.forms[0].submit()\"> \
-<form id=f action=http://127.0.0.1/javascript-created-and-submitted-form method=POST> \
+<form id=f action=http://www.otherdomain.test/javascript-created-and-submitted-form method=POST> \
 <input name=whatever value=whatever> \
 </form> \
 </body></html>'";
-</script> 
\ No newline at end of file
+</script>
\ No newline at end of file
diff --git a/tests/js_document_location_auto.html b/tests/js_document_location_auto.html
index 7450536..3d3fb5c 100644
--- a/tests/js_document_location_auto.html
+++ b/tests/js_document_location_auto.html
@@ -1,5 +1,5 @@
 <html>
-<body onload="document.location = 'http://127.0.0.1/'">
+<body onload="document.location = 'http://www.otherdomain.test/'">
 
 <p>This only works when not loaded from a local file. That is, this
    page must be requested through a webserver. If used through a file://
diff --git a/tests/js_document_location_link.html b/tests/js_document_location_link.html
index af49447..1e252a2 100644
--- a/tests/js_document_location_link.html
+++ b/tests/js_document_location_link.html
@@ -8,7 +8,7 @@
    won't match any url in open tabs and the redirect notification won't
    be shown.</p>
 
-<a href="javascript:document.location = 'http://127.0.0.1/'">click me</a>
+<a href="javascript:document.location = 'http://www.otherdomain.test/'">click me</a>
 
 </body>
 </html>
\ No newline at end of file
diff --git a/tests/js_link_1.html b/tests/js_link_1.html
index 745e0a3..a56b038 100644
--- a/tests/js_link_1.html
+++ b/tests/js_link_1.html
@@ -1,9 +1,9 @@
 <html>
 <head>
 <script>
-	function addLink() {
-		document.getElementById("target").innerHTML = "<a href='http://127.0.0.1/?test'>Link to http://127.0.0.1/</a>";
-	}
+  function addLink() {
+    document.getElementById("target").innerHTML = "<a href='http://www.otherdomain.test/?test'>Link to http://www.otherdomain.test/</a>";
+  }
 </script>
 </head>
 <body onload="setTimeout('addLink()', 500);">
diff --git a/tests/link_1.html b/tests/link_1.html
index 4e837ca..458d2e4 100644
--- a/tests/link_1.html
+++ b/tests/link_1.html
@@ -4,23 +4,23 @@
 <body>
 
 <div style="margin : 100px 0 0 100px">
-<a href="http://127.0.0.1/cross-site-link">Cross-site link</a>
+<a href="http://www.otherdomain.test/cross-site-link">Cross-site link</a>
 </div>
 
 <br /><br />
 
 <div style="margin : 100px 0 0 100px">
-<a href="http://127.0.0.1">Cross-site link with no path and no slash on the end</a>
+<a href="http://www.otherdomain.test">Cross-site link with no path and no slash on the end</a>
 </div>
 
 <br /><br />
 
 <div style="margin : 100px 0 0 100px">
-http://127.0.0.1
+http://www.otherdomain.test
 </div>
 
 <div style="margin : 100px 0 0 100px">
-http://127.0.0.1/
+http://www.otherdomain.test/
 </div>
 
 </body>
diff --git a/tests/metarefresh_1.html b/tests/metarefresh_1.html
index 687cc70..928ff0a 100644
--- a/tests/metarefresh_1.html
+++ b/tests/metarefresh_1.html
@@ -1,6 +1,6 @@
 <html>
 <head>
-<meta http-equiv="refresh" content="0;url=http://localhost/meta_refresh"/>
+<meta http-equiv="refresh" content="0;url=http://www.otherdomain.test/meta_refresh"/>
 </head>
 <body>
 
diff --git a/tests/metarefresh_11.html b/tests/metarefresh_11.html
index 139dc1c..90c1f17 100644
--- a/tests/metarefresh_11.html
+++ b/tests/metarefresh_11.html
@@ -1,6 +1,6 @@
 <html>
 <head>
-<meta http-equiv="refresh" content="0; url=../">
+<meta http-equiv="refresh" content="0; url=subdirectory/">
 </head>
 <body>
 
diff --git a/tests/metarefresh_2.html b/tests/metarefresh_2.html
index ffe0aaa..1712ba0 100644
--- a/tests/metarefresh_2.html
+++ b/tests/metarefresh_2.html
@@ -1,6 +1,6 @@
 <html>
 <head>
-<meta http-equiv="refresh" content="0;url=http://localhost/meta_refresh"/>
+<meta http-equiv="refresh" content="0;url=http://www.otherdomain.test/meta_refresh"/>
 </head>
 <body>
 
diff --git a/tests/metarefresh_4.html b/tests/metarefresh_4.html
index 8b89b4d..57d2a89 100644
--- a/tests/metarefresh_4.html
+++ b/tests/metarefresh_4.html
@@ -1,6 +1,6 @@
 <html>
 <head>
-<meta http-equiv="refresh" content="100;url=http://localhost/meta_refresh"/>
+<meta http-equiv="refresh" content="100;url=http://www.otherdomain.test/meta_refresh"/>
 <meta name="robots" content="index,follow" />
 <meta name="generator" content="blah" />
 </head>
diff --git a/tests/metarefresh_5.html b/tests/metarefresh_5.html
index 1e3172b..05392ac 100644
--- a/tests/metarefresh_5.html
+++ b/tests/metarefresh_5.html
@@ -1,8 +1,8 @@
 <html>
 <head>
-<meta http-equiv="refresh" content="0;url=http://localhost/meta_refresh/1"/>
-<meta http-equiv="refresh" content="1;url=http://localhost/meta_refresh/2"/>
-<meta http-equiv="refresh" content="100;url=http://localhost/meta_refresh/3"/>
+<meta http-equiv="refresh" content="0;url=http://www.otherdomain.test/meta_refresh/1"/>
+<meta http-equiv="refresh" content="1;url=http://www.otherdomain.test/meta_refresh/2"/>
+<meta http-equiv="refresh" content="100;url=http://www.otherdomain.test/meta_refresh/3"/>
 <meta name="robots" content="index,follow" />
 <meta name="generator" content="MindTouch Deki 8.08" />
 </head>
diff --git a/tests/other_origins_1.html b/tests/other_origins_1.html
index de9f58b..e6e2550 100644
--- a/tests/other_origins_1.html
+++ b/tests/other_origins_1.html
@@ -3,7 +3,7 @@
 </head>
 <body>
 
-<iframe src="http://requestpolicy.com/tests/iframe-to-other-site.html"></iframe>
+<iframe src="http://www.otherdomain.test/iframe-to-other-site.html"></iframe>
 
 </body>
 </html>
\ No newline at end of file
diff --git a/tests/popup_1.html b/tests/popup_1.html
index 99d85fb..6b7204a 100644
--- a/tests/popup_1.html
+++ b/tests/popup_1.html
@@ -7,8 +7,8 @@ This page has javascript which attempts to open a popup to a different
 site.
 
 <script>
-	window.open("http://127.0.0.1/javascript-popup-in-new-window", "Window1",
-			"menubar=no,width=430,height=360,toolbar=no");
+  window.open("http://www.otherdomain.test/javascript-popup-in-new-window",
+              "Window1", "menubar=no,width=430,height=360,toolbar=no");
 </script>
 
 </body>
diff --git a/tests/popup_2.html b/tests/popup_2.html
index fa4b466..2fb4fe4 100644
--- a/tests/popup_2.html
+++ b/tests/popup_2.html
@@ -3,17 +3,10 @@
 </head>
 <body>
 
-<div onmouseover='window.open("http://127.0.0.1/javascript-popup-in-new-window", "Window1",
+<div onmouseover='window.open("http://www.otherdomain.test/javascript-popup-in-new-window", "Window1",
 "menubar=no,width=430,height=360,toolbar=no");'>
-	This page has javascript which attempts to open a popup to a different
-	site when you mouseover this text.
-</div>
-
-<br /><br />
-
-<div onmouseover='window.open("http://requestpolicy.com/tests/javascript-popup-in-new-window", "Window1",
-"menubar=no,width=430,height=360,toolbar=no");'>
-    This text initiates a popup to a different domain.
+  This page has javascript which attempts to open a popup to a different
+  site when you mouseover this text.
 </div>
 
 </body>
diff --git a/tests/prefetch_1.html b/tests/prefetch_1.html
index 79e7904..4607e29 100644
--- a/tests/prefetch_1.html
+++ b/tests/prefetch_1.html
@@ -1,6 +1,6 @@
 <html>
 <head>
-<link rel="prefetch" href="http://127.0.0.1/prefetched-document.html" />
+<link rel="prefetch" href="http://www.otherdomain.test/prefetched-document.html" />
 </head>
 <body>
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/requestpolicy.git



More information about the Pkg-mozext-commits mailing list