mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-22 20:09:41 +01:00
Merge pull request #740 from slingamn/proxy_dline
don't check the real IP for bans on proxy-before-TLS
This commit is contained in:
commit
68968d6868
@ -222,7 +222,10 @@ func (server *Server) RunClient(conn clientConn, proxyLine string) {
|
|||||||
isBanned, banMsg = server.checkTorLimits()
|
isBanned, banMsg = server.checkTorLimits()
|
||||||
} else {
|
} else {
|
||||||
realIP = utils.AddrToIP(conn.Conn.RemoteAddr())
|
realIP = utils.AddrToIP(conn.Conn.RemoteAddr())
|
||||||
isBanned, banMsg = server.checkBans(realIP)
|
// skip the ban check for k8s-style proxy-before-TLS
|
||||||
|
if proxyLine == "" {
|
||||||
|
isBanned, banMsg = server.checkBans(realIP)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if isBanned {
|
if isBanned {
|
||||||
|
Loading…
Reference in New Issue
Block a user