summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorLukas Fleischer <lfleischer@archlinux.org>2017-01-25 08:37:48 +0100
committerLukas Fleischer <lfleischer@archlinux.org>2017-01-25 18:42:34 +0100
commit70db022aa8287c57a2ee03328ae893ba8b83b192 (patch)
tree9576426d39b9f6b2240cdf936b79bae29df1300b /web
parentf8916d7e9bda129a57143d769f7eb1f596614c80 (diff)
downloadaur-70db022aa8287c57a2ee03328ae893ba8b83b192.tar.gz
aur-70db022aa8287c57a2ee03328ae893ba8b83b192.tar.xz
Store banned IP addresses as plain text
Inspired by commit 32c8d0c (Store last login address as plain text, 2016-03-13). Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
Diffstat (limited to 'web')
-rw-r--r--web/lib/acctfuncs.inc.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/web/lib/acctfuncs.inc.php b/web/lib/acctfuncs.inc.php
index 08dbc671..b3cf6122 100644
--- a/web/lib/acctfuncs.inc.php
+++ b/web/lib/acctfuncs.inc.php
@@ -621,7 +621,7 @@ function try_login() {
function is_ipbanned() {
$dbh = DB::connect();
- $q = "SELECT * FROM Bans WHERE IPAddress = " . $dbh->quote(ip2long($_SERVER['REMOTE_ADDR']));
+ $q = "SELECT * FROM Bans WHERE IPAddress = " . $dbh->quote($_SERVER['REMOTE_ADDR']);
$result = $dbh->query($q);
return ($result->fetchColumn() ? true : false);