pull/104/head
有安科技 2024-09-19 18:04:40 +08:00
parent 6156ded263
commit c2fea8d6c1
3 changed files with 4 additions and 4 deletions

View File

@ -10,6 +10,6 @@
if waf.scheme == "http" then if waf.scheme == "http" then
return waf.redirect("https://" .. waf.host) return waf.redirect("https://" .. waf.host .. waf.reqUri)
end end
return false return false

View File

@ -14,7 +14,7 @@ if waf.contains(waf.ip,":") then
end end
local country, province, city = waf.ip2loc(waf.ip) local country, province, city = waf.ip2loc(waf.ip)
if country and country ~= "中国" then if country ~= "中国" and country ~= "内网IP" then
return true, "限制非中国地区访问", true return true, "限制非中国地区访问", true
end end
return false return false

View File

@ -11,7 +11,7 @@
local ip = waf.ip local ip = waf.ip
if waf.contains(ip,"10.20.11.193") then if waf.startWith(ip,"10.20.11.") then
return waf.block(true) -- 重置TCP连接不记录日志 return waf.block(true) -- 重置TCP连接不记录日志
end end