SECURITY: Fixed a severe bug in handling JOIN commands, which could cause
the server to crash. Thanks to Sebastian Vesper, <net@veoson.net>.

 ChangeLog                |    5 +++++
 src/ngircd/irc-channel.c |    4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)

Index: ChangeLog
===================================================================
RCS file: /srv/cvs/ngircd/ngircd/ChangeLog,v
retrieving revision 1.302.2.17
diff -u -p -r1.302.2.17 ChangeLog
--- ChangeLog	8 Jun 2007 09:05:23 -0000	1.302.2.17
+++ ChangeLog	30 Jul 2007 22:02:58 -0000
@@ -10,6 +10,11 @@
                                -- ChangeLog --
 
 
+ngIRCd 0.10.3 (2007-08-01)
+
+  - SECURITY: Fixed a severe bug in handling JOIN commands, which could
+    cause the server to crash. Thanks to Sebastian Vesper, <net@veoson.net>.
+
 ngIRCd 0.10.2 (2007-06-08)
 
   ngIRCd 0.10.2-pre2 (2007-05-19)
Index: src/ngircd/irc-channel.c
===================================================================
RCS file: /srv/cvs/ngircd/ngircd/src/ngircd/irc-channel.c,v
retrieving revision 1.35.2.3
diff -u -p -r1.35.2.3 irc-channel.c
--- src/ngircd/irc-channel.c	3 Apr 2007 20:23:31 -0000	1.35.2.3
+++ src/ngircd/irc-channel.c	30 Jul 2007 22:02:58 -0000
@@ -52,7 +52,9 @@ IRC_JOIN( CLIENT *Client, REQUEST *Req )
 	assert( Req != NULL );
 
 	/* Bad number of arguments? */
-	if(( Req->argc > 2 )) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command );
+	if (Req->argc < 1 || Req->argc > 2)
+		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
+					  Client_ID(Client), Req->command);
 
 	/* Who is the sender? */
 	if( Client_Type( Client ) == CLIENT_SERVER ) target = Client_Search( Req->prefix );
