Commit Briefs
ngIRCd release 19~rc1 (tags/rel-19-rc1)
Fix forwarding of LIST commands
Bug reported by Cahata, thanks!
New_Connection(): don't set the client hostname twice
Setting the hostname twice doesn't do much harm a lot, but isn't elegant. And for IPv6 addresses, it isn't correct the first time (missing []) ...
io: remove outer do {} while loops for epoll/kqueue/devpoll backends
simplifies things a bit. io_dispatch() is called repeatedly from the main loop.
Enhance server command limits
This patch updates the limits for handling commands from a remote server: - "<user count> / 5 + <min>" using "<min>=10" during normal operation, - the above count multiplied with 5 while servers are syncing. The intention is to a) make the limit dependent of the number of users in the network (the more users, the more commands required to sync) and b) to significantly rise this limit while servers are joining the network to make the login and synchronization faster.
Send a PING at the end of the server sync to detect it
At the end of sending all "state" to the remote server, a PING command is sent to request a PONG reply. Until then, no "regual" PING was sent, so Conn_LastPing(<connection>) is null and now becomes non-null in the PONG command handler. So the servers are still synchronizing when Conn_LastPing(<connection>) is 0, which could easily be tested.
RPL_ISUPPORT_MSG(005): add "EXCEPTS=e INVEX=I"
Thanks to Cahata for the idea!
Fix "MAXLIST=beI:50": the limit is the sum of all lists
"Modes which are specified in the same pair share the same maximum size", so "beI:50" means a total of 50 entries, regardless of the list. See <http://www.irc.org/tech_docs/draft-brocklesby-irc-isupport-03.txt>, thanks to Cahata for reporting this!
New RPL_WHOISHOST_MSG(378): show hostname and IP address
The numeric RPL_WHOISHOST_MSG(378) returns the DNS hostname (if available) and the IP address of a client in the WHOIS reply. Only the user itself and local IRC operators get this numeric.
Check G/K-Lines before the client has been registered, too
This allows to use "*!<user>@<host>" or "*!*@<host>" masks to reject clients even before receiving PASS, NICK and USER commands and before forking authentication child processes which reduces resource usage.
Streamline handling of connection rejects (bad password, G/K-line)
- Use Client_Reject(), get rid of Reject_Client(). - Refactor Class_IsMember() to Class_GetMemberReason(), - New function Class_HandleServerBans().
