summaryrefslogtreecommitdiffstats
path: root/dom/u2f/tests/test_override_request.html
diff options
context:
space:
mode:
Diffstat (limited to 'dom/u2f/tests/test_override_request.html')
-rw-r--r--dom/u2f/tests/test_override_request.html35
1 files changed, 35 insertions, 0 deletions
diff --git a/dom/u2f/tests/test_override_request.html b/dom/u2f/tests/test_override_request.html
new file mode 100644
index 0000000000..76ee3b0e43
--- /dev/null
+++ b/dom/u2f/tests/test_override_request.html
@@ -0,0 +1,35 @@
+<!DOCTYPE html>
+<meta charset=utf-8>
+<head>
+ <title>Test for overriding U2F requests</title>
+ <script src="/tests/SimpleTest/SimpleTest.js"></script>
+ <script type="text/javascript" src="frame_utils.js"></script>
+ <script type="text/javascript" src="u2futil.js"></script>
+ <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
+</head>
+<body>
+
+ <h1>Test for overriding U2F requests</h1>
+ <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1420906">Mozilla Bug 1420906</a>
+
+ <iframe id="testing_frame"></iframe>
+
+ <script class="testbody" type="text/javascript">
+ "use strict";
+
+ SimpleTest.waitForExplicitFinish();
+
+ // Enable USB tokens.
+ SpecialPowers.pushPrefEnv({"set": [
+ ["security.webauth.u2f", true],
+ ["security.webauth.webauthn_enable_softtoken", false],
+ ["security.webauth.webauthn_enable_android_fido2", false],
+ ["security.webauth.webauthn_enable_usbtoken", true],
+ ]}, () => {
+ addEventListener("message", handleEventMessage);
+ document.getElementById("testing_frame").src = "https://example.com/tests/dom/u2f/tests/frame_override_request.html";
+ });
+ </script>
+
+</body>
+</html>