Commits


ngIRCd release 15~rc1


Updated NEWS and ChangeLog files


Make sure forwarded CONNECT commands are handled correctly


Generate WALLOPS message on operator-generated SQUIT


Enable SQUIT command for IRC Operators This patch enables IRC Operators to use the SQUIT command as specified in RFC 2812, section 3.1.8 "Squit". When forwarding SQUIT commands, the server connected to the target will drop the connection (not the target server itself!). Please note: - the configuration option "AllowRemoteOper" mus be enabled on the server disconnecting the target to allow forwarding of SQUIT commands. - if the remote server is configured to establish the connection, it will just do this; so the disconnect is not permanent in this case!


Xcode: added new op.{c|h} to project file


Use functions provided by op.c "module" Local functions Check_Oper() and No_Privileges() have been replaced by global functions in op.c "module": Op_Check() and Op_NoPrivileges().


New "module" op.c/op.h for IRC operator related functions The new "module" op.c is used to implement functions related to IRC Ops. At the moment, these two functions are available: - Op_Check() to check for a valid IRC Op, and - Op_NoPrivileges() to generate "permission denied" messages.


Allow forwarding of CONNECT commands. The syntax of the CONNECT command now is: - CONNECT <server-id> - CONNECT <server-id> <port> - CONNECT <server-id> <port> <target> - CONNECT <server-id> <port> <host> <my-pwd> <peer-pwd> - CONNECT <server-id> <port> <host> <my-pwd> <peer-pwd> <target> Note: the configuration option "AllowRemoteOper" mus be enabled on the target server to allow forwarding of CONNECT commands.


Check_Oper(): check origin of forwarded messages instead of server.


No_Privileges(): handle forwarded messages.


IRC_SendWallops(): support format string and variable parameter lists.


CONNECT, DISCONNECT: generate WALLOPS messages


New function IRC_SendWallops(). Implement new global function IRC_SendWallops() that can be called by other functions to generate WALLOPS messages to users with +w mode.


Code cleanup of IRC_DISCONNECT().


Code cleanup of IRC_SQUIT() in preparation to deal with bug #73.


New local functions Check_Oper() and No_Privileges().


Bad_OperPass(): code cleanup.


New configuration option "AllowRemoteOper" Added new configuration option "AllowRemoteOper" to control whether remote IRC operators are allowed to use administrative commands that affect this server or not This commit introduces the configuration variable, but actually no function is using it. That's up for the next patches to come ...


fix assertion failure in ng_ipaddr.c when building with debugging enabled, but without ipv6 support, ngircd dumped core when loading a config file that specified an ipv6 listen address. ngircd: ng_ipaddr.c:45: ng_ipaddr_init: Assertion `sizeof(*addr) >= res0->ai_addrlen' failed.


configtest: complain when ssl keys are not readable


Check for sockaddr_in.sin_len and initialize it Test for sockaddr_in.sin_len and initialize it to the correct value which some systems (notably Mac OS X) require. Note: this code path is only relevant when not using getaddrinfo().


Always use get{addr|name}info() when available Both getaddrinfo() and getnameinfo() are now used always when available, and not only when compiling ngIRCd with support for IPv6. This not only enables ngIRCd to handle multiple addresses per hostname when compiled without support for IPv6, but fixes binding ngIRCd to IP addresses on Mac OS X (and probably other BSD-based systems) as well: these systems require that sockaddr_in is zeroed out and sockaddr_in.sin_len is set to sizeof(sockaddr_in) like that: src/ipaddr/ng_ipaddr.c, line 54: assert(ip_str); + memset(addr, 0, sizeof *addr); + addr->sin4.sin_len = sizeof(addr->sin4); addr->sin4.sin_family = AF_INET; But this would break all the systems not using sockaddr_in.sin_len, for example Linux -- so we assume that all these systems provide getaddrinfo() and use that for now.


Xcode: add "debug" configuration to project


Fix cb_connserver() to handle aborted outgoing connections A configured server could have been removed while a connection apptempt is still in progress. So the cb_connserver() callback has to test if the server configuration record is still valid.