1
0
mirror of https://github.com/Yubico/yubikey-val.git synced 2025-01-20 01:52:15 +01:00

Log HTTPS status.

This commit is contained in:
Simon Josefsson 2010-08-22 14:38:26 +00:00
parent 369a6e0fbc
commit c9f58a83c7
2 changed files with 4 additions and 1 deletions

2
NEWS
View File

@ -3,6 +3,8 @@
* Timestamp request and response because syslog doesn't record year
nor sub-second resolution.
* Log whether HTTPS is used or not.
* Version 2.6 released 2010-08-02
* Don't use rowCount in ykval-revoke, there seems to be some problem

View File

@ -10,7 +10,8 @@ header("content-type: text/plain");
$myLog = new Log('ykval-verify');
$myLog->addField('ip', $_SERVER['REMOTE_ADDR']);
$myLog->log(LOG_INFO, "Request: " . $_SERVER['QUERY_STRING'] .
" (at " . date("c") . " " . microtime() . ")");
" (at " . date("c") . " " . microtime() . ") " .
($_SERVER["HTTPS"] == "on" ? "HTTPS" : "HTTP"));
/* Detect protocol version */
if (preg_match("/\/wsapi\/([0-9]+)\.([0-9]+)\//", $_SERVER['REQUEST_URI'], $out)) {