Skip to content

Commit

Permalink
mixed-script.badssl.com tweaks.
Browse files Browse the repository at this point in the history
  • Loading branch information
lgarron committed Aug 18, 2015
1 parent e13c530 commit a5da5f2
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 24 deletions.
2 changes: 1 addition & 1 deletion domains/misc/badssl.com/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -158,14 +158,14 @@
<a href="https://sha1-2017.badssl.com/" class="bad no-interstitial">sha1-2017</a>
<a href="https://sha1-2016.badssl.com/" class="dubious">sha1-2016</a>
<a href="https://mixed.badssl.com/" class="dubious">mixed</a>
<a href="https://mixed-active.badssl.com/" class="dubious">mixed-active</a>
<a href="https://rc4.badssl.com/" class="neutral">rc4</a>
<a href="https://cbc.badssl.com/" class="neutral">cbc</a>
<a href="" id="reveal-more">More...</a>
<a href="https://sha256.badssl.com/" class="more good">sha256</a>
<a href="https://hsts.badssl.com/" class="more goodish">hsts</a>
<a href="https://preloaded-hsts.badssl.com/" class="more goodish">preloaded-hsts</a>
<a href="https://subdomain.preloaded-hsts.badssl.com/" class="more bad">subdomain.<br>preloaded-hsts</a>
<a href="https://mixed-script.badssl.com/" class="more bad no-interstitial">mixed-script</a>
<a href="https://dh480.badssl.com/" class="more bad">dh480</a>
<a href="https://dh512.badssl.com/" class="more bad">dh512</a>
<a href="https://dh1024.badssl.com/" class="more dubious">dh1024</a>
Expand Down
6 changes: 3 additions & 3 deletions domains/misc/mixed-script.badssl.com.conf
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
server {
listen 80;
server_name mixed-active.badssl.com;
server_name mixed-script.badssl.com;

return 301 https://$server_name$request_uri;
}

server {
listen 443;
server_name mixed-active.badssl.com;
server_name mixed-script.badssl.com;

include /var/www/badssl/nginx-includes/wildcard.normal.conf;
include /var/www/badssl/nginx-includes/tls-defaults.conf;
include /var/www/badssl/common/common.conf;

root /var/www/badssl/domains/misc/mixed-active.badssl.com;
root /var/www/badssl/domains/misc/mixed-script.badssl.com;
}
38 changes: 21 additions & 17 deletions domains/misc/mixed-script.badssl.com/index.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<!doctype html>
<html>
<head>
<title>mixed.badssl.com</title>
<link rel="shortcut icon" href="/icons/favicon-yellow.ico"/>
<link rel="apple-touch-icon" href="/icons/icon-yellow.png"/>
<title>mixed-script.badssl.com</title>
<link rel="shortcut icon" href="/icons/favicon-red.ico"/>
<link rel="apple-touch-icon" href="/icons/icon-red.png"/>
<style>
html, body {
background: rgb(246, 207, 47);
background: gray;

margin: 0;
padding: 0;
Expand All @@ -26,27 +26,31 @@
text-align: center;
font-family: "Source Code Pro", Monaco, Consolas, "Courier New", monospace, Impact;
font-size: 5em;
font-size: 7vw;
font-size: 9vw;
text-shadow:
0 0 20px rgba(255, 255, 255, 0.5),
0 0 40px rgba(255, 255, 255, 0.5),
0 0 60px rgba(255, 255, 255, 0.5);
}
img {
width: 20vh;
max-width: 256;
margin-top: 5vh;
}
span {
font-size: 50%;
.footer {
background: rgba(0, 0, 0, 0.25);

position: fixed;
width: 80vw;
bottom: 0;
left: 0;
padding: 2vh 10vw;

font-family: Helvetica, Tahoma, sans-serif;
text-align: center;
color: white;
font-size: 3vw;
}
</style>
</head>
<body>
<h1>
mixed-active.badssl.com<br>
<span id="mixed"></span>
</body>
<script src="http://mixed-active.badssl.com/nonsecure.js"></script>
<h1>mixed-script.<br>badssl.com</h1>
<div class="footer" id="footer">This page triggers active mixed content<br>(a script from an insecure URL).</div>
<script src="http://mixed-script.badssl.com/nonsecure.js"></script>
</body>
</html>
6 changes: 3 additions & 3 deletions domains/misc/mixed-script.badssl.com/nonsecure.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
(function() {
// Change the background to red
document.querySelector("html").style.backgroundColor = "#f00";
document.querySelector("body").style.backgroundColor = "#f00";
document.querySelector("html").style.backgroundColor = "red";
document.querySelector("body").style.backgroundColor = "red";

// Write text to the page
document.getElementById("mixed").innerHTML = "[Active mixed content loaded]";
document.getElementById("footer").innerHTML = "This page has run active mixed content<br>(a script from an insecure URL).";
})();

0 comments on commit a5da5f2

Please sign in to comment.