forked from External/ergo
parent
a742ef9639
commit
1a98a37a75
10 changed files with 271 additions and 105 deletions
|
|
@ -77,10 +77,11 @@ func (client *Client) ApplyProxiedIP(session *Session, proxiedIP net.IP, tls boo
|
|||
}
|
||||
proxiedIP = proxiedIP.To16()
|
||||
|
||||
isBanned, banMsg := client.server.checkBans(proxiedIP)
|
||||
isBanned, requireSASL, banMsg := client.server.checkBans(client.server.Config(), proxiedIP, true)
|
||||
if isBanned {
|
||||
return errBanned, banMsg
|
||||
}
|
||||
client.requireSASL = requireSASL
|
||||
// successfully added a limiter entry for the proxied IP;
|
||||
// remove the entry for the real IP if applicable (#197)
|
||||
client.server.connectionLimiter.RemoveClient(session.realIP)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue