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

Unified Diff: chrome/test/data/android/keygen.html

Issue 1432573002: Adding <keygen> Content Setting (Android UI) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@keygen_ui
Patch Set: Improve comment. Created 5 years 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
« no previous file with comments | « chrome/browser/ui/android/website_settings_popup_android.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/android/keygen.html
diff --git a/chrome/test/data/android/keygen.html b/chrome/test/data/android/keygen.html
new file mode 100644
index 0000000000000000000000000000000000000000..e2c7d5daf3cccad1c0c5a38854cc68a39c5d3b09
--- /dev/null
+++ b/chrome/test/data/android/keygen.html
@@ -0,0 +1,32 @@
+<html>
+
+<head>
+<title>Test page for key generation</title>
+
+<script>
+var keygen = false;
+
+function runKeygen() {
+ if (window.location.search.indexOf('?') == -1) {
+ document.getElementById('test_form').submit();
+ } else {
+ // Verify that the form submission includes a generated key.
+ // We check for base64 'MIIC' to match the first 3 bytes: 0x30 0x82 0x02
Finnur 2015/12/11 21:06:12 nit: Generally, comments should end with some punc
+ keygen = (window.location.search.indexOf('?key=MIIC') == 0)
+ }
+}
+
+function didKeygen() {
+ return keygen;
+}
+</script>
+</head>
+
+<body onload="runKeygen()">
+This page tries to use a keygen element when it is loaded.
+<form id='test_form'>
+<keygen name='key'>
+</form>
+</body>
+
+</html>
« no previous file with comments | « chrome/browser/ui/android/website_settings_popup_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698