-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclickjacking test.html
More file actions
31 lines (27 loc) · 921 Bytes
/
clickjacking test.html
File metadata and controls
31 lines (27 loc) · 921 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<!DOCTYPE html>
<!-- written by Chris Holt -->
<html>
<title>Clickjacking / framing test</title>
<script type="text/javascript">
function frameIt() {
var url = document.getElementById("url").value;
var iframe = document.getElementById("iframe");
iframe.src = url;
}
document.addEventListener('DOMContentLoaded', function () {
document.getElementById('submit-test').addEventListener('click',
function() {
frameIt();
}
);
});
</script>
<body>
<h1>Test a page for clickjacking/framing vulnerability</h1>
<p>Enter the URL to frame:</p>
<input id="url" type="text" value="http://example.com" size="50"></input>
<button id="submit-test">Test it!</button>
<br />
<iframe src="about:blank" id="iframe" style="border:medium solid red" width="550" height="400"></iframe>
</body>
</html>