8 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Mon, 5 Mar 2012 21:29:53 +0000 (22:29 +0100)]
Update NEWS and ChangeLog files

8 years agoReally include _all_ patches to build the Anope module
Alexander Barton [Mon, 5 Mar 2012 20:26:03 +0000 (21:26 +0100)]
Really include _all_ patches to build the Anope module

8 years Fix testcase error for Debian using sbuild
Christoph Biedl [Sat, 3 Mar 2012 17:53:03 +0000 (18:53 +0100)] Fix testcase error for Debian using sbuild


 * 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, will report a fail as
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 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

8 years agoDon't log "ngIRCd hello message" two times
Alexander Barton [Fri, 2 Mar 2012 08:41:13 +0000 (09:41 +0100)]
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)

8 years agongIRCd release 19 rel-19
Alexander Barton [Wed, 29 Feb 2012 16:35:32 +0000 (17:35 +0100)]
ngIRCd release 19

8 years agoMerge branch 'master' of /srv/git/ngircd
Alexander Barton [Wed, 29 Feb 2012 13:47:37 +0000 (14:47 +0100)]
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

8 years agoUpdate doc/Platforms.txt for ngIRCd 19
Alexander Barton [Wed, 29 Feb 2012 13:42:41 +0000 (14:42 +0100)]
Update doc/Platforms.txt for ngIRCd 19

8 years agodoc/README-Interix.txt: note that GNU make should be used
Alexander Barton [Wed, 29 Feb 2012 12:20:09 +0000 (13:20 +0100)]
doc/README-Interix.txt: note that GNU make should be used

8 years agoUpdate config.guess and config.sub to recent versions
Alexander Barton [Mon, 27 Feb 2012 15:39:01 +0000 (16:39 +0100)]
Update config.guess and config.sub to recent versions

8 years agoDon't accept "[SSL]" in config when no SSL support is built in
Alexander Barton [Sun, 26 Feb 2012 14:52:12 +0000 (15:52 +0100)]
Don't accept "[SSL]" in config when no SSL support is built in

8 years agoFix C syntax: duplicate ";;" should be ";"
Alexander Barton [Sun, 26 Feb 2012 14:27:04 +0000 (15:27 +0100)]
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'

8 years agoCorrectly re-open syslog logging after reading of configuration
Alexander Barton [Tue, 14 Feb 2012 10:01:13 +0000 (11:01 +0100)]
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!

8 years agoLogging: remove "Activating ..." info message
Alexander Barton [Tue, 14 Feb 2012 09:32:58 +0000 (10:32 +0100)]
Logging: remove "Activating ..." info message

8 years agongIRCd release 19~rc1 rel-19-rc1
Alexander Barton [Sun, 12 Feb 2012 16:58:50 +0000 (17:58 +0100)]
ngIRCd release 19~rc1

8 years agoUpdate RPM spec file description to match Debian "control file"
Alexander Barton [Sun, 12 Feb 2012 16:57:33 +0000 (17:57 +0100)]
Update RPM spec file description to match Debian "control file"

8 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Sun, 12 Feb 2012 15:48:57 +0000 (16:48 +0100)]
Update NEWS and ChangeLog files

8 years agoFix forwarding of LIST commands
Alexander Barton [Sun, 12 Feb 2012 12:51:43 +0000 (13:51 +0100)]
Fix forwarding of LIST commands

Bug reported by Cahata, thanks!

8 years agoUpdate preliminary ngIRCd protocol module for Anope 1.9.6
Alexander Barton [Sat, 4 Feb 2012 11:55:41 +0000 (12:55 +0100)]
Update preliminary ngIRCd protocol module for Anope 1.9.6

8 years agoNew_Connection(): don't set the client hostname twice
Alexander Barton [Wed, 25 Jan 2012 16:11:44 +0000 (17:11 +0100)]
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 []) ...

8 years agoClient_SetHostname(): Code cleanup, more debug logging
Alexander Barton [Wed, 25 Jan 2012 16:11:00 +0000 (17:11 +0100)]
Client_SetHostname(): Code cleanup, more debug logging

8 years agoio: use define for number of possible events
Florian Westphal [Tue, 24 Jan 2012 21:24:47 +0000 (22:24 +0100)]
io: use define for number of possible events

8 years agoio: remove outer do {} while loops for epoll/kqueue/devpoll backends
Florian Westphal [Tue, 24 Jan 2012 20:57:23 +0000 (21:57 +0100)]
io: remove outer do {} while loops for epoll/kqueue/devpoll backends

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

8 years agoEnhance server command limits
Alexander Barton [Tue, 24 Jan 2012 01:55:53 +0000 (02:55 +0100)]
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.

8 years agoSend a PING at the end of the server sync to detect it
Alexander Barton [Tue, 24 Jan 2012 01:46:12 +0000 (02:46 +0100)]
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.

8 years agoNew function Conn_UpdatePing() to update the "ping timestamp"
Alexander Barton [Tue, 24 Jan 2012 01:44:57 +0000 (02:44 +0100)]
New function Conn_UpdatePing() to update the "ping timestamp"

8 years agoConn_UpdateIdle(): Code cleanup
Alexander Barton [Tue, 24 Jan 2012 01:43:55 +0000 (02:43 +0100)]
Conn_UpdateIdle(): Code cleanup

8 years agoRPL_ISUPPORT_MSG(005): add "EXCEPTS=e INVEX=I"
Alexander Barton [Mon, 23 Jan 2012 21:07:40 +0000 (22:07 +0100)]

Thanks to Cahata for the idea!

8 years agoFix "MAXLIST=beI:50": the limit is the sum of all lists
Alexander Barton [Mon, 23 Jan 2012 20:51:38 +0000 (21:51 +0100)]
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 <>,
thanks to Cahata for reporting this!

8 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Mon, 23 Jan 2012 11:30:16 +0000 (12:30 +0100)]
Update NEWS and ChangeLog files

8 years agoNew RPL_WHOISHOST_MSG(378): show hostname and IP address
Alexander Barton [Sun, 22 Jan 2012 21:41:39 +0000 (22:41 +0100)]
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.

8 years agoNew function Conn_GetIPAInfo(): get IP address of a connection
Alexander Barton [Sun, 22 Jan 2012 21:35:27 +0000 (22:35 +0100)]
New function Conn_GetIPAInfo(): get IP address of a connection

8 years agoG/K-Lines: only add and delete valid IRC masks
Alexander Barton [Sun, 22 Jan 2012 17:53:16 +0000 (18:53 +0100)]
G/K-Lines: only add and delete valid IRC masks

8 years agoCheck G/K-Lines before the client has been registered, too
Alexander Barton [Sun, 22 Jan 2012 17:35:54 +0000 (18:35 +0100)]
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.

8 years agoStreamline handling of connection rejects (bad password, G/K-line)
Alexander Barton [Sun, 22 Jan 2012 17:33:45 +0000 (18:33 +0100)]
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().

8 years agoNew function Client_Reject() to reject clients on connect
Alexander Barton [Sun, 22 Jan 2012 17:17:28 +0000 (18:17 +0100)]
New function Client_Reject() to reject clients on connect

8 years agoNew function Lists_CheckReason() to get reason of list entries
Alexander Barton [Sun, 22 Jan 2012 17:11:24 +0000 (18:11 +0100)]
New function Lists_CheckReason() to get reason of list entries

8 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Sun, 22 Jan 2012 14:58:39 +0000 (15:58 +0100)]
Update NEWS and ChangeLog files

8 years agoFix ERR_{SUMMON|USERS}DISABLED: don't repeat command name in reply
Alexander Barton [Sun, 22 Jan 2012 14:41:21 +0000 (15:41 +0100)]
Fix ERR_{SUMMON|USERS}DISABLED: don't repeat command name in reply

8 years agoImplement channel exception list (mode 'e')
Alexander Barton [Sat, 21 Jan 2012 18:59:57 +0000 (19:59 +0100)]
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).

8 years ago{Add|Del}_Ban_Invite > {Add_To|Del_From}_List(): more generic
Alexander Barton [Sat, 21 Jan 2012 18:27:03 +0000 (19:27 +0100)]
{Add|Del}_Ban_Invite > {Add_To|Del_From}_List(): more generic

8 years agoRename ShowInvitesBans() to ShowChannelList(), make it more flexible
Alexander Barton [Sat, 21 Jan 2012 12:48:31 +0000 (13:48 +0100)]
Rename ShowInvitesBans() to ShowChannelList(), make it more flexible

8 years agoPRIVMSG/NOTICE: handle nick!user@host masks case-insensitive
Alexander Barton [Sat, 21 Jan 2012 12:21:36 +0000 (13:21 +0100)]
PRIVMSG/NOTICE: handle nick!user@host masks case-insensitive

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

8 years agoPRIVMSG/NOTICE: don't stop list processing on invalid target
Alexander Barton [Mon, 16 Jan 2012 11:37:37 +0000 (12:37 +0100)]
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.

8 years agoImplement user mode 'C': require "same channel" to send message
Alexander Barton [Mon, 16 Jan 2012 10:43:22 +0000 (11:43 +0100)]
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.

8 years agoNew RPL_WHOISREGNICK_MSG(307) numeric: indicate if nick is registered
Alexander Barton [Mon, 16 Jan 2012 01:18:24 +0000 (02:18 +0100)]
New RPL_WHOISREGNICK_MSG(307) numeric: indicate if nick is registered

8 years agoIRC_WHOIS_SendReply(): Code cleanup
Alexander Barton [Mon, 16 Jan 2012 01:15:41 +0000 (02:15 +0100)]
IRC_WHOIS_SendReply(): Code cleanup

8 years agoLimit channel invite and ban lists to 50 entries
Alexander Barton [Sun, 15 Jan 2012 23:26:12 +0000 (00:26 +0100)]
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")

8 years agoMake Send_ListChange() a little bit more generic
Alexander Barton [Sun, 15 Jan 2012 23:15:26 +0000 (00:15 +0100)]
Make Send_ListChange() a little bit more generic

8 years agoRemove unused prototype of Lists_AlreadyRegistered()
Alexander Barton [Sun, 15 Jan 2012 18:46:00 +0000 (19:46 +0100)]
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 ...

8 years agoChannel lists: Fix duplicate check and error messages
Alexander Barton [Sun, 15 Jan 2012 18:07:15 +0000 (19:07 +0100)]
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().

8 years agoDon't enforce MAX_HNDL_MODES_ARG on server and service links
Alexander Barton [Sun, 15 Jan 2012 13:33:04 +0000 (14:33 +0100)]
Don't enforce MAX_HNDL_MODES_ARG on server and service links

8 years agoUpdate documentation (fix some URL, update some info)
Alexander Barton [Sat, 14 Jan 2012 11:29:53 +0000 (12:29 +0100)]
Update documentation (fix some URL, update some info)

8 years agoUpdate NEWS and ChangeLog for next ngIRCd release once more
Alexander Barton [Fri, 13 Jan 2012 18:23:07 +0000 (19:23 +0100)]
Update NEWS and ChangeLog for next ngIRCd release once more

8 years agoDon't stop join handling on faulty channel, skip it (part #2)
Alexander Barton [Fri, 13 Jan 2012 09:43:05 +0000 (10:43 +0100)]
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.

8 years agoJOIN command: don't check channel limit if already member
Alexander Barton [Fri, 13 Jan 2012 09:40:20 +0000 (10:40 +0100)]
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.

8 years agoReturn ERR_UNKNOWNMODE(472) for unknown channel modes
Alexander Barton [Mon, 9 Jan 2012 22:18:39 +0000 (23:18 +0100)]
Return ERR_UNKNOWNMODE(472) for unknown channel modes

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

8 years agoNumberic 005 (ISUPPORT), CHANMODES: add "O", "R", "z" modes
Alexander Barton [Mon, 9 Jan 2012 11:34:55 +0000 (12:34 +0100)]
Numberic 005 (ISUPPORT), CHANMODES: add "O", "R", "z" modes

8 years agoLimit list replies of LIST, WHO, WHOIS, and MAX_RPL_WHOWAS
Alexander Barton [Fri, 6 Jan 2012 19:06:25 +0000 (20:06 +0100)]
Limit list replies of LIST, WHO, WHOIS, and MAX_RPL_WHOWAS

Introduce new #define's MAX_RPL_LIST(100), MAX_RPL_WHO(25),

8 years agoNew function IRC_CheckListTooBig() to check size of list replies
Alexander Barton [Fri, 6 Jan 2012 19:05:07 +0000 (20:05 +0100)]
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.

8 years agoLIST command: compare pattern case insensitive
Alexander Barton [Fri, 6 Jan 2012 18:55:21 +0000 (19:55 +0100)]
LIST command: compare pattern case insensitive

8 years agoIRC_LIST(): Code cleanup
Alexander Barton [Fri, 6 Jan 2012 18:54:23 +0000 (19:54 +0100)]
IRC_LIST(): Code cleanup

Alexander Barton [Fri, 6 Jan 2012 17:56:53 +0000 (18:56 +0100)]

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

8 years agodefines.h: Code cleanup and (a little bit) more documentation
Alexander Barton [Fri, 6 Jan 2012 17:25:10 +0000 (18:25 +0100)]
defines.h: Code cleanup and (a little bit) more documentation

8 years agoRPL_ISUPPORT (numeric 005): Report MODES=<MAX_CMODES_ARG>
Alexander Barton [Fri, 6 Jan 2012 16:46:52 +0000 (17:46 +0100)]

"Maximum number of channel modes with parameter allowed per MODE command."
See <> for details.

8 years agoChannel modes: really break handling when MAX_CMODES_ARG is hit
Alexander Barton [Fri, 6 Jan 2012 16:42:52 +0000 (17:42 +0100)]
Channel modes: really break handling when MAX_CMODES_ARG is hit

This fixes 98493077.

8 years agochannel modes: only handle MAX_CMODES_ARG modes with arguments
Alexander Barton [Fri, 6 Jan 2012 16:27:29 +0000 (17:27 +0100)]
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) ...

8 years agoFix handling of channel mode sequence with/without arguments
Alexander Barton [Fri, 6 Jan 2012 16:24:55 +0000 (17:24 +0100)]
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".

8 years agoConn_Write(): Make sure there is a client when detecting its type
Alexander Barton [Fri, 6 Jan 2012 02:26:24 +0000 (03:26 +0100)]
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!

8 years agoProc_Close(): Only close socket if it is still valid
Alexander Barton [Fri, 6 Jan 2012 01:26:04 +0000 (02:26 +0100)]
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 :-(

8 years agoWHOIS command: make sure matching is case-insensitive
Alexander Barton [Wed, 4 Jan 2012 23:51:39 +0000 (00:51 +0100)]
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.

8 years agoWHOIS command: don't anser queries for IRC servers
Alexander Barton [Wed, 4 Jan 2012 23:24:46 +0000 (00:24 +0100)]
WHOIS command: don't anser queries for IRC servers

Thanks to Cahata for spotting this!

8 years agoWHOIS command: make sure the reply ends with RPL_ENDOFWHOIS
Alexander Barton [Wed, 4 Jan 2012 23:22:57 +0000 (00:22 +0100)]
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.

8 years agoREADME: update features list, borrow from list on our website
Alexander Barton [Wed, 4 Jan 2012 22:30:55 +0000 (23:30 +0100)]
README: update features list, borrow from list on our website

8 years agoLINKS command: support <mask> parameter
Alexander Barton [Wed, 4 Jan 2012 21:51:02 +0000 (22:51 +0100)]
LINKS command: support <mask> parameter

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

8 years agoIRC_LINKS(): Code cleanup; more documentation
Alexander Barton [Wed, 4 Jan 2012 21:49:18 +0000 (22:49 +0100)]
IRC_LINKS(): Code cleanup; more documentation

8 years agoAdd 1 second penalty for every further target on PRIVMSG/NOTICE
Alexander Barton [Wed, 4 Jan 2012 20:43:32 +0000 (21:43 +0100)]
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!

8 years agoConn_SetPenalty(): Add new "penalty time" on each function call
Alexander Barton [Wed, 4 Jan 2012 20:39:46 +0000 (21:39 +0100)]
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.

8 years agoEnhance log messages when setting user and group bug118-UnknownUID
Alexander Barton [Tue, 3 Jan 2012 20:05:35 +0000 (21:05 +0100)]
Enhance log messages when setting user and group

8 years agoNGIRCd_getNobodyID(): Code cleanup
Alexander Barton [Tue, 3 Jan 2012 19:49:42 +0000 (20:49 +0100)]
NGIRCd_getNobodyID(): Code cleanup

8 years agoDisplay correct error message when "Server{UID|GID}" is invalid
Alexander Barton [Tue, 3 Jan 2012 19:37:41 +0000 (20:37 +0100)]
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).

8 years agoNGIRCd_Init(): Code cleanup
Alexander Barton [Tue, 3 Jan 2012 18:34:54 +0000 (19:34 +0100)]
NGIRCd_Init(): Code cleanup

8 years agomain(): Code cleanup
Alexander Barton [Tue, 3 Jan 2012 18:25:31 +0000 (19:25 +0100)]
main(): Code cleanup

8 years agoREADME: point to included COPYING file, not
Alexander Barton [Tue, 3 Jan 2012 17:56:31 +0000 (18:56 +0100)]
README: point to included COPYING file, not

8 years agoUpdate Copyright notices for 2012
Alexander Barton [Tue, 3 Jan 2012 10:30:45 +0000 (11:30 +0100)]
Update Copyright notices for 2012

8 years agolists: don't crash if reason ptr is NULL
Florian Westphal [Mon, 2 Jan 2012 22:37:46 +0000 (23:37 +0100)]
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.

8 years agoDon't stop join handling on faulty channel, skip it
Alexander Barton [Mon, 2 Jan 2012 14:23:17 +0000 (15:23 +0100)]
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!

8 years agoIRC_JOIN(): Code cleanup
Alexander Barton [Mon, 2 Jan 2012 14:22:52 +0000 (15:22 +0100)]
IRC_JOIN(): Code cleanup

8 years agoISON command: reply with correct upper-/lowercase nick names
Alexander Barton [Mon, 2 Jan 2012 14:06:44 +0000 (15:06 +0100)]
ISON command: reply with correct upper-/lowercase nick names

Reported by Cahata -- thanks!

8 years agoIRC_ISON(): Code cleanup
Alexander Barton [Mon, 2 Jan 2012 14:04:40 +0000 (15:04 +0100)]
IRC_ISON(): Code cleanup

8 years agoRemove unused "bool have_arg" from IRC_WHO()
Alexander Barton [Sun, 1 Jan 2012 23:56:31 +0000 (00:56 +0100)]
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

8 years agoUpdate NEWS and ChangeLog for next ngIRCd release
Alexander Barton [Sun, 1 Jan 2012 22:14:28 +0000 (23:14 +0100)]
Update NEWS and ChangeLog for next ngIRCd release

8 years agongircd.conf.5: reword description of "Ports" variable
Alexander Barton [Sun, 1 Jan 2012 16:39:07 +0000 (17:39 +0100)]
ngircd.conf.5: reword description of "Ports" variable

8 years agoNew configuration option "PAMIsOptional"
Alexander Barton [Sun, 1 Jan 2012 16:12:36 +0000 (17:12 +0100)]
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.

8 years agoPAM: don't use global password buffer for conv struct
Alexander Barton [Sat, 31 Dec 2011 17:06:17 +0000 (18:06 +0100)]
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 ...

8 years agodoc/Modes.txt: document channel mode "r"
Alexander Barton [Sat, 31 Dec 2011 17:04:58 +0000 (18:04 +0100)]
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.

8 years agoFixed handling of WHO commands
Alexander Barton [Fri, 30 Dec 2011 13:52:48 +0000 (14:52 +0100)]
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.

8 years agoRemove unused "time_t now" from Lists_Check()
Alexander Barton [Fri, 30 Dec 2011 00:02:44 +0000 (01:02 +0100)]
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

8 years agoFixed some spelling errors in documentation and code comments
Alexander Barton [Thu, 29 Dec 2011 23:50:27 +0000 (00:50 +0100)]
Fixed some spelling errors in documentation and code comments

Thanks to Christoph Biedl!

8 years agocontrib/Debian/control: Update and complete "Build-Depends"
Alexander Barton [Thu, 29 Dec 2011 23:40:18 +0000 (00:40 +0100)]
contrib/Debian/control: Update and complete "Build-Depends"

8 years agoUpdate our Debian package descriptions with "official" ones
Alexander Barton [Thu, 29 Dec 2011 23:36:26 +0000 (00:36 +0100)]
Update our Debian package descriptions with "official" ones

See Debian Bug #648241 for details.