diff options
| author | Bruno Cesar Ribas <brunoribas@gmail.com> | 2019-05-25 12:06:19 +0000 |
|---|---|---|
| committer | Bruno Cesar Ribas <brunoribas@gmail.com> | 2019-05-25 12:06:19 +0000 |
| commit | 6b2aa24a9d0b8fdead344f6bd8936e381400eab1 (patch) | |
| tree | e7864561ae40aff0df3c9bf0297a96affdb1c382 /src/flog.php | |
| parent | 897384ab2441da9c5d8c595cf65987fa6f027f0f (diff) | |
| parent | f74c0fdddbdb768a2ec50e9a9f165887cc6f51e1 (diff) | |
| download | boca-6b2aa24a9d0b8fdead344f6bd8936e381400eab1.tar.gz boca-6b2aa24a9d0b8fdead344f6bd8936e381400eab1.zip | |
Merge branch 'develc' into devel
Signed-off-by: Bruno Cesar Ribas <brunoribas@gmail.com>
Diffstat (limited to 'src/flog.php')
| -rw-r--r-- | src/flog.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/flog.php b/src/flog.php index 1e6e6cb..9ff6357 100644 --- a/src/flog.php +++ b/src/flog.php @@ -187,8 +187,14 @@ function DBLogInContest($name,$pass,$contest,$msg=true) { if($a["usertype"] == "team") @file_put_contents($dircode, $ccode); } - + $gip=getIP(); + if(!ValidCookie(true,$gip)) { + if($msg) MSGError("Invalid computer (4)."); + unset($_SESSION["usertable"]); + return false; + } + if ($a["userip"] != $gip && $a["userip"] != "" && $a["usertype"] != "score") { LOGLevel("User $name is using two different IPs: " . $a["userip"] . "(" . dateconv($a["userlastlogin"]) .") and " . $gip,1); |