pull/83/head v0.7.2
loveshell 2016-01-10 22:45:34 +08:00
parent fa5bf74cbe
commit 3492d0601c
1 changed files with 1 additions and 4 deletions

View File

@ -15,10 +15,7 @@ attacklog = optionIsOn(attacklog)
CCDeny = optionIsOn(CCDeny)
Redirect=optionIsOn(Redirect)
function getClientIp()
IP = ngx.req.get_headers()["X-Real-IP"]
if IP == nil then
IP = ngx.var.remote_addr
end
IP = ngx.var.remote_addr
if IP == nil then
IP = "unknown"
end