Skip to content

Commit 4e561c9

Browse files
committed
[security-update] add click-jacking protection
1 parent ac3f045 commit 4e561c9

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

demo/doc-versioning/doc_versioning/gui/document.html

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,16 @@
2121

2222
<!-- differ
2323
-- --------------------------------------------------- -->
24-
24+
25+
<!-- clickjacking protection-->
26+
<style> html {display : none; } </style>
27+
<script>
28+
if ( self === top ) {
29+
document.documentElement.style.display = 'block';
30+
} else {
31+
top.location = self.location;
32+
}
33+
</script>
2534
</head>
2635
<body>
2736
<div style="text-align: center; margin-top: 50px; margin-left: 50px">

0 commit comments

Comments
 (0)