Subversion Repositories ALCASAR

Rev

Rev 2267 | Rev 2818 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 2267 Rev 2488
Line 1... Line 1...
1
<?php
1
<?php
2
# $Id: haut.php 2267 2017-06-04 09:28:36Z richard $
2
# $Id: haut.php 2488 2018-02-25 14:53:54Z lucas.echard $
3
 
3
 
4
// Inform admin log about his last connection
4
// Inform admin log about his last connection
5
$admin_log = '/var/Save/security/acc_access.log';
5
$admin_log = '/var/Save/security/acc_access.log';
6
$user_htdigest = $_SERVER['PHP_AUTH_USER'];
6
$user_htdigest = $_SERVER['REMOTE_USER'];
7
$date_system = date('d/m/Y H:i:s');
7
$date_system = date('d/m/Y H:i:s');
8
$user_ip = $_SERVER['REMOTE_ADDR'];
8
$user_ip = $_SERVER['REMOTE_ADDR'];
9
$user_agent = $_SERVER['HTTP_USER_AGENT'];
9
$user_agent = $_SERVER['HTTP_USER_AGENT'];
10
$text = $date_system . '|' . $user_htdigest . '|' . $user_ip . '|' . $user_agent;
10
$text = $date_system . '|' . $user_htdigest . '|' . $user_ip . '|' . $user_agent;
11
file_put_contents($admin_log, $text.PHP_EOL, FILE_APPEND);
11
file_put_contents($admin_log, $text.PHP_EOL, FILE_APPEND);