Commit 5907aba9 authored by William Paul Liggett's avatar William Paul Liggett

Security: Force the browser to connect via HTTPS.

parent ba4e378d
<?php
// Enables user sessions.
session_start();
// Force the user to connect via "https://".
if($_SERVER["HTTPS"] != "on") {
header("Location: https://" . $_SERVER["HTTP_HOST"] . htmlspecialchars($_SERVER["REQUEST_URI"], ENT_QUOTES, "UTF-8"));
exit();
}
?>
<!DOCTYPE html>
<html>
......
<?php
// Enables user sessions.
session_start();
// Force the user to connect via "https://".
if($_SERVER["HTTPS"] != "on") {
header("Location: https://" . $_SERVER["HTTP_HOST"] . htmlspecialchars($_SERVER["REQUEST_URI"], ENT_QUOTES, "UTF-8"));
exit();
}
?>
<!DOCTYPE html>
<html>
......@@ -197,7 +203,8 @@
echo "$tab$tab<div id=\"user_sign_out\" class=\"hidden\">" . PHP_EOL .
"$tab$tab$tab<form action=\".\" name=\"UserSignOut\" id=\"UserSignOut\" method=\"GET\">" . PHP_EOL .
"$tab$tab$tab$tab<input id=\"user_sign_out_button\" type=\"submit\" value=\"Sign Out\" />" . PHP_EOL .
"$tab$tab$tab</form>" . PHP_EOL;
"$tab$tab$tab</form>" . PHP_EOL .
"$tab$tab</div>" . PHP_EOL;
}
}
?>
......
......@@ -492,11 +492,11 @@ var ov_participant_response_time = -1;
var thirty_seconds_in_ms = parseFloat(30000); // 30 seconds = 30,000 ms [Used between the practice and the real test.]
var practice_time_in_ms = thirty_seconds_in_ms; // Practice Test is only 30 seconds for now.
//var twelve_minutes_in_ms = parseFloat(720000); // 12 minutes = 720,000 ms
var twelve_minutes_in_ms = parseFloat(720000); // 12 minutes = 720,000 ms
var four_minutes_in_ms = parseFloat(240000); // 4 minutes = 240,000 ms
// Inaccurate... TESTING VALUES.
var twelve_minutes_in_ms = parseFloat(15000); // 15 seconds = 15,000 ms
//var twelve_minutes_in_ms = parseFloat(15000); // 15 seconds = 15,000 ms
//var twelve_minutes_in_ms = parseFloat(120000); // 2 minutes = 120,000 ms
//var four_minutes_in_ms = thirty_seconds_in_ms;
//var twelve_minutes_in_ms = parseFloat(360000); // 6 minutes = 360,000 ms
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment