Commit Briefs

e17d4bdec7 Alexander Barton

ngIRCd Release 24 (tags/rel-24)


b2ba3e745a Alexander Barton

Platforms.txt: Add and update systems

- Update i386/unknown/freebsd7.3 (gcc 4.2.1) - Update i386/unknown/netbsdelf4.0 (gcc 4.1.2) - Update x86_64/apple/darwin16.3.0 (Apple clang 8.0) - Update x86_64/unknown/freebsd8.4 (gcc 4.2.1) - Update x86_64/pc/linux-gnu (gcc 4.4.5) - Update x86_64/pc/linux-gnu (gcc 4.8.4) - Update x86_64/pc/linux-gnu (gcc 4.9.2) - Update x86_64/pc/linux-gnu (gcc 6.2.1) - Add x86_64/pc/linux-gnu (gcc 6.3.1)


3890304b54 Alexander Barton

Make sure that platformtest.sh aborts when autogen.sh fails


a69866f3f9 Alexander Barton

Specify Debian "source format"


7071476d2a Alexander Barton

Update config.guess and config.sub to recent versions

- config.guess: 2016-10-02 - config.sub: 2016-11-04


3c627dd70d Alexander Barton

Build Debian packages with OpenSSL instead of GnuTLS

OpenSSL allows to reload used certificates on runtime for example (which is very useful when using Let's Encrypt), and therefore is preferred ...


879d550408 Alexander Barton

Fix handling of connection pool allocation and enlargement

The daemon only enlarged its connection pool when accepting new client connections, not when establishing new outgoing server links. Thanks to Lukas Braun (k00mi) for reporting this! In addition this patch streamlines the connection pool allocation, so that there is only one place in the code allocating the pool: the now updated Socket2Index() function. The name doesn't quite fit, but this existing and today quite useless function (because the mapping from socket number to connection index is 1:1 today) already became called in almost all relevant code paths, so I decided to reuse it to keep the patch small ...probably we want to fix the naming in a second patch? Closes #231.


2bb917f05a Alexander Barton

2017!


72acf53d69 Alexander Barton

Update doc/RFC.txt, add RFC 7194


479d7d99c1 Alexander Barton

ngIRCd Release 24~rc1 (tags/rel-24-rc1)


181da30997 Alexander Barton

Debian: Use "dh_prep" instead deprecated "dh_clean -k"


bfebdaece8 Alexander Barton

ngircd.conf.5.tmpl: Fix spelling

Thanks to Christoph Biedl.


d2a134b79c Alexander Barton

Platforms.txt: Add and update systems

- Add x86_64/apple/darwin16.3.0 (Apple clang 8.0) - Update x86_64/pc/linux-gnu (gcc 4.9.2) - Add x86_64/pc/linux-gnu (gcc 6.2.1.)


74f021fb44 Alexander Barton

Further enhance systemd unit file

- Add more comments/documentation. - Add dependencies for services and proxy scanners. - Add more limit configurations. - Allow AF_UNIX address family, required for syslog!


8e09180295 Alexander Barton

Install systemd service file in Debian package


f0532c98cd Alexander Barton

Enhance systemd service file

- Add homepage :-) - Remote CAP_SETUID and CAP_SETGID from CapabilityBoundingSet: This is nor needed, because the unit already sets User=irc and Group=irc. - Add RestrictAddressFamilies, and restrict it to AF_INET and AF_INET6. - Read in the Debian "default files", but note: only PARAMS is supported!


9e0e955daf Alexander Barton

Update Debian package

- Update debhelper compatibility to version 9. - Update build-dependencies. - Change group of ngircd.conf to "irc" in postinst script (this makes starting ngIRCd as user "irc" easier, for example when using systemd). - Don't create /var/run/ircd during installation: this is handled by the SysV init script and the systemd service already.


3e44738416 Alexander Barton

Update NEWS and ChangeLog files



77861f6fe2 Alexander Barton

Immediately shut down connection on receiving ERROR

Don't wait for the peer to close the connection. This allows us to forward the ERROR mesage in the network, instead of the very generic "client closed connection" message.


e9e3df27b7 Alexander Barton

Xcode: Fix "duplicate symbols" error in current Xcode


0dc3c13469 Alexander Barton

x-Line synchronization: Don't send negative durations


d0d4de4980 Alexander Barton

List expiration: use same log level as when setting

And log this event to the &SERVER channel, too.


85df414907 Alexander Barton

Remove leftover debug message. Oops!


f5ff22d98f Alexander Barton

G-LINES: Forbid remote modifications if "AllowRemoteOper" is not set

Explicitely forbid remote servers to modify "x-lines" (G-LINES) when the "AllowRemoteOper" configuration option isn't set, even when the command seems to originate from the remote server itself: this prevents GLINE's to become set during server handshake in this case (what wouldn't be possible during regular runtime when a remote IRC Op sends the command) and what can't be undone by IRC Ops later on (because of the missing "AllowRemoteOper" option) ...


995bbfd627 Alexander Barton

Make scripts and init-files in ./contrib executable


dd6d75d37d Alexander Barton

autogen.sh: Fix some shellcheck(1) warning messages


daa88b7651 Alexander Barton

Fix building ngIRCd with OpenSSL 1.1

At the moment, ngIRCd fails to build against OpenSSL 1.1 since the configure check probes for the SSL_library_init symbol which was removed, but probing for a different function availabe in both versions solves that problem: SSL_new(). And as SSL_library_init is no longer needed, the patch boils down to probing SSL_new to assert libssl is available, and disabling the SSL_library_init invokation from OpenSSL 1.1 on, see also another application[1] (NSCA-ng) that did pretty much the same. Patch was compile-tested on both Debian jessie (OpenSSL 1.0.2) and stretch (OpenSSL 1.1). [1] <https://www.nsca-ng.org/cgi-bin/repository/nsca-ng/commit/?id=8afc22031ff174f02caad4afc83fa5dff2c29f8a> (Patch by Christoph, commit message cherry-picked from the email thread on the mailing list by Alex. Thanks!)


2924b3d52a Alexander Barton

gcc 6.2 warnings: fix code indentation

This fixes the following correct -Wmisleading-indentation warning messages of gcc 6.2: irc-write.c: In function ‘IRC_SendWallops’: irc-write.c:521:4: warning: this ‘if’ clause does not guard... irc-write.c:524:5: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’ irc-write.c:526:4: warning: this ‘if’ clause does not guard... [] irc-write.c:529:5: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’ irc-info.c: In function ‘IRC_STATS’: irc-info.c:895:3: warning: this ‘else’ clause does not guard... irc-info.c:897:4: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘else’ No functional changes, the code has been correct, but the indentation was wrong ...


a335e480c5 Alexander Barton

Update config.guess and config.sub to recent versions

- config.guess: 2016-04-02 - config.sub: 2016-03-30


dde89b1267 Alexander Barton

Platforms.txt: Update systems

- Update x86_64/apple/darwin15.6.0 (Apple clang 8.0) - Update x86_64/unknown/linux-gnu (gcc 4.9.2) - Update i386/pc/solaris2.11 (gcc 4.8.2), tests have been run both on Solaris 11.2 and Solaris 11.3 successfully, but the system identifier is the same ... Thanks to Götz Hoffart <goetz@hoffart.de>!


455f073687 Alexander Barton

PAM.txt: Add note about /etc/pam.d/ngircd permissions


804c240320 Alexander Barton

autogen.sh, ngindent, platformtest.sh: Fix warnings of "shellcheck"

- SC2006: Use $(..) instead of legacy `..`. - SC2015: Note that A && B || C is not if-then-else. C may run when A is true. - SC2086: Double quote to prevent globbing and word splitting. - SC2166: Prefer [ p ] && [ q ] as [ p -a q ] is not well defined.


fb99d7c92e Alexander Barton

Update Xcode project for latest Xcode version (8.0)


1d06ed02ce Alexander Barton

Update Xcode project for latest Xcode version (7.3)


c283b52a78 Alexander Barton

Updated config.sub to version 2014-09-11


b708c95173 Alexander Barton

Add "Documentation" variables to systemd configuration files


722afc1b81 Alexander Barton

Make sure that SYSCONFDIR is always set

This is useful when ./configure hasn't been run but some source code linters are run in an editor, for example.


86a64ce6aa Alexander Barton

Add "PAMServiceName" configuration option

This setting allows to run multiple ngIRCd instances with separate PAM configurations on each instance. If one sets it to ngircd-foo, PAM will use /etc/pam.d/ngircd-foo instead of the default /etc/pam.d/ngircd. Thanks to "somechris" for the patch & pull request! Closes #226.


e84000f7b8 Christian Aistleitner

Add PAMServiceName setting to specify the used PAM configuration

This setting allows to run multiple ngIRCd instances with PAM configurations on each instance. If one sets it to "ngircd-foo", PAM will use `/etc/pam.d/ngircd-foo` instead of the default `/etc/pam.d/ngircd`.


a93247d32f Alexander Barton

Add an ".editorconfig" file to the project


a673a6e3af Alexander Barton

Platforms.txt: Remove x86_64/unknown/linux-gnu, tcc 0.9.25

This combination had been successfully tested with ngIRCd 21, but after further investigation didn't build correctly: it seems as if tcc fails to correctly link external libraries (e. g. ngipaddr). Astonishingly the test suite passed nevertheless, with garbled output, but without the daemon crashing!? When using tcc with ngIRCd 23 (and current master), the test suite fails completely because the daemon crashes ... (which actually is good!)


0ab4e7bffd Alexander Barton

Platforms.txt: Add systems

- Add armv7l/unk./linux-gnueabihf (gcc 4.9.2) - Add x86_64/unknown/linux-gnu (icc 16)


8f0d24c831 Alexander Barton

Travis-CI: use "container-based infrastructure"

See <https://docs.travis-ci.com/user/migrating-from-legacy/> for details.


0a6e284582 Alexander Barton

platformtest.sh: Delete ngIRCd binary before test run

This ensures that we definitely don't test an old binary later on ...


2254e92e60 Alexander Barton

platformtest.sh: Only show "runs=Y" when test suite succeeded

Display "?" in the "runs" colum when the simple "run test" succeeded but the test suite failed. And display a message to double check the actual status, because it is somewhat unclear, if the daemon actually "works" or not in this case.


7cda2f13f4 Alexander Barton

Platforms.txt: Add and update systems

- Add i386/pc/minix (clang 3.4) - Update i686/pc/cygwin (gcc 4.9.3) - Add x86_64/apple/darwin15.2.0 (Apple clang 7.0)


7dba1a0766 Alexander Barton

Send_Message: Fix handling of "empty" targets

Clients can specify multiple targets for the "PRIVMSG", "NOTICE", and "SQUERY" commands, separated by commas (e. g. "PRIVMSG a,#b,c :text"). Since commit 49ab79d0 ("Limit the number of message targes, and suppress duplicates"), ngIRCd crashed when the client sent the separator character only as target(s), e. g. "," or ",,,," etc.! This patch fixes the bug and adds a test case for this issue. Thanks to Florian Westphal <fw@strlen.de> for spotting the issue!


055d6e8056 Alexander Barton

Update README file


432a9297f8 Alexander Barton

Platforms.txt: Add and update systems

- Update i586/pc/interix3.5 (gcc 3.3) - Add i686/pc/linux-gnu (gcc 2.6.3) - Add i686/pc/linux-gnu (gcc 2.95.2) Thanks to Götz Hoffart <goetz@hoffart.de>!


4dcd5f1225 Alexander Barton

platformtest.sh: Use $LOGNAME instead of $USER

LOGNAME is more standard than USER.


6a5569c27d Alexander Barton

Update copyright notices for 2016


49ab79d0e6 Alexander Barton

Limit the number of message targes, and suppress duplicates

This prevents an user from flooding the server using commands like this: PRIVMSG nick1,nick1,nick1,... Duplicate targets are suppressed silently (channels and clients). In addition, the maximum number of targets per PRIVMSG/NOTICE/... command are limited to MAX_HNDL_TARGETS (25). If there are more, the daemon sends the new 407 (ERR_TOOMANYTARGETS_MSG) numeric, containing the first target that hasn't been handled any more. Closes #187.


cedba36965 Alexander Barton

Add "_MSG" postfix to ERR_WILDTOPLEVEL_MSG


40bea95c08 Alexander Barton

Commands.txt, PRIVMSG: Fix "server mask" description


7c7d03b730 Alexander Barton

Enahnce comments for Send_Message() and Send_Message_Mask()

No functional changes.


4693226d69 Alexander Barton

Get rid of unclever assert() in Send_Message_Mask()

Either we use assert() to _guarantee_ a certain condition, or we use if(...) to test for it. But never both. So get rid of the assert() in Send_Message_Mask() and handle the case that the target mask doesn't contain a dot (".") as regular error, don't require the caller to assure that any more. This polishes commit 5a312824. Please note: The test in Send_Message() is still _required_ to detect whether the target is a channel (no dot) or a "target mask" (at least one dot)!


afb59ab8e5 Alexander Barton

Test suite: Add new test for server-server logins

This test detects the recent NJOIN breakage, for example ...


d90f0323e5 Alexander Barton

Fix NJOIN handler killing all clients

This bug has been introduced by commit 1e386fb7ac which had the logic reversed :-( Reported by "ninguno" in #ngircd, thanks a lot!


01e590b007 Alexander Barton

contrib/ngindent: Fix shebang line



46838510ab Alexander Barton

contrib/platformtest.sh: Make script more portable


0903343f85 Alexander Barton

Platforms.txt: Add and update systems

- Update i386/unknown/openbsd3.5 (gcc 2.95.3) - Update i686/pc/linux-gnu (gcc 2.7.2.1) - Add x86_64/unknown/linux-gnu (gcc 5.3.0) Thanks to Götz Hoffart <goetz@hoffart.de>!


182bfac855 Alexander Barton

doc/Platforms.txt: Sort list


1e386fb7ac Alexander Barton

Make NJOIN handler more fault-tolerant

Don't crash the daemon when the NJOIN handler can't join the new client to a channel (when the Channel_Join() function failed) but try to KILL this client -- which is the only possible reaction besides crashing: otherwise the network would get out of sync.


52ccba5d1e Alexander Barton

IRC_KillClient(): Don't break when called without "Client"

The IRC_KillClient() function is documented to handle the case that the "Client" structure is NULL, so make sure that this actually works and can't crash the daemon. Please note: The current code doesn't make use of this feature, so this fix is definitely the "right" thing to do but doesn't fix an actual problem.


98e9467c85 Alexander Barton

IRC_NJOIN(): Code cleanup

No functional changes.



398022631a Alexander Barton

Fix NJOIN not propagating "half ops" status

ngIRCd tested for the wrong prefix of "half ops" when processing NJOIN commands and therefore never classified a remote user as "half op". Thanks to wowaname for pointing this out on #ngircd!


f2cef85fde Alexander Barton

ngIRCd Release 23 (tags/rel-23)


6ed59a8548 Alexander Barton

Update ChangeLog file


49acb68584 Alexander Barton

Update doc/Platforms.txt


d8aba40f07 Alexander Barton

Explicitly cast time_t to long when printing it out

This prevents wrong sizes data types on platforms where time_t doesn't equal a long any more, for example on OpenBSD.


87887bc632 Alexander Barton

contrib/Debian/changelog: Fix email address


cb3a4321a2 Alexander Barton

Documentation: Spelling fixes


1e84b2640e Alexander Barton

ngIRCd Release 23~rc1 (tags/rel-23-rc1)


86d27eaf89 Alexander Barton

Update AUTHORS and .mailmap file

And add a note to doc/HowToRelease.txt to not forget to update the list of authors in the future ...


4acf95ab61 Alexander Barton

Update ChangeLog file


57cd41d289 Alexander Barton

Add ".clang_complete" file

This file is used of the "linter-clang" package of the Atom editor, for example.


eb9929e82c Alexander Barton

Make server-to-server protocol more robust

Now ngIRCd catches more errors on the server-to-server (S2S) protocol that could crash the daemon before. This hasn't been a real problem because the IRC S2S protocol is "trusted" by design, but the behavior is much better now. Thanks to wowaname on #ngircd for pointing this out!


c2e4c304e3 Alexander Barton

platformtest.sh: Fix quoting


c56138c280 Alexander Barton

autogen.sh: Fix parameter quoting


a1ce3fc779 Alexander Barton

ngircd.init: Fix non-POSIX "==" test operator


ccc899c7f4 Alexander Barton

Reproducible builds

At the moment ngircd fails the tests for reproducible builds in Debian since it uses the __DATE__ and __TIME__ macros for the INFO command. Instead of patching this out I decided to implement an optional constant BIRTHTIME that allows you to set a time stamp for the "Birth Date" information, in seconds since the epoch, like in export CFLAGS += -DBIRTHTIME=$(shell date +%s --date="2015/08/15 23:42:22") In the future, Debian will provide a SOURCE_DATE_EPOCH environment variable, dealing with the situation until then will be my job. The time format was taken from the NGIRCd_StartStr formatting in ngircd.c so the "Birth Date" and "On-line since" lines in the INFO output look similar: :irc.example.net 371 nick :ngIRCd 22.1-IDENT+IPv6+IRCPLUS+PAM+SSL+SYSLOG+ZLIB-x86_64/pc/linux-gnu :irc.example.net 371 nick :Birth Date: Tue Aug 25 2015 at 18:11:11 (CEST) :irc.example.net 371 nick :On-line since Tue Aug 25 2015 at 18:11:33 (CEST) :irc.example.net 374 nick :End of INFO list The format of the time stamped is changed, but as far as I can tell, there's no rule that is violated by that. Bonus level: Reformat the messages so the time stamps are aligned.


2a52befa56 Alexander Barton

Update systemd service file


2c18e9a7f8 Alexander Barton

Update NEWS and ChangeLog files


9811223fb8 Alexander Barton

Whitespace fixes (no functional changes)


0083fe177f Alexander Barton

Fix debug message "Client ... is closing connection"

It should be "host:port"!


34578b8b30 Alexander Barton

INSTALL: Add deprecation notice for "PredefChannelsOnly"

Obviously I forgot to list this for ngIRCd 21 ... oops!


85dc4d8777 Alexander Barton

"NoticeAuth" configuration variable is deprecated now!


64c265cf33 Alexander Barton

Merge pull request #217 from SaberUK/master+notice-auth

Use "NOTICE *" before registration instead of "NOTICE AUTH".


b72a7a4b96 Alexander Barton

Channel mode "N" is targeted for ngIRCd 23.


5545e1bebf Peter Powell

Rename NoticeAuth to NoticeBeforeRegistration.

The old name is still supported for compatibility reasons.


b8482fd3cf Alexander Barton

First check if channel has mode "N", then check membership

This should be more efficient.


d118cd74b6 Peter Powell

Use "NOTICE *" before registration instead of "NOTICE AUTH".

AUTH is a valid nickname so sending notices to it is probably not a good idea. Use * as the target instead as done with numerics when the nick is not available. This mimics the behaviour in Charybdis, IRCD-Hybrid, InspIRCd 2.2, Plexus 4, etc.


90ea23ab4f Alexander Barton

Merge pull request #214 from Flupsy/channel-mode-N

Channel mode N (users on this channel can't change their nick)


571b1a8b83 Alexander Barton

Merge pull request #215 from tejr/master

Specify session context for OpenSSL clients. Closes #182.


6e7e744cc6 Alexander Barton

Add "build+*" to .gitignore file



b71a0ddbd5 Tom Ryder

Specify session context for OpenSSL clients

Reconnecting to ngIRCd 22.1 built with OpenSSL with some OpenSSL clients, including Pidgin and stunnel 5.06, attempts to reuse a session and fails due to the absence of this line. The error message in syslog from ngIRCd is: > SSL protocol error: SSL_accept (error:140D9115:SSL > routines:SSL_GET_PREV_SESSION:session id context uninitialized) This patch appears to fix the problem for both Pidgin and stunnel; it may work for other OpenSSL clients that attempt to re-use sessions. * <https://github.com/ngircd/ngircd/issues/182> * <https://developer.pidgin.im/ticket/11568> * <https://www.openssl.org/docs/ssl/SSL_CTX_set_session_id_context.html>


f6b7764eb5 Alexander Barton

Fix several broken URLs.


24cec978ee Alexander Barton

Remote GIT.txt from Makefile[.am], too!


7ff16e8116 Ian Chard

Don't bother looking for +N channels for an op


d28d838cb9 Alexander Barton

Merge remote-tracking branch 'LucentW/master'

* LucentW/master: Fix with oneshot invites Fixed building issues\ Implement timestamp tracking of invites Keep track of who placed bans/invites/excepts IRC operators w/OperCanMode can kick anyone [already cherry-picked] Closes #203, Closes #205.


a02524465e Alexander Barton

READNE, AUTHORS: Update mailing list and issue tracker URLs


adfe5affed Ian Chard

Don't use a standard message number


2fc61ce8a6 Alexander Barton

Make setgroups(3) function optional

For example, Interix is missing this function, which prevented ngIRCd to build on this platform. When setgroups(3) isn't available, a warning message is issued when ngIRCd starts up.


93a872a36b LucentW

Fix with oneshot invites

This should finally implement correctly oneshot invites sent via /INVITE


813ea874f8 Alexander Barton

doc/Contributing.txt: Add note about using GitHub


27934afd7e Ian Chard

Add documentation for channel mode N


5c48d7e9c7 Alexander Barton

IRC operators w/OperCanMode can kick anyone

Closes #202. (cherry picked from commit 10c7ba99e73b42ec8c4c191ccdae60bdd35bba7d)


03c8997af3 LucentW

Fixed building issues\

Now builds cleanly. Pass all tests from make check.


813897023e Alexander Barton

Remove doc/GIT.txt: it is outdated

ngIRCd uses GitHub, and Git itself is quite common today. So don't include an own Git "mini HowTo" any longer.



0f490b5cae Alexander Barton

Implement numeric RPL_LISTSTART(321)

lightIRC and other clients expecting RPL_LISTSTART should now behave correctly. Closes #207. (cherry picked from commit 0680ce5fd99bc643651d1433bcdaf271aeb73c46)


4396936f38 LucentW

Implement timestamp tracking of invites

Now lists nodes also have the "onlyonce" field, since the valid_until is used to keep the timestamp of placing. Found no references to onlyonce or about valid_until being == 1, though, so it might be unused, but still available for other enhancements.


a5ca8be658 Alexander Barton

Streamline ".gitignore" files


a43d79aeff Alexander Barton

Update ngircd.conf.5: "CloadUserToNick" hides user and real name

Closes #208.


4da04640e6 LucentW

Keep track of who placed bans/invites/excepts

Implements #203. WARNING: it does not track the time of placement of invites, since the time_t is already used as a flag for single use invites!


c364d67f80 Alexander Barton

Update NEWS and ChangeLog files


c4245220de Alexander Barton

Fix MatchCaseInsensitive[List]](): lowercase string _and_ pattern

Up to now, only the the string ("haystack") became lowercased and was the compared to the pattern ("needle") -- which failed, when the pattern itself wasn't all lowercase ...


10c7ba99e7 LucentW

IRC operators w/OperCanMode can kick anyone


f8f7f83f5a Alexander Barton

Streamline effect of "MorePrivacy" option (WHOIS, LIST)

- Update documentation in ngircd.conf(5) - LIST: Don't hide channels for IRC Ops when "MorePrivacy" is in effect - WHOIS: Don't hide IP addresses/hostnames when "MorePrivacy" is in effect Closes #198


1136b97690 Alexander Barton

doc/Modes.txt: Fix indentation


d9a97f2857 Alexander Barton

Merge pull request #197 from LucentW/master

Implement user mode "I": Hide channels on WHOIS User mode +I prevents ngIRCd from showing channels on WHOIS. IRC Operators can always see those. Closes #197.


a4af9024fd LucentW

Fixed indents 2


c5da483685 Alexander Barton

Make sure that the target user is able to join a local channel

Implement ERR_USERNOTONSERV(504) numeric and make sure that the target user is on the same server when inviting other users to local ("&") channels. ircd-ratbox uses the ERR_USERNOTONSERV(504) numeric for this, and I think this is a good idea -- other IRC daemons (like ircu) silently drop such impossible invites, but thats not a big benefit ... Idea by Cahata, thanks! Closes #183.


6fc53558ed LucentW

Fixed indents and documentation

(also updated the copyright date on the txt I edited)


4330f5d1c9 Alexander Barton

INVITE command: Enforce 1 second penalty time

This prevents flooding of the target client. This closes #186. Reported by Cahata, thanks!


21767c968d LucentW

Implement +I (private channel list on whois)

Implements enhancement requested in issue #179


81b81c818c Alexander Barton

MODE command: Always report channel creation time

Up to now when receiving a MODE command, ngIRCd only reported the channel creation time to clients that were members of the channel. This patch reports the channel creation time to all clients, regardless if they are joined to that channel or not. At least ircd-seven behaves like this. This closes #188. Thanks Cahata!


52825cde29 Alexander Barton

Update Xcode project for latest Xcode version (6.3)


03e6568079 Alexander Barton

ngIRCd Release 22.1 (tags/rel-22.1)


7dacc314f9 Alexander Barton

Update NEWS and ChangeLog for ngIRCd 22.1


24adfb88b4 Alexander Barton

Update some copyright notices for 2015


6ed440a030 Alexander Barton

Platforms.txt: Add and update systems

- Update powerpc/apple/darwin7.9.0 Thanks to Götz Hoffart <goetz@hoffart.de>!


c7bbc9a390 Alexander Barton

Fix spelling of RPL_WHOISBOT message text


6171beb7ab Alexander Barton

Don't send nick name as default PART reason

No other IRC daemon seems to do this (today?), don't remember why ngIRCd did it in the first place ... Closes #185. Reported by Cahata in #ngircd, thanks!


2196e945e4 Alexander Barton

Fix "WHO #<chan>" showing invisible users and hiding all visible

The logic is reversed ... This bug has been introduced by commit c74115f2, "Simplify mode checking on channels and users within a channel", ngIRCd releases 21, 21.1, and 22 are affected :-( Problem reported by Cahata in #ngircd, Thanks!


f16eb1b686 Alexander Barton

Fix typo in src/testsuite/README


c41f18e3f9 Alexander Barton

Auth PING: Fix our information text for manual sending of "PONG"

Up to now, ngIRCd doesn't send a valid IRC command at all, oops!


dbfe1beca8 Alexander Barton

Auth PING: The numeric ID is a "long", use atol()


6bdae55177 Alexander Barton

Auth PING: Don't send a prefix in our PING command

The prefix confuses WeeChat, at least, which doesn't send an appropriate PONG in the case ... Debugging and patch by "wowaname" on #ngircd, thanks!


fb5ae9e844 Alexander Barton

FAQ: How can I "auto-op" users in channels?


bd8d4e710c Alexander Barton

Fix syntax of ERR_LISTFULL_MSG(478) numeric

Pointed out by "wowaname" in #ngircd, thanks!


9a931a549b Alexander Barton

Enhance debug messages while sending CHANINFO commands


3c30490d54 Alexander Barton

Reset "last try" timer when enabling a passive server

This results in a new connection attempt as soon as possible.


6250335352 Alexander Barton

Change log message for "Can't resolve address"


7e14bd3b58 Alexander Barton

Change log messages issued for IP address forgeries


31b3c83c1f Alexander Barton

Merge remote-tracking branch 'alex/TestsuiteNoDNS'

* alex/TestsuiteNoDNS: Test suite: Don't use DNS lookups


6e4235443e Alexander Barton

Merge branch 'CipherListNoSSL3'

* CipherListNoSSL3: INSTALL: List the changed SSL CipherList default value. Update "CipherList" to not enable SSLv3 by default


3f807e1045 Alexander Barton

Test suite: Don't use DNS lookups

Different operating systems do behave quite differently when doing DNS lookups, for example "127.0.0.1" sometimes resolves to "localhost" and sometimes to "localhost.localdomain" (for example OpenBSD). And other systems resolve "localhost" to the real host name (for example Cygwin). So not using DNS at all makes the test site much more portable.


cdcf474f15 Alexander Barton

INSTALL: List the changed SSL CipherList default value.


f33a4067a1 Alexander Barton

HowToRelease.txt: Add note about the bug tracker


39b8fc65b6 Alexander Barton

Add "tests-skipped.lst" to src/testsuite/.gitignore


100de3e4cc Alexander Barton

Update "CipherList" to not enable SSLv3 by default

Idea, initial patch, and testing by Christoph Biedl <ngircd.anoy@manchmal.in-ulm.de>


7b58538074 Alexander Barton

ngIRCd Release 22 (tags/rel-22)


3de972e0bd Alexander Barton

Test suite/platformtest.sh: Detect when tests have been skipped

Detect if some tests have been skipped, for example when telnet(1) or expect(1) is missing: ./contrib/platformtest.sh will echo a warning message now.


3f436e1810 Alexander Barton

Platforms.txt: Add and update systems

- Add armv7l/unk./linux-gnueabihf - Update hppa/unknown/openbsd5.4 - Update i686/unknown/gnu0.5 - Update i686/pc/cygwin - Add i386/pc/linux-gnu, gcc 4.4.5 - Update x86_64/apple/darwin14.0.0 - Update x86_64/unknown/freebsd8.4 - Update x86_64/unknown/freebsd9.2 - Add x86_64/unknown/freebsd10.0 - Add/update x86_64/unknown/linux-gnu, various compilers - Update x86_64/unknown/openbsd4.8 - Add x86_64/unknown/openbsd5.5 Tested version is "rel-22-rc1-3-g967deeb".


ec2bf5c5a2 Alexander Barton

Platforms.txt: Add and update systems

- Add sparc/unknown/openbsd5.5 - Update powerpc/apple/darwin7.9.0 - Update x86_64/unknown/linux-gnu, Open64 - Update x86_64/unknown/linux-gnu, Sun C 5.12/Solaris Studio 12.3 - Update x86_64/unknown/linux-gnu, tcc 0.9.25 Thanks to Götz Hoffart <goetz@hoffart.de>!


967deebacd Alexander Barton

User mode "F": Fix description in NEWS and ChangeLog



74262a4093 Alexander Barton

Update NEWS and ChangeLog for ngIRCd 22 once more ...


a90004b913 Alexander Barton

Test suite: Update file headers and comments


be88707027 Alexander Barton

Match list patterns case-insensitive

The invite-, ban-, and except lists are affected by this change, as well as G-Lines an K-Lines. Problem pointed out by "wowaname" on #ngircd, thanks!


9e79ed8605 Alexander Barton

Update links to "Arthur" to use the HTTP protocol


7d7eb735f0 Alexander Barton

ngIRCd Release 22~rc1 (tags/rel-22-rc1)


cdd6b961af Alexander Barton

ngIRCd Release 21.1

(cherry picked from commit ee28e76df2a73f3bb4bcf69c644eae9a10298a58)


fa7fac88d2 Alexander Barton

Update NEWS and ChangeLog for ngIRCd 22 once more ...


bfc727ce49 Alexander Barton

Platforms.txt: Update i686/unknown/gnu0.5


84ff5a6eb9 Alexander Barton

Sync "except lists" between servers

Up to now, ban, invite, and G-Line lists have been synced between servers while linking -- but obviously nobody noticed that except list have been missing ever since. Until now. Thanks to "j4jackj", who reported this issue in #ngircd.


dee824a3f0 Alexander Barton

Platforms.txt: Update powerpc/apple/darwin7.9.0

- Update powerpc/apple/darwin7.9.0, gcc 3.3 Thanks to Götz Hoffart <goetz@hoffart.de>!


bf2eae3249 Alexander Barton

Allow longer usernames for authentication


f5ae1dd36c Alexander Barton

Platforms.txt: Update x86_64/unkn./linux-gnu, clang 3.x

- Update x86_64/unknown/linux-gnu, clang 3.2 => clang 3.3


ffad2da835 Alexander Barton

Correctly check that a server has a valid hostname and port

David Binderman <dcb314@hotmail.com> reported the following compiler warning, which is a real bug in ngIRCd, thanks! conn.c:2077:55: warning: logical not is only applied to the left hand side of comparison [-Wlogical-not-parentheses]


794cb51e4b Alexander Barton

Platforms.txt: Add and update more systems

- update i686/pc/linux-gnu, gcc 2.7.2 - update powerpc/apple/darwin6.8, gcc 3.1 - add powerpc/apple/darwin9.8.0, gcc 4.0.1 Thanks to Götz Hoffart <goetz@hoffart.de>!


3f1547ecde Alexander Barton

Fix spelling and whitespaces in INSTALL


dd4b74e29b Alexander Barton

doc/Bopm.txt: Update file header


7893dc5241 Alexander Barton

Update NEWS and ChangeLog for ngIRCd 22


daed2467dd Alexander Barton

doc/Bopm.txt: Update "connregex" and "kline" for current ngIRCd

Thanks to "kerin" on IRC for pointing this out!


896d45471a Alexander Barton

Lists_MakeMask: Don't destroy source buffer


d314c75a37 Alexander Barton

Allow "DefaultUserModes" to set all possible modes

Let IRC_MODE() detect that the "fake" MODE command originated on the local sever, which enables all modes to be settable using "DefaultUserModes" that can be set by regular MODE commands, including modes only settable by IRC Operators.


01c3552140 Alexander Barton

Initialize Conf_ScrubCTCP even when SYSLOG isn't #define'd

The "SYSLOG" #define isn't related to "Conf_ScrubCTCP" at all, so initialize the latter even when "SYSLOG" isn't #define'd. Pointed out by wowaname on #ngircd, thanks!


5009ab3e8c Alexander Barton

Spoofed prefixes: Really kill connection on non-server links

This fixes commit 6cbe1308 which only killed the connection when the spoofed prefix itself belonged to a non-server client.


ce3c4074ba Alexander Barton

Platforms.txt: Add and update systems

- Add armv7l/unk./linux-gnueabihf - Add x86_64/apple/darwin14.0.0 Thanks to Götz Hoffart <goetz@hoffart.de>!


5713c49c84 Alexander Barton

Implement user mode "F": "relaxed flood protection"

ngIRCd relaxes its flood protection for users having the user mode "F" set and allows them to rapidly send data to the daemon. This mode is only settable by IRC Operators and can cause problems in the network -- so be careful and only set it on "trusted" clients! User mode "F" is used by Bahamut for this purpose, for example, see <http://docs.dal.net/docs/modes.html#4.9>.


40ed94a1f2 Alexander Barton

Increase MAX_SERVERS from 16 to 64

There are installations out there that would like to configure more than 16 links per server, so increase this limit. Best would be to get rid of MAX_SERVERS altogether and make if fully dynamic, but start with this quick and dirty hack ...


35f1db5f28 Alexander Barton

Handle "throttling" in a single function

ngIRCd uses "command throttling" and "bps throttling" (bytes per second). The states are detected in different functions, Conn_Handler() and Read_Request(), but handle the actual "throttling" in a common function: this enables us to guarantee consistent behavior and to disable throttling for special connections in only one place, eventually.


c1f180b87b Alexander Barton

New "Debian release" 21.1-0ab2

(cherry picked from commit 48fcb97fa4a2762a873d9d693c7a126588a1811d)


4c2acd55c6 Alexander Barton

Updated config.{guess|sub} to version 2014-03-13


f5944a17e4 Alexander Barton

Debian: Don't adjust path names that are correct by default


f547981188 Alexander Barton

Streamline DEBUG_ARRAY, DEBUG_BUFFER, DEBUG_IO, DEBUG_ZIP

Change all #define's to follow the form #define DEBUG_xxx {0|1} to disable (0, default) or enable (1) additional debug messages. And somewhat enhance some DEBUG_BUFFER messages.


06920df4bb Alexander Barton

Debian: Correctly set and use "docdir"


b35f8916a5 Alexander Barton

conn.c: Code cleanup

Reformat and restructure some code, move all SSL related code into one single #ifdef block, for example.


e864b1f33e Alexander Barton

Update config.guess and config.sub to recent versions

- config.guess: 2014-03-23 - config.sub: 2014-05-01


3d7aa9f906 Alexander Barton

Xcode: remove imp.h and exp.h from project file

These files have been removed from ngIRCd in commit 259c314d, "Remove imp.h and exp.h header files".


a534e71e8d Alexander Barton

Re-add #include's for header files of the C file itself

This partially reverts commit b130b35f4, "Update #include's: remove unused and add missing ones", but fixes the following compiler and analyzer warnings of Apple Xcode 5: "Semantic issue: No previous prototype for function 'yyy'"


a13bb78b1e Alexander Barton

Update copyright notices of recently changed files


b130b35f48 Alexander Barton

Update #include's: remove unused and add missing ones

The "deheader" tool (<http://www.catb.org/~esr/deheader/>) has been used to find unused #include directives as well as missing ones. Tested on: - A/UX 3.1.1 - ArchLinux (2014-03-17) - Debian GNU/Hurd - Debian GNU/Linux 6.0.9 - Debian GNU/Linux 7.4 - Fedora 20 - FreeBSD 9.2 - OpenBSD 4.8 - OpenBSD 5.1 - OS X 10.9 - Solaris 11


37090a28e8 Alexander Barton

portab.h: Restructure and clean up code

- Don't use HAVE_SYS_TYPES_H, <sys/types.h> is a required header now. - Streamline check for boolean data types. - Better indent #ifdef constructs.


67256f9da1 Alexander Barton

configure[.ng]: <sys/types.h> is a required header file

ngIRCd already includes <sys/types.h> in a lot of places without checking for its existence (for example in "ngircd.c", "io.c", ...), therefore make it a required header file.


7b10a0e4ee Alexander Barton

io.c: <sys/time.h> is only needed when using select()

Only include the <sys/time.h> header when using the select() IO API, it isn't required otherwise.


259c314d14 Alexander Barton

Remove imp.h and exp.h header files

These include files don't have a function any more, remove them.


51396f8f1c Alexander Barton

strdup.c: Code cleanup


6238196dac Alexander Barton

Don't define SSL_Want{Read|Write}() when SSL is disabled

Not even call the "dummy" functions.


43fb18f2f5 Alexander Barton

Code cleanup, remove blank lines


a4ed90ba9a Alexander Barton

Fix two K&R C portability issues

Fix the following two errors emitted by the Apple K&R C compiler on Apple A/UX: "./class.c", line 47: no automatic aggregate initialization "./class.c", line 47: illegal lhs of assignment operator "./conf.c", line 1052: syntax error Tested on A/UX 3.1.1.


af9161a9bc Alexander Barton

Merge pull request #6 from norrs/pam_server_password_fix

Validate server password when PAM is disabled.


485d0aec81 Roy Sindre Norangshol

Use server password when PAM is compiled in but disabled


abf280d5bd Alexander Barton

CHARCONV: Fix handling conversion errors

Don't overwrite already converted text!


ccc9e1baa4 Alexander Barton

Streamline punctuation of log messages

See commit d38d153f for details.


755562d147 Alexander Barton

Services.txt: Update information for Anope 2.x


384b27cee0 Alexander Barton

IRC_INVITE(): Code cleanup


6496fa4655 Alexander Barton

Streamline punctuation of log messages

See commit d38d153f for details.


20b52fe33d Alexander Barton

Correctly use cloaked IRC masks on "INVITE nickname"

The cloaked IRC mask of a user is his visible mask, so the daemon has to use it for generating the "one time" entries for the invite list of the given channel. Without this patch, ngIRCd records the real IRC mask which will never match while the target client is "+x", and even worse, will disclose the real mask on "MODE #channel +I" commands :-/ Bug reported by Cahata on #ngircd, thanks!


0fc822d8c4 Alexander Barton

Use correct sender as target for ISUPPORT replies on "VERSION"

This fixes commit 2e168c78 ("Return ISUPPORT(005) numerics on 'VERSION'") and make sure, that the 005 numerics are correctly routed back to the sender.


2e168c7809 Alexander Barton

Return ISUPPORT(005) numerics on "VERSION"

This is how ircd-seven, Charybdis, Hybrid, and InspIRCd behave, for example.


14a84dfca5 Alexander Barton

configure: Only link "contrib/Debian" if it exists

This isn't the case on "VPATH builds", for example.


4cb36e370e Alexander Barton

Merge pull request #5 from grawity/accountname-whois

Show account name in WHOIS


e273bd226a Mantas Mikulėnas

Show account name in WHOIS

This uses the same numeric as Charybdis and ircu families.


3b24ebf122 Alexander Barton

ngircd.conf.5: Update manual page


599cfd0944 Alexander Barton

Merge branch 'no-range-matching' of git://arthur.barton.de/ngircd-alex

* 'no-range-matching' of git://arthur.barton.de/ngircd-alex: Remove "range matching" functionality


90062111f7 Alexander Barton

Use $(MKDIR_P) instead of $(mkinstalldirs) in Makefile's

And test for "mkdir -p" using AC_PROG_MKDIR_P in "configure".


e73d70ce6f Alexander Barton

Remove "range matching" functionality

Don't support "range marching" in our pattern matching code using the "[...]" syntax, because [ and ] are valid characters in nick names and one has to quote them currently using the "\" character, which is quite unexpected. For example: Nick "te[st" => "MODE #channel +b te\[st" And remove quoting altogether, too, because "*" and "?" don't need to be quoted because these characters are not allowed in IRC masks, nicks, and hostnames. Reported by "hifi" (Toni Spets) on IRC, thanks!


e747fe9277 Alexander Barton

Fix configure script and "make check" for TCP Wrappers

Add missing #include's and static variables. Problem spotted on OpenBSD.


2560e5f156 Alexander Barton

platformtest.sh: Allow using separate source and build trees

Now you can call platformtest.sh using its complete path name from an other directory which is then used for building. See <http://www.gnu.org/software/automake/manual/html_node/VPATH-Builds.html> Please not that the build system itself is still (re-)genrated in the original source tree. This can be avoided by passing the "-x" switch to the platformtest.sh script.


0f85c4c6a7 Alexander Barton

Add libwrap at the end of the configure run

If libwrap becomes added earlier, other tests may fail because of not all external variables required by libwrap are available when linking: for example allow_severity and deny_severity. This patch adds generic support for the LDFLAGS_END and LIBS_END variables (CFLAGS_END has been implemented already). Problem spotted on OpenBSD.




fe73835666 Alexander Barton

Client_SetHostname(): Don't use strlen() to test for value


5b4b7e2f55 Alexander Barton

Test suite: explicitely enable glibc memory checking


8ae2cdfce9 Alexander Barton

Send "fake '*' key" in "MODE -k" replies

According to RFC 2812 3.2.3 "Channel mode message" and the examples there, it looks like clients should use "MODE -k <key>" to unset channel keys; and that's how other servers and services behave and do expect it. (But please note that this is NOT the case for "MODE -l"!) In the end, it doesn't make sense to specify a key when UNsetting it at all, and different services behave diffrently when clients do not send the currently set key to unset it - some ignore such calls, for example! But this implementation is quite relaxed, it accepts any key when unsetting channel mode "k" and even accepts no key at all. But the reply will always include an "*" character for every "-k" parameter.


6685ae063f Alexander Barton

Add "config.cache" to .gitignore file


e2b85ccde3 Alexander Barton

platformtest.sh: don't use "test -e", it isn't portable


7b358a57ac Alexander Barton

Makefile.am: don't use "test -e", it isn't portable


5d88030bd1 Alexander Barton

Support non-standard vsnprintf() return code

C99 states that vsnprintf() "returns the number of characters that would have been printed if the n were unlimited"; but according to the Linux manual page "glibc until 2.0.6 would return -1 when the output was truncated" -- so we have to handle both cases ...


8872653ef6 Alexander Barton

Partially revert bc098794: don't require autoconf 2.67

GNU autoconf 2.61 is still sufficient to generate the configure script, even after updating configure.{ng|in}, so don't require a newer version.


4d4512cd72 Alexander Barton

doc/Platforms.txt: Update some systems to ngIRCd 21

- update i686/pc/cygwin, gcc 4.8.2 - update x86_64/apple/darwin13.0.0, Apple clang 5.0 - update x86_64/unknown/freebsd8.4, gcc 4.2.1 - update x86_64/unknown/freebsd9.1, gcc 4.2.1 - update x86_64/unknown/linux-gnu, gcc 4.8.2 - update x86_64/unknown/linux-gnu, Open64 - update x86_64/unknown/openbsd4.8, gcc 4.2.1 - update x86_64/unknown/openbsd5.1, gcc 4.2.1


bc098794ee Alexander Barton

Update configure.ng for autoconf 2.67

We already require GNU autoconf 2.67 for generating our build system (at least this is what the INSTALL document states), so update the build system accordingly and implement all changes that autoupdate(1) suggests: - Update AC_PREREQ and AC_INIT - Use AC_LINK_IFELSE, AC_RUN_IFELSE, and AC_COMPILE_IFELSE - Remove AC_TYPE_SIGNAL (we don't use RETSIGTYPE)


788da901ee Alexander Barton

Update Copyright notices for 2014


2a40112f09 Alexander Barton

Merge branch 'bug167-WebircIPAnoDNS' of git://arthur.barton.de/ngircd-alex

* 'bug167-WebircIPAnoDNS' of git://arthur.barton.de/ngircd-alex: WEBIRC: Don't respect hostname when DNS is disabled


61b7932e82 Alexander Barton

Merge branch 'bug165-005-NETWORK' of git://arthur.barton.de/ngircd-alex

* 'bug165-005-NETWORK' of git://arthur.barton.de/ngircd-alex: Implement new configuration option "Network"


1a628fff51 Alexander Barton

WEBIRC: Don't respect hostname when DNS is disabled

When DNS lookups are disabled, don't set the hostname received by the WEBIRC command, but use the IP address instead. Reported by Toni Spets <toni.spets@iki.fi>, thanks! Closes bug #167.



86bdf6e1d4 Alexander Barton

Implement new configuration option "Network"

The new configuration variable "Network" is used to set the (completely optional) "network name", to which this instance of the daemon belongs. When set, this name is used in the ISUPPORT(005) numeric which is sent to all clients connecting to the server after logging in. Closes bug #165.


bd33bd770d Alexander Barton

OS X has a working getaddrinfo() implementation


d38747d951 Alexander Barton

portabtest: Actually test functions

Test functions snprintf(), strlcpy(), strlcat(), vsnprintf() for correctness, not only existance (which was quite useless, because if they weren't available, the program could not have been linked at all ...).


b8433e9261 Alexander Barton

Check for working getaddrinfo() function

At least AIX 4.3.3 and 5.1 have a broken implementation of getaddrinfo() which doesn't handle "0" as numeric service correctly. This patch adds a configure check for this case and changes all calling functions to only use getaddrinfo() if it "works". See <http://www.stacken.kth.se/lists/heimdal-discuss/2004-05/msg00059.html>


18070e5381 Alexander Barton

portabtest: Only use one exit code to indicate errors


5a424f60da Federico G. Schwindt

Fix spelling


d913323ca9 Alexander Barton

portabtest: Code cleanup


444308ccde Alexander Barton

doc/Platforms.txt: Add and update more systems

- add i386/unknown/netbsdelf1.5.2, egcs-1.1.2 - update i386/unknown/openbsd5.3, gcc 4.2.1 - add i386/unknown/openbsd5.4, gcc 4.2.1 - add x86_64/unknown/linux-gnu, nwcc 0.8.2 - update x86_64/unknown/linux-gnu, tcc 0.9.25 Thanks to Götz Hoffart <goetz@hoffart.de>!


9230f2fff1 Alexander Barton

Fix permanent k/gline

Reported by Toni Spets (hifi - at - jnz - dot - fi).


1ad536eeed Alexander Barton

doc/Platforms.txt: Add and update more systems

- add i386/unknown/openbsd3.5, gcc 2.95.3 - add x86_64/unknown/linux-gnu, Sun C 5.12 - update mipsel/unknown/linux-gnu, gcc 4.4.5 Thanks to Götz Hoffart <goetz@hoffart.de>!


c68ae1a9f5 Alexander Barton

doc/Platforms.txt: add DragonflyBSD 3.4 on x86_64

Thanks to Götz Hoffart <goetz@hoffart.de>!


df7ea9e7b4 Alexander Barton

doc/Platforms.txt: add OpenBSD 5.4 on HPPA


34824abe0d Alexander Barton

configure: clean up function definitions


ae00c100ac Alexander Barton

Only use unsetenv() when it is available

AIX 4.3 dosn't support it, for example.


61d1c864c5 Alexander Barton

conf-ssl.h: make code compatible with pre-ANSI C compilers


8d25044ce5 Alexander Barton

vsnprintf.c: make code compatible with ansi2knr tool


c3c719b978 Alexander Barton

Remove unused vsnprintf.c test function


9ee3760493 Federico G. Schwindt

Add comments around some IRC_SetPenalty() calls


344185b1bd Federico G. Schwindt

Rework the penalty handling slightly

Increase the penalty for a command before checking its arguments. This makes the handling more consistent and allow us to move more penalties to Handle_Request().


fcf61e9e02 Federico G. Schwindt

Move IRC_SetPenalty() to Handle_Request() when possible

This centralizes the penalty handling. It also exposes some commands that lack it for our attention.


9f236c4b91 Federico G. Schwindt

Introduce a macro to define the command list

This will pave the way to other changes and simplifies the entries somewhat.


00249f3c80 Federico G. Schwindt

When sending an error use the IRC_WriteErrClient() variant

This ensures that all errors have a 2 second penalty.


925b4de298 Federico G. Schwindt

On bad /oper set the penalty to 10 seconds

This helps against brute-force attempts.


48ea69d778 Federico G. Schwindt

Remove unneded IRC_SetPenalty() calls

IRC_WriteErrClient() already calls IRC_SetPenalty(). While here convert some IRC_SetPenalty() + IRC_WriteStrClient() to IRC_WriteErrClient().


80d0613bf2 Federico G. Schwindt

Use sizeof() intead of the explicit size


4ab688c5e8 Alexander Barton

Remove wrong #ifdef in Option_String()

This fixes the following error when compiling without zlib support: irc.c: In function ‘Option_String’: irc.c:487: error: ‘options’ undeclared (first use in this function) Reported by "der_baer" on #ngircd.


2e93129877 Alexander Barton

NEWS/ChangeLog: Clean up version numbers and release dates


94148c37f5 Alexander Barton

ngIRCd Release 21 (tags/rel-21)


f25be28ab8 Alexander Barton

doc/Platforms.txt: add Mac OS X 10.6.8


fae7bd1bb7 Alexander Barton

Update doc/Platforms.txt


0556aa1901 Alexander Barton

ngircd.init: Make sure no stale PID file is left over



8e6db769ac Federico G. Schwindt

Check and call arc4random_stir() if present

FreeBSD prior to 10.0 does not automatically stir on fork(). Same with current NetBSD. If arc4random_stir() is present assume is needed and call it instead of srand().


8a041373bb Alexander Barton

Debian: Fix sed(1) rules adjusting "ngircd-full" package

Error introduced by last commit :-/


37c8699f34 Alexander Barton

Debian: Fix default "HelpFile" file name in ngircd.conf

The "full" package variants must use "/usr/share/doc/ngircd-full/Commands.txt" and "/usr/share/doc/ngircd-full-dbg/Commands.txt" respectively.


788b3002d8 Alexander Barton

ngIRCd Release 21~rc2 (tags/rel-21-rc2)


beb9f65dc8 Alexander Barton

platformtest.sh: Detect clang compilers


62865f7e19 Federico G. Schwindt

Add support for longer config lines

With the introduction of CipherList we could have longer config lines. Handle up to 1024 bytes and warn if the line will be truncated.


a7dda1b28c Federico G. Schwindt

Report the correct file on error


cba5a2579f Alexander Barton

doc/Platforms.txt: Add Open64 and tcc C compilers on Linux

Thanks to Götz Hoffart!


a2479bb906 Alexander Barton

platformtest.sh: Detect tcc compiler


17589534d0 Federico G. Schwindt

Add support for arc4random

If arc4random is present it will be used over the srand/rand interface. This fixes some warnings in OpenBSD-current.


ea26fd2840 Federico G. Schwindt

Fix another strcat warning missed in commit 4c5b43


45d3e6aa91 Alexander Barton

platformtest.sh: Clean up GIT source tree, when possible


0bd3fb88b2 Alexander Barton

platformtest.sh: Detect Apple LLVM (clang) compiler


c34b91d8dd Alexander Barton

Update (date of) manual pages


56da86b4f4 Alexander Barton

ChnageLog file: even more spelling fixes ...


ea8a2bf1fc Alexander Barton

INSTALL file: Update "Upgrade Information"


1b349b05d5 Alexander Barton

Fix spelling in NEWS and ChangeLog files


4c5b439992 Alexander Barton

ngircd.c, main(): use strlcat() instead of strcat()

This fixes the following warning on OpenBSD 5.3: ngircd.o(.text+0xeb4): In function `main': src/ngircd/ngircd.c:300: warning: strcat() is almost always misused, please use strlcat() Thanks to Götz Hoffart for reporting this!


86cd2da8d5 Alexander Barton

ngIRCd Release 21~rc1 (tags/rel-21-rc1)


9b1fee8995 Alexander Barton

Update NEWS and ChangeLog files


2798a12444 Alexander Barton

Actually KILL clients on GLINE/KLINE

Kill all clients that match a new GLINE/KLINE mask and genrate apropriate KILL commands. These KILL commands can be superfluous, but are required when the IRC Operator isn't allowd to set remote G-Lines or if there are older servers in the network that don't kill clients on GLINE/KLINE. Closes bug #156.


02182143c3 Alexander Barton

Don't forward KILL commands for unknown clients


b5faf3055b Alexander Barton

New function IRC_KillClient() to kill clients

The old local function Kill_Nick() in irc.c has been an ugly hack. This patch implements a generic function for killing clients. Adjust all callers of Kill_Nick() and respect the return code!


cccd8fc957 Alexander Barton

Adjust log messages for invalid and spoofed prefixes

Now invalid prefixes aren't logged no more when originating from an other server (besides in debug mode), and spoofed prefixes are correctly logged using LOG_WARNING (from an other server) or LOG_ERR (from a client) levels. In addition, the log message texts have been adjusted to better reflect what will happen: commands with invalid prefixes are ignored and logged, commands with spoofed prefixes will result in the client being disconncted (regular users) or the command being ignored (other servers). This cleans up logging of commands related to already KILL'ed clients.


eccbd97e1f Alexander Barton

Remove CLIENT.oper_by_my, Client_SetOperByMe() and Client_OperByMe()

All places where Client_OperByMe() is used can either be converted to Client_HasMode(Client, 'o') or Op_Check(). And Op_Check() itself can use the connection handle for deciding whether the IRC Operator is a local user or not.


ec5ab4fcd1 Alexander Barton

Add support to show user links using "STATS L"

Change "stats L" to show servers and user links and restrict it to IRC Operators.



99db111bca Alexander Barton

doc/PAM.txt: add a slightly more useful example


27b9d32bf2 Federico G. Schwindt

Change the certificate fingerprint digest to sha256

While here correct some indentation.


0985d69cc6 Federico G. Schwindt

Change cipher defaults

Switch cipher defaults to HIGH:!aNULL:@STRENGTH (OpenSSL) or SECURE128 (GnuTLS).


d0977258ee Alexander Barton

Merge remote-tracking branch 'alex/bug162-SSLCipherList'

* alex/bug162-SSLCipherList: Cipher list selection for GnuTLS ConnSSL_Init_SSL(): correctly set CONN_SSL flag Cipher list selection for OpenSSL ConnSSL_InitLibrary(): Code cleanup


2cebfc54f5 Federico G. Schwindt

Fix server reconnection

In some error cases conn_id will be left as SERVER_WAIT and subsequently ignored in Check_Servers(). Ensure conn_id is set to NONE before returning from New_Server() if we couldn't establish the connection. Prompted by a report from gabrielgi-at-gmail-dot-com.


b9006acee3 Alexander Barton

Cipher list selection for GnuTLS

This patch implements the missing functionality for cipher list selection using GnuTLS (our OpenSSL code has this already).


de3e5fa77c Alexander Barton

Don't ignore SSL-related errors during startup

Without this patch, ngIRCd ignores SSL-related messages and continues to start up but only listens on plain text communication ports -- and this most probably isn't what the administrator wanted ... Closes bug #163.


51231ac8d4 Alexander Barton

ConnSSL_Init_SSL(): correctly set CONN_SSL flag

The CONN_SSL flag must be set before any calls to ConnSSL_Free()!


84ed46d4c1 Alexander Barton

Cipher list selection for OpenSSL

This patch introduces the possibility to arbitrarily select ciphers which should be promoted resp. declined when establishing a SSL connection with a client by implementing the new configuration option "CipherList". By default, OpenSSL would accept low and medium strength and RC-4 ciphers, which nowadays are known to be broken. This patch only implements the feature for OpenSSL. A GnuTLS counterpart has to be implemented in another patch ... Original patch by Bastian <bastian-ngircd@t6l.de>. Closes bug #162.


e8e0351985 Alexander Barton

TRACE: fix error message when there are too many parameters

ircd 2.11 ignores additional parameters silently, but I don't think that this is the correct behaviour either ...


849f85a05c Alexander Barton

ConnSSL_InitLibrary(): Code cleanup


131364def1 Alexander Barton

IRC_SetPenalty(): Code cleanup


bcb45da1b4 Federico G. Schwindt

Add more penalty times

Ensure before every numeric 461 there is a call to IRC_SetPenalty().


08f9d31d60 Federico G. Schwindt

Rework check for number of parameters

Move most of the checks that return numeric 461 into Handle_Request().


37609d6a4f Federico G. Schwindt

Reorder checks

Move oper and Conf_MorePrivacy checks after checking the number of parameters.


33c2d5e4e2 Federico G. Schwindt

Move the IRC_SetPenalty() call after the asserts


a98bbc8e0b Federico G. Schwindt

Correct numeric returned by whois

As per RFC whois should return 431 if no nick is provided. While here convert upper check to use irc-macros. As a bonus we get to set the penalty for free.


9f74c0ff07 Federico G. Schwindt

Minor cosmetic change

Add a define to indicate any client. While I'm here use hex values instead of decimal, it's somewhat clearer that they could be OR'ed together.


e5cdd61fe3 Alexander Barton

Commands.txt: Document proprietary DIE <message> parameter


e3a2a6c44d Alexander Barton

getpid.sh: use /bin/pidof when available


aad92ceafe Alexander Barton

Don't enforce channel types for other servers

The configuration option "AllowedChannelTypes" must only be enforced for regular clients and not for remote servers. Channels created by other servres are always allowed, because they already exist and the daemon must stay in sync with the network.


4102e8fdfe Alexander Barton

Only log "IDENT ... no result" when IDENT was looked up

Without this patch, ngIRCd logged the "IDENT lookup for connection X: no result"-message even when IDENT lookups have been disabled using the "Ident = no" configuration option, which is a little bit misleading. Reported by "btwe" in #ngircd.


f8f8a9a041 Florian Westphal

ngircd: use setgid/setuid errno value in error path

Need to use saved errno value as strerror argument, else you get bogus output ('success') in the log message.


04b947cdc3 Alexander Barton

Show connection flag "s" (SSL) in RPL_TRACE{LINK|SERVER}

Now you can check if a server-to-server link is SSL-encrypted or not using the IRC "TRACE" command. Idea by Götz Hoffart, thanks!


be2e611680 Federico G. Schwindt

Change away to be allocated dynamically


41f75b6974 Alexander Barton

Ignore "operation not permitted" while dropping groups

Without this exception, you can't start ngIRCd as user any more, it is analog to setting the user and group ID.


e009ccbe66 Florian Westphal

ngircd: discard supplementary group ids on startup

The intention was to switch to JUST uid:gid, but setgid is not sufficient. Reported-by: Michael Scherer <misc@zarb.org>


46d43dc09c Alexander Barton

Xcode: update project settings for Xcode 5


44698e44e8 Alexander Barton

Merge branch 'bug159-WebircIPA'

* bug159-WebircIPA: Introduce Free_Client() function to free CLIENT structure Save client IP address text for "WebIRC" users


0ff33777fe Alexander Barton

Introduce Free_Client() function to free CLIENT structure


2bacb8210b Alexander Barton

Implement new configuration option "DefaultUserModes"

The new configuration option "DefaultUserModes" lists user modes that become automatically set on new local clients right after login. Please note that only modes can be set that the client could set on itself, you can't set "a" (away) or "o" (IRC Op), for example! User modes "i" (invisible) or "x" (cloaked) etc. are "interesting", though. Default: set no modes (like without this patch). Closes bug #160.


1dc93286a0 Alexander Barton

Save client IP address text for "WebIRC" users

This patch introduces a new field in the CLIENT structure, "ipa_text", which points to an optional textual representation of the client IP address (or NULL) which can be used to store the "real" IP address information of a client using the "WEBIRC" protocol. Without this patch, ngIRCd ignored the <ip-address> paramater ... In addition, the functions Client_SetIPAText() and Client_IPAText() have been introduced to set and get the textual representation of the client IP address. Client_IPAText() can be used even when no "IP address text" has been set before, it then returns the real IP address of the connection. Closes bug #159.


3b65f4e38d Federico G. Schwindt

Change strdup() to strndup()


6ac5a82eec Federico G. Schwindt

private strndup() implementation in case libc does not provide it


086cf3a272 Federico G. Schwindt

Cosmetic changes to METADATA

Update certfp and sort entries.


8d01be7bbd Federico G. Schwindt

Silence warning

Cast the result of the operation to long, not the time(NULL) call. On systems where sizeof(time_t) is other than long this will produce a warning.


eb86d234f8 Federico G. Schwindt

Plug memory leak


3af0ece2bc Federico G. Schwindt

Implement account login support

This is done via the `accountname' METADATA command and used to automatically identify users after netsplits or across service restarts.


a9ffbdea3f Federico G. Schwindt

Fix spelling


6dc5471a75 Alexander Barton

ngIRCd Release 20.3

(cherry picked from commit bb6e2779636aa6d74bbff474880829f0183a3c94) Conflicts: ChangeLog NEWS


309122017e Alexander Barton

Correctly handle return code of Handle_Write()

There have been code paths that ignored the return code of Handle_Write() when sending "notice auth" messages to new clients connecting to the server. But because Handle_Write() would have closed the client connection again if an error occurred, this would have resulted in new errors and assert()'s later on that could have crashed the server (denial of service). Only setups having the configuration option "NoticeAuth" enabled are affected, which is not the default. CVE-2013-5580.


8f530eb315 Alexander Barton

Enhance log messages on "recursive" connection errors


d56341c77b Alexander Barton

Add some assert() calls to ng_ipaddr library


212d99146d Alexander Barton

Update ChangeLog file


e2f09213bc Alexander Barton

Debian init script: test for binary after reading defaults

This allows the system administrator to overwrite the DAEMON variable in /etc/defaults/<name> and to use this init script even when the default "/usr/sbin/ngircd" doesn't exist on the system.


c8b12af1d2 Alexander Barton

Merge branch 'ssl-log-messages'

* ssl-log-messages: Make SSL-related log messages more readable ConnSSL_HandleError: Code cleanup, more documentation


a919e02ba1 Alexander Barton

Make SSL-related log messages more readable

- Don't use internal function names but describe the error. - Streamline wording, use "SSL" for SSL and TLS. - Streamline punctuation.


b081cfb628 Federico G. Schwindt

Use _IRC_ARGC_BETWEEN_OR_RETURN_ when possible


dd4c60cf39 Alexander Barton

ConnSSL_HandleError: Code cleanup, more documentation


4828bae8d3 Alexander Barton

Change log level of "SSL connection shutting down"


cd38e9580e Federico G. Schwindt

Fix 2 bugs introduced in 74514b8c23

Channel_Modes() and Channel_Topic() return static memory that is zeroed at creation time. Fix checking for empty modes and topic so they're propagated correctly.


aeebde4642 Alexander Barton

configure: Don't quote IO backend type(s)

It's not needed and inconsistent compared to the other settings. Reported by "allerbest" (Götz Hoffart) on #ngircd, thanks!


298158501d Alexander Barton

IRC_SERVER(): Code cleanup


904c8a4375 Alexander Barton

Introduce new function IRC_WriteErrClient()

This function is used to send "error messages", including numerics, back to clients and to automatically enforce a 2 second penalty. With this patch, all error results enforces a delay for the client. All callers of IRC_WriteStrClient(ERR_xxx) have been converted. Please note that this patch prolongs the time "make check" needs to complete its tests, because of lots of new enforced penalties ...


b86e33ef49 Alexander Barton

irc-macros.h: Update copyright, don't forget contributors!



08d49a8fa0 Alexander Barton

Fix return code of some IRC_WriteXXX() functions

These functions usually write to more than one target, and therefore can't return value indicating success or failure in a sane way. And, even more omportant, these functions should send to as much as possible clients and not stop at the first client which isn't reachable any more!


8f5cbe51a7 Alexander Barton

Streamline punctuation of log messages

See commit d38d153f for details.


bd0de15d31 Alexander Barton

Update NEWS and ChangeLog files


fcdb5cf8dd Federico G. Schwindt

More spelling corrections


7db8481500 Federico G. Schwindt

Inline who_flags_status


74514b8c23 Federico G. Schwindt

Convert more code to use Channel_HasMode


c74115f25c Federico G. Schwindt

Simplify mode checking on channels and users within a channel

Add Channel_HasMode() and Channel_UserHasMode() and use it where possible.


672a167963 Federico G. Schwindt

Use Client_HasMode and Client_HasFlag where appropriate


139f5961a0 Alexander Barton

Merge branch 'bug152-AllowedChannelTypes'

* bug152-AllowedChannelTypes: Implement new configuration option "AllowedChannelTypes" Introduce "CHANTYPES" #define


5258fb7f7c Alexander Barton

Implement new configuration option "AllowedChannelTypes"

The new configuration variable "AllowedChannelTypes" lists all allowed channel types (channel prefixes) for newly created channels on the local server. By default, all supported channel types are allowed. If set to the empty string, local clients can't create new channels at all, which equals the old "PredefChannelsOnly = yes" setting. This patch deprecates the "PredefChannelsOnly" variable, too, but it is still supported and translated to the apropriate "AllowedChannelTypes" setting. When "PredefChannelsOnly" is processed, a warning message is logged. Closes bug #152.


15dfdaac82 Federico G. Schwindt

More spelling fixes

Remove superflous comments, mostly in German. Fix spelling and use american variants for consistency.


bb8d207efa Federico G. Schwindt

Change cloaked hostname to be malloc'd on demand

This shaves a few bytes when cloaked hostnames are not used and restricts the cloakhost announcement iif there is something to send.


5e775a3fae Alexander Barton

Introduce "CHANTYPES" #define

This #define lists all the prefix characters of all supported channel types, this is "#&+" at the moment.


e03d8eb728 Federico G. Schwindt

Add Client_HasFlag() to check if a client has certain flag


69ce65bacb Alexander Barton

Merge remote-tracking branch 'fgsch/certfp'

* fgsch/certfp: Simplify MOTD handling Add certificate fingerprint support


a95d3e05e7 Federico G. Schwindt

Fix spelling


bf8e03c466 Federico G. Schwindt

Simplify MOTD handling

Merge Show_MOTD_Start, Show_MOTD_Sendline and Show_MOTD_End into IRC_Show_MOTD.


4ec19c0332 Alexander Barton

Update irc-server.c to use irc-macros.h

And add some comments :-)


646a97de5f Federico G. Schwindt

Rename XXX_Fingerprint to XXX_CertFp


1254d315b9 Federico G. Schwindt

Add certificate fingerprint support


61a6691b36 Alexander Barton

Commands.txt: Update more descriptions

Update description of "CHANINFO", "METADATA", "NJOIN", "SERVER", "SQUIT", "GET", and "POST".


8e60fac73b Federico G. Schwindt

Improved client announcement

Move Announce_User() to client.c and rename it to Client_Announce(). Use this in cb_introduceClient() instead of duplicating the code. This fix the certificate fingerprint announcement for new clients. Also ensure the certificate fingerprint is only announced if the client supports it (`M' flag).


78c8212280 Alexander Barton

Update irc-oper.c to use irc-macros.h


313881d0c1 Alexander Barton

Add penalty times in error paths of generic IRC helper macros

Add a 2 second penalty time when the number of parameters is invalid.


adc8d4f6c8 Alexander Barton

Commands.txt: Update more descriptions

Update description of "CONNECT", "DIE", "DISCONNECT", "GLINE", "KILL", "KLINE", "OPER", "REHASH", "RESTART" and "WALLOPS".


3bd973037a Alexander Barton

Add more penalty times in error paths

This patch changes the handlers of the "PASS", "NICK", "USER", and "SERVICE" commands to enforce a 2 second penalty when an error like "need more/other parameters" occurs. More functions should follow, I think ...


24183b1a91 Alexander Barton

Commands.txt: Fix <target> description of TRACE command


f494023b0d Alexander Barton

Update irc-login.c to use irc-macros.h

This includes code cleanups, too :-)


888c524683 Alexander Barton

Update irc-mode.c to use irc-macros.h

This includes code cleanups and more comments, too.


659d126460 Alexander Barton

Commands.txt: Update more descriptions

Update descriptions of "NICK", "PASS", "PING", "PONG", "QUIT", "USER", "WEBIRC", "SERVICE", and "SVSNICK".


ae0af66d50 Alexander Barton

Update irc-channel.c to use irc-macros.h

This includes code cleanups, too :-)



a8ecde2553 Alexander Barton

Commands.txt: Update more descriptions

Update descriptions of "AWAY", "JOIN", "LIST", "MODE", "PART", "TOPC", and "TRACE".


4cb2edf020 Alexander Barton

Add "compile" to .gitignore file


fef10f590b Alexander Barton

Commands.txt: Streamline references to IRC+ protocol


720eb874a9 Alexander Barton

Commands.txt: Update description of the "ERROR" command


771e539c18 Alexander Barton

Show IRC Operator name when logging a successful OPER command


fa15eb1698 Alexander Barton

Update irc.c to use irc-macros.h

This includes code cleanups and better documentation for some functions, too.


b54e664a63 Alexander Barton

Merge pull request #4 from fgsch/master

Changes for ngircd 21.


7adc4b8e99 Federico G. Schwindt

Handle services in IRC_WHOIS_SendReply()

If the target is a service, advertise it as such and ignore operator mode.


5115756b79 Alexander Barton

Slightly update ngircd.8 manual page


5021977bb1 Federico G. Schwindt

Fix spelling


f6ac0d89ae Alexander Barton

Travis-CI: Enable OpenSSL and libiconv support


11240376a5 Alexander Barton

Updated NEWS and ChangeLog files


e377f4ea47 Alexander Barton

Enhance Travis-CI configuration file

It now configures the sandbox to build ngIRCd with IPv6, IDENT, PAM, TCP-Wrappers, and zlib support. And it installs expect(1) and telnet(1) for the test suite.


9d3800fd15 Alexander Barton

Merge pull request #3 from Cofyc/master

irc-info.c: some commands use LINE_LEN as command buffer len


4f525d39d4 Yecheng Fu

LINE_LEN -> COMMAND_LEN

LINE_LEN is configuration file line length


7ea3864a93 Alexander Barton

IncludeDir: default to "$SYSCONFDIR/ngircd.conf.d"

Now "IncludeDir" defaults to "$SYSCONFDIR/ngircd.conf.d" instead of no directory, but a missing directory is only reported as an error if it has explicitely configured in the main configuration file and simply ignored otherwise. Therefore it is now possible not to touch the default (sample) configuration file at all, and set all distribution and/or system specific configuration options in "*.conf" files stored in "$SYSCONFDIF/ngircd.conf.d/". Thanks to "Elmasloco" for the idea!


891dbd2acc Alexander Barton

"IncludeDir" can't be overwritten by included files


27fd92d580 Alexander Barton

Rename "Mask" variables into "Pattern" in assert() statements

This completes commit 3ab00e3a11 which broke debug builds.


f206fda8ae Alexander Barton

Implement new configuration option "IncludeDir"

The option "IncludeDir" in the [Options] section can be used to specify a directory which can contain further configuration files and configuration file snippets matching the pattern "*.conf" that should be read in after the main configuration file ("ngircd.conf" by default) has been parsed. Closes bug #157.


51e5ba94b3 Federico G. Schwindt

Ensure there is enough space for the mask

As pointed by Alex while strl{cat,cpy} take the full length we need to leave space to ensure a proper mask is always created so revert the removal of - N from my last change.


6beb0fad3f Alexander Barton

conf.c: New function Read_Config_File()

This function reads in and parses a single configuration file. Adjust all other functions to display the correct name of the file being read in currently.


b4d0a40383 Federico G. Schwindt

Better description for Lists_CheckReason()


3ab00e3a11 Federico G. Schwindt

Change Lists_MakeMask() to receive a buffer for the mask

Change callers accordingly so they don't rely on a global buffer and rename Mask to Pattern where it makes sense since some functions where indeed receiving a pattern and not a mask.


cde2e8a277 Federico G. Schwindt

Fix use-after-free on Lists_CheckReason()

Change Lists_CheckReason() to receive a buffer where the reason will be stored and its length. Change callers accordingly. Change Class_GetMemberReason() (and its callers) in a similar way so it doesn't rely on a global buffer for the rejected reason.


528c8fc244 Alexander Barton

Update doc/Platforms.txt a little bit ...


7f9bce705c Alexander Barton

Build OS X package with correct file permissions

This requires to have the correct permissions in the source tree, which is "root:wheel", which in turn requires root privileges. Therefore the Makefile now tries to become root on "make osxpkg-dest" but tries hard not to require root privileges on "clean" etc.


ce3e41cf4c Alexander Barton

Xcode: fix detection of host OS, vendor, and CPU


dd6a058992 Alexander Barton

PackageMaker: use relativ path names


7ed06b2189 Alexander Barton

Add Travis-CI configuration file


a14eb495b7 Alexander Barton

Make configure[.ng] compatible with autoconf 1.10 again

The incompatibility has been introduced by commit d0c9f4a6, "configure: search for iconv_open as well as libiconv_open".


0131e1e00b Sebastian Köhler

Lists_CheckReason(): Check for Client_MaskCloaked()

Look for possible cloaked Masks in Lists. Users with +x usermode can be banned with their cloaked hostname now.


8618e942e6 Alexander Barton

Services.txt: Anope 1.9.8 has been released now


2fea782efc Alexander Barton

Commands.txt: Update description of the "KILL" command


a2e26aad1e Alexander Barton

Conn_Handler(): Don't test for penalty times

The Conn_Handler() main loop calls Handle_Buffer() which checks for the "penalty time" of each client itself, so don't do it twice.


b4393277ea Alexander Barton

Don't read SSL client data before DNS resolver is finished

Fix the cb_clientserver_ssl() callback function to not read in and store SSL encrypted client data before the asynchronous DNS resolver sub-process has finished: This could have resulted in discarding the resolved client hostname and IDENT reply afterwards, because in some situations (timing dependent) the NICK and USER commands could have already been read in from the client, stored in the buffer, and been processed. Thanks to Julian Brost for reporting the issue and testing, and to Federico G. Schwindt <fgsch@lodoss.net> for helping to debug it!


b33da9b8f3 Alexander Barton

Increase password length limit to 64 characters

Closes bug #154.


3e35857080 Alexander Barton

doc/Services.txt: Update Anope status and URL


b25fd8a98c Alexander Barton

Commands.txt: Update description of the "KICK" command


be08349dcb Alexander Barton

Commands.txt: Update description of the "INVITE" command


3228f1b267 Alexander Barton

irc-op.c: use irc-macros.h


a53de63ba7 Alexander Barton

irc-cap.c: use irc-macros.h


e8f512bfe7 Alexander Barton

irc-op.c: Update source code documentation


bb31d7b88c Alexander Barton

irc-cap.c: Update source code documentation


7f99f7c14f Alexander Barton

Add new _IRC_ARGC_EQ_OR_RETURN_ macro to irc-macros.h


883a8fa6f1 Alexander Barton

Add new _IRC_ARGC_BETWEEN_OR_RETURN_ macro to irc-macros.h


a7b04ce6cf Alexander Barton

irc-cap.c: move static functions to the top of the file

And remove now unnecessary (local) prototypes.


bd1b727187 Alexander Barton

Update Doxygen configuration



0f0f4f41b8 Alexander Barton

src/testsuite/README: add whois-test.e


221365d8ef Alexander Barton

irc-login.c: conenction -> connection

Introduced by commit d3ef2239 as of Sun Jan 16 2011 ... Thanks to Patrik Schindler <poc@pocnet.net> for reporting this!


2c96966431 Alexander Barton

Merge branch 'bug151-iconv' into master

* bug151-iconv: configure: search for iconv_open as well as libiconv_open


65359ff8f7 Alexander Barton

Merge branch 'bug153-ServerMask' into master

* bug153-ServerMask: Update irc-info.c to use irc-macros.h Add new irc-macros.h to project irc-info.c: add/streamline function documentation comments irc-info: move static functions at the top of the file Implement new function Client_SearchServer() Conflicts: src/ngircd/irc-info.c


d0c9f4a692 Alexander Barton

configure: search for iconv_open as well as libiconv_open

On some installations iconv_open() is actually libiconv_open(). iconv_open() is the glibc version while libiconv_open() is the libiconv version. This patch enables ngIRCd to detect both cases. Tested on OpenBSD 5.1. Closes bug #151.


d5763937ad Alexander Barton

configure: conversation -> conversion


5dce3301bd Alexander Barton

Update irc-info.c to use irc-macros.h

This includes: - move IRC_SetPenalty() at the beginning of the handler functions, - use macros provided by irc-macros.h, - code cleanup. The main benefits of this patch are core size reduction, streamlined structure of the handler functions, and enhanced functionality: because of the _IRC_GET_TARGET_SERVER_OR_RETURN_() macro using the Client_SearchServer() function, the target of the specific IRC command can now be given server names, server mask, or the nickname of a user connected to the server. Closes bug #153.


25b19e08e2 Alexander Barton

ngIRCd Release 20.2

(cherry picked from commit c45d9dd1f08fddb95fa01d62c69848cd753a3161)


a917514546 Alexander Barton

Add new irc-macros.h to project

This file prvides some macros for common tasks required by functions implementing handlers for IRC commands: * _IRC_ARGC_LE_OR_RETURN_ * _IRC_ARGC_GE_OR_RETURN_ * _IRC_GET_SENDER_OR_RETURN_ * _IRC_GET_TARGET_SERVER_OR_RETURN_


0e63fb3fa7 Sebastian Köhler

KICK: Fix denial of service bug

Test if the user that it is to be kicked is on the channel before user channel modes are tested. Otherwise assert( cl2chan != NULL ); in line 742 would fail and stop the service.


4dc940f59e Alexander Barton

irc-info.c: add/streamline function documentation comments

Add missing comments, streamline wording, and remove references to the RFCs: this will be added to ./doc/Commands.txt with an other patch and we want to avoid redundancy ...


3e72331896 Alexander Barton

sighandlers.c: Update some log messages


5facf5c15e Alexander Barton

irc-info: move static functions at the top of the file


1438771124 Alexander Barton

my_sd_listen_fds(): really return an "int"

This fixes the following warning using Apple LLVM version 4.2 (clang-425.0.24) on OS X: src/ngircd/conn.c:157:9: Implicit conversion loses integer precision: 'long' to 'int'


0ad0fe207a Alexander Barton

Implement new function Client_SearchServer()

This function returns the server structure of a client or a given "mask"; it is useful for implemention handlers for commands like "COMMAND *.net", which should work on a server matching "*.net". Please note that the local server is always returned when it matches the mask, but besides that, the order is completely arbitrary.


b95dfb3ffd Alexander Barton

Merge branch 'bug155-allowAtInUser'

* bug155-allowAtInUser: Allow "@" character in user names for authentication


999c11ad49 Alexander Barton

Exit message: use singular & plural :-)


4b15f10fbb Alexander Barton

Allow "@" character in user names for authentication

The "@" character isn't allowed in IRC usernames, because it is the separator between user name and hostname in IRC masks: <nickname>!<username>@<hostname> This patch accepts user names including "@" characters, saves the unmodified name for authentication but stores only the part in front of the "@" character as "IRC user name". And the latter is how ircd2.11, Bahamut, and irc-seven behave as well. Closes bug #155.


628c14d656 Alexander Barton

Merge branch 'systemd'

* systemd: ngircd.sock: explicitely bind to IPv4 and IPv6 addresses Show address and port of sockets passed-in by systemd(8) Check type of sockets passed-in by systemd(8) Adjust severity levels of some log messages New configuration option "IdleTimeout": exit daemon when idle Implement support for systemd(8) "socket activation" contrib/README: add more files


c891b5f250 Alexander Barton

autogen.sh: Check for autoconf/automake wrapper scripts

For example OpenBSD uses a "autoconf" and "automake" wrapper script which tells the user to set AUTOCONF_VERSION and AUTOMAKE_VERSION environment variables. This patch enhances autogen.sh to not detect these wrapper scripts as regular autoconf/automake commands but to set the required environment variables after detecting the real "command-X.Y" commands. Tested on OpenBSD 5.1.


2cb7023e28 Alexander Barton

ngircd.sock: explicitely bind to IPv4 and IPv6 addresses


ac32d07aaf Alexander Barton

Commands.txt: spelling fixes ...


1e8b775a7a Alexander Barton

"WHO <hostmask>": use displayed hostname for matching

Use the currently "displayed hostname" (which can be cloaked!) for hostname matching, not the real one. In other words: don't display all the cloaked users on a specific real hostname! Thanks to DNS <dns@rbose.org> for reporting this issue.


419ff38a07 Alexander Barton

autogen.sh: Don't use "egrep -o", use "sed"

"egrep -o" isn't portable and not available on OpenBSD, for example. So let's use sed instead to get the automake version. The expression used now is less specific but should work as well ...


69c3f96998 Alexander Barton

Show address and port of sockets passed-in by systemd(8)


7fce719142 Alexander Barton

Merge branch 'HelpText'

* HelpText: (22 commits) Commands.txt: Update description of the "USERS" command Commands.txt: Update description of the "SUMMON" command Commands.txt: Update description of the "SERVLIST" command Commands.txt: Update description of the "WHOWAS" command Commands.txt: Update description of the "WHOIS" command Commands.txt: Update description of the "WHO" command Commands.txt: Update description of the "VERSION" command Commands.txt: Update description of the "USERHOST" command Commands.txt: Update description of the "TIME" command Commands.txt: Update description of the "STATS" command Commands.txt: Update description of the "NAMES" command Commands.txt: Update description of the "MOTD" command Commands.txt: Update description of the "LUSERS" command Commands.txt: Update description of the "LINKS" command Commands.txt: Update description of the "ISON" command Commands.txt: Update description of the "INFO" command Commands.txt: Update description of the "ADMIN" command Commands.txt: Add description for the "CHARCONV" command Commands.txt: Add description for the "CAP" command Commands.txt: Import descriptions from "rbose/command_help" ...


f16d230530 Alexander Barton

Rename ports_initlisteners() to Init_Listeners()


8d8201502f Alexander Barton

IRC_WHO_Channel(): Use strlcpy() instead of strcpy()

This fixes the following warning, at least on OpenBSD 4.8: irc-info.o(.text+0x2427): In function `IRC_WHO': src/ngircd/irc-info.c:896: warning: strcpy() is almost always misused, please use strlcpy()


5c6875d768 Alexander Barton

Check type of sockets passed-in by systemd(8)

This patch makes sure that ngIRCd doesn't try to handle sockets of unsupported types, for example of AF_INET6 sockets when ngIRCd isn't compiled with support for IPv6 ...


cb7e4e8679 Alexander Barton

Commands.txt: Update description of the "USERS" command


3a3b3225d4 Alexander Barton

NewListener(): Code cleanup


d38d153f51 Alexander Barton

Streamline punctuation of log messages

Make sure that all log messages end with a correct punctuation mark. The rules for formatting log messages are: 1. Add punctuation marks to all messages passed to the actual logging functions like Log() and LogDebug(). 2. Don't add any punctuation marks to messages that are stored in variables for later use or are passed over the network. 3. IP addresses, DNS host names and IRC server names should be quoted. 4. Messages originating in the network should be quoted (at least if they are "untrusted" or variable). Most probably this patch doesn't fix all mistakes, but it should be a good starting point ...


a78c7b3898 Alexander Barton

Adjust severity levels of some log messages


35452b3157 Alexander Barton

Commands.txt: Update description of the "SUMMON" command


84a599ece4 Alexander Barton

Enable WHOIS to display information about IRC Services

This patch introduces the new numeric 310(RPL_WHOISSERVICE) and enables WHOIS to display information about IRC services. This numeric is used for this purpose by InspIRCd, for example -- but as usual, other numerics are in use, too, like 613 in UltimateIRCd ... Please note that neither the Operator (+o) not the "bot status" (+B) of an IRC service id displayed in the output. Change suggested by Federico G. Schwindt <fgsch@lodoss.net>, Thanks.


fd260404ca Alexander Barton

configure: "netinet/in_systm.h" is optional

The header file "netinet/in_systm.h" already is optional in ngIRCd, so don't require it in the configure script. Now ngIRCd can be built on Minix 3 again :-)


e90d30a2cc Alexander Barton

Commands.txt: Update description of the "SERVLIST" command


f295117fba Alexander Barton

New configuration option "IdleTimeout": exit daemon when idle

This patch implements a new configuration option "IdleTimeout" in the [Limits] section of the configuration file which can be used to set a timeout (in seconds) after which the whole daemon will shutdown when no more connections are left active after handling at least one client. The default is 0, "never". This can be useful for testing or when ngIRCd is started using "socket activation" with systemd(8), for example.


a551942635 Alexander Barton

contrib/Debian/rules: Do no compress Commands.txt

This is required, because ngIRCd can't use a compressed file as help text ... (cherry picked from commit 6d09b4f366f656f6d2732ea96a653e086380e458)


45ab73ac81 Alexander Barton

Commands.txt: Update description of the "WHOWAS" command


8ab097afb7 Alexander Barton

Implement support for systemd(8) "socket activation"

This patch enables ngIRCd to work with listening sockets already initialized and passed-in by systemd(8) and hereby to support on-demand "socket activation". systemd(8) uses two environment variables to pass information about the sockets to ngIRCd, LISTEN_PID and LISTEN_FDS, and this mechanism only kicks in when both variables are set. In all other cases, and therefore in most installations out there, nothing changes at all. Please note: If socket activation is in effect, ngIRCd will not initialize any (other) soeckets on its own! All sockets must be configured in the systemd(8) socket unit configuration file in this case, see ./contrib/ngircd.socket for example. Probably it would be interesting to match passed-in sockets to configured listening sockets and to initialize all the remaining ones not already set up by systemd(8), but this is kept back for an other patch ... See - <http://0pointer.de/blog/projects/socket-activation.html> - <http://0pointer.de/blog/projects/socket-activation2.html> - <http://www.freedesktop.org/software/systemd/man/systemd.socket.html>


b60d5a0a11 Alexander Barton

AUTHORS: Update list of contributors


78978994df Alexander Barton

Commands.txt: Update description of the "WHOIS" command


84e24afd2f Alexander Barton

contrib/README: add more files


fae0054d31 Alexander Barton

AUTHORS: Use "email address syntax"


19cb29da51 Alexander Barton

Commands.txt: Update description of the "WHO" command


3d49e8ac84 Alexander Barton

ngircd.service: Use "forking" service type

Don't run ngIRCd in forground mode but let it daemonize itself. This enhances the log output of "systemctl status ngircd.service", because now ngIRCd doesn't print out its PID and timestamp on each log message which is redundant: it becomes logged by systemd/journald already.


6ed3b6f85c Alexander Barton

Commands.txt: Update description of the "VERSION" command


508ca3044d Alexander Barton

Return better "Connection not registered as server link" errors

Now ngIRCd returns a more specific error message for numeric ERR_NOTREGISTERED(451) when a regular user tries to use a command that isn't allowed for users but for servers: ERR_NOTREGISTEREDSERVER(451).


5b8f13a4a9 Alexander Barton

Commands.txt: Update description of the "USERHOST" command


d8f2964710 Alexander Barton

MODE: don't report error on "more modes than parameters"

Don't report ERR_NEEDMOREPARAMS(461) when a MDOE command with more modes than nicknames is handled, as well as for channel limit and key changes without specifying the limit or key parameters. This is how a lot (all?) other IRC servers behave, including ircd2.11, InspIRCd, and ircd-seven. And because of clients (tested with Textual and mIRC) sending bogus MODE commands like "MODE -ooo nick", end-users got the expected result as well as correct but misleading error messages ... If ngIRCd is compiled using "strict mode", these errors are still reported. Reported-by: Tim <tim@stackwatch.net>


b6e6e2e1da Alexander Barton

Commands.txt: Update description of the "TIME" command


ab00997698 Alexander Barton

Correctly detect when SSL subsystem must be initialized

This patch introduces the new function Conf_SSLInUse() to check when the current server configuration requires the SSL subsystem to be initialized and accounts incoming as well as outgoing connections -- so this fixes commit bb20aeb9 ("Initialize SSL when needed only, and disable SSL on errors") which only handled the inbound case ... Tested-by: Brett Smith <brett@w3.org>


7c7fc8b5c4 Alexander Barton

Commands.txt: Update description of the "STATS" command


b4966aa1bd Alexander Barton

configure: use AS_HELP_STRING for --with-iconv


1a5e08f3f6 Alexander Barton

Commands.txt: Update description of the "NAMES" command


0703fcd719 Alexander Barton

autogen.sh: Enforce serial test harness on automake >=1.13


e051ea06fc Alexander Barton

Commands.txt: Update description of the "MOTD" command


4594583f52 Alexander Barton

autogen.sh: Reformat messages.


a7023113e7 Alexander Barton

Commands.txt: Update description of the "LUSERS" command


68cb1a8c2e Alexander Barton

Merge branch 'bug145-ProvideHelp'

* bug145-ProvideHelp: Use "${docdir}/Commands.txt" as help text file Add a note that "help file" is updated on startup and REHASH only Add doc/Commands.txt which should document all commands Implement Help() function parsing and returning the help text Document "HelpFile" in sample-ngircd.conf and ngircd.conf.5 Implement new configuration option "HelpFile" IRC_HELP(): Code cleanup Refactor Read_Motd() into Read_TextFile()


02e24f5d1e Alexander Barton

Commands.txt: Update description of the "LINKS" command


21493731df Alexander Barton

ngIRCd Release 20.1 (tags/rel-20.1)


950aeec3ff Alexander Barton

Use "${docdir}/Commands.txt" as help text file


13740c1bf4 Alexander Barton

Commands.txt: Update description of the "ISON" command


1f59821270 Alexander Barton

Update Copyright notices for 2013



8212b730c7 Alexander Barton

Commands.txt: Update description of the "INFO" command


8ec09e3ca4 Alexander Barton

Add doc/Commands.txt which should document all commands

This document can be used as "help text", too, see configuration option "HelpFile" in ngircd.conf(5). Please note that this file in its current state is far from complete, only a few commands are documented, but you should get an idea how it works. So please send in patches adding the remaining parts! :-)


3e47bc9af5 Alexander Barton

Allow ERROR command on server and service links only

Ignore it and add a penalty time on all other link types.


a4daa613ae Alexander Barton

Commands.txt: Update description of the "ADMIN" command


289a26e9e4 Alexander Barton

Implement Help() function parsing and returning the help text

This function parses the already read in help text and sends the requested portions to the user. Parsing is done as following when a user user issues a "HELP <cmd>" command: 1. Search the file for a line "- <cmd>", 2. Output all subsequent lines that start with a TAB (ASCII 9) character to the client using NOTICE commands, treat lines containing a single "." after the TAB as empty lines. 3. Break at the first line not starting with a TAB character. This format allows to have information to each command stored in this file which will not be sent to an IRC user requesting help which enables us to have additional annotations stored here which further describe the origin, implementation details, or limits of the specific command. A special "Intro" block is returned to the user when the HELP command is used without a command name.


5d92198487 Alexander Barton

Get rid of Conn_ResetPenalty(), it is unused


b7690a0add Alexander Barton

Commands.txt: Add description for the "CHARCONV" command


d2a1f6aa4b Alexander Barton

Document "HelpFile" in sample-ngircd.conf and ngircd.conf.5


20ddffca0d Alexander Barton

Mode setting: only check channel user modes when on channel

Only check the channel user modes of the initiator if he is joined to this channel and not an IRC operator enforcing modes (which requires the configuration option "OperCanUseMode" to be enabled), because trying to check channel user modes of a non-member results in this assertion: Assertion failed: (cl2chan != NULL), function Channel_UserModes, file channel.c, line 742. This closes bug #147, thanks to James Kirwill <james.kirwill@bk.ru> for tracking this down!


18ecc2fd81 Alexander Barton

Commands.txt: Add description for the "CAP" command


f68aa02272 Alexander Barton

Implement new configuration option "HelpFile"

This new configuration option allows to specify a specially formatted text file which can be used by the HELP command to provide information about the commands and their syntaxes.


25e56a5e83 Alexander Barton

Add some more casts in assert() statemens

This fixes the following warning messages of gcc 4.5.3 on Cygwin when building with debug code enabled: ng_ipaddr.c: In function ‘ng_ipaddr_init’: ng_ipaddr.c:52:2: warning: comparison between signed and unsigned integer expressions ng_ipaddr.c:53:20: warning: comparison between signed and unsigned integer expressions resolve.c: In function ‘ForwardLookup’: resolve.c:271:3: warning: comparison between signed and unsigned integer expressions


73fded7515 Alexander Barton

Commands.txt: Import descriptions from "rbose/command_help"

Import command description texts from the "rbose/command_help" branch, which have been written by DNS <dns@rbose.org> -- thanks a lot!


588af510a3 Alexander Barton

IRC_HELP(): Code cleanup


1e5a7aac87 Alexander Barton

Makefiles: Correctly quote sed expressions

Now the Makefiles support spaces in "$sysconfdir", which isn't uncommon for Cygwin for example, when $HOME contains whitespaces ("/home/User Name") and ngIRCd is installed into the user home ("./configure --prefix=$HOME").


7630e8ffc6 Alexander Barton

Commands.txt: Reorder some commands

Reorder some commands and introduce new section "Connection Handling". Idea by DNS <dns@rbose.org>, thanks!


9e1c25a889 Alexander Barton

Refactor Read_Motd() into Read_TextFile()

Now this function allows to read arbitrary text files into arrays.


b5b3dd9cfd Alexander Barton

Add Cygwin binaries (*.exe) to .gitignore files


4552ad5269 Alexander Barton

Commands.txt: Fix some wording and spelling


92fba63ad8 Alexander Barton

Add a cast in ForwardLookup() to fix a gcc warning on Cygwin

This fixes the following warning message of 4.5.3 on Cygwin: resolve.c: In function ‘ForwardLookup’: resolve.c:273:21: warning: comparison between signed and unsigned integer expressions


25d35dd6f4 Alexander Barton

ngIRCd Release 20 (tags/rel-20)


a445abc10e Alexander Barton

Update NEWS and ChangeLog files


1342f78b09 Alexander Barton

Allow user names up to 20 characters

This patch allows user names up to 20 characters when ngIRCd has not been configured for "strict RFC mode". Patch suggested by Brett Smith <brett@w3.org>, see <http://arthur.barton.de/pipermail/ngircd-ml/2012-October/000579.html>.


a0d57a6afd Alexander Barton

ngIRCd 20~rc2 (tags/rel-20-rc2)


c6ae353756 Alexander Barton

Update NEWS and ChangeLog files


12768e7a54 Alexander Barton

Update doc/Platforms.txt


35e2dcff88 Alexander Barton

Rework cloaked hostname handling, implement "METADATA cloakhost"

Now ngIRCd uses two fields internally, one to store the "real" hostname and one to save the "cloaked" hostname. And both fields can be set independently using the "METADATA host" and "METADATA cloakhost" commands. This allows "foreign servers" (aka "IRC services") to alter the real and cloaked hostnames of clients without problems, even when the user itself issues additional "MODE +x" and "MODE -x" commands.


dc89e42ef5 Alexander Barton

RPL_UMODEIS: send correct target name, even on server links


4a2d74c9ab Alexander Barton

Client_HostnameCloaked() -> Client_HostnameDisplayed()


cd48b8128e Alexander Barton

platformtest.sh: Only generate configure script when missing


301d4915bc Alexander Barton

Update platformtest.sh to follow autoconf changes


8061056cec Alexander Barton

Test suite: correctly execute tests when stdout is redirected


44926b7f9f Alexander Barton

Add a few casts, fix compiler warnings on NetBSD 5

This fixes a few warnings of this type: XXX.c: In function 'AAA': XXX.c:YY: warning: array subscription has type 'char' Tested on NetBSD 5.0.2 with gcc 4.1.3.


d11a700589 Alexander Barton

irc-info.c: Use strlcpy() instead of strcpy()

This fixes the following warning of gcc (tested on OpenBSD 5.0:) irc-info.c:990: warning: strcpy() is almost always misused, please use strlcpy


0a26079af2 Alexander Barton

ngIRCd 20~rc1 (tags/rel-20-rc1)


b6e49f3920 Alexander Barton

Update Xcode project files


4123118d5a Alexander Barton

conf.c: Use strlcpy() instead of strcpy()

This fixes the following warning of gcc on OpenBSD 5.0: conf.c:728: warning: strcpy() is almost always misused, please use strlcpy()


e29d198700 Alexander Barton

tool.h: Don't check for and #define PF_INET

This is correctly handled by ipaddr/ng_ipaddr.h today, and the check in tool.h isn't required any more -- and caused errors on OpenBSD 5.0: In file included from ./../tool/tool.h:23: /usr/include/arpa/inet.h:74: warning: "struct in_addr" declared inside parameter list


6f531a3c99 Alexander Barton

conf-ssl.h: Use "gnutls_session_t" instead of "gnutls_session"

This fixes the following warning with current versions of GnuTLS: conf-ssl.h:36: warning: "gnutls_session" is deprecated


53917fa4b8 Alexander Barton

Add new IRC+ server flag "X": "XOP modes supported"

This flag indicates, that the server supports the enhanced "xop channel user modes", like channel owner, admin, and halfop. This information is used to make sure that no unsupported CHANINFO commands are sent to servers not supporting such mode prefixes, for example.



4185c4a44a Alexander Barton

Update NEWS and ChangeLog files


45b0bb5aff Alexander Barton

Remove Anope "ngircd" protocol module patches

Starting with Anope 1.9.8, the ngIRCd protocol module is included in the Anope distribution, so there's no longer any need to support our own (but now heavily outdated!) patches. Therefore remove them.


c7db2f8429 Alexander Barton

doc/Services.txt: Update documentation for Anope 1.9.8

Starting with Anope 1.9.8, the ngIRCd protocol module is rewritten from scratch by "DukePyrolator" and included in the Anope distribution. So no patching is required any more, yeah! Drawback: Anope 1.9.8 is in development and not yet released ...


f0b86e6c26 Alexander Barton

Correctly add irc-metadata.{c|h} to Makefile.ng ...


7871a904d7 Alexander Barton

doc/Protocol.txt: Document METADATA command


40e3daf560 Alexander Barton

Generate "METADATA host" commands on "MODE +/-x"

Use "METADATA host" commands to let servers supporting this command know which (possibly cloaked) hostname is in effect for a specific client. This prevents "double cloaking" of hostnames and even cloaked hostnames are in sync on all servers supporting "METADATA" now.


44b7ff02fd Alexander Barton

Don't cloak already cloaked hostname when using METADATA

A client for which a METADATA command has been received from one of its peers got the client flag "M" set. So it's safe to assume that such a client gets "METADATA host" commands for its cloaked hostname and the server must not cloak the hostname on its own, even when the client mode "+x" is set.


35ed57e6c1 Alexander Barton

Implement METADATA command to update client metadata

The METADATA command can be used by other servers to update "metadata" of registered clients, like the client info text ("real name"), user name, and hostname: :<prefix> METADATA <target> <key> :<value> It is distributed in the network, unknown <key> names are silently ignored and passed on, too. This allows for further extensions.


79731a57f3 Alexander Barton

doc/Protocol.txt: add/fix CHARCONV description


a7f37cebdc Alexander Barton

PredefChannelsOnly: Fix message for non pre-defined channels

If PredefChannelsOnly is enabled, and if someone tries to create a channel which does not exist, then the error message is a 474. The 474 Error message changed recently and does not match anymore: 'Cannot join channel (+b) -- You are banned'. Changed the error message to numeric 403 'No such channel'. Bug introduced by commit 9a82304a. (cherry picked from commit 2c2e08f34187a33c1da745995c5f213e33a91410)


47b99c69cc Alexander Barton

Test suite: add some "remote checks" to whois-test.e


757f3497bc Alexander Barton

Send NICK commands with prefix of (target) user

Now NICK commands are always generated using the prefix of the target user, even when the nickname change has been initiated by some other (pseudo) server or using the SVSNICK command. In this case, the prefix of the initiator has been used, but this isn't compatible with clients (at least weechat and irssi don't handle such NICK commands correctly).


f2455cbe33 Alexander Barton

Update doc/Services.txt, sort services alphabetically


e3f300d323 Alexander Barton

Implement SVSNICK command to change remote nicknames

The SVSNICK command allows other servers (and services on "pseudo-servers") to forcefully change nicknames of remote users. Syntax: ":<from> SVSNICK <oldnick> <newnick>" The SVSNICK command itself doesn't change the nickname, but it becomes forwarded to the server to which the user is connected to. And then this server initiates the real nickname changing using regular NICK commands. This allows to still run networks with old servers not supporting the SVSNICK command, because SVSNICK commands for nicknames on such servers are silently ignored and don't cause a desync of the network.


497edbaf3e Alexander Barton

IRC_NICK(): Code cleanup, new function Change_Nick()


48326e061a Alexander Barton

Spelling fix: "nick name" -> "nickname"


84e9dcbab0 Alexander Barton

Xcode: correctly #define PACKAGE and PACKAGE_NAME


30b32e84fe Alexander Barton

Fix warning message introduced when cleaning up IRC_SERVER()

This reverts a not intentional code change and fixes the following compiler warning message (tested with gcc 4.4.5): irc-server.c: In function "IRC_SERVER": irc-server.c:142: warning: suggest parentheses around operand of "!" or change "&" to "&&" or "!" to "~"


fb92493376 Alexander Barton

Make server reconnect time a little bit more random

Add randomly up to 15 seconds to the reconnect delay for outgoing server links when the connection has been "short" and therefore the "ConnectRetry" delay is being enforced. This should make it even more unlikely that two servers deadlock each other when both are trying to connect to the other one at the same time, for example in test environments.


eb4f9eac0c Alexander Barton

Don't accept connections for servers already beeing linked

If two servers try to link each other, there was a time frame that could result in one connection overwriting the other, e. g. the incoming connection overwriting the status of the outgoing one. And this could lead to all kind of weirdness (even crashes!) later on. So now such incoming connections are dropped. But this most probably prevents the two servers from linking until timing changes somehow (network latency?) because each server drops the incoming connection of the other one, so no connection survives in the end. But this has to be addressed by an other patch ...


d7b5dd1bbf Alexander Barton

IRC_SERVER(): Code cleanup


b18e81b631 Alexander Barton

Use lowercase "package name" for syslog logging again

This is how ngIRCd up to release 19.2 behaved; "bug" introduced by commit 67e882, "configure.in: require autoconf 2.67 and automake 1.11", which changed the "PACKAGE_NAME" to "ngIRCd"; so use "PACKAGE" which still is the lowercase version for initializing syslog logging.


8ff153d7d4 Alexander Barton

Document new configuration option "MaxListSize"



23572af942 Alexander Barton

Update NEWS and ChangeLog files


8d9cfa157a Alexander Barton

Allow remote servers and IRC Ops to change channel topics

Remote servers are always allowed to change all channel topics, and IRC Operators are allowed to change all channel topics if the configuration option "OperCanUseMode" is enabled. Bug introduced by commit 7b01bb8 and reported by DNS777.


58abd0777b Alexander Barton

Increased maximum number of possible user and channel modes

Currntly ngIRCd supports 13 user and 15 channel modes, because there have been quite a few additions since our last release. But our data structures can only hold 15 user and -- even worse! -- only 9 channel modes! So enlarge the buffers to 20 bytes (actually 21 including NULL) to allow storing of all mode characters and to have some space left for more modes to come ... (cherry picked from commit 8996d777621d88d4bcc439ab4792b2814920687f)


3ee98d9f72 Alexander Barton

Update error messages for user mode +b and channel Mode +M.

Replaced error message for channel mode +M with ERR_NEEDREGGEDNICK_MSG (used by Bahamut, inspircd, ircu & Unreal too) and using numeric 477 and the msg simliar like inspircd. Replaced the error message ERR_CANNOTSENDTONICK_MSG for user mode +b with ERR_NONONREG_MSG and using numeric 486, similar like unrealircd. (cherry picked from commit 55a61ab17f63a9e757b7c7598c31b98ce5a132e8 and commit 3737d9ab7da1ea0485cefc07c65dc5308bf0db02)


b1a5ade88f Alexander Barton

Test suite: add more checks to whois-test.e


73229249d8 Alexander Barton

Add "i586/pc/haiku" to doc/Platforms.txt


e0da56fc7b Alexander Barton

Disable UID/GID checks on "single user OS"

Don't abort on "single user operating systems" that don't know more than one user account and therefore can't change user and group IDs. Currently, the only such system supported by ngIRCd is Haiku, a BeOS clone.


cdaaae0cb2 Alexander Barton

Search gethostbyname() in libbind and libnetwork

This is required for Haiku (BeOS clone) at least.


c319fb8eaa Alexander Barton

Update manual pages

Among other little things, bring project description in line with website.


538e612a47 Alexander Barton

Test suite: add test for user mode "b"


9d97004a28 Alexander Barton

Implement user mode "b": block messages

When a user has set mode "b", all private messages and notices to this user are blocked if they don't originate from a registered user, an IRC Op, server or service. The originator gets an error numeric sent back in this case, ERR_CANNOTSENDTONICK_MSG(976), which is/was(?) used by KineIRCd, too. This closes bug #144.


87deb43012 Alexander Barton

Fix ERR_CANNOTSENDTOCHAN_MSG message

This error message is not only used if one can not send to a channel because it is moderated, but for _all_ reasons when a message can not be delivered (moderated, banned, no external messages, ...), so strip the "(+m) -- Moderated" part of the error message again. Bug introduced by commit 9a82304a.


a9cbb375b7 Alexander Barton

Shorten filenames of Anope protocol module patchfiles

Filenames have been too long and couldn't be stored in all tar archive formats ...


161adbb1aa Alexander Barton

WHOIS: show RPL_WHOISHOST_MSG to all IRC Ops in the network

Not only show RPL_WHOISHOST_MSG to local IRC opreators, but show it to all IRC operators in the network. And don't show it to anybody if the "more privacy" configuration option is enabled. This closes bug #134.


de2fa78d92 Alexander Barton

Test suite: make expect scripts more verbose

Now tests.sh transforms each expect script it executes using sed(1) and inserts a 'puts -nonewline stderr "."' in front of each "expect" command.


8bede388af Alexander Barton

Test suite: remove indentation of messages


c9d166747d Alexander Barton

Merge branch 'bug141-ModesQq'

This closes bug #141. * bug141-ModesQq: KICK-protect IRC services Implement channel mode "Q" and user mode "q" Conflicts: src/ngircd/defines.h src/ngircd/messages.h


56cdc2175c Alexander Barton

Show active user modes in WHOIS reply

Implement numeric RPL_WHOISMODES_MSG(379) and show user modes in the reply of the WHOIS command for the user himself or, if MorePrivacy isn't set, for request initiated by an IRC operator. Numeric 379 is used by Unreal and InspIRCd for this purpose, too. Closes bug #129.


9ac94339dc Alexander Barton

KICK-protect IRC services


de453d71cb Alexander Barton

Implement channel mode 'V' (invite disallow)

If the new channel mode "V" is set, the INVITE command becomes invalid and all clients get the new ERR_NOINVITE_MSG(518) reply. Unreal and InspIRCd uses this mode, too. This closes bug #143.


d3ae351236 Alexander Barton

Implement channel mode "Q" and user mode "q"

Both modes protect users from channel kicks: only IRC operators and servers can kick users having mode "q" or in channels with mode "Q". Original patch by DNS777 <dns@rbose.org>, thanks! This closes bug #141.


23b07bdf50 Alexander Barton

Allow channel admins to "de-admin" channel members

This patch fixes unsetting of channel user mode "+a" (channel admin) and adds a better error message: without this patch, a channel admin is unable to unset this mode. This closes bug #142.


4790d78c98 Alexander Barton

Define HAVE_SETSID for Mac OS X Xcode builds


46b0eef721 Alexander Barton

Merge branch 'bug109-CHARCONV'

This closes bug #109. * bug109-CHARCONV: Debian: require "telnet" or "telnet-ssl" for building Debian ngircd-full[-dbg]: enable CHARCONV Add "CHARCONV" to "feature string" when enabled Implement new IRC+ "CHARCONV" command Added new configure option "--with-iconv" Conflicts: src/ngircd/messages.h


c66e20ce6e Alexander Barton

Fix spelling: ERR_CHANOPPRIVTOLOW_MSG -> ERR_CHANOPPRIVTOOLOW_MSG

Thanks to DNS for pointing this out, see bug #126!


343a90dc37 Alexander Barton

Debian: require "telnet" or "telnet-ssl" for building


114644cdb0 Alexander Barton

Makefile.am: don't use "make -C", it isn't portable


09ab0704f4 Alexander Barton

Debian ngircd-full[-dbg]: enable CHARCONV


cf9f9e1f30 Alexander Barton

Test suite: don't use "mkdir -p"

"mkdir -p" is not supported on all platforms. Tested with Apple A/UX 3.1.x.


19ce256a95 Alexander Barton

ERR_CHANNELISFULL_MSG: better wording

(cherry picked from commit 0fcfa7e00fa8e098dd3724c7188c88ac82a52881)


e9d0b2f039 Alexander Barton

Add "CHARCONV" to "feature string" when enabled


eba53f652c Alexander Barton

Fix getpid.sh to work on Apple A/UX again


222ecbffbb Alexander Barton

Implement new IRC+ "CHARCONV" command

See bug 109 and doc/Protocol.txt for details and documentation.


d8ee498a65 Alexander Barton

Send RPL_REHASHING if rehash was accepted

(cherry picked from commit f1b171a09cd076f743a7fff221fa7aa752abb374)


ce736fc15b Alexander Barton

Added new configure option "--with-iconv"

The iconv library should be used for implementing the new CHARCONV IRC command discussed in bug 109. And because CHARCONV will be an IRC+ feature, we only test for libiconv if IRC+ is enabled as well.


e3a1a61868 Alexander Barton

Change variable name "SSLDHFile" to "DHFile" in log messages

(cherry picked from commit d96db0a2e56d310177edb45d0a8b164a37992ab1)


1413a4886f Alexander Barton

Sort "feature string" alphabetically


1a2bdd9e4c Alexander Barton

Move ConnSSL_InitLibrary() "dummy" from header into C file

(cherry picked from commit 5fd88c81a70d0c9e627f08522e57d251586288eb)


cfec819f0d Alexander Barton

Include CAP command even when using "strict RFC mode"


384f965fba Alexander Barton

NJOIN: correctly reset channel level flags

This fixes commit 7b01bb83. Bug reported by DNS777 <dns@rbose.org>, thanks!


107bfdc821 Alexander Barton

Merge branch 'autoconf-update'

Update GNU autoconf and automake infrastructure. Tested on modern systems as well as Apple A/UX :-) * autoconf-update: AUTOMAKE_OPTIONS: fix ansi2knr option, include path Don't use AC_FUNC_MALLOC and AC_FUNC_REALLOC Make our own targets "silent", if enabled configure.in: use AC_CHECK_{FUNCS|HEADERS}_ONCE Updated config.{guess|sub} to version 2012-08-14 Make autogen.sh more verbose when VERBOSE=1 is set configure.in: use AC_SEARCH_LIBS (not AC_CHECK_LIB) configure.in: use AS_HELP_STRING macro configure.in: use AC_CANONICAL_HOST (not AC_CANONICAL_TARGET) configure.in: inttypes.h is an optional header file Use HAVE_SETSID #define when testing for setsid() Don't include <stdint.h>, it is included by "portab.h" Don't check type.h availability, it is required configure.in: Use AC_CONFIG_FILES macro configure.in: Don't use AC_C_PROTOTYPES configure.in: Update checks for required and optional features configure.in: require autoconf 2.67 and automake 1.11 configure.in: sort some lists (templates, output, ...)


005340c83f Alexander Barton

Simplify check for valid user names in IRC_USER().

Patches from Federico G. Schwindt, thanks! (cherry picked from commit a44b7126227ba1118ec02b399e31b08102af5e8c and 6fbe9583753b2620da275676cde46a89cb4d06c2)


5c160921ff Alexander Barton

AUTOMAKE_OPTIONS: fix ansi2knr option, include path

Set correct relative path to ansi2knr.c in AUTOMAKE_OPTIONS, so that ansi2knr.{1|c} is only included once in the distribution archive.



d21afce2b6 Alexander Barton

Allow user mode +x only when "CloakHostModeX" is set

Allow users to "cloak" their hostname only when the configuration variable "CloakHostModeX" (introduced in 19.2) is set. Otherwise, only IRC opertators, other servers, and services are allowed to set mode +x. This prevents regular users from changing their hostmask to the name of the IRC server itself, which confused quite a few people ;-) This fixes bug #133.


fe3bef55b7 Alexander Barton

Don't use AC_FUNC_MALLOC and AC_FUNC_REALLOC

We don't expect the GNU'ish behaviour of of malloc() and realloc() and never implemented the replacement functions rpl_malloc()/rpl_realloc() -- so these test result in linking failues on systems that don't have a GNU'ish malloc() and realloc() even though we don't require it! Introduced by commit 47ad9afc.


a072180c92 Alexander Barton

Merge pull request #2 from briancollins/master

Fix IRC_Send_NAMES not sending correct prefix for certain clients.


808c291c76 Alexander Barton

New configuration option "OperChanPAutoOp"

If disabled, IRC operators don't become channel operators in persistent channels when joining. Enabled by default, which has been the behavior of ngIRCd up to this patch. Closes bug #135. (Cosmetic fixes by Alex.)


5300f0082c Alexander Barton

Make our own targets "silent", if enabled


0fd9a8505a Alexander Barton

Correctly re-initialize signal handlers on RESTART

This fixes part 2 of bug #127 :-)


16f94546f5 Brian Collins

Fix NAMES response when client has multi-prefix

Two fixes here: IRC_Send_NAMES was checking the capability of the wrong client when responding, and it didn't return any prefix for clients that had either +v or +o but not both.


62a07596d6 Alexander Barton

Allow opers to see secret (+s) channels in LIST command

As long as 'MorePrivacy' isn't enabled in the configuration file, local IRC operators can see secret (+s) channels when using the LIST command. Closes bug #136.


005ffeaa8c Alexander Barton

configure.in: use AC_CHECK_{FUNCS|HEADERS}_ONCE


f5441d2170 Alexander Barton

New_Connection(): mark "IsSSL" parameter as UNUSED

This fixes the following warning message when building without SSL support: conn.c: In function "New_Connection": conn.c:1365: warning: unused parameter "IsSSL" Introduced by commit 01b62202.


55859c1bef Alexander Barton

Merge branch 'better-chan-errors'

By Alexander Barton (1) and DNS777 (1) * better-chan-errors: Remove unused ERR_CANNOTSENDTOCHAN2_MSG message Add some more information to channel error numerics


b730b64bbe Alexander Barton

configure: only use AM_PROG_AR when available

This fixes commit 78d189fb on systems with older automake ...


5c8c6d3c70 Alexander Barton

Updated config.{guess|sub} to version 2012-08-14


f38a9035e5 Alexander Barton

Show a warning on startup if config file is not a full path

ngIRCd is a long-running process and changes its working directory to "/" to not block mounted filesystems and the like when running as daemon ("not in the foreground"); therefore the path to the configuration file must be relative to "/" (or the chroot() directory), which basically is "not relative", to ensure that "kill -HUP" and the "REHASH" command work as expected later on. This fixes parts of bug #127.


bcefdef1ea Alexander Barton

Merge branch 'move-connection-password' of git://arthur.barton.de/ngircd-alex

This patch series converts the statically allocated password buffer in the CLIENT structure into a dynamically (and only when needed) allocated buffer which is referenced by the CONNECTION structure. This a) saves memory for clients not using passwords at all and b) allows for "arbitrarily" long passwords. By Brett Smith (5) and Alexander Barton (2). * 'move-connection-password' of git://arthur.barton.de/ngircd-alex: Login_User(): use "conn" insted of calling Client_Conn(Client) Free already saved password when storing a new one Indentation and style fixes. Connection password is not constant. Implementation clean-ups. Dynamically allocate memory for connection password. Move client password from the Client to the Connection struct.


a5984c702a Alexander Barton

Remove unused ERR_CANNOTSENDTOCHAN2_MSG message


3e22fc32f3 Alexander Barton

Remove all geneerated Makefile.am on "make maintainer-clean"


7eb3932d3a Alexander Barton

Make autogen.sh more verbose when VERBOSE=1 is set


a12d6ff257 Alexander Barton

Create &SERVER channel after predefined channels

This patch allows you to define &SERVER in a [Channel] block yourself and to overwrite the built-in topic and channel modes. Fixes bug #131.



9a82304ae9 Alexander Barton

Add some more information to channel error numerics


360a254be0 Alexander Barton

Enhance "ServiceMask" to handle a list of masks

The "ServiceMask" variable in "Server" blocks now can handle more than one mask using the new MatchCaseInsensitiveList() function. This makes marking "service clients" much more specific, which is a good thing per se, but which is the prerequisite for reasonably blocking these nick names, too (see commit a6dd2e3 for details).


e65a35e964 Alexander Barton

Rename configure.in to configure.ac

This fixes automake: warning: autoconf input should be named 'configure.ac', not 'configure.in' when running the autogen.sh script.


ebf2f991b5 Alexander Barton

configure.in: use AC_SEARCH_LIBS (not AC_CHECK_LIB)

Use the AC_SEARCH_LIBS macro to test for "sometimes but not always" required libraries, not AC_CHECK_LIB.


2205227c3b Alexander Barton

WHO #channel: don't limit list size

It makes no sense to limit the list size when doing WHO for a channel and not to return all the users in that channel, so I removed the check. But if there are more than MAX_RPL_WHO(25) replies, the client requesting the list will be "penalized" one second more (then 2 in total). This fixes bug #125.


1680ea02da Alexander Barton

Free already saved password when storing a new one

This shouldn't happen (clients aren't allowed to send more than one PASS command), but who knows ...



78d189fbf7 Alexander Barton

configure.ng: use AM_PROG_AR to check ar(1) command

This fixes automake-1.12/am/library.am: warning: 'libngipaddr.a': linking libraries using a non-POSIX .../automake-1.12/am/library.am: archiver requires 'AM_PROG_AR' in 'configure.in' src/ipaddr/Makefile.am:12: while processing library 'libngipaddr.a' and similar warnings of automake.


a451cb22f1 Alexander Barton

configure.in: use AS_HELP_STRING macro


d2d867ea36 Alexander Barton

Define EV_SET() for kqueue() on systems that don't have it

Some systems, notably FreeBSD 4.x, do have the kqueue() function but lack the definition of EV_SET() in their header files -- but don't worry, we can #define it on our own ;-) Definition taken from /usr/include/sys/event.h of FreeBSD 8.1. Patch tested on FreeBSD 4.1 by Götz Hoffart. Thanks!


a6dd2e33c2 Alexander Barton

Block nicknames that are reserved for services

This patch introduces the new function Conf_NickIsBlocked() which checks if a given nick name matches with the "service mask" of a configured server. And Client_CheckNick() uses this information to deny such names for regular IRC users. So nick names intended for IRC services are more protected and can't be used by regular users even when the "services pseudo-server" isn't connected to the network. But please note: Up to now, there can be only one "ServiceMask" pattern per server, which most probably blocks much more nick names than really required ... So "ServiceMask" should allow more than one pattern which can be more specific, and most probably it should be possible to block nick names in the global server configuration as well. Nick names introduced by other servers/services are never restricted.


be97fa8ab1 Brett Smith

Indentation and style fixes.


8cfb910441 Alexander Barton

Merge branch 'automake-am11-am12'

* automake-am11-am12: autogen.sh: detect automake version format a.b.c and a.b configure.ng: don't require GIT tree to detect version string Include .mailmap file in distribution archives Include all build-system files into distribution archives Change build system to support new and old GNU automake


82bf4eb059 Alexander Barton

configure.in: use AC_CANONICAL_HOST (not AC_CANONICAL_TARGET)

See the autoconf manual for details: http://www.gnu.org/software/autoconf/manual/autoconf.html#Specifying-Target-Triplets


b232ae2f17 Alexander Barton

Fix contrib/Makefile.am to list all files in EXTRA_DIST


9d8974d509 Alexander Barton

Rename Conf_IsService() to Conf_NickIsService()


164954a788 Brett Smith

Connection password is not constant.

Saying otherwise makes a warning when we assign this to conv.appdata_ptr in pam.c.


039a939cb8 Alexander Barton

autogen.sh: detect automake version format a.b.c and a.b


a3f3a1097b Alexander Barton

INSTALL: update GNU automake/autoconf requirements


d53d58fff2 Alexander Barton

configure.in: inttypes.h is an optional header file


53b2acc00b Alexander Barton

Update project description


037b4b76df Alexander Barton

Check_Connections(): code cleanup


c1d7f6216f Brett Smith

Implementation clean-ups.

* Have Conn_Password return an empty string when no password has been set, to play better with pam.c. * Use strdup in Conn_SetPassword.


d7d5f4330b Alexander Barton

configure.ng: don't require GIT tree to detect version string


d4df626d88 Alexander Barton

automake: don't use INCLUDES, it's AM_CPPFLAGS nowadays


b2482b39e4 Alexander Barton

Use HAVE_SETSID #define when testing for setsid()


01b62202b2 Alexander Barton

New function Conn_StartLogin() to finish connection initialization

Conn_StartLogin() is called after the connection has been established and fully innitialized, including the SSL handshake, for example. Up to this patch, the "NoticeAuth" option broke the SSL handshake ...


7df4c12da9 Brett Smith

Dynamically allocate memory for connection password.


4b0f526006 Alexander Barton

Xcode: use certificate of Alex for code signing

When doing non-debug Xcode builds, use the "Developer ID Application: Alexander Barton" certificate for code signing by default.


79c1222896 Alexander Barton

Include .mailmap file in distribution archives


eed8a4ee6e Alexander Barton

automake: enable colored test output, if available

The "color-tests" option can't be checked for, but is available starting with automake 1.11 which introduced AM_SILENT_RULES -- so we check this ...


74c7d7131f Alexander Barton

Don't include <stdint.h>, it is included by "portab.h"


b68bb560e9 Alexander Barton

Convert CONN_ID and Conf_MaxConnections to "int" datatype

We can't handle more connections than accept(2) can supply, and accept(2) returns an "int" ...


0d5de60584 Brett Smith

Move client password from the Client to the Connection struct.

This is a relatively naive implementation, basically doing the bare minimum necessary to make the switchover go. Subsequent commits can focus on improving the implementation.


4cf65b973c Alexander Barton

"make uninstall": remove ngircd.conf if not modified

Now "make uninstall" removes the installed "ngircd.conf" file, if it is still equal to our "sample-ngircd.conf" file and therefore hasn't been modified by the user. If it has been modified, it isn't removed and a notice is displayed to the user. In addition, "make install" now displays a message when no ngircd.conf file exists and the "sample-ngircd.conf" file will be installed as a starting point.


b1b83831d1 Alexander Barton

Add doc/Contributing.txt to distribution archive


8e1beae4e7 Alexander Barton

Include all build-system files into distribution archives


4dd1c31dc7 Alexander Barton

Don't check type.h availability, it is required


21467c76f1 Alexander Barton

Introduce numeric RPL_HOSTHIDDEN_MSG(396)

This numeric is sent to the client each time it changes its displayed hostname using "MODE +/-x", and if "CloakHost" is set right after the MOTD has been sent.


160f728530 Alexander Barton

contrib/ngircd.service: systemd service file for ngircd

Thanks to Kyle Keen <keenerd@gmail.com>: Date: Sat, 18 Aug 2012 08:28:22 -0400 Message-ID: <CAAKTTKNNmrB=8XtxcV6w1Q-RQ6J_xTTDGD4MHQFaDy6V3=B19Q@mail.gmail.com> From: keenerd <keenerd@gmail.com> To: ngircd-ml@ngircd.barton.de Subject: [ngIRCd-ML] systemd service Hello all. Linked is a service file for ngircd. Please add this to your source tree so other people don't have to learn to write service files ;-) https://projects.archlinux.org/svntogit/community.git/plain/trunk/ngircd.service?h=packages/ngircd -Kyle Keen Arch Linux TU http://kmkeen.com


baed0618ed Alexander Barton

Loose GNU autoconf / automake requirements a bit

Now ngIRCd requires at least GNU autoconf 2.61 and automake 1.10, the requirements of commit 67e882d4 have been too restrictive: 19.2 67e882d4 now ---------- --------- --------- --------- autoconf >=2.50 >=2.67 >=2.61 automake >=1.6 >=1.11 >=1.10 The tools required now are supported by Debian GNU/Linux 4.0 "Etch", RedHat Enterprise Linux 5, and Mac OS X 10.6.x for example. I read the changelogs of autoconf and automake, and I think ther's nothing that prevents it from working with these older versions; and we don't want to force users to upgrade without real benefits. Please note: the recommended versions are still autoconf 1.11.x and the most recent autoconf release that works with automake 1.11.x!


192e304b94 Alexander Barton

Change build system to support new and old GNU automake

Starting with GNU automake 1.12, the "de-ANSI-fication support" has been removed, which ngIRCd used to enable building itself on very old systems. Now the problem is, that using automake >= 1.12 isn't working because of the now unsupported M4 macros. Therefore the solution that this patch implements is to dynamically generate the automake input files with our own ./autogen.sh script: configure.ng => configure.in Makefile.ng => Makefile.am This is quite an ugly approach, but it works and enables us to: 1. use current automake >= 1.12 for development and "private builds", 2. still build distribution archives using automake 1.11.x that have "de-ANSI-fication support" enabled in the generated Makefile's. And if you are using Makefile's generated with a automake version newer than 1.11.x (without "de-ANSI-fication support"), the ./configure script warns you not to use this generated build system to generate distribution archives. Drawback of this patch: you MUST use our autogen.sh script, you can't call the autoconf/automake commands directly any more; but autoreconf should still work ...


2e13e821f8 Alexander Barton

configure.in: Use AC_CONFIG_FILES macro


33fae67579 Alexander Barton

Always cloak client hostname, if needed

Not only cloak the hostname in Client_MaskCloaked(), but also in Client_HostnameCloaked() -- so move the actual cloaking to this function and call it in Client_MaskCloaked() to get the (cloaked) hostname. This fixes USERHOST not displaying the correctly cloaked hostname, for example.


922540306e Alexander Barton

ngt_RandomStr(): Add implicit cast to "unsigned".

This fixes the following warning of Xcode 4.5: src/tool/tool.c:150:19: Implicit conversion loses integer precision: 'long' to 'unsigned int'


e3e181f4b3 Alexander Barton

Merge branch 'bug92-xop'

By Alexander Barton (5) and Sebastian Köhler (2) * bug92-xop: Fix NAMES/WHO response when client has multi-prefix Fix prefix of "halfop" when "multi-prefix" is active Clean up doc/.gitignore doc/Modes.txt: add version number to new channel modes Fix some "whitespace glitches" Tests and documentation for xop Implemented xop support Conflicts (because of "multi-prefix fix"): src/ngircd/irc-info.c This fixes bug #92 "ngircd does not support XOP usermodes".


2478c5816b Alexander Barton

configure.in: Don't use AC_C_PROTOTYPES

Don't use AC_C_PROTOTYPES, AM_C_PROTOTYPES is already used.


864015fa3f Alexander Barton

NoticeAuth: make sure messages are flushed immediately


d48e440a72 Alexander Barton

Fix a buffer overflow when initializing the random salt for "+x"

This "off by one" buffer overflow has been introduced in commit 49385a98, "Implemented hashed cloaked hostnames for +x".


1f2aa4da6f Alexander Barton

Fix NAMES/WHO response when client has multi-prefix

This has been fixed by commit 16f94546 "Fix NAMES response when client has multi-prefix" in the master branch, fix it in this patch series, too.


ef82ef4ddb Alexander Barton

Free all listen ports on initialization

Now you can reconfigure listen ports and reload the server configuration on runtime. Without this patch, no ports could be removed.


47ad9afcf3 Alexander Barton

configure.in: Update checks for required and optional features

Update checks for required and optional header files, data types, and functions.


1d3def0cc6 Alexander Barton

Merge branch 'umode-B'

This patch series allows ngIRCd to support the user mode "B" ("Bot flasg"): it is settable and unsettable by every (non-restricted) client. According to DNS777, this is how Unreal and InspIRCd do behave, so do we :-) By Alexander Barton (1) and DNS777 (1) * umode-B: Add new user mode "B" to doc/Modes.txt Implement an Unreal-like user mode "B" ("Bot mode")


0709a0f050 Alexander Barton

configure.in: Use AC_CONFIG_HEADER instead of AM_CONFIG_HEADER

AM_CONFIG_HEADER is marked obsolete and will be removed in Automake 1.13.


fc39146f48 Alexander Barton

Fix prefix of "halfop" when "multi-prefix" is active


bb20aeb9bc Alexander Barton

Initialize SSL when needed only, and disable SSL on errors

With this patch, the SSL subsystem will only be initialized if at least one SSL ports is configured; so you won't get "SSL initialization failed" messages if you didn't configured it at all. And if SSL initialization fails, no SSL listen ports will be enabled later which never could establish a working SSL connection at all ...


67e882d4bb Alexander Barton

configure.in: require autoconf 2.67 and automake 1.11

And use newer features such as bug reporting address and project URL.


e01e8f1cb6 Alexander Barton

Merge branch 'recognize-umode-R'

By Alexander Barton (1) and DNS777 (1) * recognize-umode-R: Only allow IRC services to modify user mode "R" Recognize user mode "R"


a26e37b746 Alexander Barton

Add new user mode "B" to doc/Modes.txt


cfd0bddc30 Alexander Barton

Fix compiler warning when not building with ZLIB support

This fixes: irc.c: In function ‘Option_String’: irc.c:333:9: error: variable ‘options’ set but not used


1744a8d145 Alexander Barton

Clean up doc/.gitignore


25c216cbdf Alexander Barton

configure.in: sort some lists (templates, output, ...)


186ab51137 Alexander Barton

Only allow IRC services to modify user mode "R"



c2b39fdede Alexander Barton

Implement an Unreal-like user mode "B" ("Bot mode")


b53b12aa5f Alexander Barton

Update NEWS and ChangeLog files for hashed cloaked hostnames


b12acddf4f Alexander Barton

doc/Modes.txt: add version number to new channel modes


298cd9a327 Alexander Barton

Get_CAP_String(): make it buildable with pre-ANSI C compilers


8349a1c0d9 Alexander Barton

Recognize user mode "R"

This allows users to unset the user mode "R".


d0bb185cf5 Sebastian Köhler

Hashed hostnames for CloakHost

Implemented support for hashed hostnames for CloakHost. The admin can use '%x' in both the CloakHost and CloakHostModeX setting. The config option CloakHostModeX was renamed to CloakHostSalt. This salt is used for both cloaking options.


0d67be3f30 Alexander Barton

Fix some "whitespace glitches"

Some have been introduced by commit 7b01bb83, some are older.


414bfe65eb Alexander Barton

Enhance "NOTICE AUTH": show hostname and IDENT reply


49385a98b2 Sebastian Köhler

Implemented hashed cloaked hostnames for +x

CloakHostModeX can now contain '%x'. It will be replace by the hash of the original client hostname. The new config option CloakHostModeXSalt defines the salt for the hash function. When CloakHostModeXSalt is not set a random salt will be generated after each server restart. Spelling fix in defines.h


f37600ee01 Alexander Barton

Merge branch 'xop' of https://github.com/kart0ffelsack/ngircd into bug92-xop

* 'xop' of https://github.com/kart0ffelsack/ngircd: Tests and documentation for xop Implemented xop support Conflicts (because of merge of the 'cmode-M' branch): src/ngircd/channel.c src/ngircd/defines.h src/ngircd/messages.h


c519ba9920 Alexander Barton

Merge branch 'cmode-M'

By Alexander Barton (2) and DNS777 (1) * cmode-M: Add new channel mode "M" to doc/Modes.txt Remove Can_Send_To_Channel_Identified() Implement channel mode "M"


b9e6cb3e55 Alexander Barton

ngIRCd release 19.2 (tags/rel-19.2)


fee8ff37b3 Alexander Barton

Add new channel mode "M" to doc/Modes.txt


097c72aa65 Sebastian Köhler

Tests and documentation for xop


dffe5a9d60 Alexander Barton

doc/Capabilities.txt: document "multi-prefix" capability


fee591b759 Alexander Barton

Remove Can_Send_To_Channel_Identified()

Move the functionality directly into Can_Send_To_Channel() function. There should be no functional change ...


7b01bb833f Sebastian Köhler

Implemented xop support

3 new channel user modes have been added. Half Op: +h(Prefix: %) can set the channel modes +imntvIbek and kick all +v and normal users. Admin: +a(Prefix: &) can set channel modes +imntvIbekoRsz and kick all +o, +h, +v and normal users. Owner: +q(Prefix: ~) can set channel modes +imntvIbekoRsz and kick all +a, +o, +h, +v and normal users


d7eb343ea0 Alexander Barton

ngIRCd release 19.2~rc1 (tags/rel-19.2-rc1)


1aaf54ac24 Alexander Barton

Implement channel mode "M"

Only the server, identified users and IRC operators are able to talk.


bf5610a3b9 Alexander Barton

Merge branch 'bug124-CloakHostModeX'

* bug124-CloakHostModeX: Describe "CloakHostModeX" in sample-ngircd.conf an ngircd.conf(5) Rename "CloakModeHost" option to "CloakHostModeX" Introduce new configuration option "CloakModeHost" This closes bug #124.


7bce6780ca Alexander Barton

Update ChangeLog and NEWS files



7b6b492bdd Alexander Barton

Rename "CloakModeHost" option to "CloakHostModeX"


684e50f0a4 Alexander Barton

Correctly handle asynchronously re-established server links

Don't try to establish an outgoing server link after DNS lookup when this server re-connected on its own in the meantime. In addition, log a warning message if we try to update the connection index of an already connected server structure -- and ignore it. Up to now, both behaviour could lead to a race when the remote server connects to this daemon while it still prepares the outgoing connection: - The local server prepares the new outgoing connection ... - in the meantime the remote server becomes connected and registered. - Now the new outgoing connection overwrites the (correct) socket handle, - then the 2nd connection becomes disconnected: "already registered", - and the 1st connection becomes unhandled ("gets lost") because the configuration structure is reset because of the wrong socket handle. This patch hopefully fixes all these problems.


aa7db2c0e9 Alexander Barton

Introduce new configuration option "CloakModeHost"

This closes bug #124.


4a90959cb5 Alexander Barton

Log a debug message when SIGUSR2 is handled


9b1cf420f1 Alexander Barton

doc/Platforms.txt: more updates

Added: - armv6l/unkn./linux-gnueabi, gcc 4.4.5 - i686/pc/linux-gnu, gcc 2.7.2 Updated: - i386/pc/solaris2.11, gcc 4.2.3 Thanks to Götz Hoffart!


e7e47e77a3 Alexander Barton

NoticeAuth: Fix test if IDENT reply has been invalid

This fixes conn.c: In function ‘cb_Read_Resolver_Result’: conn.c:2252: warning: comparison between pointer and integer


695df6532e Alexander Barton

IDENT reply: only allow alphanumeric characters in user name

Only alphanumeric characters are allowed in the user name, so ignore all IDENT replies that would violate this rule and use the one supplied by the USER command.


6680b536c4 Alexander Barton

USER command: only allow alphanumeric characters in user name

Only alphanumeric characters are allowed in the user name, so terminate the connection if any "strage" characters have been supplied by the user. This is how other IRC daemons (like ircd2.11 and ircd-seven) behave ...


a21a7d8b66 Alexander Barton

doc/Platforms.txt: add powerpc/apple/darwin7.9.0


c0d059cd0e Alexander Barton

Change wording of "TLS initialized" message

Don't use the word "socket" to identify the connection number, but use the word "connection" like on all the other messages logged.


7faa3ed7d6 Alexander Barton

Pidfile_Create(): Don't leak file descriptor on error path

Detected by cppcheck: [src/ngircd/ngircd.c:502]: (error) Resource leak: pidfd


c9b152fa41 Alexander Barton

INSTALL: Add "satisfy prerequisites" section

Include information for RedHat/Fedora and Debian/Ubuntu based Linux distributions.


ae27571414 Alexander Barton

NEWS, ChangeLog: fixed some misspellings


5e5377a063 Alexander Barton

Numeric 005 (ISUPPORT), CHANMODES: add missing mode "r"


884c5bcff1 Alexander Barton

doc/Platforms.txt: add "armv7l/unknown/linux-gnueabi"


3a2fcc32cd Alexander Barton

Add instructions for setting up Atheme.


a8aa8c6cbc Alexander Barton

irc-cap.c: mark arguments of Handle_CAP_ACK() as "unused"

This fixes irc-cap.c: In function ‘Handle_CAP_ACK’: irc-cap.c:163: warning: unused parameter ‘Client’ irc-cap.c:163: warning: unused parameter ‘Arg’


f01b09ce84 Alexander Barton

irc-login.c, login.c: add missing include of "string.h"

This fixes the following warnings with GCC 4.4.5 on Linux: irc-login.c: In function ‘IRC_PASS’: irc-login.c:92: warning: implicit declaration of function ‘strlen’ irc-login.c:92: warning: incompatible implicit declaration of built-in function ‘strlen’ irc-login.c:113: warning: incompatible implicit declaration of built-in function ‘strlen’ irc-login.c:129: warning: implicit declaration of function ‘strchr’ irc-login.c:129: warning: incompatible implicit declaration of built-in function ‘strchr’ irc-login.c:133: warning: implicit declaration of function ‘strcmp’ irc-login.c: In function ‘IRC_SERVICE’: irc-login.c:556: warning: incompatible implicit declaration of built-in function ‘strchr’ login.c: In function ‘Login_User’: login.c:131: warning: implicit declaration of function ‘strcmp’


2419a701d8 Alexander Barton

doc/Modes.txt: Document missing channel mode "e"


110be707c3 Alexander Barton

Merge branch 'master' of /srv/git/ngircd

* 'master' of /srv/git/ngircd: "multi-prefix" capability 2/2: adjust NAME and WHO handlers "multi-prefix" capability 1/2: implement complete CAP infrastructure IRC_Send_NAMES(): Code cleanup New function Client_CapSet() in addition to Client_Cap{Add|Del} "CAP REQ" starts capability negotiation and delays user registration Xcode: update project file for Xcode 4.3 Correctly handle "CAP END", new client type CLIENT_WAITCAPEND Implement core IRC capability handling and "CAP" command New "login" source file Introduce_Client() => Client_Introduce(), and move it to client.c


b2743af0ed Alexander Barton

contrib/platformtest.sh: support "CC=xxx MAKE=yyy ./platformtest.sh"

Now you can use contrib/platformtest.sh on platforms that require a "special" make (not "make") or compiler (not cc/gcc) binary.


76565022fb Alexander Barton

Merge branch 'capabilities'

* capabilities: "multi-prefix" capability 2/2: adjust NAME and WHO handlers "multi-prefix" capability 1/2: implement complete CAP infrastructure IRC_Send_NAMES(): Code cleanup New function Client_CapSet() in addition to Client_Cap{Add|Del} "CAP REQ" starts capability negotiation and delays user registration Correctly handle "CAP END", new client type CLIENT_WAITCAPEND Implement core IRC capability handling and "CAP" command New "login" source file Introduce_Client() => Client_Introduce(), and move it to client.c


4602cb9891 Alexander Barton

"multi-prefix" capability 2/2: adjust NAME and WHO handlers

The NAME and WHO commands now return multiple usermode prfixes when the "multi-prefix" capability is in effect for the requesting client. See <http://ircv3.atheme.org/extensions/multi-prefix-3.1>


359732af85 Alexander Barton

Xcode: update project file for Xcode 4.3

(No changes needed)


1dea0d91a0 Alexander Barton

platformtest.sh: Detect Open64 C compiler


1d7e99531a Alexander Barton

"multi-prefix" capability 1/2: implement complete CAP infrastructure

Now ngIRCd is able to handle "CAP LS", "CAP REQ", "CAP LIST", and "CAP CLEAR" commands. "multi-prefix" can be set/unset, but has no functionality - yet!


d67d077a71 Alexander Barton

Fix 8ec17063: "Lists_Add(): use size of destination when copying data"

Thanks to Florian Westphal for spotting my silliness ...


f0a9dbe3ad Alexander Barton

IRC_Send_NAMES(): Code cleanup


69be7a85a2 Alexander Barton

Xcode: correctly sort conn-ssl.{c|h} files in file list



8ec17063a6 Alexander Barton

Lists_Add(): use size of destination when copying data

This fixes the following warning of clang: /src/ngircd/lists.c:152:44: warning: size argument in 'strlcpy' call appears to be size of the source; expected the size of the destination [-Wstrlcpy-strlcat-size] But it isn't a real problem, because the size of the source always is the same than the size of the destination ...


2327b17656 Alexander Barton

"CAP REQ" starts capability negotiation and delays user registration

New helper function Set_CAP_Negotiation().


67bd1bf34f Alexander Barton

Makefiles: list each source files on a separate line

Patches that add/remove source files become much nicer this way :-)


da4c1ebe81 Alexander Barton

Correctly handle "CAP END", new client type CLIENT_WAITCAPEND


9f3af061cf Alexander Barton

Add missing documentation files to Xcode project


bd3a7ccb15 Alexander Barton

Implement core IRC capability handling and "CAP" command

This patch implements the core functions to support "IRC Capabilities" and the IRC "CAP" command as used by other servers and specified here: <http://www.leeh.co.uk/draft-mitchell-irc-capabilities-02.html>. It enables ngIRCd to support the defined handshake, but it doesn't implement any capabilities, so "CAP LS" and "CAP LIST" always return the empty set and "CAP REQ ..." always fails with "CAP NAK".


88c3d4896a Alexander Barton

Don't ignore "permission denied" errors when enabling chroot

Up to now, ngIRCd silently ignored permission denied errors when trying to enable a chroot setup: only the "not running chrooted" message became logged later on. This patch lets ngIRCd exit with a fatal error when the chroot can't be enabled on startup -- this is the much safer bevahiour!


edfcc2f9d5 Alexander Barton

New "login" source file

Rename Hello_User[_PostAuth] to Login_User[_PostAuth] and move it to the new login.c; and move cb_Read_Auth_Result(), too. This will enable further code to easily call Login_User() when required.


7b6ef3bc8e Alexander Barton

FAQ: enhance description of chroot setup



fbaa751da8 Alexander Barton

ngIRCd Release 19.1 (tags/rel-19.1)


06b6327875 Alexander Barton

Update ChangeLog for upcoming ngIRCd 19.1 release


0d9740b9fa Alexander Barton

Fix gcc warning, initialize "list" variable to NULL

This fixes the following warning with gcc 4.6.3.: irc-mode.c: In function "Channel_Mode": irc-mode.c:947:26: error: "list" may be used uninitialized in this function irc-mode.c:884:25: error: "list" may be used uninitialized in this function (The variable has never been used uninitialized, so don't worry)


e9be3334d1 Alexander Barton

Fix manual page "hyphen-used-as-minus-sign" error (lintian)

Thanks to Christoph Biedl for reporting this!


0ae74ceaed Alexander Barton

Fix typo: Please not -> Please note

Thanks to Götz Hoffart!


17ffda1c8a Alexander Barton

Fix typo: recieved -> received

Thanks to Christoph Biedl.


0de11ead36 Alexander Barton

Update NEWS and ChangeLog files


9d486db460 Alexander Barton

Really include _all_ patches to build the Anope module


257fe922d2 Alexander Barton

getpid.sh: Fix testcase error for Debian using sbuild

When * building the ngircd Debian package (on Linux at least) and * using the sbuild build system, the command "ps -af" does not include the commands running inside the sbuild system. Therefore, start-server.sh will report a fail as getpid.sh cannot not find the ./T-ngircd1 just started although it's actually running. This results in a funny build log ... starting server 1 ... failure! FAIL: start-server1 running connect-test ... ok. PASS: connect-test The self-test of getpid.sh however will likely succeed as it's happy if it sees any process with "sh" somewhere in the name. Things go downhill from there. The confusing things are: * The alternative cowbuilder/pbuilder does not have this problem. * The alternative usage "ps ax" does fine. So, as a quick hack, the patch attached adds another switch to getpid.sh.


1068f88377 Alexander Barton

Don't log "ngIRCd hello message" two times

Start "regular" logging not until the configuration file has been read in and "SyslolgFacility" is set, and log all configuration errors using the generic "daemon" facility. So if there are no configuration errors, logging starts right after parsing the configuration and we log the configuration file used _after_ reading it. But this is no problem because every configuration error message includes the configuration file name as well. (The "double hello" has been introduced by commit 3641e5110952)


9e7360e5fa Alexander Barton

ngIRCd release 19 (tags/rel-19)


273d4bdd32 Alexander Barton

Merge branch 'master' of /srv/git/ngircd

* 'master' of /srv/git/ngircd: Update doc/Platforms.txt for ngIRCd 19 doc/README-Interix.txt: note that GNU make should be used


27d244dfae Alexander Barton

Update doc/Platforms.txt for ngIRCd 19


ef392e7d37 Alexander Barton

Update config.guess and config.sub to recent versions


a39a1a5273 Alexander Barton

doc/README-Interix.txt: note that GNU make should be used



5cbdcf4f0d Alexander Barton

Fix C syntax: duplicate ";;" should be ";"

Using gcc 2.7.2, this fixes: irc-channel.c: In function `join_allowed': irc-channel.c:86: parse error before `const'


3641e51109 Alexander Barton

Correctly re-open syslog logging after reading of configuration

Syslog logging has been initialized before reading the configuraton file, so ngIRCd always used the default facility and ignored the "SyslogFacility" configuration option. Thanks to Patrik Schindler for reporting this issue!


3f46e93ccc Alexander Barton

Logging: remove "Activating ..." info message


8e3c56e5b2 Alexander Barton

ngIRCd release 19~rc1 (tags/rel-19-rc1)



f7bdee5f13 Alexander Barton

Update NEWS and ChangeLog files


391aa8d1f7 Alexander Barton

Fix forwarding of LIST commands

Bug reported by Cahata, thanks!


89d99e2ff9 Alexander Barton

Update preliminary ngIRCd protocol module for Anope 1.9.6


c16133c5ee Alexander Barton

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 []) ...


4888984429 Alexander Barton

Client_SetHostname(): Code cleanup, more debug logging


44bb22d23e Florian Westphal

io: use define for number of possible events


c7dd5ea0ba Florian Westphal

io: remove outer do {} while loops for epoll/kqueue/devpoll backends

simplifies things a bit. io_dispatch() is called repeatedly from the main loop.


871760583c Alexander Barton

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.


bc20f9ec10 Alexander Barton

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.


5a200e1543 Alexander Barton

New function Conn_UpdatePing() to update the "ping timestamp"


d2df7396a8 Alexander Barton

Conn_UpdateIdle(): Code cleanup


3d27073d61 Alexander Barton

RPL_ISUPPORT_MSG(005): add "EXCEPTS=e INVEX=I"

Thanks to Cahata for the idea!


b6f19ea8fe Alexander Barton

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!


8c46067b34 Alexander Barton

Update NEWS and ChangeLog files


594fdd02aa Alexander Barton

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.



1537c79132 Alexander Barton

G/K-Lines: only add and delete valid IRC masks


e0c9931ad8 Alexander Barton

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.


eba95bb0d2 Alexander Barton

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().


51a6a33056 Alexander Barton

New function Client_Reject() to reject clients on connect



9882e578e9 Alexander Barton

Update NEWS and ChangeLog files



f2fa1045e2 Alexander Barton

Implement channel exception list (mode 'e')

This allows a channel operator to define exception masks that allow users to join the channel even when a "ban" would match and prevent them from joining: the exception list (e) overrides the ban list (b).


33a165721b Alexander Barton

{Add|Del}_Ban_Invite > {Add_To|Del_From}_List(): more generic



39412d6486 Alexander Barton

PRIVMSG/NOTICE: handle nick!user@host masks case-insensitive

And enhance our test suite to check this a little bit better :-)


c1656256df Alexander Barton

PRIVMSG/NOTICE: don't stop list processing on invalid target

Process further targets, even if one has been a server ID: just skip this one with an error message and continue.


1f4711a547 Alexander Barton

Implement user mode 'C': require "same channel" to send message

If the target user of a PRIVMSG or NOTICE command has the user mode 'C' set, it is required that both sender and receiver are on the same channel. This prevents private flooding by completely unknown clients.



12c60a670e Alexander Barton

IRC_WHOIS_SendReply(): Code cleanup


2f7d0c0839 Alexander Barton

Limit channel invite and ban lists to 50 entries

- New function Lists_Count(). - New limit #define MAX_HNDL_CHANNEL_LISTS = 50. - New numeric #define ERR_LISTFULL_MSG(478). - Adjust numeric RPL_ISUPPORT2_MSG(005) accordingly ("MAXLIST")


1afbf71236 Alexander Barton

Make Send_ListChange() a little bit more generic


7ed08f01ef Alexander Barton

Remove unused prototype of Lists_AlreadyRegistered()

This prototype has been introduced by commit fa7bb279 in 2006, but as far as I can see, this function never existed ...


81cc5f82b5 Alexander Barton

Channel lists: Fix duplicate check and error messages

- Check correct list for duplicates when adding items. - Don't generate any messages when adding duplicates or removing non-existing items (this is how ircd-seven and ircu behave). - Code cleanup: Add_Ban_Invite(), Del_Ban_Invite().


78a3b4c7d6 Alexander Barton

Don't enforce MAX_HNDL_MODES_ARG on server and service links


39d630c00d Alexander Barton

Update documentation (fix some URL, update some info)


4fe6b42c53 Alexander Barton

Update NEWS and ChangeLog for next ngIRCd release once more


d4d8102fc9 Alexander Barton

Don't stop join handling on faulty channel, skip it (part #2)

Commit 565523cb allowed processing of further channel names given to the JOIN command when a single name was invalid. After this patch, the JOIN command handler continues to process channel name lists even after errors like "channel is full", "too many channels", and the like and generates appropriate error messages for all the channels given by the client.


77f68b4fd1 Alexander Barton

JOIN command: don't check channel limit if already member

Don't check the channel limit and don't report "too many channels" when trying to join a channel that the client is already a member of.


2f8877ded4 Alexander Barton

Return ERR_UNKNOWNMODE(472) for unknown channel modes

The daemon reported ERR_UMODEUNKNOWNFLAG(501), which is wrong.


4bff3daf92 Alexander Barton

Numberic 005 (ISUPPORT), CHANMODES: add "O", "R", "z" modes


c5beca8aab Alexander Barton

Limit list replies of LIST, WHO, WHOIS, and MAX_RPL_WHOWAS

Introduce new #define's MAX_RPL_LIST(100), MAX_RPL_WHO(25), MAX_RPL_WHOIS(10), and MAX_RPL_WHOWAS(25).


f8405b1a4f Alexander Barton

New function IRC_CheckListTooBig() to check size of list replies

It the limit is reached, a NOTICE is sent to the client and list processing should stop.


fdfc27265e Alexander Barton

LIST command: compare pattern case insensitive


a4d1e6007f Alexander Barton

IRC_LIST(): Code cleanup


9260759cec Alexander Barton

DEFAULT_WHOWAS->DEF_RPL_WHOWAS; MAX_CMODES_ARG->MAX_HNDL_MODES_ARG

To streamline naming, in preparation for MAX_RPL_WHO and MAX_RPL_WHOWAS :-)


c2ac1ad3ba Alexander Barton

defines.h: Code cleanup and (a little bit) more documentation


470d2e2362 Alexander Barton

RPL_ISUPPORT (numeric 005): Report MODES=<MAX_CMODES_ARG>

"Maximum number of channel modes with parameter allowed per MODE command." See <http://www.irc.org/tech_docs/005.html> for details.


888664435a Alexander Barton

Channel modes: really break handling when MAX_CMODES_ARG is hit

This fixes 98493077.


98493077a2 Alexander Barton

channel modes: only handle MAX_CMODES_ARG modes with arguments

Limit the MODE command to handle a maximum of MAX_CMODES_ARG (5) channel modes that require an argument (+Ibkl) per call. Please note: Further modes that require arguments are silently ignored and end the handling of any further modes. This is similar to the behavior of ircd2.11 (silently ignores but seems to handle other modes) as well as ircd-seven (silently ignores but handles some(!) other modes) ...


1fa2af5b3a Alexander Barton

Fix handling of channel mode sequence with/without arguments

For example, don't generate wrong error messages when handling "MODE #chan +IIIIItn *!aa@b *!bb@c *!cc@d *!dd@e *!ee@f".


05cc9bf9b0 Alexander Barton

Conn_Write(): Make sure there is a client when detecting its type

The assert(client != NULL) got triggered during our tests, so there is an error path that resulted in the connection being still established (sock >= 0) but the client structure already freed. So Conn_Write() should handle it!


cc06e1ff89 Alexander Barton

Proc_Close(): Only close socket if it is still valid

It could be invalid when calling Proc_Close() a 2nd time, for exmaple, which could happen when we hit a timeout doing IDENT requests :-(


9fbf592924 Alexander Barton

WHOIS command: make sure matching is case-insensitive

And make sure that RPL_ENDOFWHOIS replies with the unmodified mask like it has been received from the client.


adf92302bf Alexander Barton

WHOIS command: don't anser queries for IRC servers

Thanks to Cahata for spotting this!


566a451299 Alexander Barton

WHOIS command: make sure the reply ends with RPL_ENDOFWHOIS

Up to now, each reply for itself ended in RPL_ENDOFWHOIS and queries for unknown nick names lacked the RPL_ENDOFWHOIS -- both is wrong.


e0f8ce093a Alexander Barton

README: update features list, borrow from list on our website


5e3449a241 Alexander Barton

LINKS command: support <mask> parameter

The <mask> can be used to limit the servers shown in the listing.


762b0325df Alexander Barton

IRC_LINKS(): Code cleanup; more documentation


6b62a5ec4f Alexander Barton

Add 1 second penalty for every further target on PRIVMSG/NOTICE

This reduces the possibility of flooding channels with commands like "PRIVMSG/NOTICE #a,#n,#c,... :message" a little bit. Problem noticed by Cahata -- thanks!


b24d645ca1 Alexander Barton

Conn_SetPenalty(): Add new "penalty time" on each function call

Until now, the penalty time has only been set when longer as the already set one, so it didn't accumulate. And add documentation for and clean up code in Conn_SetPenalty() and Conn_ResetPenalty() functions.


1bb2fbedcc Alexander Barton

Enhance log messages when setting user and group


3193d5477c Alexander Barton

NGIRCd_getNobodyID(): Code cleanup


edab86e0f8 Alexander Barton

Display correct error message when "Server{UID|GID}" is invalid

This partly closes bug #118. ngIRCd still starts up even when Server{UID|GID} is invalid: then the daemon falls back to "nobody" when running with root(0) privileges (as before).


e4006a93e3 Alexander Barton

NGIRCd_Init(): Code cleanup


9069380ddf Alexander Barton

main(): Code cleanup


ab188c1486 Alexander Barton

README: point to included COPYING file, not gnu.org


5eb9f2e717 Alexander Barton

Update Copyright notices for 2012


abfc5c6e27 Florian Westphal

lists: don't crash if reason ptr is NULL

commit 15fec92ed75c3de0b32c40d005e93e3f61aef77e (Update list item, if it already exists) can make ngircd crash because 'Reason' can be NULL, as reported by Cahata on the ngircd mailing list. Doesn't affect any released ngircd versions. Also, make sure that we do not pass NULL as arguments to a '%s' printf-like function.


565523cbb4 Alexander Barton

Don't stop join handling on faulty channel, skip it

When JOIN is received with more than one channel name, don't stop processing on the first error (e.g. bad name, wrong channel key, ...) but report an error and continue with the other given channel names. Reported by Cahata -- thanks!


013298d4c6 Alexander Barton

IRC_JOIN(): Code cleanup


af13732ec7 Alexander Barton

ISON command: reply with correct upper-/lowercase nick names

Reported by Cahata -- thanks!


408a74b865 Alexander Barton

IRC_ISON(): Code cleanup


f47904bf95 Alexander Barton

Remove unused "bool have_arg" from IRC_WHO()

This fixes: irc-info.c: In function ‘IRC_WHO’: irc-info:936:18: warning: variable ‘have_arg’ set but not used


70eb8219f5 Alexander Barton

Update NEWS and ChangeLog for next ngIRCd release


9e5b9ddad0 Alexander Barton

ngircd.conf.5: reword description of "Ports" variable


56b7e67307 Alexander Barton

New configuration option "PAMIsOptional"

When "PAMIsOptional" is set, clients not sending a password are still allowed to connect: they won't become "identified" and keep the "~" character prepended to their supplied user name.


b681aa5b9f Alexander Barton

PAM: don't use global password buffer for conv struct

Use the pointer of the password of the client directly. Eventually we can get rid of the global password again ...


b32f3b76e9 Alexander Barton

doc/Modes.txt: document channel mode "r"

And make clear, that user mode "r" and channel mode "r" are not set by ngIRCd itself but by IRC services.


1a5ed654b4 Alexander Barton

Fixed handling of WHO commands

This fixes two bugs: - "WHO <nick>" returned nothing at all if the user was "+i" (reported by Cahata, thanks). - "WHO <nick|nickmask>" returned channel names instead of "*" when the user was member of a (visible) channel. Clean up code and add documentation as well.


9cbb8f3bb8 Alexander Barton

Remove unused "time_t now" from Lists_Check()

This fixes: lists.c: In function ‘Lists_Check’: lists.c:330:9: warning: variable ‘now’ set but not used


e19ce437ca Alexander Barton

Fixed some spelling errors in documentation and code comments

Thanks to Christoph Biedl!


4e550bf9ef Alexander Barton

contrib/Debian/control: Update and complete "Build-Depends"


1d29a59f7e Alexander Barton

Update our Debian package descriptions with "official" ones

See Debian Bug #648241 for details.


765c2f26ea Alexander Barton

Fixed typo in two error messages

Thanks to Christoph Biedl!


69fa6f268a Alexander Barton

LUSERS reply: only count "visible" channels

Rename Channel_Count() to Channel_CountVisible() and only count channels that are visible to the requesting client, so the existence of secret channels is no longer revealed by using LUSERS. Reported by Cahata -- thanks!


43509fd22c Alexander Barton

IRC_Send_LUSERS(): Code cleanup


a71abfef4b Alexander Barton

Don't stop mode handling on unknown modes; skip it

Unknown user and channel modes no longer stop the mode parser, but are simply ignored. Therefore modes after the unknown one are now handled. This is how ircd2.10/ircd2.11/ircd-seven behave, at least. Reported by Cahata -- thanks!


8a8e8a3a23 Alexander Barton

IRC_xLINE(): output an error message for unexpected "lines"

This fixes: irc-oper.c: In function ‘IRC_xLINE’: irc-oper.c:429: warning: ‘class’ may be used uninitialized in this function irc-oper.c:430: warning: ‘class_c’ may be used uninitialized in this function


65befdafaa Alexander Barton

README: Update list of implemented commands


15fec92ed7 Alexander Barton

Update list item, if it already exists

This updates the "validity" (timeout) as well as the "reason" text, if given.


1e4a00f94f Alexander Barton

Lists_CheckDupeMask(): return pointer to already existing item

The old behavior of returning true/false is compatible to this change, so there are no other code changes required.


338758799d Alexander Barton

Log better error messages when rejecting clients


164e15b8c6 Alexander Barton

Synchronize G-Lines on server login



6ef20e0f9a Alexander Barton

Class_GetList() now retuns a pointer to list_head structure


e86e193e01 Alexander Barton

Check G-Line and K-Line lists after authenticating clients


ae5ebfb9f0 Alexander Barton

New functions Lists_Expire() and Class_Expire()

GLINE and KLINE lists are cleared automatically now, not when they are checked. So "STATS g" and "STATS k" no longer show expired entries :-)



e23f025dd6 Alexander Barton

Op_Check(): return client that initiated the request or NULL

The old behavior of returning true/false is compatible to this change, so there are no other code changes required.


3ca8703309 Alexander Barton

irc-oper.c: code cleanup; more documentation


fc82efc3e8 Alexander Barton

Implement IRC "STATS g" and "STATS k" command


dc9fcb0fb2 Alexander Barton

New function Class_GetList()


2b95c69ea1 Alexander Barton

lists.{c|h}: code cleanup; more documentation


af70c3dbc9 Alexander Barton

List and class handling: add optional "reason" text

Adjust Lists_Add() and Class_AddMask() accordingly, implement Lists_GetReason() and Lists_GetValidity().


1e054e0b82 Alexander Barton

Add new class.{c|h} module to Xcode project


06a20b87c4 Alexander Barton

Add new class.{c|h} to project

Implement Class_{AddMask|DeleteMask|IsMember}() functions.


fea2194fc0 Alexander Barton

Lists: change "only once" property into "valid until"

The old "only once" true/false behavior is still supported, so there are no other code changes required.


872dc5042d Alexander Barton

Xcode: update project file for Xcode 4.2


e1315f30fd Alexander Barton

define HAVE_GAI_STRERROR for Mac OS X Xcode builds

On Mac OS X 10.7 Lion, this fixes In file included from .../contrib/MacOSX/../../src/ngircd/client.c:28: /Developer/SDKs/MacOSX10.7.sdk/usr/include/netdb.h:272:13: error: expected identifier or '('


0a85c58878 Alexander Barton

Configuration: get rid of Conf_Oper_Count and Conf_Channel_Count

Count elements dynamically when needed.


ee21490887 Alexander Barton

./configure: Fix logic and quoting of poll() detection code

This fixes commit 8e193df ...


8fa92f0a24 Alexander Barton

Suppress 'Can't create pre-defined channel: invalid name: ""' messages

Skip predefined channel structures that have configured no name, like the "--configtest" does.


8e193df973 Alexander Barton

Only use poll() when poll.h exists as well


9d348d00d9 Alexander Barton

Not only check for poll(), make sure poll.h exists as well

This fixes building ngIRCd on Debian GNU/Linux 1.3 "Bo" :-)


9e48f3f8f8 Alexander Barton

whois-test: handle local hostname = "localhost.localdomain"

Use the pattern "localhost*" for valid local hostnames.


e4a06844a3 Alexander Barton

sample-ngircd.conf: show correct default for "PAM" variable

The default of "PAM" is "yes" when ngIRCd has been configured to use it, so show the correct default value in the sample configuration file. Closes #119.


20ccc1bba7 Alexander Barton

Update GPL 2 license text to current version

See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.


13d9e0c5a7 Alexander Barton

Test for gai_strerror()

If gai_strerror() isn't available, use a macro that simply returns a static error message (regardless of the real error code). For example, GNU libc 2.0.7 doesn't implement gai_strerror().


a7911e35af Alexander Barton

Only use AI_NUMERICHOST if it is #define'd

It isn't using GNU libc 2.0.7, for example ...


60812b6fdf Alexander Barton

defines.h: fix comment: "lenth" -> "length"

Reported by Christoph Biedl in #ngircd. Thanks!


1ea6811616 Alexander Barton

Init_Server_Struct(): correctly zero Server->bind_addr

Don't use the size of the pointer, use the size of the variable!


d2f54abbed Alexander Barton

Clean up and fix comments of Check_ArgIsTrue()

Thanks to kaFux for pointing this out! And fix code formatting as well ...


07dbb73c92 Alexander Barton

Update doc/GIT.txt


30796698a9 Alexander Barton

Only close "unrelated" sockets in forked child processes

This fixes the problem that ngIRCd can't do any IDENT lookups because of the socket has already been closed in the child process. The bug has been introduced starting with ngIRCd 17 ... :-( (commit ID 6ebb31ab35e)


f173a974be Alexander Barton

Added doc/Modes.txt: document modes supported by ngIRCd


8aac366802 Alexander Barton

Implemented user mode "R" and channel mode "R"

- User mode "R": indicates that the nick name of this user is "registered". This mode isn't handled by ngIRCd itself, but must be set and unset by IRC services like Anope. - Channel mode "R": only registered users (having the user mode "R" set) are allowed to join this channel.


69803d6ff1 Alexander Barton

Use Proc_Close() to remove no longer unused pipes to child processes

This removes spurious (but harmless) debug messages.



1361b3742d Alexander Barton

Introduce DEBUG_BUFFER, rework some debug messages

DEBUG_BUFFER is off by default and therefore disables these messages: - "Handle_Write() called for connection XX, YY bytes pending ..." - "Connection XX: ZZ bytes left in read buffer."


d3036c74e9 Alexander Barton

Testsuite: bind to loopback (127.0.0.1) interface only


553e8b6aa3 Alexander Barton

doc/Platforms.txt: ngIRCd 18 on Nexenta works

Thanks to Götz Hoffart for testing!


51d7674ee7 Alexander Barton

New 2nd message "Nickname too long" for error code 432


1189200d4a Alexander Barton

Client_CheckNick(), Client_IsValidNick(): code cleanup


7795b07c53 Alexander Barton

Merge branch 'ServerMode'

* ServerMode: Handle channel user modes 'a', 'h', and 'q' from remote servers Handle unknown channel modes on server links Handle unknown user modes on server links IRC_MODE(), Client_Mode(): code cleanup [2/2] Enlarge client user mode buffer, reduce client flags buffer Infom clients when other servers change their user modes IRC_MODE(), Client_Mode(): code cleanup [1/2]


d9325e8030 Alexander Barton

Merge branch 'bug113-SrvPrefix'

* bug113-SrvPrefix: Slightly change (and document!) IRC_KILL() calling convention Spoofed prefixes: close connection on non-server links only


989c9fa531 Alexander Barton

Handle channel user modes 'a', 'h', and 'q' from remote servers

These channel user modes aren't used for anything at the moment, but ngIRCd knows that these three modes are "channel user modes" and not "channel modes", that is that these modes take an "nick name" argument. Like unknown user and channel modes, these modes are saved and forwarded, but ignored otherwise.


641045249c Alexander Barton

Xcode: update project file to Xcode 3.2 or newer

Xcode requires Mac OS X 10.6 or newer; Xcode 4 supports this project format as well, so effectively you can use Mac OS X 10.6.x or 10.7.x for building ngIRCd with the Apple Xcode IDE.


2fd42667c2 Alexander Barton

Handle unknown channel modes on server links


456e55921d Alexander Barton

Slightly change (and document!) IRC_KILL() calling convention



2dfa24d2fa Alexander Barton

Handle unknown user modes on server links


6cbe13085d Alexander Barton

Spoofed prefixes: close connection on non-server links only

On server-links, spoofed prefixes can happen because of the asynchronous nature of the IRC protocol. So don't break server-links, only log a message and ignore the command. This fixes bug 113, see: <https://arthur.barton.de/bugzilla/show_bug.cgi?id=113>



1ed602eb47 Alexander Barton

IRC_MODE(), Client_Mode(): code cleanup [2/2]



160c52400f Alexander Barton

Cast getpid() and time() results for srand() input

This fixes: src/ngircd/ngircd.c:596: warning: implicit conversion shortens 64-bit value into a 32-bit value (i686-apple-darwin11-llvm-gcc-4.2)


ea725b99b7 Alexander Barton

Enlarge client user mode buffer, reduce client flags buffer

We have to enlage our user mode buffer, so we can handle even unknown user modes in the future; and reduce the client flags buffer, because I can't imagine why we ever would need ~100 flags!? Now we support up to 15 user modes (was: 8) and up to 15 flags (was: 99). So in the end, we even save 99-15+8-15=77 bytes for each client structure!


04744e9d89 Alexander Barton

ngIRCd release 18 (tags/rel-18)


0b8acf1205 Alexander Barton

Xcode: update and add missing files to project


3dc3a03538 Alexander Barton

Infom clients when other servers change their user modes


54f04f81e9 Alexander Barton

Update ChangeLog and NEWS for ngIRCd release 18


88f6fc5fd8 Alexander Barton

IRC_QUIT(): disconnect directly linked servers sending QUIT

Without this patch, the server becomes removed from the network and the client structures, but the connection isn't shut down at all ...


d692286d7a Alexander Barton

IRC_MODE(), Client_Mode(): code cleanup [1/2]


95e156b519 Alexander Barton

Updated doc/Platforms.txt for ngIRCd release 18


da897a2a14 Alexander Barton

contrib/ngindent: detect "gindent" as GNU indent


9f3690c39c Alexander Barton

Testsuite: make getpid.sh work even when run as root

Use ps(1) flag "-a" (as well as "-f"): "Select all processes except both session leaders (see getsid(2)) and processes not associated with a terminal." Thanks to Götz Hoffart for reporting this problem!


e160121698 Alexander Barton

MorePrivacy: Don't register WHOWAS information

Citing an email from Florian to the ngIRCd mailing list: "I wonder what the expected behaviour is when Conf_MorePrivacy is changed from 'yes' to 'no' and the config is reloaded. At the moment, WHOWAS will start giving out information on Users that were connected during Conf_MorePrivacy=yes period. If this is not wanted, Client_RegisterWhowas() should be changed to not store a record when Conf_MorePrivacy is enabled." And I think it is "not wanted" :-)



54566b6b32 Alexander Barton

Add preliminary ngIRCd protocol module for Anope 1.9

See contrib/Anope/README and doc/Services.txt for more details and installation instructions!


409b2c86c8 Alexander Barton

Updated doc/Platforms.txt: mipsel/unknown/linux-gnu


c041bb340c Alexander Barton

Update timestamp of ngircd(8) manual page


af60f04fef Alexander Barton

ngIRCd release 18~rc2 (tags/rel-18-rc2)


2d35731399 Alexander Barton

GnuTLS: use 1024 (DH_BITS_MIN) as minimum size of the DH prime

For outgoing connections, we use 2048 (DH_BITS) since commit 49b2d0e. This patch enables ngIRCd to accept incoming connections from other servers and clients that use at least 1024 bits (and no longer requires 2048 for incoming connections, too). Patch proposed by Florian Westphal.


7ae7ace579 Alexander Barton

ngircd.8: document debugging options



bd118c65fd Alexander Barton

Fix some wording, use spellchecker ;-)


29c49f643f Alexander Barton

doc/SSL.txt: adopt to new configuration file layout


b6185b1ac8 Alexander Barton

ngIRCd release 18~rc1 (tags/rel-18-rc1)


14afdaee08 Alexander Barton

hash: Use UINT32 instead of uint32_t


949c8ea7c7 Alexander Barton

Update NEWS and ChangeLog file for our upcoming next release


1765f0ae0b Florian Westphal

hash: use more recent lookup3 algorithm instead of lookup2

Bob Jenkins published a newer hash function in May 2006, it has better distribution. See http://burtleburtle.net/bob/hash/doobs.html for lengthy comparisions.



d99edb7728 Alexander Barton

Merge branch 'MorePrivacy'

* MorePrivacy: New configuration opion "MorePrivacy" to "censor" some user information



b80e115f39 Alexander Barton

New configuration opion "MorePrivacy" to "censor" some user information

this patch contains: * Fix for Conf_CloakUserToNick to make it conceal user details * Adds MorePrivacy-feature MorePrivacy censors some user information from being reported by the server. Signon time and idle time is censored. Part and quit messages are made to look the same. WHOWAS requests are silently dropped. All of this is useful if one wish to conceal users that access the ngircd servers from TOR or I2P.


269310f04b Alexander Barton

Merge branch 'ScrubCTCP'

* ScrubCTCP: Add documentation for "ScrubCTCP" configuration option New option to scrub incoming CTCP commands


6aad5a6706 Alexander Barton

INSTALL: document changed location of configuration variables


3282c1325e Alexander Barton

Merge branch 'newconfig'

* newconfig: sample-ngircd.conf: "SyslogFacility" should be commented out Move SSL-related configuration variables to new [SSL] section CheckFileReadable(): only check when a filename is given ... PAM: make clear which "Password" config option is ignored Really remove [Features] in our manual pages INSTALL: document changed location of configuration variables Update sample config file and manual page for new config structure Testsuite: update configuration files for new config file format Display configuration errors more prominent on "--configtest" conf.c: code cleanup Check for redability of SSL-related files like for MOTD file Restructure ngIRCd configuration, introduce [Limits] and [Options]


5410d96748 Alexander Barton

Add documentation for "ScrubCTCP" configuration option



3d0ce77f12 Alexander Barton

sample-ngircd.conf: "SyslogFacility" should be commented out


f087c68a99 Alexander Barton

New option to scrub incoming CTCP commands

This patch makes it possible to scrub incomming CTCP commands from other servers and clients alike. The ngircd oper can enable it from the config file, by adding "ScrubCTCP = yes" under [OPTIONS]. It is default off. CTCP can be used to profile IRC users (get user clients name and version, and also their IP addresses). This is not something we like to happen when user pseudonymity/secrecy is important. The server silently drops incomming CTCP requests from both other servers and from users. The server that scrubs CTCP will not forward the CTCP requests to other servers in the network either, which can spell trouble if not every oper knows about the CTCP-scrubbing. Scrubbing CTCP commands also means that it is not possible to send files between users. There is one exception to the CTCP scrubbing performed: ACTION ("/me commands") requests are not scrubbed. ACTION is not dangerous to users (unless they use OTR, which does not encrypt CTCP requests) and most users would be confused if they were just dropped. A CTCP request looks like this: ctcp_char, COMMAND, arg0, arg1, arg2, .. argN, ctcp_char ctcp_char is 0x01. (just like bold is 0x02 and color is 0x03.) They are sent as part of a message and can be delivered to channels and users alike.



b1786f309e Alexander Barton

New documentation: "how to contribute"


946d838de4 Alexander Barton

Move SSL-related configuration variables to new [SSL] section


d41f4d6d20 Alexander Barton

Display configuration errors more prominent on "--configtest"


42b32f8a2a Florian Westphal

conn: fix error handling when connecting to server

The io_event_create error handling seems to miss a 'return' statement. Fix this by moving io_event_create() call around so we do not need the Conn_Close/Init calls in the error case.


a085444035 Alexander Barton

CheckFileReadable(): only check when a filename is given ...


391cf4e2a1 Alexander Barton

conf.c: code cleanup


49b2d0ec98 Florian Westphal

ssl: gnutls: bump dh bitsize to 2048

problem is that some clients refuse to connect to severs that only offer 1024. For interoperability it would be best to just use 4096, but that takes minutes, even on current hardware.


449ad1eeea Alexander Barton

PAM: make clear which "Password" config option is ignored


7ef6cb4584 Alexander Barton

Check for redability of SSL-related files like for MOTD file

Remove functions ssl_print_configvar() and ConfSSL_Puts(), introduce new function CheckFileReadable().


dd7d64f577 Alexander Barton

Mac OS X: split up make targets

New targets are: "have-packagemaker", "osxpkg-dest"


9dfde13f0c Alexander Barton

Really remove [Features] in our manual pages


e7256bb8ac Alexander Barton

Restructure ngIRCd configuration, introduce [Limits] and [Options]

The intention of this restructuring is to make the [Global] section much cleaner, so that it only contains variables that most installations must adjust to the local requirements. All the optional variables are moved to [Limits], for configurable limits and timers of ngIRCd, and [Options], for optional features. The old variables in the [Global] section are deprecated now, but still recognized.


605b6a67bc Florian Westphal

fix clang warning about dead stores

clang 'scan-build': Value stored to 'r' is never read Value stored to 'fd' is never read


10c7a15687 Alexander Barton

contrib/platformtest.sh: fix gcc version detection

Now the version of GNU C is detected correctly on SuSE Linux, too ...


05748aa5ee Florian Westphal

parse: fix logical expression testing for non RFC1459 links

parse.c:284: warning: suggest parentheses around operand of '!' or change '&' to '&&' or '!' to '~' The expression looks dubious, this should probably be an if-not-set, then... test.


0bb892bb5f Florian Westphal

conn: avoid needlesly scary 'buffer overflow' messages

When the write buffer space grows too large, ngircd has to disconnect the client to avoid wasting too much memory. ngircd logs this with a scary 'write buffer overflow' message. Change this to a more descriptive wording.


c26ca7773b Alexander Barton

Only require server prefixes on non RFC1459 links

Not all servers (and services!) using the RFC1459 protocol style send prefixes on all commands; so don't require them to do so. This relaxes the requirements introduced by commit 15775e679.


1cb2f5739d Alexander Barton

Merge branch 'master' of git://arthur.barton.de/ngircd-alex

* 'master' of git://arthur.barton.de/ngircd-alex: Do reverse lookups using the AF of the incoming connection resolve: fix reverse lookups of client connections with ConnectIPv6=no


160f5725a6 Alexander Barton

Do reverse lookups using the AF of the incoming connection

This fixes errors like this one: Address mismatch: 2001:1234:abcd:1::1 != 192.168.1.1


66315cab9a Alexander Barton

Mac OS X: install on root volume only, and set correct permissions

Update Mac OS X Installer.app description bundle, so that the ngIRCd package can only be installed on the root volume ("/"); and make sure that all installed files and directories have correct ownership and permissions.


e4e1595bff Florian Westphal

resolve: fix reverse lookups of client connections with ConnectIPv6=no

We re-use the same helper function for both forward lookups (when we want to connect to a peer server) and for validation of reverse loopups (where we make a lookup on the hostname returned by a reverse lookup on the IP address that connected). Problem: When ConnectIPv6=no, the forward lookup helper sets the adderss family to AF_INET, and, if out client connected via ipv6, we fail to validate the result. Thus move the ConnectIPvX check out of the helper.


67a9d994e3 Alexander Barton

Mac OS X: update installer texts and add logo.


1cd8d7f386 Alexander Barton

Doxygen'ify conf.c


9a102ca96b Alexander Barton

New function Config_Error_Section(); and code cleanup


e70e81460b Alexander Barton

Add some type casts to random() and srandom() functions

This fixes two gcc warnings (on Mac OS X): "warning: implicit conversion shortens 64-bit value into a 32-bit value"


5acb90fafc Florian Westphal

ngircd: improve rng initialisation

we do not need this for cryptographic purposes, but we can do better than plain srandom(getpid()). Also, keep in mind that rng state is inherited across fork(), so re-init it in the child.


d61fbfc6e3 Alexander Barton

Merge branch 'AuthPing'

* AuthPing: Add documentation for "RequireAuthPing" configuration option New configuration option "RequireAuthPing": PING-PONG on login


cf7e3b1c02 Alexander Barton

Merge branch 'NoticeAuth'

* NoticeAuth: Add documentation for "NoticeAuth" configuration option Configuration: move "NoticeAuth" to GLOBAL section New configuration option "NoticeAuth": send NOTICE AUTH on connect


fc0b026149 Alexander Barton

Add documentation for "RequireAuthPing" configuration option



680db6755b Alexander Barton

Add documentation for "NoticeAuth" configuration option


162433398e Alexander Barton

New configuration option "RequireAuthPing": PING-PONG on login

When enabled, this configuration option lets ngIRCd send a PING with an numeric "token" to clients logging in; and it will not become registered in the network until the client responds with the correct PONG. This is used by QuakeNet for example (ircu/snircd), and looks like this: NICK nick :irc.example.net PING :1858979527 USER user . . :real name PONG 1858979527 :irc.example.net 001 nick :Welcome to the Internet Relay Network ...