Index: AUTHORS =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/AUTHORS,v retrieving revision 1.5.2.2 retrieving revision 1.8.2.1 diff -u -p -r1.5.2.2 -r1.8.2.1 --- a/AUTHORS 3 Feb 2004 16:01:29 -0000 1.5.2.2 +++ b/AUTHORS 7 May 2004 11:24:17 -0000 1.8.2.1 @@ -19,6 +19,7 @@ Contributors ~~~~~~~~~~~~ Goetz Hoffart, (goetz) Ilja Osthoff, (ilja) +Benjamin Pineau, Sean Reifschneider, @@ -30,4 +31,4 @@ Andrew Tridgell & Martin Pool: strl{cpy| -- -$Id: AUTHORS,v 1.5.2.2 2004/02/03 16:01:29 alex Exp $ +$Id: AUTHORS,v 1.8.2.1 2004/05/07 11:24:17 alex Exp $ Index: ChangeLog =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/ChangeLog,v retrieving revision 1.188.2.24 retrieving revision 1.233.2.2 diff -u -p -r1.188.2.24 -r1.233.2.2 --- a/ChangeLog 5 Feb 2004 13:33:24 -0000 1.188.2.24 +++ b/ChangeLog 7 May 2004 11:56:19 -0000 1.233.2.2 @@ -10,6 +10,34 @@ -- ChangeLog -- +ngIRCd 0.8.0-pre1 (2004-05-07) + + - Two new configuration options: "ChrootDir" and "MotdPhrase", thanks to + Benjamin Pineau . Now you can force the daemon to change + its root and working directory to something "safe". MotdPhrase is used + to define an "MOTD string" instead of a whole file, useful if the + "real" MOTD file would be outside the "jail". + - INVITE- and BAN-lists become synchronized between IRC+ servers when + establishing new connections, if the peer supports this as well. + - Reorganized autogen.sh and configure scripts. + - Fixed a wrong assert() which could cause the daemon to exit spuriously + when closing down connections. + - Better logging of decompression errors returned by zlib. + - Servers other than the destination server didn't clean up the invite + list of an "invite-only" channel properly when an INVITE'd user joined. + - Changed the reply of the MODE command to match the syntax of the + original ircd exactly: the unnecessary but missing ":" before the last + parameter has been added. + - Fixed TRACE: don't output "Serv" lines for ourself; display more info. + - Results of the resolver (hostnames and IDENT names) are discarded after + the client is successfully registered with the server. + - Better logging while establishing and shutting down connections. + - The type of service (TOS) of all sockets is set to "interactive" now. + - Added short command line option "-t" as alternative to "--configtest". + - Added optional support for "IDENT" lookups on incoming connections. You + have to enable this function with the ./configure switch "--with-ident". + The default is not to do IDENT lookups. + ngIRCd 0.7.7 (2004-02-05) - The info text ("real name") of users is set to "-" if none has been @@ -493,4 +521,4 @@ ngIRCd 0.0.1, 31.12.2001 -- -$Id: ChangeLog,v 1.188.2.24 2004/02/05 13:33:24 alex Exp $ +$Id: ChangeLog,v 1.233.2.2 2004/05/07 11:56:19 alex Exp $ Index: INSTALL =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/INSTALL,v retrieving revision 1.15.2.2 retrieving revision 1.18.2.1 diff -u -p -r1.15.2.2 -r1.18.2.1 --- a/INSTALL 3 Feb 2004 16:01:29 -0000 1.15.2.2 +++ b/INSTALL 7 May 2004 11:24:17 -0000 1.18.2.1 @@ -75,6 +75,11 @@ In addition, you can pass some command l and/or disable some features of ngIRCd. All these options are shown using "./configure --help", too. +Compiling a static binary will avoid you the hassle of feeding a chroot dir +(if you want use the chroot feature). Just do something like: + CFLAGS=-static ./configure [--your-options ...] +Then you can use a void directory as ChrootDir (like OpenSSH's /var/empty). + 3): "make" @@ -148,7 +153,7 @@ These parameters could be passed to the -p, --passive Server-links won't be automatically established. ---configtest +-t, --configtest Reads, validates and dumps the configuration file as interpreted by the server. Then exits. @@ -158,4 +163,4 @@ number. In both cases the server exits a -- -$Id: INSTALL,v 1.15.2.2 2004/02/03 16:01:29 alex Exp $ +$Id: INSTALL,v 1.18.2.1 2004/05/07 11:24:17 alex Exp $ Index: Makefile.am =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/Makefile.am,v retrieving revision 1.10.4.2 retrieving revision 1.14 diff -u -p -r1.10.4.2 -r1.14 --- a/Makefile.am 9 Jul 2003 21:14:08 -0000 1.10.4.2 +++ b/Makefile.am 1 Jan 2004 22:24:48 -0000 1.14 @@ -8,18 +8,18 @@ # (at your option) any later version. # Please read the file COPYING, README and AUTHORS for more information. # -# $Id: Makefile.am,v 1.10.4.2 2003/07/09 21:14:08 alex Exp $ +# $Id: Makefile.am,v 1.14 2004/01/01 22:24:48 alex Exp $ # AUTOMAKE_OPTIONS = gnu -SUBDIRS = doc MacOSX src man contrib debian +SUBDIRS = doc src man contrib maintainer-clean-local: rm -rf autom4te.cache rm -f Makefile.in Makefile aclocal.m4 configure rm -f mkinstalldirs missing depcomp install-sh - rm -f config.log + rm -f config.log build-stamp* debian lint: make -C src/ngircd lint @@ -28,6 +28,7 @@ rpm: distcheck rpm -ta ngircd-*.tar.gz deb: + [ -f debian/rules ] || ln -s contrib/Debian debian dpkg-buildpackage -rfakeroot # -eof- Index: NEWS =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/NEWS,v retrieving revision 1.53.2.6 retrieving revision 1.64.2.2 diff -u -p -r1.53.2.6 -r1.64.2.2 --- a/NEWS 3 Feb 2004 16:01:29 -0000 1.53.2.6 +++ b/NEWS 7 May 2004 11:56:19 -0000 1.64.2.2 @@ -10,6 +10,21 @@ -- NEWS -- +ngIRCd 0.8.0-pre1 (2004-05-07) + + - Two new configuration options: "ChrootDir" and "MotdPhrase", thanks to + Benjamin Pineau . Now you can force the daemon to change + its root and working directory to something "safe". MotdPhrase is used + to define an "MOTD string" instead of a whole file, useful if the + "real" MOTD file would be outside the "jail". + - INVITE- and BAN-lists become synchronized between IRC+ servers when + establishing new connections, if the peer supports this as well. + - The type of service (TOS) of all sockets is set to "interactive" now. + - Added short command line option "-t" as alternative to "--configtest". + - Added optional support for "IDENT" lookups on incoming connections. You + have to enable this function with the ./configure switch "--with-ident". + The default is not to do IDENT lookups. + ngIRCd 0.7.5 (2003-07-11) - New configuration variable "MaxConnectionsIP" to limit the number of @@ -18,7 +33,7 @@ ngIRCd 0.7.5 (2003-07-11) (DoS), the default is 5 connections per client IP. - Added new configuration variable "Listen" to bind all listening sockets of the server to a single IP address. - + ngIRCd 0.7.1 (2003-07-18) - Added support for GNU/Hurd. @@ -174,4 +189,4 @@ ngIRCd 0.0.1, 31.12.2001 -- -$Id: NEWS,v 1.53.2.6 2004/02/03 16:01:29 alex Exp $ +$Id: NEWS,v 1.64.2.2 2004/05/07 11:56:19 alex Exp $ Index: README =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/README,v retrieving revision 1.17.2.1 retrieving revision 1.18.2.1 diff -u -p -r1.17.2.1 -r1.18.2.1 --- a/README 3 Feb 2004 16:01:29 -0000 1.17.2.1 +++ b/README 7 May 2004 11:24:17 -0000 1.18.2.1 @@ -45,7 +45,8 @@ III. Features (or: why use ngIRCd?) - ngIRCd will be developed on in the future. - supported platforms (tested versions): AIX (3.2.5), A/UX (3.0.1), FreeBSD (4.5), HP-UX (10.20), IRIX (6.5), Linux (2.x), Mac OS X (10.x), NetBSD - (1.5.2/i386, 1.5.3/m68k), Solaris (2.5.1, 2.6), and Windows with Cygwin. + (1.5.2/i386, 1.5.3/m68k), Solaris (2.5.1, 2.6), Windows with Cygwin, and + OpenBSD (3.4/i386). IV. Documentation @@ -83,4 +84,4 @@ mail to: or # +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# Please read the file COPYING, README and AUTHORS for more information. +# +# $Id: autogen.sh,v 1.12 2004/04/05 12:02:21 alex Exp $ +# + +# +# Usage: [VAR=] ./autogen.sh [] +# +# This script generates the ./configure script using GNU automake and +# GNU autoconf. It tries to be smart in finding the correct/usable/available +# installed versions of these tools on your system. +# +# The following strategy is used for each of aclocal, autoheader, automake, +# and autoconf: first, "tool" (the regular name of the tool, e. g. "autoconf" +# or "automake") is checked. If this fails, "tool" (for example +# "automake16") and "tool-." (e. g. "autoconf-2.54") are tried +# with being 2 for tool of GNU autoconf and 1 for tools of automake; +# is tried from 99 to 0. The first occurrence will be used. +# +# When you pass to autogen.sh it will call the generated +# ./configure script on success and pass these parameters to it. +# +# You can tweak the behaviour using these environment variables: +# +# - ACLOCAL=, AUTOHEADER=, AUTOMAKE=, AUTOCONF= +# Name and optionally path to the particular tool. +# - PREFIX= +# Search the GNU autoconf and GNU automake tools in first. If the +# generated ./configure script will be called, pass "--prefix=" to it. +# - EXIST= +# Use to test for aclocal, autoheader etc. pp. ... +# When not specified, either "type" or "which" is used. +# - VERBOSE=1 +# Output the detected names of the GNU automake and GNU autoconf tools. +# - GO=1 +# Call ./configure even if no arguments have been passed to autogen.sh. +# +# Examples: +# +# - ./autogen.sh +# Generates the ./configure script. +# - GO=1 ./autogen.sh +# Generates the ./configure script and runs it as "./configure". +# - VERBOSE=1 ./autogen.sh --with-ident +# Show tool names, generates the ./configure script, and runs it with +# these arguments: "./configure --with-ident". +# - ACLOCAL=aclocal-1.6 GO=1 PREFIX=$HOME ./autogen.sh +# Uses "aclocal-1.6" as aclocal tool, generates the ./configure script, +# and runs it with these arguments: "./configure --prefix=$HOME". +# + +Search() +{ + [ $# -eq 2 ] || exit 1 -WANT_AUTOMAKE=1.6 + searchlist="$1" + major="$2" + minor=99 + + [ -n "$PREFIX" ] && searchlist="${PREFIX}/$1 ${PREFIX}/bin/$1 $searchlist" + + for name in $searchlist; do + $EXIST "${name}" >/dev/null 2>&1 + if [ $? -eq 0 ]; then + echo "${name}" + return 0 + fi + done + + while [ $minor -ge 0 ]; do + for name in $searchlist; do + $EXIST "${name}${major}${minor}" >/dev/null 2>&1 + if [ $? -eq 0 ]; then + echo "${name}${major}${minor}" + return 0 + fi + $EXIST "${name}-${major}.${minor}" >/dev/null 2>&1 + if [ $? -eq 0 ]; then + echo "${name}-${major}.${minor}" >/dev/null 2>&1 + return 0 + fi + done + minor=`expr $minor - 1` + done + return 1 +} + +Notfound() +{ + echo "Error: $* not found!" + echo "Please install recent versions of GNU autoconf and GNU automake." + exit 1 +} + +# Reset locale settings to suppress warning messages of Perl +unset LC_ALL +unset LANG + +# Which command should be used to detect the automake/autoconf tools? +[ -z "$EXIST" ] && existlist="type which" || existlist="$EXIST" +EXIST="" +for t in $existlist; do + $t /bin/ls >/dev/null 2>&1 + if [ $? -eq 0 ]; then + rm -f /tmp/test.$$ + $t /tmp/test.$$ >/dev/null 2>&1 + [ $? -ne 0 ] && EXIST="$t" + fi + [ -n "$EXIST" ] && break +done +if [ -z "$EXIST" ]; then + echo "Didn't detect a working command to test for the autoconf/automake tools!" + echo "Searchlist: $existlist" + exit 1 +fi +[ "$VERBOSE" = "1" ] && echo "Using \"$EXIST\" to test for tools." + +# We want to use GNU automake 1.7, if available (WANT_AUTOMAKE is used by +# the wrapper scripts of Gentoo Linux): +WANT_AUTOMAKE=1.7 export WANT_AUTOMAKE -aclocal && \ - autoheader && \ - automake --add-missing && \ - autoconf && \ - echo "Okay, autogen.sh done." +# Try to detect the needed tools when no environment variable already +# spezifies one: +echo "Searching tools ..." +[ -z "$ACLOCAL" ] && ACLOCAL=`Search aclocal 1` +[ "$VERBOSE" = "1" ] && echo "ACLOCAL=$ACLOCAL" +[ -z "$AUTOHEADER" ] && AUTOHEADER=`Search autoheader 2` +[ "$VERBOSE" = "1" ] && echo "AUTOHEADER=$AUTOHEADER" +[ -z "$AUTOMAKE" ] && AUTOMAKE=`Search automake 1` +[ "$VERBOSE" = "1" ] && echo "AUTOMAKE=$AUTOMAKE" +[ -z "$AUTOCONF" ] && AUTOCONF=`Search autoconf 2` +[ "$VERBOSE" = "1" ] && echo "AUTOCONF=$AUTOCONF" + +# Call ./configure when parameters have been passed to this script and +# GO isn't already defined. +[ -z "$GO" -a $# -gt 0 ] && GO=1 + +# Verify that all tools have been found +[ -z "$AUTOCONF" ] && Notfound autoconf +[ -z "$AUTOHEADER" ] && Notfound autoheader +[ -z "$AUTOMAKE" ] && Notfound automake +[ -z "$AUTOCONF" ] && Notfound autoconf + +export AUTOCONF AUTOHEADER AUTOMAKE AUTOCONF + +# Generate files +echo "Generating files ..." +$ACLOCAL && \ + $AUTOHEADER && \ + $AUTOMAKE --add-missing && \ + $AUTOCONF + +if [ $? -eq 0 -a -x ./configure ]; then + # Success: if we got some parameters we call ./configure and pass + # all of them to it. + if [ "$GO" = "1" ]; then + [ -n "$PREFIX" ] && p=" --prefix=$PREFIX" || p="" + [ -n "$*" ] && a=" $*" || a="" + c="./configure${p}${a}" + echo "Calling \"$c\" ..." + $c + exit $? + else + echo "Okay, autogen.sh done; now run the \"configure\" script." + exit 0 + fi +else + # Failure!? + echo "Error! Check your installation of GNU automake and autoconf!" + exit 1 +fi # -eof- Index: config.guess =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/config.guess,v retrieving revision 1.1.8.2 retrieving revision 1.4 diff -u -p -r1.1.8.2 -r1.4 --- a/config.guess 7 Nov 2003 21:04:21 -0000 1.1.8.2 +++ b/config.guess 11 Mar 2004 22:18:28 -0000 1.4 @@ -3,7 +3,7 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. -timestamp='2003-10-07' +timestamp='2004-01-05' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -221,6 +221,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$ mvmeppc:OpenBSD:*:*) echo powerpc-unknown-openbsd${UNAME_RELEASE} exit 0 ;; + pegasos:OpenBSD:*:*) + echo powerpc-unknown-openbsd${UNAME_RELEASE} + exit 0 ;; pmax:OpenBSD:*:*) echo mipsel-unknown-openbsd${UNAME_RELEASE} exit 0 ;; @@ -307,6 +310,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$ *:OS/390:*:*) echo i370-ibm-openedition exit 0 ;; + *:OS400:*:*) + echo powerpc-ibm-os400 + exit 0 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit 0;; @@ -742,6 +748,11 @@ EOF FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit 0 ;; + 5000:UNIX_System_V:4.*:*) + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit 0 ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; @@ -986,6 +997,9 @@ EOF i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit 0 ;; + i*86:syllable:*:*) + echo ${UNAME_MACHINE}-pc-syllable + exit 0 ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit 0 ;; @@ -1172,7 +1186,7 @@ EOF *:QNX:*:4*) echo i386-pc-qnx exit 0 ;; - NSR-[DGKLNPTVWY]:NONSTOP_KERNEL:*:*) + NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit 0 ;; *:NonStop-UX:*:*) @@ -1216,6 +1230,9 @@ EOF SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit 0 ;; + *:DRAGONFLY:*:*) + echo ${UNAME_MACHINE}-unknown-dragonfly${UNAME_RELEASE} + exit 0 ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 Index: config.sub =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/config.sub,v retrieving revision 1.1.8.2 retrieving revision 1.4 diff -u -p -r1.1.8.2 -r1.4 --- a/config.sub 7 Nov 2003 21:04:47 -0000 1.1.8.2 +++ b/config.sub 11 Mar 2004 22:18:28 -0000 1.4 @@ -3,7 +3,7 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. -timestamp='2003-10-07' +timestamp='2004-01-05' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -118,7 +118,8 @@ esac # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in - nto-qnx* | linux-gnu* | linux-dietlibc | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) + nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ + kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; @@ -379,6 +380,9 @@ case $basic_machine in amd64) basic_machine=x86_64-pc ;; + amd64-*) + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; amdahl) basic_machine=580-amdahl os=-sysv @@ -743,6 +747,10 @@ case $basic_machine in basic_machine=or32-unknown os=-coff ;; + os400) + basic_machine=powerpc-ibm + os=-os400 + ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose @@ -963,6 +971,10 @@ case $basic_machine in tower | tower-32) basic_machine=m68k-ncr ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; udi29k) basic_machine=a29k-amd os=-udi @@ -1137,13 +1149,13 @@ case $os in | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ - | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ + | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ - | -powermax* | -dnix* | -nx6 | -nx7 | -sei*) + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) @@ -1182,6 +1194,9 @@ case $os in -opened*) os=-openedition ;; + -os400*) + os=-os400 + ;; -wince*) os=-wince ;; @@ -1203,6 +1218,9 @@ case $os in -atheos*) os=-atheos ;; + -syllable*) + os=-syllable + ;; -386bsd) os=-bsd ;; @@ -1225,6 +1243,9 @@ case $os in -sinix*) os=-sysv4 ;; + -tpf*) + os=-tpf + ;; -triton*) os=-sysv3 ;; @@ -1473,9 +1494,15 @@ case $basic_machine in -mvs* | -opened*) vendor=ibm ;; + -os400*) + vendor=ibm + ;; -ptx*) vendor=sequent ;; + -tpf*) + vendor=ibm + ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; Index: configure.in =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/configure.in,v retrieving revision 1.89.2.16 retrieving revision 1.102.2.1 diff -u -p -r1.89.2.16 -r1.102.2.1 --- a/configure.in 5 Feb 2004 13:33:24 -0000 1.89.2.16 +++ b/configure.in 7 May 2004 11:56:19 -0000 1.102.2.1 @@ -1,6 +1,6 @@ # # ngIRCd -- The Next Generation IRC Daemon -# Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) +# Copyright (c)2001-2004 Alexander Barton # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -8,19 +8,19 @@ # (at your option) any later version. # Please read the file COPYING, README and AUTHORS for more information. # -# $Id: configure.in,v 1.89.2.16 2004/02/05 13:33:24 alex Exp $ +# $Id: configure.in,v 1.102.2.1 2004/05/07 11:56:19 alex Exp $ # -# -- Initialisierung -- +# -- Initialisation -- AC_PREREQ(2.50) -AC_INIT(ngircd, 0.7.7) +AC_INIT(ngircd, 0.8.0-pre1) AC_CONFIG_SRCDIR(src/ngircd/ngircd.c) AC_CANONICAL_TARGET AM_INIT_AUTOMAKE(1.6) AM_CONFIG_HEADER(src/config.h) -# -- Templates fuer config.h -- +# -- Templates for config.h -- AH_TEMPLATE([DEBUG], [Define if debug-mode should be enabled]) AH_TEMPLATE([HAVE_socklen_t], [Define if socklen_t exists]) @@ -31,6 +31,7 @@ AH_TEMPLATE([ZLIB], [Define if zlib comp AH_TEMPLATE([TCPWRAP], [Define if TCP wrappers should be used]) AH_TEMPLATE([IRCPLUS], [Define if IRC+ protocol should be used]) AH_TEMPLATE([RENDEZVOUS], [Define if Rendezvous support should be included]) +AH_TEMPLATE([IDENTAUTH], [Define if the server should do IDENT requests]) AH_TEMPLATE([TARGET_OS], [Target operating system name]) AH_TEMPLATE([TARGET_VENDOR], [Target system vendor]) @@ -40,7 +41,7 @@ AH_TEMPLATE([TARGET_CPU], [Target CPU na AC_PROG_CC -# -- Hilfsprogramme -- +# -- Helper programs -- AC_PROG_AWK AC_PROG_INSTALL @@ -50,47 +51,33 @@ AC_PROG_RANLIB # -- Compiler Features -- -AC_LANG_C - AM_C_PROTOTYPES AC_C_CONST -# -- Defines -- - -os=`uname` +# -- Hard coded system and compiler dependencies/features/options ... -- -if test "$os" = "Linux" -o $os = "GNU"; then - # define _POSIX_SOURCE, _GNU_SOURCE and _BSD_SOURCE when compiling - # on Linux or Hurd (glibc-based systems): - AC_MSG_RESULT([detected ${os}, defining _POSIX_SOURCE, _GNU_SOURCE and _BSD_SOURCE]) - add_DEFINES="-D_POSIX_SOURCE -D_GNU_SOURCE -D_BSD_SOURCE $add_DEFINES" +if test "$GCC" = "yes"; then + # We are using the GNU C compiler. Good! + CFLAGS="$CFLAGS -pipe -W -Wall -Wpointer-arith -Wstrict-prototypes" fi -if test "$os" = "A/UX"; then - # define _POSIX_SOURCE when compiling on A/UX: - AC_MSG_RESULT([detected A/UX, defining _POSIX_SOURCE]) - add_DEFINES="-D_POSIX_SOURCE $add_DEFINES" -fi +case "$target_os" in + hpux*) + # This is HP/UX, we need to define _XOPEN_SOURCE_EXTENDED + # (tested with HP/UX 11.11) + CFLAGS="$CFLAGS -D_XOPEN_SOURCE_EXTENDED" + ;; +esac -if test "$os" = "HP-UX"; then - # define _XOPEN_SOURCE_EXTENDED when compiling on HP-UX (11.11): - AC_MSG_RESULT([detected HP-UX, defining _XOPEN_SOURCE_EXTENDED]) - add_DEFINES="-D_XOPEN_SOURCE_EXTENDED $add_DEFINES" -fi +# Add additional CFLAGS, eventually specified on the command line: +test -n "$CFLAGS_ADD" && CFLAGS="$CFLAGS $CFLAGS_ADD" -if test "$os" = "SunOS"; then - # define _XOPEN_SOURCE, _XOPEN_SOURCE_EXTENDED=1 and __EXTENSIONS__ - # when compiling on SunOS (tested with 5.6): - AC_MSG_RESULT([detected SunOS, defining _XOPEN_SOURCE, _XOPEN_SOURCE_EXTENDED=1 and __EXTENSIONS__]) - add_DEFINES="-D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1 -D__EXTENSIONS__ $add_DEFINES" -fi +CFLAGS="$CFLAGS -DSYSCONFDIR='\"\$(sysconfdir)\"'" -# -- Header -- +# -- Headers -- AC_HEADER_STDC - AC_HEADER_TIME - AC_HEADER_SYS_WAIT AC_CHECK_HEADERS([ \ @@ -100,7 +87,7 @@ AC_CHECK_HEADERS([ \ AC_CHECK_HEADERS([arpa/inet.h ctype.h malloc.h stdint.h varargs.h]) -# -- Datentypen -- +# -- Datatypes -- AC_MSG_CHECKING(whether socklen_t exists) AC_TRY_COMPILE([ @@ -116,7 +103,6 @@ AC_TRY_COMPILE([ ]) AC_TYPE_SIGNAL - AC_TYPE_SIZE_T # -- Libraries -- @@ -125,18 +111,15 @@ AC_CHECK_LIB(UTIL,memmove) AC_CHECK_LIB(socket,bind) AC_CHECK_LIB(nsl,gethostent) -# -- Funktionen -- - -AC_FUNC_MALLOC +# -- Functions -- AC_FUNC_FORK - AC_FUNC_STRFTIME AC_CHECK_FUNCS([ \ - bind gethostbyaddr gethostbyname gethostname inet_ntoa memmove \ - memset setsockopt socket strcasecmp strchr strerror strstr waitpid \ - ],,AC_MSG_ERROR([required function missing!])) + bind gethostbyaddr gethostbyname gethostname inet_ntoa malloc memmove \ + memset realloc setsid setsockopt socket strcasecmp strchr strerror \ + strstr waitpid],,AC_MSG_ERROR([required function missing!])) AC_CHECK_FUNCS(inet_aton isdigit sigaction snprintf vsnprintf strlcpy strlcat) @@ -144,7 +127,7 @@ AC_CHECK_FUNCS(select,[AC_CHECK_HEADERS( AC_MSG_ERROR([required function select() is missing!]) ) -# -- Konfigurationsoptionen -- +# -- Configuration options -- x_syslog_on=no AC_ARG_WITH(syslog, @@ -223,6 +206,22 @@ if test "$x_rendezvous_on" = "yes"; then AC_CHECK_HEADERS(DNSServiceDiscovery/DNSServiceDiscovery.h mach/port.h) fi +x_identauth_on=no +AC_ARG_WITH(ident, + [ --with-ident enable "IDENT" ("AUTH") protocol support], + [ if test "$withval" = "yes"; then + AC_CHECK_LIB(ident, ident_id) + AC_CHECK_FUNCS(ident_id, x_identauth_on=yes, + AC_MSG_ERROR([Can't enable IDENT support!]) + ) + fi + ] +) +if test "$x_identauth_on" = "yes"; then + AC_DEFINE(IDENTAUTH, 1) + AC_CHECK_HEADERS(ident.h) +fi + x_ircplus_on=yes AC_ARG_ENABLE(ircplus, [ --disable-ircplus disable IRC+ protocol], @@ -247,6 +246,7 @@ AC_ARG_ENABLE(debug, ) if test "$x_debug_on" = "yes"; then AC_DEFINE(DEBUG, 1) + test "$GCC" = "yes" && CFLAGS="-pedantic $CFLAGS" fi x_strict_rfc_on=no @@ -258,59 +258,21 @@ AC_ARG_ENABLE(strict-rfc, fi ) -# -- Definitionen -- +# -- Definitions -- AC_DEFINE_UNQUOTED(TARGET_CPU, "$target_cpu" ) AC_DEFINE_UNQUOTED(TARGET_VENDOR, "$target_vendor" ) AC_DEFINE_UNQUOTED(TARGET_OS, "$target_os" ) -# -- Variablen -- +# Add additional CFLAGS, eventually specified on the command line, but after +# running this configure script. Useful for "-Werror" for example. +test -n "$CFLAGS_END" && CFLAGS="$CFLAGS $CFLAGS_END" -if test "$GCC" = "yes"; then - the_CFLAGS="-Wmissing-declarations -Wpointer-arith -Wstrict-prototypes" - ansi=" -ansi" - pedantic=" -pedantic" - - $CC --version | grep 20020420 >/dev/null 2>&1 - if test $? -eq 0; then - # Mac OS X (and Darwin?) ship with a slightly broken - # prerelease of GCC 3.1 which don't like -pedantic: - AC_MSG_RESULT([detected broken GNU C compiler, disabling "-pedantic"]) - pedantic="" - fi - - $CC --version | grep 20030304 >/dev/null 2>&1 - if test $? -eq 0; then - # Mac OS X 10.3 (and Darwin 7.0?) have a strange gcc (or - # system header files?) which produces lots of errors when - # using -ansi; so we don't =:-) - AC_MSG_RESULT([detected broken GNU C compiler, disabling "-ansi"]) - ansi="" - fi - - uname | grep "CYGWIN" >/dev/null 2>&1 - if test $? -eq 0; then - # The include files of Cygwin don't like -ansi, - # so we disable it: - AC_MSG_RESULT([detected Cygwin, disabling "-ansi"]) - ansi="" - fi - - add_CFLAGS="-pipe -Wall -W${ansi}${pedantic} $CFLAGS $CFLAGS_ADD" -else - the_CFLAGS="$CFLAGS" - add_CFLAGS="$CFLAGS_ADD" -fi - -CFLAGS="$the_CFLAGS $add_CFLAGS $add_DEFINES -DSYSCONFDIR='\"\$(sysconfdir)\"'" - -# -- Ausgabe der Dateien -- +# -- Generate files -- AC_OUTPUT([ \ Makefile \ doc/Makefile \ - MacOSX/Makefile \ - MacOSX/ngircd.pbproj/Makefile \ src/Makefile \ src/portab/Makefile \ src/tool/Makefile \ @@ -318,9 +280,18 @@ AC_OUTPUT([ \ src/testsuite/Makefile \ man/Makefile \ contrib/Makefile \ - debian/Makefile \ + contrib/Debian/Makefile \ + contrib/MacOSX/Makefile \ ]) +type dpkg >/dev/null 2>&1 +if test $? -eq 0; then + # Generate debian/ link if the dpkg command exists + # (read: if we are running on a debian compatible system) + echo "creating Debian-specific links ..." + test -f debian/rules || ln -s contrib/Debian debian +fi + # -- Result -- echo @@ -334,11 +305,10 @@ C=`eval echo ${sysconfdir}` ; C=`eval ec M=`eval echo ${mandir}` ; M=`eval echo ${M}` D=`eval echo ${datadir}/doc/${PACKAGE}` ; D=`eval echo ${D}` -echo " Host: ${host}" +echo " Target: ${target}" +test "$target" != "$host" && echo " Host: ${host}" echo " Compiler: ${CC}" -echo " Compiler flags: ${the_CFLAGS}" -test -n "$add_CFLAGS" && echo " ${add_CFLAGS}" -test -n "$add_DEFINES" && echo " ${add_DEFINES}" +test -n "$CFLAGS" && echo " Compiler flags: ${CFLAGS}" test -n "$CPPFLAGS" && echo " Preprocessor flags: ${CPPFLAGS}" test -n "$LDFLAGS" && echo " Linker flags: ${LDFLAGS}" test -n "$LIBS" && echo " Libraries: ${LIBS}" @@ -384,6 +354,12 @@ echo $ECHO_N " IRC+ protocol: $ECHO test "$x_ircplus_on" = "yes" \ && echo "yes" \ || echo "no" -echo + +echo $ECHO_N " IDENT support: $ECHO_C" +test "$x_identauth_on" = "yes" \ + && echo $ECHO_N "yes $ECHO_C" \ + || echo $ECHO_N "no $ECHO_C" + +echo; echo # -eof- Index: contrib/Makefile.am =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/contrib/Makefile.am,v retrieving revision 1.1 retrieving revision 1.4 diff -u -p -r1.1 -r1.4 --- a/contrib/Makefile.am 1 Oct 2002 09:57:08 -0000 1.1 +++ b/contrib/Makefile.am 28 Apr 2004 12:18:02 -0000 1.4 @@ -1,6 +1,6 @@ # # ngIRCd -- The Next Generation IRC Daemon -# Copyright (c)2001,2002 by Alexander Barton (alex@barton.de) +# Copyright (c)2001-2004 Alexander Barton # # Dieses Programm ist freie Software. Sie koennen es unter den Bedingungen # der GNU General Public License (GPL), wie von der Free Software Foundation @@ -9,10 +9,12 @@ # Naehere Informationen entnehmen Sie bitter der Datei COPYING. Eine Liste # der an ngIRCd beteiligten Autoren finden Sie in der Datei AUTHORS. # -# $Id: Makefile.am,v 1.1 2002/10/01 09:57:08 alex Exp $ +# $Id: Makefile.am,v 1.4 2004/04/28 12:18:02 alex Exp $ # -EXTRA_DIST = ngircd.spec +SUBDIRS = Debian MacOSX + +EXTRA_DIST = README ngircd.spec systrace.policy maintainer-clean-local: rm -f Makefile Makefile.in Index: contrib/README =================================================================== RCS file: contrib/README diff -N contrib/README --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/README 28 Apr 2004 12:18:50 -0000 1.1 @@ -0,0 +1,27 @@ + + ngIRCd - Next Generation IRC Server + + (c)2001-2004 by Alexander Barton, + alex@barton.de, http://www.barton.de/ + + ngIRCd is free software and published under the + terms of the GNU General Public License. + + -- Contributions -- + + +MacOSX/ + - Project file for XCode "project builder" of Mac OS X. + +Debian/ + - Various files for building Debian packages. + +ngircd.spec + - RPM "spec" file. + +systrace.policy + - Systrace policy file for OpenBSD (and probably NetBSD). + + +-- +$Id: README,v 1.1 2004/04/28 12:18:50 alex Exp $ Index: contrib/ngircd.spec =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/contrib/ngircd.spec,v retrieving revision 1.2.4.7 retrieving revision 1.4.2.1 diff -u -p -r1.2.4.7 -r1.4.2.1 --- a/contrib/ngircd.spec 5 Feb 2004 13:33:24 -0000 1.2.4.7 +++ b/contrib/ngircd.spec 7 May 2004 11:56:19 -0000 1.4.2.1 @@ -1,5 +1,5 @@ %define name ngircd -%define version 0.7.7 +%define version 0.8.0-pre1 %define release 1 %define prefix %{_prefix} Index: contrib/systrace.policy =================================================================== RCS file: contrib/systrace.policy diff -N contrib/systrace.policy --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/systrace.policy 28 Apr 2004 12:16:59 -0000 1.1 @@ -0,0 +1,77 @@ +# +# Sample systrace policy for ngIRCd on OpenBSD +# Author: Benjamin Pineau +# +# $Id: systrace.policy,v 1.1 2004/04/28 12:16:59 alex Exp $ +# +# Tune me, put me in /etc/systrace/usr_local_bin_ngircd and start ngIRCd +# (with root privileges) as: +# +# systrace -a /usr/local/bin/ngircd +# +# I didn't tried this on NetBSD, but it should work as is. +# +# On systems with pf, it can be supplemented by strict firewall rules: +# for a ngircd running as '$ircuser', binding on '$ircport' and accepting +# 30 connections: +# +# block out log quick proto tcp from any port $ircport to any \ +# user != $ircuser +# pass in inet proto tcp from any to any port $ircport user $ircuser \ +# keep state (max 30) flags S/SA +# + +Policy: /usr/local/bin/ngircd, Emulation: native + native-__sysctl: permit + native-fsread: filename eq "/etc/malloc.conf" then permit + native-fsread: filename sub "/usr/share/zoneinfo/" then permit + native-fsread: filename eq "/usr/local/etc/ngircd.conf" then permit + native-fsread: filename eq "/usr/local/etc/ngircd.motd" then permit + native-fsread: filename eq "/etc/ngircd.conf" then permit + native-fsread: filename eq "/etc/ngircd.motd" then permit + native-fsread: filename eq "/etc/spwd.db" then deny[eperm] + native-fsread: filename eq "/etc/group" then permit + native-fsread: filename eq "/etc/resolv.conf" then permit + native-fsread: filename eq "/etc/localtime" then permit + native-fsread: filename eq "/etc/hosts" then permit + native-fsread: filename sub "" then deny[enoent] + native-socket: sockdom eq "AF_UNIX" and socktype eq "SOCK_DGRAM" then permit + native-socket: sockdom eq "AF_INET" and socktype eq "SOCK_STREAM" then permit + native-bind: sockaddr match "inet-*:6667" then permit, if user != root + native-connect: sockaddr eq "/dev/log" then permit, if user != root + native-connect: sockaddr match "inet-*:53" then permit, if user != root + native-setsockopt: permit, if user != root + native-listen: permit, if user != root + native-accept: permit, if user != root + native-sendto: true then permit, if user != root + native-recvfrom: permit, if user != root + native-read: permit + native-pread: permit + native-write: permit, if user != root + native-mmap: permit + native-munmap: permit + native-mprotect: permit + native-break: permit + native-umask: permit + native-fork: permit + native-setsid: permit + native-chdir: permit + native-chroot: permit + native-setgid: gid neq "0" then permit + native-setuid: uid neq "0" and uname neq "root" then permit + native-getuid: permit + native-getgid: permit + native-gettimeofday: permit + native-getpid: permit + native-select: permit + native-fcntl: permit + native-fstat: permit + native-issetugid: permit + native-sigaction: permit + native-pipe: permit + native-sigreturn: permit + native-close: permit + native-exit: permit + native-fswrite: deny[eperm] + +# -eof- Index: contrib/Debian/Makefile.am =================================================================== RCS file: contrib/Debian/Makefile.am diff -N contrib/Debian/Makefile.am --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/Makefile.am 13 Jan 2004 01:10:11 -0000 1.3 @@ -0,0 +1,27 @@ +# +# ngIRCd -- The Next Generation IRC Daemon +# Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# Please read the file COPYING, README and AUTHORS for more information. +# +# $Id: Makefile.am,v 1.3 2004/01/13 01:10:11 alex Exp $ +# + +EXTRA_DIST = rules changelog compat control copyright \ + ngircd.init ngircd.postinst + +maintainer-clean-local: + rm -f Makefile Makefile.in + rm -f ngircd.postinst.debhelper ngircd.postrm.debhelper \ + ngircd.prerm.debhelper ngircd.substvars + rm -f ngircd-full.postinst.debhelper ngircd-full.postrm.debhelper \ + ngircd-full.prerm.debhelper ngircd-full.substvars + + rm -rf ngircd ngircd-full + rm -f files + +# -eof- Index: contrib/Debian/changelog =================================================================== RCS file: contrib/Debian/changelog diff -N contrib/Debian/changelog --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/changelog 25 Apr 2004 23:57:19 -0000 1.8 @@ -0,0 +1,124 @@ +ngircd (0.7.7+HEAD-0ab5) unstable; urgency=low + + * Updates from CVS HEAD branch, most notably: "INVITE- and BAN-lists + become synchronized between IRC+ servers when establishing new + connections, if the peer supports this as well." + + -- Alexander Barton Mon, 26 Apr 2004 01:53:15 +0200 + +ngircd (0.7.7+HEAD-0ab4) unstable; urgency=low + + * This version includes fixes for INVITE command and the handling of the + invite and ban lists from CVS-HEAD. + + -- Alexander Barton Fri, 9 Apr 2004 23:55:13 +0200 + +ngircd (0.7.7+HEAD-0ab3) unstable; urgency=low + + * Included MODE fix from CVS-HEAD branch. + + -- Alexander Barton Mon, 5 Apr 2004 13:09:24 +0200 + +ngircd (0.7.7+HEAD-0ab2) unstable; urgency=low + + * Incorporated more fixes and enhancements of CVS-HEAD version, + e. g. better connection logging and fixed TRACE command. + + -- Alexander Barton Sat, 28 Feb 2004 03:20:32 +0100 + +ngircd (0.7.7+HEAD-0ab1) unstable; urgency=low + + * New upstream version. This debian package includes all features of + ngIRCd 0.7.7 and changes of the CVS-HEAD development tree. + + -- Alexander Barton Thu, 5 Feb 2004 15:23:22 +0100 + +ngircd (0.7.6+HEAD-0ab2) unstable; urgency=low + + * Included new fixes and additions from the CVS-HEAD upstream branch, + e. g. the setting of type of service (TOS) on sockets. + + -- Alexander Barton Mon, 26 Jan 2004 04:05:41 +0100 + +ngircd (0.7.6+HEAD-0ab1) unstable; urgency=low + + * Included all changes from the CVS-HEAD upstream version. + * Restructured debian packaging system: now there are two packages, a + "standard" version that includes all the default options and a "full" + version that additionally includes support for TCP wrappers and IDENT + lookups. + + -- Alexander Barton Thu, 1 Jan 2004 23:12:11 +0100 + +ngircd (0.7.6-0ab1) unstable; urgency=medium + + * New upstream version. + * Changed version numvering scheme of debian package. + + -- Alexander Barton Fri, 5 Dec 2003 14:26:41 +0100 + +ngircd (0.7.5-0.2ab) unstable; urgency=low + + * Updated RPM and Debian package description and configuration. + + -- Alexander Barton Sat, 29 Nov 2003 21:24:32 +0100 + +ngircd (0.7.5-0.1ab) unstable; urgency=low + + * New upstream version. + + -- Alexander Barton Fri, 7 Nov 2003 21:59:58 +0100 + +ngircd (0.7.1-0.1ab) unstable; urgency=low + + * New upstream version :-) + + -- Alexander Barton Fri, 18 Jul 2003 22:53:02 +0200 + +ngircd (0.7.0-0.7ab) unstable; urgency=low + + * Fixed up post installation script (added interpreter, fixed chmod call). + + -- Alexander Barton Sun, 13 Jul 2003 00:52:38 +0200 + +ngircd (0.7.0-0.6ab) unstable; urgency=low + + * Added /etc/default/ngircd. + * Included own post installation script. + + -- Alexander Barton Sat, 12 Jul 2003 20:31:09 +0200 + +ngircd (0.7.0-0.5ab) unstable; urgency=low + + * Enhanced init script. + * Included NJOIN fix from actual CVS "HEAD" branch. + + -- Alexander Barton Wed, 9 Jul 2003 22:40:49 +0200 + +ngircd (0.7.0-0.4ab) unstable; urgency=low + + * Reverted use of dh_installexamples. + + -- Alexander Barton Thu, 22 May 2003 00:15:03 +0200 + +ngircd (0.7.0-0.3ab) unstable; urgency=low + + * Removed "debian/docs" and "debian/conffiles"; debhelper takes care of + this for us automagically. + * Excluded "etc/ngircd.conf" from dh_fixperms. + + -- Alexander Barton Wed, 21 May 2003 23:25:05 +0200 + +ngircd (0.7.0-0.2ab) unstable; urgency=low + + * Fixed wrong variable substitution in init script. + * Added some CVS "Id-Tags" (but not checked in, yet). + * Removed own "Provides:" from control file. + + -- Alexander Barton Wed, 21 May 2003 12:32:34 +0200 + +ngircd (0.7.0-0.1ab) unstable; urgency=low + + * Initial Release. + + -- Alexander Barton Wed, 21 May 2003 02:36:52 +0200 Index: contrib/Debian/compat =================================================================== RCS file: contrib/Debian/compat diff -N contrib/Debian/compat --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/compat 31 Dec 2003 17:20:11 -0000 1.1 @@ -0,0 +1 @@ +4 Index: contrib/Debian/control =================================================================== RCS file: contrib/Debian/control diff -N contrib/Debian/control --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/control 1 Jan 2004 22:24:48 -0000 1.2 @@ -0,0 +1,47 @@ +Source: ngircd +Section: net +Priority: optional +Maintainer: Alexander Barton +Build-Depends: debhelper (>> 4.0.0), libz-dev, libwrap-dev, libident-dev +Standards-Version: 3.5.8 + +Package: ngircd +Architecture: any +Depends: ${shlibs:Depends} ${misc:Depends} +Description: A lightweight daemon for the Internet Relay Chat (IRC) + ngIRCd is a free open source daemon for the Internet Relay Chat (IRC) + network. It is written from scratch and is not based upon the original + IRCd like many others. + . + This package contains the "standard distribution", including support for + syslog logging and compressed server-links using zlib. + . + Advantages of ngIRCd: + - no problems with servers using changing/non-static IP addresses. + - small and lean configuration file. + - free, modern and open source C code. + - still under active development. + . + ngIRCd is compatible to the "original" ircd 2.10.3p3, so you can run + mixed networks. + +Package: ngircd-full +Architecture: any +Depends: ${shlibs:Depends} ${misc:Depends} +Conflicts: ngircd +Description: A lightweight daemon for the Internet Relay Chat (IRC) + ngIRCd is a free open source daemon for the Internet Relay Chat (IRC) + network. It is written from scratch and is not based upon the original + IRCd like many others. + . + This package includes support for TCP wrappers and IDENT requests in + addition to the features of the "standard package". + . + Advantages of ngIRCd: + - no problems with servers using changing/non-static IP addresses. + - small and lean configuration file. + - free, modern and open source C code. + - still under active development. + . + ngIRCd is compatible to the "original" ircd 2.10.3p3, so you can run + mixed networks. Index: contrib/Debian/copyright =================================================================== RCS file: contrib/Debian/copyright diff -N contrib/Debian/copyright --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/copyright 31 Dec 2003 17:20:11 -0000 1.1 @@ -0,0 +1,13 @@ +This package was debianized by Alexander Barton on +Tue, 20 May 2003 15:47:40 +0200. + +It was downloaded from ftp://Arthur.Ath.CX/pub/Users/alex/ngircd/ + +Upstream Author: Alexander Barton + +This software is copyright (c) 1999-2003 by Alexander Barton. + +You are free to distribute this software under the terms of the +GNU General Public License. +On Debian systems, the complete text of the GNU General Public +License can be found in /usr/share/common-licenses/GPL file. Index: contrib/Debian/ngircd.default =================================================================== RCS file: contrib/Debian/ngircd.default diff -N contrib/Debian/ngircd.default --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/ngircd.default 31 Dec 2003 17:20:11 -0000 1.1 @@ -0,0 +1,12 @@ +# +# Defaults for ngIRCd start and stop script +# +# $Id: ngircd.default,v 1.1 2003/12/31 17:20:11 alex Exp $ +# + +# Parameters to pass to the ngircd daemon on startup, see ngircd(8) for +# possible options (default: empty). + +PARAMS="" + +# -eof- Index: contrib/Debian/ngircd.init =================================================================== RCS file: contrib/Debian/ngircd.init diff -N contrib/Debian/ngircd.init --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/ngircd.init 31 Dec 2003 17:20:11 -0000 1.1 @@ -0,0 +1,71 @@ +#!/bin/sh +# +# ngIRCd start and stop script for Debian-based systems +# +# $Id: ngircd.init,v 1.1 2003/12/31 17:20:11 alex Exp $ +# + +PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin +DAEMON=/usr/sbin/ngircd +NAME=ngIRCd +DESC="IRC daemon" +PARAMS="" + +test -x $DAEMON || exit 0 + +test -f /etc/default/ngircd && . /etc/default/ngircd + +Check_Config() +{ + $DAEMON --configtest >/dev/null 2>&1 + if [ $? -ne 0 ]; then + echo "Configuration of $NAME is not valide, won't (re)start!" + echo "Please run \"$DAEMON --configtest\" manually and fix it up ..." + exit 1 + fi +} + +Try_Start() +{ + start-stop-daemon --start --quiet --exec $DAEMON -- $PARAMS + if [ $? -ne 0 ]; then + echo "$NAME failed!" + exit 1 + fi + echo "$NAME." +} + +case "$1" in + start) + Check_Config + echo -n "Starting $DESC: " + Try_Start + ;; + stop) + echo -n "Stopping $DESC: " + start-stop-daemon --stop --quiet --exec $DAEMON \ + && echo "$NAME." \ + || echo "(none running)" + ;; + reload|force-reload) + Check_Config + echo "Reloading $DESC configuration files." + start-stop-daemon --stop --signal 1 --quiet --exec $DAEMON + ;; + restart) + Check_Config + echo -n "Restarting $DESC: " + start-stop-daemon --stop --quiet --oknodo --exec $DAEMON + sleep 1 + Try_Start + ;; + *) + N=/etc/init.d/$NAME + echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 + exit 1 + ;; +esac + +exit 0 + +# -eof- Index: contrib/Debian/ngircd.postinst =================================================================== RCS file: contrib/Debian/ngircd.postinst diff -N contrib/Debian/ngircd.postinst --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/ngircd.postinst 31 Dec 2003 17:20:11 -0000 1.1 @@ -0,0 +1,14 @@ +#!/bin/sh +# +# Debian post-installation script +# $Id: ngircd.postinst,v 1.1 2003/12/31 17:20:11 alex Exp $ +# + +if [ -f /etc/ngircd/ngircd.conf ]; then + # make sure that configuration file is not world readable + chmod o= /etc/ngircd/ngircd.conf +fi + +#DEBHELPER# + +# -eof- Index: contrib/Debian/rules =================================================================== RCS file: contrib/Debian/rules diff -N contrib/Debian/rules --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/Debian/rules 1 Jan 2004 22:24:48 -0000 1.2 @@ -0,0 +1,156 @@ +#!/usr/bin/make -f +# +# ngIRCd -- The Next Generation IRC Daemon +# Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# Please read the file COPYING, README and AUTHORS for more information. +# +# debian/rules for ngIRCd +# +# $Id: rules,v 1.2 2004/01/01 22:24:48 alex Exp $ +# +# Based on the sample debian/rules that uses debhelper, +# GNU copyright 1997 to 1999 by Joey Hess. +# + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# These are used for cross-compiling and for saving the configure script +# from having to guess our platform (since we know it already) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) + +CFLAGS = -Wall -g + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s +endif + +configure-ngircd: configure + dh_testdir + + # configure "standard" variant: + ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \ + --prefix=/usr \ + --sysconfdir=/etc/ngircd \ + --mandir=\$${prefix}/share/man \ + --with-syslog --with-zlib + +configure-ngircd-full: configure + dh_testdir + + # configure "full" variant: + ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \ + --prefix=/usr \ + --sysconfdir=/etc/ngircd \ + --mandir=\$${prefix}/share/man \ + --with-syslog --with-zlib --with-tcp-wrappers --with-ident + +build: + dh_clean -k + +build-ngircd: build-stamp-ngircd +build-stamp-ngircd: configure-ngircd + dh_testdir + rm -f build-stamp-* + + # Add here commands to compile the "standard" package: + $(MAKE) + + touch build-stamp-ngircd + +build-ngircd-full: build-stamp-ngircd-full +build-stamp-ngircd-full: configure-ngircd-full + dh_testdir + rm -f build-stamp-* + + # Add here commands to compile the "full" package: + $(MAKE) + + touch build-stamp-ngircd-full + +clean: + dh_testdir + dh_testroot + rm -f build-stamp* + rm -f $(CURDIR)/debian/ngircd-full.default + rm -f $(CURDIR)/debian/ngircd-full.init + rm -f $(CURDIR)/debian/ngircd-full.postinst + + # Add here commands to clean up after the build process: + -$(MAKE) clean + +ifneq "$(wildcard /usr/share/misc/config.sub)" "" + cp -f /usr/share/misc/config.sub config.sub +endif +ifneq "$(wildcard /usr/share/misc/config.guess)" "" + cp -f /usr/share/misc/config.guess config.guess +endif + dh_clean + +install: install-ngircd install-ngircd-full + +install-ngircd: build-ngircd + dh_testdir + dh_testroot + dh_installdirs + + # Add here commands to install the "standard" package into debian/ngircd: + $(MAKE) install DESTDIR=$(CURDIR)/debian/ngircd + rm $(CURDIR)/debian/ngircd/usr/share/doc/ngircd/INSTALL* + rm $(CURDIR)/debian/ngircd/usr/share/doc/ngircd/COPYING* + +install-ngircd-full: build-ngircd-full + dh_testdir + dh_testroot + dh_installdirs + + # Add here commands to install the "full" package into debian/ngircd-full: + $(MAKE) install DESTDIR=$(CURDIR)/debian/ngircd-full + rm $(CURDIR)/debian/ngircd-full/usr/share/doc/ngircd/INSTALL* + rm $(CURDIR)/debian/ngircd-full/usr/share/doc/ngircd/COPYING* + mv $(CURDIR)/debian/ngircd-full/usr/share/doc/ngircd \ + $(CURDIR)/debian/ngircd-full/usr/share/doc/ngircd-full + +# Build architecture-independent files here. +binary-indep: + # We have nothing to do by default. + +# Build architecture-dependent files here. +binary-arch: build install + ln -s $(CURDIR)/debian/ngircd.default \ + $(CURDIR)/debian/ngircd-full.default + ln -s $(CURDIR)/debian/ngircd.init \ + $(CURDIR)/debian/ngircd-full.init + ln -s $(CURDIR)/debian/ngircd.postinst \ + $(CURDIR)/debian/ngircd-full.postinst + + dh_testdir + dh_testroot + dh_installchangelogs -a -A ChangeLog + dh_installdocs -a + dh_installinit -a + dh_strip -a + dh_compress -a + dh_fixperms -a + dh_installdeb -a + dh_shlibdeps -a + dh_gencontrol -a + dh_md5sums -a + dh_builddeb -a + +binary: binary-indep binary-arch + +.PHONY: build clean binary-indep binary-arch binary install + +# -eof- Index: contrib/MacOSX/Makefile.am =================================================================== RCS file: contrib/MacOSX/Makefile.am diff -N contrib/MacOSX/Makefile.am --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/MacOSX/Makefile.am 29 Feb 2004 17:19:43 -0000 1.1 @@ -0,0 +1,17 @@ +# +# ngIRCd -- The Next Generation IRC Daemon +# Copyright (c)2001-2004 Alexander Barton +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# Please read the file COPYING, README and AUTHORS for more information. +# +# $Id: Makefile.am,v 1.1 2004/02/29 17:19:43 alex Exp $ +# + +clean-local: + rm -rf build + +# -eof- Index: contrib/MacOSX/ngIRCd.xcode/project.pbxproj =================================================================== RCS file: contrib/MacOSX/ngIRCd.xcode/project.pbxproj diff -N contrib/MacOSX/ngIRCd.xcode/project.pbxproj --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ b/contrib/MacOSX/ngIRCd.xcode/project.pbxproj 9 Apr 2004 20:48:27 -0000 1.3 @@ -0,0 +1,1871 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 39; + objects = { + 014CEA520018CE5811CA2923 = { + buildRules = ( + ); + buildSettings = { + COPY_PHASE_STRIP = NO; + DEBUGGING_SYMBOLS = YES; + GCC_DYNAMIC_NO_PIC = NO; + GCC_ENABLE_FIX_AND_CONTINUE = YES; + GCC_GENERATE_DEBUGGING_SYMBOLS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + OPTIMIZATION_CFLAGS = "-O0"; + ZERO_LINK = NO; + }; + isa = PBXBuildStyle; + name = Development; + }; +//010 +//011 +//012 +//013 +//014 +//080 +//081 +//082 +//083 +//084 + 08FB7793FE84155DC02AAC07 = { + buildSettings = { + }; + buildStyles = ( + 014CEA520018CE5811CA2923, + ); + hasScannedForEncodings = 1; + isa = PBXProject; + mainGroup = 08FB7794FE84155DC02AAC07; + projectDirPath = ""; + targets = ( + 8DD76FA90486AB0100D96B5E, + FADE2C5E05F1511B0081A16E, + ); + }; + 08FB7794FE84155DC02AAC07 = { + children = ( + 08FB7795FE84155DC02AAC07, + C6A0FF2B0290797F04C91782, + FADE2AA505F149580081A16E, + FADE2AA605F1495F0081A16E, + FADE2AC905F149D70081A16E, + FADE2AAA05F1499A0081A16E, + FADE2AA805F1499A0081A16E, + FADE2AAD05F1499A0081A16E, + FADE2AA905F1499A0081A16E, + FADE2AAC05F1499A0081A16E, + FADE2AAE05F1499A0081A16E, + FADE2AA705F1499A0081A16E, + FADE2AAB05F1499A0081A16E, + 1AB674ADFE9D54B511CA2CBB, + ); + isa = PBXGroup; + name = ngIRCd; + refType = 4; + sourceTree = ""; + }; + 08FB7795FE84155DC02AAC07 = { + children = ( + FADE2B9005F14C6C0081A16E, + FADE2AED05F14A6A0081A16E, + FADE2AEE05F14A700081A16E, + FADE2AEF05F14A760081A16E, + FADE2AF005F14A840081A16E, + FADE2B8F05F14C6C0081A16E, + ); + isa = PBXGroup; + name = src; + refType = 4; + sourceTree = ""; + }; +//080 +//081 +//082 +//083 +//084 +//1A0 +//1A1 +//1A2 +//1A3 +//1A4 + 1AB674ADFE9D54B511CA2CBB = { + children = ( + FADE2B7B05F14B9F0081A16E, + FADE2C9905F1511B0081A16E, + FA83332A0627391D00A909F0, + ); + isa = PBXGroup; + name = Products; + refType = 4; + sourceTree = ""; + }; +//1A0 +//1A1 +//1A2 +//1A3 +//1A4 +//8D0 +//8D1 +//8D2 +//8D3 +//8D4 + 8DD76FA90486AB0100D96B5E = { + buildPhases = ( + 8DD76FAA0486AB0100D96B5E, + 8DD76FAB0486AB0100D96B5E, + 8DD76FAD0486AB0100D96B5E, + 8DD76FAE0486AB0100D96B5E, + 8DD76FAF0486AB0100D96B5E, + ); + buildRules = ( + ); + buildSettings = { + GCC_PREPROCESSOR_DEFINITIONS = "SYSCONFDIR='\"/opt/ngircd/etc\"'"; + GCC_TREAT_WARNINGS_AS_ERRORS = YES; + GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; + GCC_WARN_UNUSED_LABEL = YES; + GCC_WARN_UNUSED_PARAMETER = YES; + GCC_WARN_UNUSED_VALUE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = ngIRCd; + WARNING_CFLAGS = "-Wall"; + }; + dependencies = ( + ); + isa = PBXNativeTarget; + name = ngIRCd; + productInstallPath = "$(HOME)/bin"; + productName = ngIRCd; + productReference = FADE2B7B05F14B9F0081A16E; + productType = "com.apple.product-type.tool"; + }; + 8DD76FAA0486AB0100D96B5E = { + buildActionMask = 2147483647; + files = ( + FADE2B2305F14A960081A16E, + FADE2B2605F14A960081A16E, + FADE2B2705F14A960081A16E, + FADE2B2A05F14A960081A16E, + FADE2B2B05F14A960081A16E, + FADE2B2C05F14A960081A16E, + FADE2B2F05F14A960081A16E, + FADE2B3305F14A960081A16E, + FADE2B3405F14A960081A16E, + FADE2B3605F14A960081A16E, + FADE2B3705F14A960081A16E, + FADE2B3805F14A960081A16E, + FADE2B3905F14A960081A16E, + FADE2B3B05F14A960081A16E, + FADE2B3C05F14A960081A16E, + FADE2B3D05F14A960081A16E, + FADE2B4105F14A960081A16E, + FADE2B4205F14A960081A16E, + FADE2B4405F14A960081A16E, + FADE2B4505F14A960081A16E, + FADE2B4605F14A960081A16E, + FADE2B4705F14A960081A16E, + FADE2B4A05F14A960081A16E, + FADE2B4C05F14A960081A16E, + FADE2B5205F14A960081A16E, + FADE2BBD05F14DEF0081A16E, + FADE2BBF05F14DEF0081A16E, + FADE2BC105F14DF10081A16E, + FADE2CC205F152780081A16E, + ); + isa = PBXHeadersBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + 8DD76FAB0486AB0100D96B5E = { + buildActionMask = 2147483647; + files = ( + FADE2B2405F14A960081A16E, + FADE2B2505F14A960081A16E, + FADE2B2805F14A960081A16E, + FADE2B2905F14A960081A16E, + FADE2B2D05F14A960081A16E, + FADE2B2E05F14A960081A16E, + FADE2B3005F14A960081A16E, + FADE2B3105F14A960081A16E, + FADE2B3205F14A960081A16E, + FADE2B3505F14A960081A16E, + FADE2B3A05F14A960081A16E, + FADE2B3E05F14A960081A16E, + FADE2B3F05F14A960081A16E, + FADE2B4005F14A960081A16E, + FADE2B4305F14A960081A16E, + FADE2B4805F14A960081A16E, + FADE2B4905F14A960081A16E, + FADE2B4B05F14A960081A16E, + FADE2B4D05F14A960081A16E, + FADE2B4E05F14A960081A16E, + FADE2B4F05F14A960081A16E, + FADE2B5005F14A960081A16E, + FADE2B5105F14A960081A16E, + FADE2BC305F14DF40081A16E, + FADE2BC505F14DF50081A16E, + FADE2CC005F152770081A16E, + ); + isa = PBXSourcesBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + 8DD76FAD0486AB0100D96B5E = { + buildActionMask = 2147483647; + files = ( + FA83332B0627391D00A909F0, + ); + isa = PBXFrameworksBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + 8DD76FAE0486AB0100D96B5E = { + buildActionMask = 2147483647; + files = ( + ); + isa = PBXRezBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + 8DD76FAF0486AB0100D96B5E = { + buildActionMask = 8; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + ); + isa = PBXCopyFilesBuildPhase; + runOnlyForDeploymentPostprocessing = 1; + }; +//8D0 +//8D1 +//8D2 +//8D3 +//8D4 +//C60 +//C61 +//C62 +//C63 +//C64 + C6A0FF2B0290797F04C91782 = { + children = ( + FADE2AB905F149C50081A16E, + FADE2AB705F149C50081A16E, + FADE2AB805F149C50081A16E, + FADE2ABA05F149C50081A16E, + FADE2ABB05F149C50081A16E, + FADE2ABC05F149C50081A16E, + FADE2ABD05F149C50081A16E, + FADE2ABE05F149C50081A16E, + FADE2ABF05F149C50081A16E, + ); + isa = PBXGroup; + name = doc; + refType = 4; + sourceTree = ""; + }; +//C60 +//C61 +//C62 +//C63 +//C64 +//FA0 +//FA1 +//FA2 +//FA3 +//FA4 + FA83332A0627391D00A909F0 = { + isa = PBXFileReference; + lastKnownFileType = "compiled.mach-o.dylib"; + name = libz.dylib; + path = /usr/lib/libz.dylib; + refType = 0; + sourceTree = ""; + }; + FA83332B0627391D00A909F0 = { + fileRef = FA83332A0627391D00A909F0; + isa = PBXBuildFile; + settings = { + }; + }; + FAC0DF4A05F25A150024C8CE = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + path = Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AA505F149580081A16E = { + children = ( + FADE2ACB05F149EA0081A16E, + FADE2ACC05F149EA0081A16E, + FADE2ACD05F149EA0081A16E, + ); + isa = PBXGroup; + name = man; + refType = 4; + sourceTree = ""; + }; + FADE2AA605F1495F0081A16E = { + children = ( + FADE2AE505F14A2A0081A16E, + FADE2AD205F149FD0081A16E, + FADE2AD105F149F70081A16E, + FADE2AE605F14A2A0081A16E, + ); + isa = PBXGroup; + name = contrib; + path = ""; + refType = 4; + sourceTree = ""; + }; + FADE2AA705F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = autogen.sh; + path = ../../autogen.sh; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AA805F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = COPYING; + path = ../../COPYING; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AA905F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = NEWS; + path = ../../NEWS; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AAA05F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = README; + path = ../../README; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AAB05F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = configure.in; + path = ../../configure.in; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AAC05F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = ChangeLog; + path = ../../ChangeLog; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AAD05F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = INSTALL; + path = ../../INSTALL; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AAE05F1499A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = AUTHORS; + path = ../../AUTHORS; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AB705F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "README-BeOS.txt"; + path = "../../doc/README-BeOS.txt"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AB805F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = FAQ.txt; + path = ../../doc/FAQ.txt; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AB905F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../doc/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABA05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "README-AUX.txt"; + path = "../../doc/README-AUX.txt"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABB05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "sample-ngircd.conf"; + path = "../../doc/sample-ngircd.conf"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABC05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = RFC.txt; + path = ../../doc/RFC.txt; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABD05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Protocol.txt; + path = ../../doc/Protocol.txt; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABE05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = CVS.txt; + path = ../../doc/CVS.txt; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ABF05F149C50081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Platforms.txt; + path = ../../doc/Platforms.txt; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AC905F149D70081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ACB05F149EA0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../man/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ACC05F149EA0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = ngircd.conf.5; + path = ../../man/ngircd.conf.5; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ACD05F149EA0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = ngircd.8; + path = ../../man/ngircd.8; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD105F149F70081A16E = { + children = ( + FADE2AD605F14A0B0081A16E, + FADE2AD305F14A0B0081A16E, + FADE2AD705F14A0B0081A16E, + FADE2ADB05F14A0B0081A16E, + FADE2AD905F14A0B0081A16E, + FADE2AD405F14A0B0081A16E, + FADE2AD505F14A0B0081A16E, + FADE2AD805F14A0B0081A16E, + FADE2ADA05F14A0B0081A16E, + ); + isa = PBXGroup; + name = Debian; + refType = 4; + sourceTree = ""; + }; + FADE2AD205F149FD0081A16E = { + children = ( + FAC0DF4A05F25A150024C8CE, + ); + isa = PBXGroup; + name = "Mac OS X"; + refType = 4; + sourceTree = ""; + }; + FADE2AD305F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = copyright; + path = ../Debian/copyright; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD405F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = rules; + path = ../Debian/rules; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD505F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = ngircd.postinst; + path = ../Debian/ngircd.postinst; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD605F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../Debian/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD705F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = control; + path = ../Debian/control; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD805F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = ngircd.init; + path = ../Debian/ngircd.init; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AD905F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = compat; + path = ../Debian/compat; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ADA05F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = ngircd.default; + path = ../Debian/ngircd.default; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2ADB05F14A0B0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = changelog; + path = ../Debian/changelog; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AE505F14A2A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AE605F14A2A0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = ngircd.spec; + path = /local/alex/Develop/ngircd/HEAD/contrib/ngircd.spec; + refType = 0; + sourceTree = ""; + }; + FADE2AED05F14A6A0081A16E = { + children = ( + FADE2AF105F14A960081A16E, + FADE2B0105F14A960081A16E, + FADE2B0805F14A960081A16E, + FADE2B2005F14A960081A16E, + FADE2B1305F14A960081A16E, + FADE2AFC05F14A960081A16E, + FADE2B0305F14A960081A16E, + FADE2B1E05F14A960081A16E, + FADE2B2105F14A960081A16E, + FADE2B0D05F14A960081A16E, + FADE2AF505F14A960081A16E, + FADE2B1205F14A960081A16E, + FADE2AF905F14A960081A16E, + FADE2B0205F14A960081A16E, + FADE2B1C05F14A960081A16E, + FADE2AFE05F14A960081A16E, + FADE2B1805F14A960081A16E, + FADE2B0705F14A960081A16E, + FADE2B1D05F14A960081A16E, + FADE2B0C05F14A960081A16E, + FADE2AF405F14A960081A16E, + FADE2B1105F14A960081A16E, + FADE2AF805F14A960081A16E, + FADE2B0B05F14A960081A16E, + FADE2AF305F14A960081A16E, + FADE2B1005F14A960081A16E, + FADE2AF705F14A960081A16E, + FADE2B1505F14A960081A16E, + FADE2B0905F14A960081A16E, + FADE2AF205F14A960081A16E, + FADE2B0E05F14A960081A16E, + FADE2B1405F14A960081A16E, + FADE2AFD05F14A960081A16E, + FADE2AFB05F14A960081A16E, + FADE2B1A05F14A960081A16E, + FADE2B0505F14A960081A16E, + FADE2B1F05F14A960081A16E, + FADE2B0A05F14A960081A16E, + FADE2B0F05F14A960081A16E, + FADE2AF605F14A960081A16E, + FADE2AFA05F14A960081A16E, + FADE2B1705F14A960081A16E, + FADE2B0605F14A960081A16E, + FADE2AFF05F14A960081A16E, + FADE2B1905F14A960081A16E, + FADE2B0405F14A960081A16E, + FADE2B1605F14A960081A16E, + FADE2B0005F14A960081A16E, + FADE2B1B05F14A960081A16E, + ); + isa = PBXGroup; + name = ngircd; + refType = 4; + sourceTree = ""; + }; + FADE2AEE05F14A700081A16E = { + children = ( + FADE2B5605F14AB40081A16E, + FADE2B5B05F14AB40081A16E, + FADE2B5505F14AB40081A16E, + FADE2B5805F14AB40081A16E, + FADE2B5405F14AB40081A16E, + FADE2B5705F14AB40081A16E, + FADE2B5A05F14AB40081A16E, + FADE2B5305F14AB40081A16E, + FADE2B5905F14AB40081A16E, + FADE2B5C05F14AB40081A16E, + ); + isa = PBXGroup; + name = portab; + refType = 4; + sourceTree = ""; + }; + FADE2AEF05F14A760081A16E = { + children = ( + FADE2B6C05F14B300081A16E, + FADE2B6A05F14B300081A16E, + FADE2B6F05F14B300081A16E, + FADE2B6E05F14B300081A16E, + FADE2B6D05F14B300081A16E, + FADE2B7305F14B300081A16E, + FADE2B7005F14B300081A16E, + FADE2B7405F14B300081A16E, + FADE2B6B05F14B300081A16E, + FADE2B7105F14B300081A16E, + FADE2B7205F14B300081A16E, + FADE2B6905F14B300081A16E, + FADE2B6805F14B300081A16E, + ); + isa = PBXGroup; + name = testsuite; + refType = 4; + sourceTree = ""; + }; + FADE2AF005F14A840081A16E = { + children = ( + FADE2B7705F14B530081A16E, + FADE2B7805F14B530081A16E, + FADE2B7905F14B530081A16E, + ); + isa = PBXGroup; + name = tool; + refType = 4; + sourceTree = ""; + }; + FADE2AF105F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../src/ngircd/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF205F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-server.h"; + path = "../../src/ngircd/irc-server.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF305F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-op.c"; + path = "../../src/ngircd/irc-op.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF405F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-login.c"; + path = "../../src/ngircd/irc-login.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF505F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "conn-zip.h"; + path = "../../src/ngircd/conn-zip.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF605F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = match.h; + path = ../../src/ngircd/match.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF705F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-oper.c"; + path = "../../src/ngircd/irc-oper.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF805F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-mode.c"; + path = "../../src/ngircd/irc-mode.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AF905F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = conn.h; + path = ../../src/ngircd/conn.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFA05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = messages.h; + path = ../../src/ngircd/messages.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFB05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = irc.h; + path = ../../src/ngircd/irc.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFC05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = conf.c; + path = ../../src/ngircd/conf.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFD05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = irc.c; + path = ../../src/ngircd/irc.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFE05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = hash.h; + path = ../../src/ngircd/hash.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2AFF05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = parse.c; + path = ../../src/ngircd/parse.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0005F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = resolve.c; + path = ../../src/ngircd/resolve.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0105F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = channel.c; + path = ../../src/ngircd/channel.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0205F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = defines.h; + path = ../../src/ngircd/defines.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0305F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = conf.h; + path = ../../src/ngircd/conf.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0405F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = rendezvous.c; + path = ../../src/ngircd/rendezvous.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0505F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = lists.h; + path = ../../src/ngircd/lists.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0605F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = ngircd.h; + path = ../../src/ngircd/ngircd.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0705F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-channel.h"; + path = "../../src/ngircd/irc-channel.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0805F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = channel.h; + path = ../../src/ngircd/channel.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0905F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-server.c"; + path = "../../src/ngircd/irc-server.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0A05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = log.h; + path = ../../src/ngircd/log.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0B05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-mode.h"; + path = "../../src/ngircd/irc-mode.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0C05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-info.h"; + path = "../../src/ngircd/irc-info.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0D05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "conn-zip.c"; + path = "../../src/ngircd/conn-zip.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0E05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-write.c"; + path = "../../src/ngircd/irc-write.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B0F05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = match.c; + path = ../../src/ngircd/match.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1005F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-op.h"; + path = "../../src/ngircd/irc-op.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1105F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-login.h"; + path = "../../src/ngircd/irc-login.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1205F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = conn.c; + path = ../../src/ngircd/conn.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1305F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = client.h; + path = ../../src/ngircd/client.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1405F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-write.h"; + path = "../../src/ngircd/irc-write.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1505F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "irc-oper.h"; + path = "../../src/ngircd/irc-oper.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1605F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = rendezvous.h; + path = ../../src/ngircd/rendezvous.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1705F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = ngircd.c; + path = ../../src/ngircd/ngircd.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1805F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-channel.c"; + path = "../../src/ngircd/irc-channel.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1905F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = parse.h; + path = ../../src/ngircd/parse.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1A05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = lists.c; + path = ../../src/ngircd/lists.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1B05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = resolve.h; + path = ../../src/ngircd/resolve.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1C05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = hash.c; + path = ../../src/ngircd/hash.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1D05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "irc-info.c"; + path = "../../src/ngircd/irc-info.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1E05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = "conn-func.c"; + path = "../../src/ngircd/conn-func.c"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B1F05F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = log.c; + path = ../../src/ngircd/log.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B2005F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = client.c; + path = ../../src/ngircd/client.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B2105F14A960081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = "conn-func.h"; + path = "../../src/ngircd/conn-func.h"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B2305F14A960081A16E = { + fileRef = FADE2AF205F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2405F14A960081A16E = { + fileRef = FADE2AF305F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2505F14A960081A16E = { + fileRef = FADE2AF405F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2605F14A960081A16E = { + fileRef = FADE2AF505F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2705F14A960081A16E = { + fileRef = FADE2AF605F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2805F14A960081A16E = { + fileRef = FADE2AF705F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2905F14A960081A16E = { + fileRef = FADE2AF805F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2A05F14A960081A16E = { + fileRef = FADE2AF905F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2B05F14A960081A16E = { + fileRef = FADE2AFA05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2C05F14A960081A16E = { + fileRef = FADE2AFB05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2D05F14A960081A16E = { + fileRef = FADE2AFC05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2E05F14A960081A16E = { + fileRef = FADE2AFD05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B2F05F14A960081A16E = { + fileRef = FADE2AFE05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3005F14A960081A16E = { + fileRef = FADE2AFF05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3105F14A960081A16E = { + fileRef = FADE2B0005F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3205F14A960081A16E = { + fileRef = FADE2B0105F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3305F14A960081A16E = { + fileRef = FADE2B0205F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3405F14A960081A16E = { + fileRef = FADE2B0305F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3505F14A960081A16E = { + fileRef = FADE2B0405F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3605F14A960081A16E = { + fileRef = FADE2B0505F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3705F14A960081A16E = { + fileRef = FADE2B0605F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3805F14A960081A16E = { + fileRef = FADE2B0705F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3905F14A960081A16E = { + fileRef = FADE2B0805F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3A05F14A960081A16E = { + fileRef = FADE2B0905F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3B05F14A960081A16E = { + fileRef = FADE2B0A05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3C05F14A960081A16E = { + fileRef = FADE2B0B05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3D05F14A960081A16E = { + fileRef = FADE2B0C05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3E05F14A960081A16E = { + fileRef = FADE2B0D05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B3F05F14A960081A16E = { + fileRef = FADE2B0E05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4005F14A960081A16E = { + fileRef = FADE2B0F05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4105F14A960081A16E = { + fileRef = FADE2B1005F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4205F14A960081A16E = { + fileRef = FADE2B1105F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4305F14A960081A16E = { + fileRef = FADE2B1205F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4405F14A960081A16E = { + fileRef = FADE2B1305F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4505F14A960081A16E = { + fileRef = FADE2B1405F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4605F14A960081A16E = { + fileRef = FADE2B1505F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4705F14A960081A16E = { + fileRef = FADE2B1605F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4805F14A960081A16E = { + fileRef = FADE2B1705F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4905F14A960081A16E = { + fileRef = FADE2B1805F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4A05F14A960081A16E = { + fileRef = FADE2B1905F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4B05F14A960081A16E = { + fileRef = FADE2B1A05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4C05F14A960081A16E = { + fileRef = FADE2B1B05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4D05F14A960081A16E = { + fileRef = FADE2B1C05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4E05F14A960081A16E = { + fileRef = FADE2B1D05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B4F05F14A960081A16E = { + fileRef = FADE2B1E05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B5005F14A960081A16E = { + fileRef = FADE2B1F05F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B5105F14A960081A16E = { + fileRef = FADE2B2005F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B5205F14A960081A16E = { + fileRef = FADE2B2105F14A960081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2B5305F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = splint.h; + path = ../../src/portab/splint.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5405F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = imp.h; + path = ../../src/portab/imp.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5505F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = ansi2knr.c; + path = ../../src/portab/ansi2knr.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5605F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../src/portab/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5705F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = portab.h; + path = ../../src/portab/portab.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5805F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = exp.h; + path = ../../src/portab/exp.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5905F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = strlcpy.c; + path = ../../src/portab/strlcpy.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5A05F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = portabtest.c; + path = ../../src/portab/portabtest.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5B05F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.man; + name = ansi2knr.1; + path = ../../src/portab/ansi2knr.1; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B5C05F14AB40081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = vsnprintf.c; + path = ../../src/portab/vsnprintf.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6805F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = tests.sh; + path = ../../src/testsuite/tests.sh; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6905F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = "stress-server.sh"; + path = "../../src/testsuite/stress-server.sh"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6A05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "channel-test.e"; + path = "../../src/testsuite/channel-test.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6B05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = "stop-server.sh"; + path = "../../src/testsuite/stop-server.sh"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6C05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../src/testsuite/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6D05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = getpid.sh; + path = ../../src/testsuite/getpid.sh; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6E05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "connect-test.e"; + path = "../../src/testsuite/connect-test.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B6F05F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "check-idle.e"; + path = "../../src/testsuite/check-idle.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7005F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "ngircd-test.conf"; + path = "../../src/testsuite/ngircd-test.conf"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7105F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "stress-A.e"; + path = "../../src/testsuite/stress-A.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7205F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "stress-B.e"; + path = "../../src/testsuite/stress-B.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7305F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = "mode-test.e"; + path = "../../src/testsuite/mode-test.e"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7405F14B300081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text.script.sh; + name = "start-server.sh"; + path = "../../src/testsuite/start-server.sh"; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7705F14B530081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../src/tool/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7805F14B530081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.c; + name = tool.c; + path = ../../src/tool/tool.c; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7905F14B530081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = tool.h; + path = ../../src/tool/tool.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B7B05F14B9F0081A16E = { + explicitFileType = "compiled.mach-o.executable"; + includeInIndex = 0; + isa = PBXFileReference; + path = ngIRCd; + refType = 3; + sourceTree = BUILT_PRODUCTS_DIR; + }; + FADE2B8F05F14C6C0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = sourcecode.c.h; + name = config.h; + path = ../../src/config.h; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2B9005F14C6C0081A16E = { + fileEncoding = 5; + isa = PBXFileReference; + lastKnownFileType = text; + name = Makefile.am; + path = ../../src/Makefile.am; + refType = 2; + sourceTree = SOURCE_ROOT; + }; + FADE2BBD05F14DEF0081A16E = { + fileRef = FADE2B5805F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2BBF05F14DEF0081A16E = { + fileRef = FADE2B5405F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2BC105F14DF10081A16E = { + fileRef = FADE2B5705F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2BC305F14DF40081A16E = { + fileRef = FADE2B5905F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2BC505F14DF50081A16E = { + fileRef = FADE2B5C05F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2C5E05F1511B0081A16E = { + buildPhases = ( + FADE2C5F05F1511B0081A16E, + FADE2C7C05F1511B0081A16E, + FADE2C9605F1511B0081A16E, + FADE2C9705F1511B0081A16E, + FADE2C9805F1511B0081A16E, + ); + buildRules = ( + ); + buildSettings = { + GCC_TREAT_WARNINGS_AS_ERRORS = YES; + GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES; + GCC_WARN_UNUSED_LABEL = YES; + GCC_WARN_UNUSED_PARAMETER = YES; + GCC_WARN_UNUSED_VALUE = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + PRODUCT_NAME = portabtest; + WARNING_CFLAGS = "-Wall"; + }; + dependencies = ( + ); + isa = PBXNativeTarget; + name = portabtest; + productInstallPath = "$(HOME)/bin"; + productName = ngIRCd; + productReference = FADE2C9905F1511B0081A16E; + productType = "com.apple.product-type.tool"; + }; + FADE2C5F05F1511B0081A16E = { + buildActionMask = 2147483647; + files = ( + FADE2CB205F151490081A16E, + FADE2CB305F151490081A16E, + ); + isa = PBXHeadersBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + FADE2C7C05F1511B0081A16E = { + buildActionMask = 2147483647; + files = ( + FADE2CB405F151490081A16E, + ); + isa = PBXSourcesBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + FADE2C9605F1511B0081A16E = { + buildActionMask = 2147483647; + files = ( + ); + isa = PBXFrameworksBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + FADE2C9705F1511B0081A16E = { + buildActionMask = 2147483647; + files = ( + ); + isa = PBXRezBuildPhase; + runOnlyForDeploymentPostprocessing = 0; + }; + FADE2C9805F1511B0081A16E = { + buildActionMask = 8; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + ); + isa = PBXCopyFilesBuildPhase; + runOnlyForDeploymentPostprocessing = 1; + }; + FADE2C9905F1511B0081A16E = { + explicitFileType = "compiled.mach-o.executable"; + includeInIndex = 0; + isa = PBXFileReference; + path = portabtest; + refType = 3; + sourceTree = BUILT_PRODUCTS_DIR; + }; + FADE2CB205F151490081A16E = { + fileRef = FADE2B5805F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2CB305F151490081A16E = { + fileRef = FADE2B5405F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2CB405F151490081A16E = { + fileRef = FADE2B5A05F14AB40081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2CC005F152770081A16E = { + fileRef = FADE2B7805F14B530081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + FADE2CC205F152780081A16E = { + fileRef = FADE2B7905F14B530081A16E; + isa = PBXBuildFile; + settings = { + }; + }; + }; + rootObject = 08FB7793FE84155DC02AAC07; +} Index: doc/FAQ.txt =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/doc/FAQ.txt,v retrieving revision 1.5.2.1 retrieving revision 1.7 diff -u -p -r1.5.2.1 -r1.7 --- a/doc/FAQ.txt 29 Apr 2003 13:45:09 -0000 1.5.2.1 +++ b/doc/FAQ.txt 7 Nov 2003 21:32:15 -0000 1.7 @@ -64,4 +64,4 @@ A: Please file a bug report at are defined - C: The server supports the CHANINFO command. +- L: INVITE- and BAN-lists should be synchronized between servers: if the + peer understands this flag, it will send "MODE +I" and "MODE +b" + commands after the server link has been established. + - o: IRC operators are allowed to change channel- and channel-user-modes even if they aren't channel-operator of the affected channel. @@ -111,4 +115,4 @@ channel mode). In this case shou -- -$Id: Protocol.txt,v 1.9.2.2 2003/12/08 14:24:13 alex Exp $ +$Id: Protocol.txt,v 1.12 2004/04/25 15:44:10 alex Exp $ Index: doc/README-BeOS.txt =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/doc/README-BeOS.txt,v retrieving revision 1.6.2.1 retrieving revision 1.7 diff -u -p -r1.6.2.1 -r1.7 --- a/doc/README-BeOS.txt 18 Jul 2003 20:48:20 -0000 1.6.2.1 +++ b/doc/README-BeOS.txt 15 May 2003 21:47:57 -0000 1.7 @@ -50,4 +50,4 @@ mir in Verbindung setzen (alex@barton.de Fuer eine Aenderung im CVS ist es aber meiner Meinung nach noch zu frueh ... -- -$Id: README-BeOS.txt,v 1.6.2.1 2003/07/18 20:48:20 alex Exp $ +$Id: README-BeOS.txt,v 1.7 2003/05/15 21:47:57 alex Exp $ Index: doc/sample-ngircd.conf =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/doc/sample-ngircd.conf,v retrieving revision 1.20.2.4 retrieving revision 1.25.2.1 diff -u -p -r1.20.2.4 -r1.25.2.1 --- a/doc/sample-ngircd.conf 19 Dec 2003 14:30:49 -0000 1.20.2.4 +++ b/doc/sample-ngircd.conf 7 May 2004 11:24:17 -0000 1.25.2.1 @@ -1,4 +1,4 @@ -# $Id: sample-ngircd.conf,v 1.20.2.4 2003/12/19 14:30:49 alex Exp $ +# $Id: sample-ngircd.conf,v 1.25.2.1 2004/05/07 11:24:17 alex Exp $ # # This is a sample configuration file for the ngIRCd, which must be adepted @@ -23,7 +23,7 @@ # Info text of the server. This will be shown by WHOIS and # LINKS requests for example. Info = Server Info Text - + # Global password for all users needed to connect to the server ;Password = abc @@ -45,6 +45,10 @@ # be shown to all users connecting to the server: ;MotdFile = /usr/local/etc/ngircd.motd + # A simple Phrase (<256 chars) if you don't want to use a motd file. + # If it is set no MotdFile will be read at all. + ;MotdPhrase = "Hello world!" + # User ID under which the server should run; you can use the name # of the user or the numerical ID. ATTENTION: For this to work the # server must have been started with root privileges! In addition, @@ -57,6 +61,13 @@ # server must have been started with root privileges! ;ServerGID = 65534 + # A directory to chroot in when everything is initialized. It + # doesn't need to be populated if ngIRCd is compiled as a static + # binary. By default ngIRCd won't use the chroot() feature. + # ATTENTION: For this to work the server must have been started + # with root privileges! + ;ChrootDir = /var/empty + # After seconds of inactivity the server will send a # PING to the peer to test whether it is alive or not. ;PingTimeout = 120 Index: man/ngircd.8 =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/man/ngircd.8,v retrieving revision 1.8 retrieving revision 1.9 diff -u -p -r1.8 -r1.9 --- a/man/ngircd.8 10 Mar 2003 00:58:06 -0000 1.8 +++ b/man/ngircd.8 5 Apr 2004 10:59:10 -0000 1.9 @@ -1,5 +1,5 @@ .\" -.\" $Id: ngircd.8,v 1.8 2003/03/10 00:58:06 alex Exp $ +.\" $Id: ngircd.8,v 1.9 2004/04/05 10:59:10 alex Exp $ .\" .TH ngircd 8 "March 2003" ngircd "ngIRCd Manual" .SH NAME @@ -36,9 +36,6 @@ controlling terminal and to wait for cli .PP You can use these options to modify this default: .TP -\fB\-\-configtest\fR -Read, validate and display the configuration; then exit. -.TP \fB\-f\fR \fIfile\fR, \fB\-\-config\fR \fIfile\fR Use .I file @@ -52,6 +49,9 @@ All log messages go to the console. Disable automatic connections to other servers. You can use the IRC command CONNECT later on as IRC Operator to link this ngIRCd to other servers. .TP +\fB\-t\fR, \fB\-\-configtest\fR +Read, validate and display the configuration; then exit. +.TP \fB\-\-version\fR Output version information and exit. .TP Index: man/ngircd.conf.5 =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/man/ngircd.conf.5,v retrieving revision 1.9.2.2 retrieving revision 1.12.2.1 diff -u -p -r1.9.2.2 -r1.12.2.1 --- a/man/ngircd.conf.5 7 Nov 2003 20:51:10 -0000 1.9.2.2 +++ b/man/ngircd.conf.5 7 May 2004 11:24:18 -0000 1.12.2.1 @@ -1,5 +1,5 @@ .\" -.\" $Id: ngircd.conf.5,v 1.9.2.2 2003/11/07 20:51:10 alex Exp $ +.\" $Id: ngircd.conf.5,v 1.12.2.1 2004/05/07 11:24:18 alex Exp $ .\" .TH ngircd.conf 5 "Mai 2003" ngircd "ngIRCd Manual" .SH NAME @@ -75,6 +75,10 @@ the server listens on all configured ip Text file with the "message of the day" (MOTD). This message will be shown to all users connecting to the server. .TP +\fBMotdPhrase\fR +A simple Phrase (<256 chars) if you don't want to use a motd file. +If it is set no MotdFile will be read at all. +.TP \fBServerUID\fR User ID under which the server should run; you can use the name of the user or the numerical ID. @@ -98,6 +102,18 @@ For this to work the server must have been started with root privileges! .RE .TP +\fBChrootDir\fR +A directory to chroot in when everything is initialized. It doesn't need +to be populated if ngIRCd is compiled as a static binary. By default ngIRCd +won't use the chroot() feature. +.PP +.RS +.B Attention: +.br +For this to work the server must have +been started with root privileges! +.RE +.TP \fBPingTimeout\fR After seconds of inactivity the server will send a PING to the peer to test whether it is alive or not. Default: 120. Index: src/ngircd/Makefile.am =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/Makefile.am,v retrieving revision 1.39.2.3 retrieving revision 1.42 diff -u -p -r1.39.2.3 -r1.42 --- a/src/ngircd/Makefile.am 4 Dec 2003 14:13:42 -0000 1.39.2.3 +++ b/src/ngircd/Makefile.am 4 Dec 2003 14:05:16 -0000 1.42 @@ -8,7 +8,7 @@ # (at your option) any later version. # Please read the file COPYING, README and AUTHORS for more information. # -# $Id: Makefile.am,v 1.39.2.3 2003/12/04 14:13:42 alex Exp $ +# $Id: Makefile.am,v 1.42 2003/12/04 14:05:16 alex Exp $ # AUTOMAKE_OPTIONS = ../portab/ansi2knr Index: src/ngircd/channel.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/channel.c,v retrieving revision 1.42.2.1 retrieving revision 1.45 diff -u -p -r1.42.2.1 -r1.45 --- a/src/ngircd/channel.c 7 Nov 2003 20:51:10 -0000 1.42.2.1 +++ b/src/ngircd/channel.c 11 Mar 2004 22:16:31 -0000 1.45 @@ -17,12 +17,13 @@ #include "portab.h" -static char UNUSED id[] = "$Id: channel.c,v 1.42.2.1 2003/11/07 20:51:10 alex Exp $"; +static char UNUSED id[] = "$Id: channel.c,v 1.45 2004/03/11 22:16:31 alex Exp $"; #include "imp.h" #include #include #include +#include #include "conn-func.h" #include "client.h" @@ -707,7 +708,7 @@ Channel_Create( CHAR *Name ) assert( Name != NULL ); - c = malloc( sizeof( CHANNEL )); + c = (CHANNEL *)malloc( sizeof( CHANNEL )); if( ! c ) { Log( LOG_EMERG, "Can't allocate memory! [New_Chan]" ); @@ -759,7 +760,7 @@ Add_Client( CHANNEL *Chan, CLIENT *Clien assert( Client != NULL ); /* neue CL2CHAN-Struktur anlegen */ - cl2chan = malloc( sizeof( CL2CHAN )); + cl2chan = (CL2CHAN *)malloc( sizeof( CL2CHAN )); if( ! cl2chan ) { Log( LOG_EMERG, "Can't allocate memory! [Add_Client]" ); Index: src/ngircd/client.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/client.c,v retrieving revision 1.74 retrieving revision 1.76 diff -u -p -r1.74 -r1.76 --- a/src/ngircd/client.c 31 Mar 2003 15:54:21 -0000 1.74 +++ b/src/ngircd/client.c 11 Mar 2004 22:16:31 -0000 1.76 @@ -17,7 +17,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: client.c,v 1.74 2003/03/31 15:54:21 alex Exp $"; +static char UNUSED id[] = "$Id: client.c,v 1.76 2004/03/11 22:16:31 alex Exp $"; #include "imp.h" #include @@ -25,6 +25,7 @@ static char UNUSED id[] = "$Id: client.c #include #include #include +#include #include #include "conn.h" @@ -1023,7 +1024,7 @@ New_Client_Struct( VOID ) CLIENT *c; - c = malloc( sizeof( CLIENT )); + c = (CLIENT *)malloc( sizeof( CLIENT )); if( ! c ) { Log( LOG_EMERG, "Can't allocate memory! [New_Client_Struct]" ); Index: src/ngircd/conf.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conf.c,v retrieving revision 1.57.2.4 retrieving revision 1.63.2.1 diff -u -p -r1.57.2.4 -r1.63.2.1 --- a/src/ngircd/conf.c 19 Dec 2003 14:30:49 -0000 1.57.2.4 +++ b/src/ngircd/conf.c 7 May 2004 11:24:18 -0000 1.63.2.1 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: conf.c,v 1.57.2.4 2003/12/19 14:30:49 alex Exp $"; +static char UNUSED id[] = "$Id: conf.c,v 1.63.2.1 2004/05/07 11:24:18 alex Exp $"; #include "imp.h" #include @@ -23,6 +23,7 @@ static char UNUSED id[] = "$Id: conf.c,v #include #include #include +#include #include #include #include @@ -113,6 +114,8 @@ Conf_Test( VOID ) printf( " AdminInfo2 = %s\n", Conf_ServerAdmin2 ); printf( " AdminEMail = %s\n", Conf_ServerAdminMail ); printf( " MotdFile = %s\n", Conf_MotdFile ); + printf( " MotdPhrase = %s\n", Conf_MotdPhrase ); + printf( " ChrootDir= %s\n", Conf_Chroot ); printf( " Ports = " ); for( i = 0; i < Conf_ListenPorts_Count; i++ ) { @@ -342,6 +345,10 @@ Set_Defaults( BOOLEAN InitServers ) strlcpy( Conf_MotdFile, SYSCONFDIR, sizeof( Conf_MotdFile )); strlcat( Conf_MotdFile, MOTD_FILE, sizeof( Conf_MotdFile )); + strlcpy( Conf_MotdPhrase, MOTD_PHRASE, sizeof( Conf_MotdPhrase )); + + strlcpy( Conf_Chroot, CHROOT_DIR, sizeof( Conf_Chroot )); + Conf_ListenPorts_Count = 0; strcpy( Conf_ListenAddress, "" ); @@ -612,6 +619,18 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR if( strlcpy( Conf_MotdFile, Arg, sizeof( Conf_MotdFile )) >= sizeof( Conf_MotdFile )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MotdFile\" too long!", NGIRCd_ConfFile, Line ); return; } + if( strcasecmp( Var, "MotdPhrase" ) == 0 ) + { + /* "Message of the day" phrase (instead of file) */ + if( strlcpy( Conf_MotdPhrase, Arg, sizeof( Conf_MotdPhrase )) >= sizeof( Conf_MotdPhrase )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MotdPhrase\" too long!", NGIRCd_ConfFile, Line ); + return; + } + if( strcasecmp( Var, "ChrootDir" ) == 0 ) + { + /* directory for chroot() */ + if( strlcpy( Conf_Chroot, Arg, sizeof( Conf_Chroot )) >= sizeof( Conf_Chroot )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"ChrootDir\" too long!", NGIRCd_ConfFile, Line ); + return; + } if( strcasecmp( Var, "ServerUID" ) == 0 ) { /* UID the daemon should switch to */ @@ -620,7 +639,7 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR else { #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"ServerUID\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"ServerUID\" is not a number!", NGIRCd_ConfFile, Line ); else #endif Conf_UID = (UINT)atoi( Arg ); @@ -635,7 +654,7 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR else { #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"ServerGID\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"ServerGID\" is not a number!", NGIRCd_ConfFile, Line ); else #endif Conf_GID = (UINT)atoi( Arg ); @@ -688,7 +707,7 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR { /* Maximum number of connections. Values <= 0 are equal to "no limit". */ #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxConnections\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxConnections\" is not a number!", NGIRCd_ConfFile, Line ); else #endif Conf_MaxConnections = atol( Arg ); @@ -698,7 +717,7 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR { /* Maximum number of simoultanous connections from one IP. Values <= 0 are equal to "no limit". */ #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxConnectionsIP\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxConnectionsIP\" is not a number!", NGIRCd_ConfFile, Line ); else #endif Conf_MaxConnectionsIP = atoi( Arg ); @@ -708,7 +727,7 @@ Handle_GLOBAL( INT Line, CHAR *Var, CHAR { /* Maximum number of channels a user can join. Values <= 0 are equal to "no limit". */ #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxJoins\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"MaxJoins\" is not a number!", NGIRCd_ConfFile, Line ); else #endif Conf_MaxJoins = atoi( Arg ); @@ -801,7 +820,7 @@ Handle_SERVER( INT Line, CHAR *Var, CHAR { /* Server group */ #ifdef HAVE_ISDIGIT - if( ! isdigit( *Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"Group\" is not a number!", NGIRCd_ConfFile, Line ); + if( ! isdigit( (INT)*Arg )) Config_Error( LOG_WARNING, "%s, line %d: Value of \"Group\" is not a number!", NGIRCd_ConfFile, Line ); else #endif New_Server.group = atoi( Arg ); Index: src/ngircd/conf.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conf.h,v retrieving revision 1.26.2.1 retrieving revision 1.28.2.1 diff -u -p -r1.26.2.1 -r1.28.2.1 --- a/src/ngircd/conf.h 7 Nov 2003 20:51:11 -0000 1.26.2.1 +++ b/src/ngircd/conf.h 7 May 2004 11:24:18 -0000 1.28.2.1 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: conf.h,v 1.26.2.1 2003/11/07 20:51:11 alex Exp $ + * $Id: conf.h,v 1.28.2.1 2004/05/07 11:24:18 alex Exp $ * * Configuration management (header) */ @@ -72,6 +72,9 @@ GLOBAL CHAR Conf_ServerAdminMail[CLIENT_ /* File with MOTD text */ GLOBAL CHAR Conf_MotdFile[FNAME_LEN]; +/* Phrase with MOTD text */ +GLOBAL CHAR Conf_MotdPhrase[LINE_LEN]; + /* Ports the server should listen on */ GLOBAL UINT Conf_ListenPorts[MAX_LISTEN_PORTS]; GLOBAL INT Conf_ListenPorts_Count; @@ -83,6 +86,9 @@ GLOBAL CHAR Conf_ListenAddress[16]; GLOBAL UINT Conf_UID; GLOBAL UINT Conf_GID; +/* A directory to chroot() in */ +GLOBAL CHAR Conf_Chroot[FNAME_LEN]; + /* Timeouts for PING and PONG */ GLOBAL INT Conf_PingTimeout; GLOBAL INT Conf_PongTimeout; Index: src/ngircd/conn-func.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conn-func.c,v retrieving revision 1.1.2.2 retrieving revision 1.3 diff -u -p -r1.1.2.2 -r1.3 --- a/src/ngircd/conn-func.c 26 Dec 2003 16:16:48 -0000 1.1.2.2 +++ b/src/ngircd/conn-func.c 26 Dec 2003 15:55:07 -0000 1.3 @@ -16,7 +16,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: conn-func.c,v 1.1.2.2 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: conn-func.c,v 1.3 2003/12/26 15:55:07 alex Exp $"; #include "imp.h" #include Index: src/ngircd/conn-zip.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conn-zip.c,v retrieving revision 1.3.2.1 retrieving revision 1.5 diff -u -p -r1.3.2.1 -r1.5 --- a/src/ngircd/conn-zip.c 26 Dec 2003 16:16:48 -0000 1.3.2.1 +++ b/src/ngircd/conn-zip.c 25 Apr 2004 13:55:36 -0000 1.5 @@ -19,7 +19,7 @@ #ifdef ZLIB -static char UNUSED id[] = "$Id: conn-zip.c,v 1.3.2.1 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: conn-zip.c,v 1.5 2004/04/25 13:55:36 alex Exp $"; #include "imp.h" #include @@ -161,7 +161,7 @@ Unzip_Buffer( CONN_ID Idx ) result = inflate( in, Z_SYNC_FLUSH ); if( result != Z_OK ) { - Log( LOG_ALERT, "Decompression error: code %d (ni=%d, ai=%d, no=%d, ao=%d)!?", result, in->next_in, in->avail_in, in->next_out, in->avail_out ); + Log( LOG_ALERT, "Decompression error: %s (code=%d, ni=%d, ai=%d, no=%d, ao=%d)!?", in->msg, result, in->next_in, in->avail_in, in->next_out, in->avail_out ); Conn_Close( Idx, "Decompression error!", NULL, FALSE ); return FALSE; } Index: src/ngircd/conn-zip.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conn-zip.h,v retrieving revision 1.1.2.1 retrieving revision 1.2 diff -u -p -r1.1.2.1 -r1.2 --- a/src/ngircd/conn-zip.h 26 Dec 2003 16:16:48 -0000 1.1.2.1 +++ b/src/ngircd/conn-zip.h 26 Dec 2003 15:55:07 -0000 1.2 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: conn-zip.h,v 1.1.2.1 2003/12/26 16:16:48 alex Exp $ + * $Id: conn-zip.h,v 1.2 2003/12/26 15:55:07 alex Exp $ * * Connection compression using ZLIB (header) */ Index: src/ngircd/conn.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conn.c,v retrieving revision 1.122.2.4 retrieving revision 1.134 diff -u -p -r1.122.2.4 -r1.134 --- a/src/ngircd/conn.c 3 Feb 2004 13:54:36 -0000 1.122.2.4 +++ b/src/ngircd/conn.c 25 Apr 2004 14:06:12 -0000 1.134 @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) + * Copyright (c)2001-2004 Alexander Barton * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -16,7 +16,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: conn.c,v 1.122.2.4 2004/02/03 13:54:36 alex Exp $"; +static char UNUSED id[] = "$Id: conn.c,v 1.134 2004/04/25 14:06:12 alex Exp $"; #include "imp.h" #include @@ -33,18 +33,22 @@ static char UNUSED id[] = "$Id: conn.c,v #include #include +#ifdef HAVE_NETINET_IP_H +# include +#endif + #ifdef HAVE_ARPA_INET_H -#include +# include #else -#define PF_INET AF_INET +# define PF_INET AF_INET #endif #ifdef HAVE_STDINT_H -#include /* e.g. for Mac OS X */ +# include /* e.g. for Mac OS X */ #endif #ifdef TCPWRAP -#include /* for TCP Wrappers */ +# include /* for TCP Wrappers */ #endif #include "defines.h" @@ -64,7 +68,7 @@ static char UNUSED id[] = "$Id: conn.c,v #include "tool.h" #ifdef RENDEZVOUS -#include "rendezvous.h" +# include "rendezvous.h" #endif #include "exp.h" @@ -113,7 +117,7 @@ Conn_Init( VOID ) /* konfiguriertes Limit beachten */ if( Pool_Size > Conf_MaxConnections ) Pool_Size = Conf_MaxConnections; } - My_Connections = malloc( sizeof( CONNECTION ) * Pool_Size ); + My_Connections = (CONNECTION *)malloc( sizeof( CONNECTION ) * Pool_Size ); if( ! My_Connections ) { /* Speicher konnte nicht alloziert werden! */ @@ -610,6 +614,7 @@ Conn_Close( CONN_ID Idx, CHAR *LogMsg, C * sub-processes are closed down. */ CLIENT *c; + CHAR *txt; DOUBLE in_k, out_k; #ifdef ZLIB DOUBLE in_z_k, out_z_k; @@ -617,7 +622,6 @@ Conn_Close( CONN_ID Idx, CHAR *LogMsg, C #endif assert( Idx > NONE ); - assert( My_Connections[Idx].sock > NONE ); /* Is this link already shutting down? */ if( My_Connections[Idx].options & CONN_ISCLOSING ) @@ -627,8 +631,16 @@ Conn_Close( CONN_ID Idx, CHAR *LogMsg, C return; } + assert( My_Connections[Idx].sock > NONE ); + /* Mark link as "closing" */ My_Connections[Idx].options |= CONN_ISCLOSING; + + if( LogMsg ) txt = LogMsg; + else txt = FwdMsg; + if( ! txt ) txt = "Reason unknown"; + + Log( LOG_INFO, "Shutting down connection %d (%s) with %s:%d ...", Idx, LogMsg ? LogMsg : FwdMsg, My_Connections[Idx].host, ntohs( My_Connections[Idx].addr.sin_port )); /* Search client, if any */ c = Client_GetFromConn( Idx ); @@ -647,7 +659,6 @@ Conn_Close( CONN_ID Idx, CHAR *LogMsg, C /* Send ERROR to client (see RFC!) */ if( FwdMsg ) Conn_WriteStr( Idx, "ERROR :%s", FwdMsg ); else Conn_WriteStr( Idx, "ERROR :Closing connection." ); - if( My_Connections[Idx].sock == NONE ) return; } /* Try to write out the write buffer */ @@ -868,11 +879,9 @@ Handle_Write( CONN_ID Idx ) return FALSE; } -#ifdef DEBUG - Log( LOG_DEBUG, "Connection %d with \"%s:%d\" established, now sendig PASS and SERVER ...", Idx, My_Connections[Idx].host, Conf_Server[Conf_GetServer( Idx )].port ); -#endif + Log( LOG_INFO, "Connection %d with \"%s:%d\" established. Now logging in ...", Idx, My_Connections[Idx].host, Conf_Server[Conf_GetServer( Idx )].port ); - /* PASS und SERVER verschicken */ + /* Send PASS and SERVER command to peer */ Conn_WriteStr( Idx, "PASS %s %s", Conf_Server[Conf_GetServer( Idx )].pwd_out, NGIRCd_ProtoID ); return Conn_WriteStr( Idx, "SERVER %s :%s", Conf_ServerName, Conf_ServerInfo ); } @@ -995,11 +1004,11 @@ New_Connection( INT Sock ) /* zunaechst realloc() versuchen; wenn das scheitert, malloc() versuchen * und Daten ggf. "haendisch" umkopieren. (Haesslich! Eine wirklich * dynamische Verwaltung waere wohl _deutlich_ besser ...) */ - ptr = realloc( My_Connections, sizeof( CONNECTION ) * new_size ); + ptr = (POINTER *)realloc( My_Connections, sizeof( CONNECTION ) * new_size ); if( ! ptr ) { /* realloc() ist fehlgeschlagen. Nun malloc() probieren: */ - ptr = malloc( sizeof( CONNECTION ) * new_size ); + ptr = (POINTER *)malloc( sizeof( CONNECTION ) * new_size ); if( ! ptr ) { /* Offenbar steht kein weiterer Sepeicher zur Verfuegung :-( */ @@ -1021,7 +1030,7 @@ New_Connection( INT Sock ) #endif /* Adjust pointer to new block */ - My_Connections = ptr; + My_Connections = (CONNECTION *)ptr; /* Initialize new items */ for( idx = Pool_Size; idx < new_size; idx++ ) Init_Conn_Struct( idx ); @@ -1055,7 +1064,11 @@ New_Connection( INT Sock ) /* Hostnamen ermitteln */ strlcpy( My_Connections[idx].host, inet_ntoa( new_addr.sin_addr ), sizeof( My_Connections[idx].host )); Client_SetHostname( c, My_Connections[idx].host ); +#ifdef IDENTAUTH + s = Resolve_Addr( &new_addr, My_Connections[idx].sock ); +#else s = Resolve_Addr( &new_addr ); +#endif if( s ) { /* Sub-Prozess wurde asyncron gestartet */ @@ -1546,24 +1559,40 @@ Init_Conn_Struct( CONN_ID Idx ) LOCAL BOOLEAN Init_Socket( INT Sock ) { - /* Socket-Optionen setzen */ + /* Initialize socket (set options) */ - INT on = 1; + INT value; -#ifdef O_NONBLOCK /* A/UX kennt das nicht? */ +#ifdef O_NONBLOCK /* unknown on A/UX */ if( fcntl( Sock, F_SETFL, O_NONBLOCK ) != 0 ) { - Log( LOG_CRIT, "Can't enable non-blocking mode: %s!", strerror( errno )); + Log( LOG_CRIT, "Can't enable non-blocking mode for socket: %s!", strerror( errno )); close( Sock ); return FALSE; } #endif - if( setsockopt( Sock, SOL_SOCKET, SO_REUSEADDR, &on, (socklen_t)sizeof( on )) != 0) + + /* Don't block this port after socket shutdown */ + value = 1; + if( setsockopt( Sock, SOL_SOCKET, SO_REUSEADDR, &value, (socklen_t)sizeof( value )) != 0 ) { - Log( LOG_ERR, "Can't set socket options: %s!", strerror( errno )); - /* dieser Fehler kann ignoriert werden. */ + Log( LOG_ERR, "Can't set socket option SO_REUSEADDR: %s!", strerror( errno )); + /* ignore this error */ } + /* Set type of service (TOS) */ +#if defined(IP_TOS) && defined(IPTOS_LOWDELAY) + value = IPTOS_LOWDELAY; +#ifdef DEBUG + Log( LOG_DEBUG, "Setting option IP_TOS on socket %d to IPTOS_LOWDELAY (%d).", Sock, value ); +#endif + if( setsockopt( Sock, SOL_IP, IP_TOS, &value, (socklen_t)sizeof( value )) != 0 ) + { + Log( LOG_ERR, "Can't set socket option IP_TOS: %s!", strerror( errno )); + /* ignore this error */ + } +#endif + return TRUE; } /* Init_Socket */ @@ -1580,26 +1609,26 @@ Read_Resolver_Result( INT r_fd ) FD_CLR( r_fd, &Resolver_FDs ); - /* Anfrage vom Parent lesen */ + /* Read result from pipe */ len = read( r_fd, result, HOST_LEN - 1 ); if( len < 0 ) { - /* Fehler beim Lesen aus der Pipe */ + /* Error! */ close( r_fd ); Log( LOG_CRIT, "Resolver: Can't read result: %s!", strerror( errno )); return; } result[len] = '\0'; - /* zugehoerige Connection suchen */ + /* Search associated connection ... */ for( i = 0; i < Pool_Size; i++ ) { if(( My_Connections[i].sock != NONE ) && ( My_Connections[i].res_stat ) && ( My_Connections[i].res_stat->pipe[0] == r_fd )) break; } if( i >= Pool_Size ) { - /* Opsa! Keine passende Connection gefunden!? Vermutlich - * wurde sie schon wieder geschlossen. */ + /* Ops, none found? Probably the connection has already + * been closed. */ close( r_fd ); #ifdef DEBUG Log( LOG_DEBUG, "Resolver: Got result for unknown connection!?" ); @@ -1611,7 +1640,7 @@ Read_Resolver_Result( INT r_fd ) Log( LOG_DEBUG, "Resolver: %s is \"%s\".", My_Connections[i].host, result ); #endif - /* Aufraeumen */ + /* Clean up ... */ close( My_Connections[i].res_stat->pipe[0] ); close( My_Connections[i].res_stat->pipe[1] ); free( My_Connections[i].res_stat ); @@ -1619,21 +1648,50 @@ Read_Resolver_Result( INT r_fd ) if( My_Connections[i].sock > NONE ) { - /* Eingehende Verbindung: Hostnamen setzen */ + /* Incoming connection */ +#ifdef IDENTAUTH + CHAR *ident; +#endif + + /* Search client ... */ c = Client_GetFromConn( i ); assert( c != NULL ); + + /* Only update client information of unregistered clients */ + if( Client_Type( c ) != CLIENT_UNKNOWN ) + { +#ifdef DEBUG + Log( LOG_DEBUG, "Resolver: discarding result for already registered connection %d.", i ); +#endif + return; + } + + /* Set hostname */ strlcpy( My_Connections[i].host, result, sizeof( My_Connections[i].host )); Client_SetHostname( c, result ); + +#ifdef IDENTAUTH + ident = strchr( result, 0 ); + ident++; + + /* Do we have a result of the IDENT lookup? If so, set it as the user name */ + if( *ident ) + { + Log( LOG_INFO, "IDENT lookup for connection %ld: \"%s\".", i, ident ); + Client_SetUser( c, ident, TRUE ); + } + else Log( LOG_INFO, "IDENT lookup for connection %ld: no result.", i ); +#endif } else { - /* Ausgehende Verbindung (=Server): IP setzen */ + /* Outgoing connection (server link!): set IP address */ n = Conf_GetServer( i ); - if( n > NONE ) strlcpy( Conf_Server[n].ip, result, sizeof( Conf_Server[n].ip )); - else Log( LOG_ERR, "Got resolver result for non-configured server!?" ); + assert( n > NONE ); + strlcpy( Conf_Server[n].ip, result, sizeof( Conf_Server[n].ip )); } - /* Penalty-Zeit zurueck setzen */ + /* Reset penalty time */ Conn_ResetPenalty( i ); } /* Read_Resolver_Result */ Index: src/ngircd/conn.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/conn.h,v retrieving revision 1.31.2.1 retrieving revision 1.32 diff -u -p -r1.31.2.1 -r1.32 --- a/src/ngircd/conn.h 26 Dec 2003 16:16:48 -0000 1.31.2.1 +++ b/src/ngircd/conn.h 26 Dec 2003 15:55:07 -0000 1.32 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: conn.h,v 1.31.2.1 2003/12/26 16:16:48 alex Exp $ + * $Id: conn.h,v 1.32 2003/12/26 15:55:07 alex Exp $ * * Connection management (header) */ Index: src/ngircd/defines.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/defines.h,v retrieving revision 1.42.2.2 retrieving revision 1.45.2.1 diff -u -p -r1.42.2.2 -r1.45.2.1 --- a/src/ngircd/defines.h 26 Dec 2003 16:16:48 -0000 1.42.2.2 +++ b/src/ngircd/defines.h 7 May 2004 11:24:18 -0000 1.45.2.1 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: defines.h,v 1.42.2.2 2003/12/26 16:16:48 alex Exp $ + * $Id: defines.h,v 1.45.2.1 2004/05/07 11:24:18 alex Exp $ * * Global defines of ngIRCd. */ @@ -67,7 +67,7 @@ #define PROTOIRCPLUS "-IRC+" /* Protokoll-Suffix fŸr IRC+-Protokoll */ #ifdef IRCPLUS -# define IRCPLUSFLAGS "C" /* IRC+-Flags, die immer zutreffen */ +# define IRCPLUSFLAGS "CL" /* IRC+-Flags, die immer zutreffen */ #endif #define STARTUP_DELAY 1 /* Erst n Sek. nach Start zu anderen Servern verbinden */ @@ -83,6 +83,8 @@ #define CONFIG_FILE "/ngircd.conf" #define MOTD_FILE "/ngircd.motd" +#define MOTD_PHRASE "" +#define CHROOT_DIR "" #define ERROR_DIR "/tmp" Index: src/ngircd/irc-channel.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-channel.c,v retrieving revision 1.25 retrieving revision 1.27 diff -u -p -r1.25 -r1.27 --- a/src/ngircd/irc-channel.c 8 Jan 2003 22:04:05 -0000 1.25 +++ b/src/ngircd/irc-channel.c 9 Apr 2004 20:46:48 -0000 1.27 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-channel.c,v 1.25 2003/01/08 22:04:05 alex Exp $"; +static char UNUSED id[] = "$Id: irc-channel.c,v 1.27 2004/04/09 20:46:48 alex Exp $"; #include "imp.h" #include @@ -68,7 +68,7 @@ IRC_JOIN( CLIENT *Client, REQUEST *Req ) channame = strtok( Req->argv[0], "," ); while( channame ) { - chan = flags = NULL; + chan = NULL; flags = NULL; /* wird der Channel neu angelegt? */ if( Channel_Search( channame )) is_new_chan = FALSE; @@ -86,7 +86,7 @@ IRC_JOIN( CLIENT *Client, REQUEST *Req ) } } - /* Lokaler Client? */ + /* Local client? */ if( Client_Type( Client ) == CLIENT_USER ) { /* Test if the user has reached his maximum channel count */ @@ -159,6 +159,16 @@ IRC_JOIN( CLIENT *Client, REQUEST *Req ) } } } + else + { + /* Remote server: we don't need to know whether the + * client is invited or not, but we have to make sure + * that the "one shot" entries (generated by INVITE + * commands) in this list become deleted when a user + * joins a channel this way. */ + chan = Channel_Search( channame ); + if( chan != NULL ) (VOID)Lists_CheckInvited( target, chan ); + } /* Channel joinen (und ggf. anlegen) */ if( ! Channel_Join( target, channame )) Index: src/ngircd/irc-info.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-info.c,v retrieving revision 1.16.2.4 retrieving revision 1.21.2.1 diff -u -p -r1.16.2.4 -r1.21.2.1 --- a/src/ngircd/irc-info.c 26 Dec 2003 16:16:48 -0000 1.16.2.4 +++ b/src/ngircd/irc-info.c 7 May 2004 11:24:18 -0000 1.21.2.1 @@ -14,13 +14,14 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-info.c,v 1.16.2.4 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: irc-info.c,v 1.21.2.1 2004/05/07 11:24:18 alex Exp $"; #include "imp.h" #include #include #include #include +#include #include "ngircd.h" #include "cvs-version.h" @@ -772,6 +773,13 @@ IRC_Show_MOTD( CLIENT *Client ) assert( Client != NULL ); + if( Conf_MotdPhrase[0] ) + { + if( ! IRC_WriteStrClient( Client, RPL_MOTDSTART_MSG, Client_ID( Client ), Client_ID( Client_ThisServer( )))) return DISCONNECTED; + if( ! IRC_WriteStrClient( Client, RPL_MOTD_MSG, Client_ID( Client ), Conf_MotdPhrase )) return DISCONNECTED; + return IRC_WriteStrClient( Client, RPL_ENDOFMOTD_MSG, Client_ID( Client )); + } + fd = fopen( Conf_MotdFile, "r" ); if( ! fd ) { @@ -779,7 +787,7 @@ IRC_Show_MOTD( CLIENT *Client ) return IRC_WriteStrClient( Client, ERR_NOMOTD_MSG, Client_ID( Client ) ); } - IRC_WriteStrClient( Client, RPL_MOTDSTART_MSG, Client_ID( Client ), Client_ID( Client_ThisServer( ))); + if( ! IRC_WriteStrClient( Client, RPL_MOTDSTART_MSG, Client_ID( Client ), Client_ID( Client_ThisServer( )))) return DISCONNECTED; while( TRUE ) { if( ! fgets( line, 126, fd )) break; Index: src/ngircd/irc-login.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-login.c,v retrieving revision 1.34.2.3 retrieving revision 1.40 diff -u -p -r1.34.2.3 -r1.40 --- a/src/ngircd/irc-login.c 4 Feb 2004 20:04:54 -0000 1.34.2.3 +++ b/src/ngircd/irc-login.c 11 Mar 2004 22:16:31 -0000 1.40 @@ -14,13 +14,14 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-login.c,v 1.34.2.3 2004/02/04 20:04:54 alex Exp $"; +static char UNUSED id[] = "$Id: irc-login.c,v 1.40 2004/03/11 22:16:31 alex Exp $"; #include "imp.h" #include #include #include #include +#include #include "ngircd.h" #include "resolve.h" @@ -285,6 +286,10 @@ IRC_NICK( CLIENT *Client, REQUEST *Req ) GLOBAL BOOLEAN IRC_USER( CLIENT *Client, REQUEST *Req ) { +#ifdef IDENTAUTH + CHAR *ptr; +#endif + assert( Client != NULL ); assert( Req != NULL ); @@ -298,11 +303,15 @@ IRC_USER( CLIENT *Client, REQUEST *Req ) if( Req->argc != 4 ) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command ); /* User name */ +#ifdef IDENTAUTH + ptr = Client_User( Client ); + if( ! ptr || ! *ptr || *ptr == '~' ) Client_SetUser( Client, Req->argv[0], FALSE ); +#else Client_SetUser( Client, Req->argv[0], FALSE ); +#endif - /* "Real name" or user info text: Don't set it to the empty - * string, the original ircd can't deal with such "real names" - * (e. g. "USER user * * :") ... */ + /* "Real name" or user info text: Don't set it to the empty string, the original ircd + * can't deal with such "real names" (e. g. "USER user * * :") ... */ if( *Req->argv[3] ) Client_SetInfo( Client, Req->argv[3] ); else Client_SetInfo( Client, "-" ); @@ -500,7 +509,7 @@ Kill_Nick( CHAR *Nick, CHAR *Reason ) assert( Nick != NULL ); assert( Reason != NULL ); - r.prefix = Client_ThisServer( ); + r.prefix = (CHAR *)Client_ThisServer( ); r.argv[0] = Nick; r.argv[1] = Reason; r.argc = 2; Index: src/ngircd/irc-mode.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-mode.c,v retrieving revision 1.31.2.1 retrieving revision 1.35 diff -u -p -r1.31.2.1 -r1.35 --- a/src/ngircd/irc-mode.c 7 Nov 2003 20:51:11 -0000 1.31.2.1 +++ b/src/ngircd/irc-mode.c 25 Apr 2004 15:42:05 -0000 1.35 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-mode.c,v 1.31.2.1 2003/11/07 20:51:11 alex Exp $"; +static char UNUSED id[] = "$Id: irc-mode.c,v 1.35 2004/04/25 15:42:05 alex Exp $"; #include "imp.h" #include @@ -225,7 +225,7 @@ client_exit: else { /* Send reply to client and inform other servers */ - ok = IRC_WriteStrClientPrefix( Client, Origin, "MODE %s %s", Client_ID( Target ), the_modes ); + ok = IRC_WriteStrClientPrefix( Client, Origin, "MODE %s :%s", Client_ID( Target ), the_modes ); IRC_WriteStrServersPrefix( Client, Origin, "MODE %s :%s", Client_ID( Target ), the_modes ); } Log( LOG_DEBUG, "User \"%s\": Mode change, now \"%s\".", Client_Mask( Target ), Client_Modes( Target )); @@ -635,6 +635,7 @@ LOCAL BOOLEAN Add_Invite( CLIENT *Prefix, CLIENT *Client, CHANNEL *Channel, CHAR *Pattern ) { CHAR *mask; + BOOLEAN already; assert( Client != NULL ); assert( Channel != NULL ); @@ -642,7 +643,12 @@ Add_Invite( CLIENT *Prefix, CLIENT *Clie mask = Lists_MakeMask( Pattern ); - if( ! Lists_AddInvited( Prefix, mask, Channel, FALSE )) return CONNECTED; + already = Lists_IsInviteEntry( mask, Channel ); + + if( ! Lists_AddInvited( mask, Channel, FALSE )) return CONNECTED; + + if(( Client_Type( Prefix ) == CLIENT_SERVER ) && ( already == TRUE )) return CONNECTED; + return Send_ListChange( "+I", Prefix, Client, Channel, mask ); } /* Add_Invite */ @@ -651,6 +657,7 @@ LOCAL BOOLEAN Add_Ban( CLIENT *Prefix, CLIENT *Client, CHANNEL *Channel, CHAR *Pattern ) { CHAR *mask; + BOOLEAN already; assert( Client != NULL ); assert( Channel != NULL ); @@ -658,7 +665,12 @@ Add_Ban( CLIENT *Prefix, CLIENT *Client, mask = Lists_MakeMask( Pattern ); - if( ! Lists_AddBanned( Prefix, mask, Channel )) return CONNECTED; + already = Lists_IsBanEntry( mask, Channel ); + + if( ! Lists_AddBanned( mask, Channel )) return CONNECTED; + + if(( Client_Type( Prefix ) == CLIENT_SERVER ) && ( already == TRUE )) return CONNECTED; + return Send_ListChange( "+b", Prefix, Client, Channel, mask ); } /* Add_Ban */ Index: src/ngircd/irc-op.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-op.c,v retrieving revision 1.11.4.1 retrieving revision 1.13 diff -u -p -r1.11.4.1 -r1.13 --- a/src/ngircd/irc-op.c 5 Dec 2003 13:33:12 -0000 1.11.4.1 +++ b/src/ngircd/irc-op.c 9 Apr 2004 21:41:52 -0000 1.13 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-op.c,v 1.11.4.1 2003/12/05 13:33:12 alex Exp $"; +static char UNUSED id[] = "$Id: irc-op.c,v 1.13 2004/04/09 21:41:52 alex Exp $"; #include "imp.h" #include @@ -104,7 +104,7 @@ IRC_INVITE( CLIENT *Client, REQUEST *Req if( remember ) { /* We must memember this invite */ - if( ! Lists_AddInvited( from, Client_Mask( target ), chan, TRUE )) return CONNECTED; + if( ! Lists_AddInvited( Client_Mask( target ), chan, TRUE )) return CONNECTED; } } Index: src/ngircd/irc-server.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-server.c,v retrieving revision 1.32.2.2 retrieving revision 1.36 diff -u -p -r1.32.2.2 -r1.36 --- a/src/ngircd/irc-server.c 26 Dec 2003 16:16:48 -0000 1.32.2.2 +++ b/src/ngircd/irc-server.c 25 Apr 2004 15:43:18 -0000 1.36 @@ -14,13 +14,14 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-server.c,v 1.32.2.2 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: irc-server.c,v 1.36 2004/04/25 15:43:18 alex Exp $"; #include "imp.h" #include #include #include #include +#include #include "resolve.h" #include "conn.h" @@ -29,6 +30,7 @@ static char UNUSED id[] = "$Id: irc-serv #include "client.h" #include "channel.h" #include "irc-write.h" +#include "lists.h" #include "log.h" #include "messages.h" #include "parse.h" @@ -182,6 +184,9 @@ IRC_SERVER( CLIENT *Client, REQUEST *Req /* Send CHANINFO if the peer supports it */ if( strchr( Client_Flags( Client ), 'C' )) { +#ifdef DEBUG + Log( LOG_DEBUG, "Sending CHANINFO commands ..." ); +#endif modes = Channel_Modes( chan ); topic = Channel_Topic( chan ); @@ -238,6 +243,18 @@ IRC_SERVER( CLIENT *Client, REQUEST *Req if( ! IRC_WriteStrClient( Client, "%s", str )) return DISCONNECTED; } +#ifdef IRCPLUS + if( strchr( Client_Flags( Client ), 'L' )) + { +#ifdef DEBUG + Log( LOG_DEBUG, "Synchronizing INVITE- and BAN-lists ..." ); +#endif + /* Synchronize INVITE- and BAN-lists */ + if( ! Lists_SendInvites( Client )) return DISCONNECTED; + if( ! Lists_SendBans( Client )) return DISCONNECTED; + } +#endif + /* naechsten Channel suchen */ chan = Channel_Next( chan ); } Index: src/ngircd/irc-write.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-write.c,v retrieving revision 1.14.2.1 retrieving revision 1.15 diff -u -p -r1.14.2.1 -r1.15 --- a/src/ngircd/irc-write.c 7 Nov 2003 20:51:11 -0000 1.14.2.1 +++ b/src/ngircd/irc-write.c 5 Nov 2003 23:24:48 -0000 1.15 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc-write.c,v 1.14.2.1 2003/11/07 20:51:11 alex Exp $"; +static char UNUSED id[] = "$Id: irc-write.c,v 1.15 2003/11/05 23:24:48 alex Exp $"; #include "imp.h" #include Index: src/ngircd/irc-write.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc-write.h,v retrieving revision 1.5.4.1 retrieving revision 1.6 diff -u -p -r1.5.4.1 -r1.6 --- a/src/ngircd/irc-write.h 7 Nov 2003 20:51:11 -0000 1.5.4.1 +++ b/src/ngircd/irc-write.h 5 Nov 2003 23:24:48 -0000 1.6 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: irc-write.h,v 1.5.4.1 2003/11/07 20:51:11 alex Exp $ + * $Id: irc-write.h,v 1.6 2003/11/05 23:24:48 alex Exp $ * * Sending IRC commands over the network (header) */ Index: src/ngircd/irc.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/irc.c,v retrieving revision 1.120.2.3 retrieving revision 1.124 diff -u -p -r1.120.2.3 -r1.124 --- a/src/ngircd/irc.c 26 Dec 2003 16:16:48 -0000 1.120.2.3 +++ b/src/ngircd/irc.c 28 Feb 2004 02:18:16 -0000 1.124 @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) + * Copyright (c)2001-2004 Alexander Barton * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: irc.c,v 1.120.2.3 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: irc.c,v 1.124 2004/02/28 02:18:16 alex Exp $"; #include "imp.h" #include @@ -210,6 +210,7 @@ IRC_TRACE( CLIENT *Client, REQUEST *Req { CLIENT *from, *target, *c; CONN_ID idx, idx2; + CHAR user[CLIENT_USER_LEN]; assert( Client != NULL ); assert( Req != NULL ); @@ -251,7 +252,9 @@ IRC_TRACE( CLIENT *Client, REQUEST *Req if( Client_Type( c ) == CLIENT_SERVER ) { /* Server link */ - if( ! IRC_WriteStrClient( from, RPL_TRACESERVER_MSG, Client_ID( from ), Client_ID( c ), Client_Mask( c ), Option_String( Client_Conn( c )))) return DISCONNECTED; + strlcpy( user, Client_User( c ), sizeof( user )); + if( user[0] == '~' ) strlcpy( user, "unknown", sizeof( user )); + if( ! IRC_WriteStrClient( from, RPL_TRACESERVER_MSG, Client_ID( from ), Client_ID( c ), user, Client_Hostname( c ), Client_Mask( Client_ThisServer( )), Option_String( Client_Conn( c )))) return DISCONNECTED; } if(( Client_Type( c ) == CLIENT_USER ) && ( strchr( Client_Modes( c ), 'o' ))) { @@ -262,9 +265,6 @@ IRC_TRACE( CLIENT *Client, REQUEST *Req c = Client_Next( c ); } - /* Some information about us */ - if( ! IRC_WriteStrClient( from, RPL_TRACESERVER_MSG, Client_ID( from ), Conf_ServerName, Client_Mask( Client_ThisServer( )), Option_String( Client_Conn( Client )))) return DISCONNECTED; - IRC_SetPenalty( Client, 3 ); return IRC_WriteStrClient( from, RPL_TRACEEND_MSG, Client_ID( from ), Conf_ServerName, PACKAGE_NAME, PACKAGE_VERSION, NGIRCd_DebugLevel ); } /* IRC_TRACE */ Index: src/ngircd/lists.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/lists.c,v retrieving revision 1.11 retrieving revision 1.15 diff -u -p -r1.11 -r1.15 --- a/src/ngircd/lists.c 26 Dec 2002 16:25:43 -0000 1.11 +++ b/src/ngircd/lists.c 25 Apr 2004 15:40:19 -0000 1.15 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: lists.c,v 1.11 2002/12/26 16:25:43 alex Exp $"; +static char UNUSED id[] = "$Id: lists.c,v 1.15 2004/04/25 15:40:19 alex Exp $"; #include "imp.h" #include @@ -30,6 +30,7 @@ static char UNUSED id[] = "$Id: lists.c, #include #include +#include #include "exp.h" #include "lists.h" @@ -101,19 +102,24 @@ Lists_CheckInvited( CLIENT *Client, CHAN GLOBAL BOOLEAN -Lists_AddInvited( CLIENT *From, CHAR *Mask, CHANNEL *Chan, BOOLEAN OnlyOnce ) +Lists_IsInviteEntry( CHAR *Mask, CHANNEL *Chan ) +{ + assert( Mask != NULL ); + assert( Chan != NULL ); + + return Already_Registered( My_Invites, Mask, Chan ); +} /* Lists_IsInviteEntry */ + + +GLOBAL BOOLEAN +Lists_AddInvited( CHAR *Mask, CHANNEL *Chan, BOOLEAN OnlyOnce ) { C2C *c2c; assert( Mask != NULL ); assert( Chan != NULL ); - if( Already_Registered( My_Invites, Mask, Chan )) - { - /* Eintrag ist bereits vorhanden */ - IRC_WriteStrClient( From, RPL_INVITELIST_MSG, Client_ID( From ), Channel_Name( Chan ), Mask ); - return FALSE; - } + if( Already_Registered( My_Invites, Mask, Chan )) return TRUE; c2c = New_C2C( Mask, Chan, OnlyOnce ); if( ! c2c ) @@ -181,6 +187,40 @@ Lists_ShowInvites( CLIENT *Client, CHANN GLOBAL BOOLEAN +Lists_SendInvites( CLIENT *Client ) +{ + C2C *c2c; + + assert( Client != NULL ); + + c2c = My_Invites; + while( c2c ) + { + if( ! IRC_WriteStrClient( Client, "MODE %s +I %s", Channel_Name( c2c->channel ), c2c->mask )) return DISCONNECTED; + c2c = c2c->next; + } + return CONNECTED; +} /* Lists_SendInvites */ + + +GLOBAL BOOLEAN +Lists_SendBans( CLIENT *Client ) +{ + C2C *c2c; + + assert( Client != NULL ); + + c2c = My_Bans; + while( c2c ) + { + if( ! IRC_WriteStrClient( Client, "MODE %s +b %s", Channel_Name( c2c->channel ), c2c->mask )) return DISCONNECTED; + c2c = c2c->next; + } + return CONNECTED; +} /* Lists_SendBans */ + + +GLOBAL BOOLEAN Lists_CheckBanned( CLIENT *Client, CHANNEL *Chan ) { return Check_List( &My_Bans, Client, Chan ); @@ -188,19 +228,24 @@ Lists_CheckBanned( CLIENT *Client, CHANN GLOBAL BOOLEAN -Lists_AddBanned( CLIENT *From, CHAR *Mask, CHANNEL *Chan ) +Lists_IsBanEntry( CHAR *Mask, CHANNEL *Chan ) +{ + assert( Mask != NULL ); + assert( Chan != NULL ); + + return Already_Registered( My_Bans, Mask, Chan ); +} /* Lists_IsBanEntry */ + + +GLOBAL BOOLEAN +Lists_AddBanned( CHAR *Mask, CHANNEL *Chan ) { C2C *c2c; assert( Mask != NULL ); assert( Chan != NULL ); - if( Already_Registered( My_Bans, Mask, Chan )) - { - /* Eintrag ist bereits vorhanden */ - IRC_WriteStrClient( From, RPL_BANLIST_MSG, Client_ID( From ), Channel_Name( Chan ), Mask ); - return FALSE; - } + if( Already_Registered( My_Bans, Mask, Chan )) return TRUE; c2c = New_C2C( Mask, Chan, FALSE ); if( ! c2c ) @@ -370,7 +415,7 @@ New_C2C( CHAR *Mask, CHANNEL *Chan, BOOL assert( Chan != NULL ); /* Speicher fuer Eintrag anfordern */ - c2c = malloc( sizeof( C2C )); + c2c = (C2C *)malloc( sizeof( C2C )); if( ! c2c ) { Log( LOG_EMERG, "Can't allocate memory! [New_C2C]" ); Index: src/ngircd/lists.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/lists.h,v retrieving revision 1.9 retrieving revision 1.11 diff -u -p -r1.9 -r1.11 --- a/src/ngircd/lists.h 12 Dec 2002 12:23:43 -0000 1.9 +++ b/src/ngircd/lists.h 25 Apr 2004 15:40:19 -0000 1.11 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: lists.h,v 1.9 2002/12/12 12:23:43 alex Exp $ + * $Id: lists.h,v 1.11 2004/04/25 15:40:19 alex Exp $ * * Management of IRC lists: ban, invite, ... (header) */ @@ -22,14 +22,18 @@ GLOBAL VOID Lists_Init PARAMS(( VOID )); GLOBAL VOID Lists_Exit PARAMS(( VOID )); GLOBAL BOOLEAN Lists_CheckInvited PARAMS(( CLIENT *Client, CHANNEL *Chan )); -GLOBAL BOOLEAN Lists_AddInvited PARAMS(( CLIENT *From, CHAR *Mask, CHANNEL *Chan, BOOLEAN OnlyOnce )); +GLOBAL BOOLEAN Lists_AddInvited PARAMS(( CHAR *Mask, CHANNEL *Chan, BOOLEAN OnlyOnce )); GLOBAL VOID Lists_DelInvited PARAMS(( CHAR *Mask, CHANNEL *Chan )); GLOBAL BOOLEAN Lists_ShowInvites PARAMS(( CLIENT *Client, CHANNEL *Channel )); +GLOBAL BOOLEAN Lists_SendInvites PARAMS(( CLIENT *Client )); +GLOBAL BOOLEAN Lists_IsInviteEntry PARAMS(( CHAR *Mask, CHANNEL *Chan )); GLOBAL BOOLEAN Lists_CheckBanned PARAMS(( CLIENT *Client, CHANNEL *Chan )); -GLOBAL BOOLEAN Lists_AddBanned PARAMS(( CLIENT *From, CHAR *Mask, CHANNEL *Chan )); +GLOBAL BOOLEAN Lists_AddBanned PARAMS(( CHAR *Mask, CHANNEL *Chan )); GLOBAL VOID Lists_DelBanned PARAMS(( CHAR *Mask, CHANNEL *Chan )); GLOBAL BOOLEAN Lists_ShowBans PARAMS(( CLIENT *Client, CHANNEL *Channel )); +GLOBAL BOOLEAN Lists_SendBans PARAMS(( CLIENT *Client )); +GLOBAL BOOLEAN Lists_IsBanEntry PARAMS(( CHAR *Mask, CHANNEL *Chan )); GLOBAL VOID Lists_DeleteChannel PARAMS(( CHANNEL *Chan )); Index: src/ngircd/log.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/log.c,v retrieving revision 1.43.2.1 retrieving revision 1.44.2.1 diff -u -p -r1.43.2.1 -r1.44.2.1 --- a/src/ngircd/log.c 26 Dec 2003 16:16:48 -0000 1.43.2.1 +++ b/src/ngircd/log.c 7 May 2004 11:24:18 -0000 1.44.2.1 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: log.c,v 1.43.2.1 2003/12/26 16:16:48 alex Exp $"; +static char UNUSED id[] = "$Id: log.c,v 1.44.2.1 2004/05/07 11:24:18 alex Exp $"; #include "imp.h" #include @@ -85,6 +85,8 @@ Log_Init( VOID ) } #endif if( Init_Txt[0] ) Log( LOG_INFO, "Activating: %s.", Init_Txt ); + + Error_File[0] = '\0'; } /* Log_Init */ @@ -122,8 +124,11 @@ Log_Exit( VOID ) if( NGIRCd_SignalRestart ) Log( LOG_NOTICE, "%s done (restarting).", PACKAGE_NAME ); else Log( LOG_NOTICE, "%s done.", PACKAGE_NAME ); - /* Error-File (stderr) loeschen */ - if( unlink( Error_File ) != 0 ) Log( LOG_ERR, "Can't delete \"%s\": %s", Error_File, strerror( errno )); + if( Error_File[0] ) + { + /* Error-File (stderr) loeschen */ + if( unlink( Error_File ) != 0 ) Log( LOG_ERR, "Can't delete \"%s\": %s", Error_File, strerror( errno )); + } #ifdef SYSLOG /* syslog abmelden */ Index: src/ngircd/log.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/log.h,v retrieving revision 1.13.4.1 retrieving revision 1.14 diff -u -p -r1.13.4.1 -r1.14 --- a/src/ngircd/log.h 26 Dec 2003 16:16:48 -0000 1.13.4.1 +++ b/src/ngircd/log.h 26 Dec 2003 15:55:07 -0000 1.14 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: log.h,v 1.13.4.1 2003/12/26 16:16:48 alex Exp $ + * $Id: log.h,v 1.14 2003/12/26 15:55:07 alex Exp $ * * Logging functions (header) */ Index: src/ngircd/messages.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/messages.h,v retrieving revision 1.64.2.1 retrieving revision 1.66 diff -u -p -r1.64.2.1 -r1.66 --- a/src/ngircd/messages.h 26 Dec 2003 16:16:48 -0000 1.64.2.1 +++ b/src/ngircd/messages.h 28 Feb 2004 02:18:16 -0000 1.66 @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) + * Copyright (c)2001-2004 Alexander Barton * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: messages.h,v 1.64.2.1 2003/12/26 16:16:48 alex Exp $ + * $Id: messages.h,v 1.66 2004/02/28 02:18:16 alex Exp $ * * IRC numerics (Header) */ @@ -26,7 +26,7 @@ #define RPL_TRACELINK_MSG "200 %s Link %s-%s %s %s V%s %ld %d %d" #define RPL_TRACEOPERATOR_MSG "204 %s Oper 2 :%s" -#define RPL_TRACESERVER_MSG "206 %s Serv 1 0S 0C %s *!*@%s :V%s" +#define RPL_TRACESERVER_MSG "206 %s Serv 1 0S 0C %s[%s@%s] *!*@%s :V%s" #define RPL_STATSLINKINFO_MSG "211 %s %s %d %ld %ld %ld %ld :%ld" #define RPL_STATSCOMMANDS_MSG "212 %s %s %ld %ld %ld" #define RPL_ENDOFSTATS_MSG "219 %s %c :End of STATS report" Index: src/ngircd/ngircd.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/ngircd.c,v retrieving revision 1.76.2.3 retrieving revision 1.83.2.1 diff -u -p -r1.76.2.3 -r1.83.2.1 --- a/src/ngircd/ngircd.c 2 Jan 2004 19:24:46 -0000 1.76.2.3 +++ b/src/ngircd/ngircd.c 7 May 2004 11:24:18 -0000 1.83.2.1 @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: ngircd.c,v 1.76.2.3 2004/01/02 19:24:46 alex Exp $"; +static char UNUSED id[] = "$Id: ngircd.c,v 1.83.2.1 2004/05/07 11:24:18 alex Exp $"; #include "imp.h" #include @@ -24,10 +24,10 @@ static char UNUSED id[] = "$Id: ngircd.c #include #include #include +#include #include #include #include -#include #include #include @@ -183,6 +183,11 @@ main( int argc, const char *argv[] ) ok = TRUE; } #endif + if( argv[i][n] == 't' ) + { + configtest = TRUE; + ok = TRUE; + } if( ! ok ) { @@ -223,6 +228,38 @@ main( int argc, const char *argv[] ) while( ! NGIRCd_SignalQuit ) { + /* Initialize global variables */ + NGIRCd_Start = time( NULL ); + (VOID)strftime( NGIRCd_StartStr, 64, "%a %b %d %Y at %H:%M:%S (%Z)", localtime( &NGIRCd_Start )); + + NGIRCd_SignalRehash = FALSE; + NGIRCd_SignalRestart = FALSE; + NGIRCd_SignalQuit = FALSE; + + /* Initialize modules, part I */ + Log_Init( ); + Conf_Init( ); + + if( Conf_Chroot[0] ) + { + /* Chroot */ + if( chdir( Conf_Chroot ) != 0 ) Log( LOG_ERR, "Can't chdir() in ChrootDir (%s): %s", Conf_Chroot, strerror( errno )); + + if( chroot( Conf_Chroot ) != 0 ) Log( LOG_ERR, "Can't change root directory to \"%s\": %s", Conf_Chroot, strerror( errno )); + else Log( LOG_INFO, "Changed root and working directory to \"%s\".", Conf_Chroot ); + } + + if( Conf_GID != 0 ) + { + /* Set new group ID */ + if( setgid( Conf_GID ) != 0 ) Log( LOG_ERR, "Can't change group ID to %u: %s", Conf_GID, strerror( errno )); + } + if( Conf_UID != 0 ) + { + /* Set new user ID */ + if( setuid( Conf_UID ) != 0 ) Log( LOG_ERR, "Can't change user ID to %u: %s", Conf_UID, strerror( errno )); + } + /* In der Regel wird ein Sub-Prozess ge-fork()'t, der * nicht mehr mit dem Terminal verbunden ist. Mit der * Option "--nodaemon" kann dies (z.B. zum Debuggen) @@ -247,18 +284,10 @@ main( int argc, const char *argv[] ) (VOID)setsid( ); chdir( "/" ); } - - /* Globale Variablen initialisieren */ - NGIRCd_Start = time( NULL ); - (VOID)strftime( NGIRCd_StartStr, 64, "%a %b %d %Y at %H:%M:%S (%Z)", localtime( &NGIRCd_Start )); - NGIRCd_SignalRehash = FALSE; - NGIRCd_SignalRestart = FALSE; - NGIRCd_SignalQuit = FALSE; - /* Module initialisieren */ - Log_Init( ); + /* Initialize modules, part II: these functions are eventually + * called with already dropped privileges ... */ Resolve_Init( ); - Conf_Init( ); Lists_Init( ); Channel_Init( ); Client_Init( ); @@ -267,28 +296,15 @@ main( int argc, const char *argv[] ) #endif Conn_Init( ); - /* Wenn als root ausgefuehrt und eine andere UID - * konfiguriert ist, jetzt zu dieser wechseln */ - if( getuid( ) == 0 ) - { - if( Conf_GID != 0 ) - { - /* Neue Group-ID setzen */ - if( setgid( Conf_GID ) != 0 ) Log( LOG_ERR, "Can't change Group-ID to %u: %s", Conf_GID, strerror( errno )); - } - if( Conf_UID != 0 ) - { - /* Neue User-ID setzen */ - if( setuid( Conf_UID ) != 0 ) Log( LOG_ERR, "Can't change User-ID to %u: %s", Conf_UID, strerror( errno )); - } - } - - /* User, Gruppe und Prozess-ID des Daemon ausgeben */ + /* Show user, group, and PID of the running daemon */ pwd = getpwuid( getuid( )); grp = getgrgid( getgid( )); Log( LOG_INFO, "Running as user %s(%ld), group %s(%ld), with PID %ld.", pwd ? pwd->pw_name : "unknown", (LONG)getuid( ), grp ? grp->gr_name : "unknown", (LONG)getgid( ), (LONG)getpid( )); - /* stderr in "Error-File" umlenken */ - Log_InitErrorfile( ); + /* Redirect stderr handle to "error file" for debugging. + * But don't try to write in the chroot jail, since it's more + * secure to have a chroot dir not writable by the daemon. + */ + if( ! Conf_Chroot[0] ) Log_InitErrorfile( ); /* Signal-Handler initialisieren */ Initialize_Signal_Handler( ); @@ -377,6 +393,10 @@ NGIRCd_VersionAddition( VOID ) if( txt[0] ) strcat( txt, "+" ); strcat( txt, "RENDEZVOUS" ); #endif +#ifdef IDENTAUTH + if( txt[0] ) strcat( txt, "+" ); + strcat( txt, "IDENT" ); +#endif #ifdef DEBUG if( txt[0] ) strcat( txt, "+" ); strcat( txt, "DEBUG" ); @@ -413,30 +433,26 @@ NGIRCd_Rehash( VOID ) Log( LOG_NOTICE|LOG_snotice, "Re-reading configuration NOW!" ); NGIRCd_SignalRehash = FALSE; - /* Alle Listen-Sockets schliessen */ + /* Close down all listening sockets */ Conn_ExitListeners( ); - /* Alten Server-Namen merken */ -#ifdef DEBUG - assert( sizeof( old_name ) == sizeof( Conf_ServerName )); -#endif + /* Remember old server name */ strcpy( old_name, Conf_ServerName ); - /* Konfiguration neu lesen ... */ + /* Re-read configuration ... */ Conf_Rehash( ); - /* Alten Server-Namen wiederherstellen: dieser - * kann nicht zur Laufzeit geaendert werden ... */ + /* Recover old server name: it can't be changed during run-time */ if( strcmp( old_name, Conf_ServerName ) != 0 ) { strcpy( Conf_ServerName, old_name ); Log( LOG_ERR, "Can't change \"ServerName\" on runtime! Ignored new name." ); } - /* neue pre-defined Channel anlegen: */ + /* Create new pre-defined channels */ Channel_InitPredefined( ); - /* Listen-Sockets neu anlegen: */ + /* Start listening on sockets */ Conn_InitListeners( ); /* Sync configuration with established connections */ @@ -548,7 +564,7 @@ Show_Help( VOID ) #ifdef SNIFFER puts( " -s, --sniffer enable network sniffer and display all IRC traffic" ); #endif - puts( " --configtest read, validate and display configuration; then exit" ); + puts( " -t, --configtest read, validate and display configuration; then exit" ); puts( " --version output version information and exit" ); puts( " --help display this help and exit" ); } /* Show_Help */ Index: src/ngircd/parse.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/parse.c,v retrieving revision 1.59 retrieving revision 1.60 diff -u -p -r1.59 -r1.60 --- a/src/ngircd/parse.c 15 Jan 2003 13:49:20 -0000 1.59 +++ b/src/ngircd/parse.c 17 Jan 2004 03:17:49 -0000 1.60 @@ -14,13 +14,14 @@ #include "portab.h" -static char UNUSED id[] = "$Id: parse.c,v 1.59 2003/01/15 13:49:20 alex Exp $"; +static char UNUSED id[] = "$Id: parse.c,v 1.60 2004/01/17 03:17:49 alex Exp $"; #include "imp.h" #include #include #include #include +#include #include "ngircd.h" #include "defines.h" Index: src/ngircd/resolve.c =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/resolve.c,v retrieving revision 1.6 retrieving revision 1.8 diff -u -p -r1.6 -r1.8 --- a/src/ngircd/resolve.c 21 Apr 2003 10:52:51 -0000 1.6 +++ b/src/ngircd/resolve.c 11 Mar 2004 22:16:31 -0000 1.8 @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001,2002 by Alexander Barton (alex@barton.de) + * Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -14,7 +14,7 @@ #include "portab.h" -static char UNUSED id[] = "$Id: resolve.c,v 1.6 2003/04/21 10:52:51 alex Exp $"; +static char UNUSED id[] = "$Id: resolve.c,v 1.8 2004/03/11 22:16:31 alex Exp $"; #include "imp.h" #include @@ -27,6 +27,12 @@ static char UNUSED id[] = "$Id: resolve. #include #include +#ifdef IDENTAUTH +#ifdef HAVE_IDENT_H +#include +#endif +#endif + #include "conn.h" #include "defines.h" #include "log.h" @@ -35,7 +41,12 @@ static char UNUSED id[] = "$Id: resolve. #include "resolve.h" +#ifdef IDENTAUTH +LOCAL VOID Do_ResolveAddr PARAMS(( struct sockaddr_in *Addr, INT Sock, INT w_fd )); +#else LOCAL VOID Do_ResolveAddr PARAMS(( struct sockaddr_in *Addr, INT w_fd )); +#endif + LOCAL VOID Do_ResolveName PARAMS(( CHAR *Host, INT w_fd )); #ifdef h_errno @@ -46,31 +57,35 @@ LOCAL CHAR *Get_Error PARAMS(( INT H_Err GLOBAL VOID Resolve_Init( VOID ) { - /* Modul initialisieren */ + /* Initialize module */ FD_ZERO( &Resolver_FDs ); } /* Resolve_Init */ +#ifdef IDENTAUTH +GLOBAL RES_STAT * +Resolve_Addr( struct sockaddr_in *Addr, int Sock ) +#else GLOBAL RES_STAT * Resolve_Addr( struct sockaddr_in *Addr ) +#endif { - /* IP (asyncron!) aufloesen. Bei Fehler, z.B. wenn der - * Child-Prozess nicht erzeugt werden kann, wird NULL geliefert. - * Der Host kann dann nicht aufgeloest werden. */ + /* Resolve IP (asynchronous!). On errors, e.g. if the child process + * can't be forked, this functions returns NULL. */ RES_STAT *s; INT pid; - /* Speicher anfordern */ - s = malloc( sizeof( RES_STAT )); + /* Allocate memory */ + s = (RES_STAT *)malloc( sizeof( RES_STAT )); if( ! s ) { Log( LOG_EMERG, "Resolver: Can't allocate memory! [Resolve_Addr]" ); return NULL; } - /* Pipe fuer Antwort initialisieren */ + /* Initialize pipe for result */ if( pipe( s->pipe ) != 0 ) { free( s ); @@ -78,11 +93,11 @@ Resolve_Addr( struct sockaddr_in *Addr ) return NULL; } - /* Sub-Prozess erzeugen */ + /* For sub-process */ pid = fork( ); if( pid > 0 ) { - /* Haupt-Prozess */ + /* Main process */ Log( LOG_DEBUG, "Resolver for %s created (PID %d).", inet_ntoa( Addr->sin_addr ), pid ); FD_SET( s->pipe[0], &Resolver_FDs ); if( s->pipe[0] > Conn_MaxFD ) Conn_MaxFD = s->pipe[0]; @@ -91,15 +106,19 @@ Resolve_Addr( struct sockaddr_in *Addr ) } else if( pid == 0 ) { - /* Sub-Prozess */ + /* Sub process */ Log_Init_Resolver( ); +#ifdef IDENTAUTH + Do_ResolveAddr( Addr, Sock, s->pipe[1] ); +#else Do_ResolveAddr( Addr, s->pipe[1] ); +#endif Log_Exit_Resolver( ); exit( 0 ); } else { - /* Fehler */ + /* Error! */ free( s ); Log( LOG_CRIT, "Resolver: Can't fork: %s!", strerror( errno )); return NULL; @@ -110,22 +129,21 @@ Resolve_Addr( struct sockaddr_in *Addr ) GLOBAL RES_STAT * Resolve_Name( CHAR *Host ) { - /* Hostnamen (asyncron!) aufloesen. Bei Fehler, z.B. wenn der - * Child-Prozess nicht erzeugt werden kann, wird NULL geliefert. - * Der Host kann dann nicht aufgeloest werden. */ + /* Resolve hostname (asynchronous!). On errors, e.g. if the child + * process can't be forked, this functions returns NULL. */ RES_STAT *s; INT pid; - /* Speicher anfordern */ - s = malloc( sizeof( RES_STAT )); + /* Allocate memory */ + s = (RES_STAT *)malloc( sizeof( RES_STAT )); if( ! s ) { Log( LOG_EMERG, "Resolver: Can't allocate memory! [Resolve_Name]" ); return NULL; } - /* Pipe fuer Antwort initialisieren */ + /* Initialize the pipe for the result */ if( pipe( s->pipe ) != 0 ) { free( s ); @@ -133,11 +151,11 @@ Resolve_Name( CHAR *Host ) return NULL; } - /* Sub-Prozess erzeugen */ + /* Fork sub-process */ pid = fork( ); if( pid > 0 ) { - /* Haupt-Prozess */ + /* Main process */ Log( LOG_DEBUG, "Resolver for \"%s\" created (PID %d).", Host, pid ); FD_SET( s->pipe[0], &Resolver_FDs ); if( s->pipe[0] > Conn_MaxFD ) Conn_MaxFD = s->pipe[0]; @@ -146,7 +164,7 @@ Resolve_Name( CHAR *Host ) } else if( pid == 0 ) { - /* Sub-Prozess */ + /* Sub process */ Log_Init_Resolver( ); Do_ResolveName( Host, s->pipe[1] ); Log_Exit_Resolver( ); @@ -154,7 +172,7 @@ Resolve_Name( CHAR *Host ) } else { - /* Fehler */ + /* Error! */ free( s ); Log( LOG_CRIT, "Resolver: Can't fork: %s!", strerror( errno )); return NULL; @@ -162,17 +180,26 @@ Resolve_Name( CHAR *Host ) } /* Resolve_Name */ +#ifdef IDENTAUTH +LOCAL VOID +Do_ResolveAddr( struct sockaddr_in *Addr, int Sock, INT w_fd ) +#else LOCAL VOID Do_ResolveAddr( struct sockaddr_in *Addr, INT w_fd ) +#endif { - /* Resolver Sub-Prozess: IP aufloesen und Ergebnis in Pipe schreiben. */ + /* Resolver sub-process: resolve IP address and write result into + * pipe to parent. */ CHAR hostname[HOST_LEN]; struct hostent *h; +#ifdef IDENTAUTH + CHAR *res; +#endif Log_Resolver( LOG_DEBUG, "Now resolving %s ...", inet_ntoa( Addr->sin_addr )); - /* Namen aufloesen */ + /* Resolve IP address */ h = gethostbyaddr( (CHAR *)&Addr->sin_addr, sizeof( Addr->sin_addr ), AF_INET ); if( h ) strlcpy( hostname, h->h_name, sizeof( hostname )); else @@ -185,13 +212,30 @@ Do_ResolveAddr( struct sockaddr_in *Addr strlcpy( hostname, inet_ntoa( Addr->sin_addr ), sizeof( hostname )); } - /* Antwort an Parent schreiben */ +#ifdef IDENTAUTH + /* Do "IDENT" (aka "AUTH") lookup and write result to parent */ + Log_Resolver( LOG_DEBUG, "Doing IDENT lookup on socket %d ...", Sock ); + res = ident_id( Sock, 10 ); + Log_Resolver( LOG_DEBUG, "IDENT lookup on socket %d done.", Sock ); +#endif + + /* Write result into pipe to parent */ if( (size_t)write( w_fd, hostname, strlen( hostname ) + 1 ) != (size_t)( strlen( hostname ) + 1 )) { Log_Resolver( LOG_CRIT, "Resolver: Can't write to parent: %s!", strerror( errno )); close( w_fd ); return; } +#ifdef IDENTAUTH + if( (size_t)write( w_fd, res ? res : "", strlen( res ? res : "" ) + 1 ) != (size_t)( strlen( res ? res : "" ) + 1 )) + { + Log_Resolver( LOG_CRIT, "Resolver: Can't write to parent (IDENT): %s!", strerror( errno )); + close( w_fd ); + free( res ); + return; + } + free( res ); +#endif Log_Resolver( LOG_DEBUG, "Ok, translated %s to \"%s\".", inet_ntoa( Addr->sin_addr ), hostname ); } /* Do_ResolveAddr */ @@ -200,7 +244,8 @@ Do_ResolveAddr( struct sockaddr_in *Addr LOCAL VOID Do_ResolveName( CHAR *Host, INT w_fd ) { - /* Resolver Sub-Prozess: Name aufloesen und Ergebnis in Pipe schreiben. */ + /* Resolver sub-process: resolve name and write result into pipe + * to parent. */ CHAR ip[16]; struct hostent *h; @@ -208,7 +253,7 @@ Do_ResolveName( CHAR *Host, INT w_fd ) Log_Resolver( LOG_DEBUG, "Now resolving \"%s\" ...", Host ); - /* Namen aufloesen */ + /* Resolve hostname */ h = gethostbyname( Host ); if( h ) { @@ -225,7 +270,7 @@ Do_ResolveName( CHAR *Host, INT w_fd ) strcpy( ip, "" ); } - /* Antwort an Parent schreiben */ + /* Write result into pipe to parent */ if( (size_t)write( w_fd, ip, strlen( ip ) + 1 ) != (size_t)( strlen( ip ) + 1 )) { Log_Resolver( LOG_CRIT, "Resolver: Can't write to parent: %s!", strerror( errno )); @@ -242,7 +287,7 @@ Do_ResolveName( CHAR *Host, INT w_fd ) LOCAL CHAR * Get_Error( INT H_Error ) { - /* Fehlerbeschreibung fuer H_Error liefern */ + /* Get error message for H_Error */ switch( H_Error ) { Index: src/ngircd/resolve.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/ngircd/resolve.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -p -r1.5 -r1.6 --- a/src/ngircd/resolve.h 21 Apr 2003 10:53:10 -0000 1.5 +++ b/src/ngircd/resolve.h 27 Dec 2003 13:01:12 -0000 1.6 @@ -1,6 +1,6 @@ /* * ngIRCd -- The Next Generation IRC Daemon - * Copyright (c)2001,2002 by Alexander Barton (alex@barton.de) + * Copyright (c)2001-2003 by Alexander Barton (alex@barton.de) * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: resolve.h,v 1.5 2003/04/21 10:53:10 alex Exp $ + * $Id: resolve.h,v 1.6 2003/12/27 13:01:12 alex Exp $ * * Asynchronous resolver (header) */ @@ -37,7 +37,12 @@ GLOBAL fd_set Resolver_FDs; GLOBAL VOID Resolve_Init PARAMS(( VOID )); +#ifdef IDENTAUTH +GLOBAL RES_STAT *Resolve_Addr PARAMS(( struct sockaddr_in *Addr, int Sock )); +#else GLOBAL RES_STAT *Resolve_Addr PARAMS(( struct sockaddr_in *Addr )); +#endif + GLOBAL RES_STAT *Resolve_Name PARAMS(( CHAR *Host )); Index: src/portab/portab.h =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/portab/portab.h,v retrieving revision 1.15 retrieving revision 1.17 diff -u -p -r1.15 -r1.17 --- a/src/portab/portab.h 31 Mar 2003 19:01:02 -0000 1.15 +++ b/src/portab/portab.h 15 Mar 2004 19:26:39 -0000 1.17 @@ -8,7 +8,7 @@ * (at your option) any later version. * Please read the file COPYING, README and AUTHORS for more information. * - * $Id: portab.h,v 1.15 2003/03/31 19:01:02 alex Exp $ + * $Id: portab.h,v 1.17 2004/03/15 19:26:39 alex Exp $ * * Portability functions and declarations (header for libngbportab). */ @@ -21,13 +21,13 @@ #include "config.h" #ifdef HAVE_SYS_TYPES_H -#include +# include #endif /* compiler features */ -#ifdef __GNUC__ +#if (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 7)) # define PUNUSED(x) __attribute__ ((unused)) x # define UNUSED __attribute__ ((unused)) #else Index: src/testsuite/channel-test.e =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/channel-test.e,v retrieving revision 1.2 retrieving revision 1.3 diff -u -p -r1.2 -r1.3 --- a/src/testsuite/channel-test.e 9 Sep 2002 21:26:00 -0000 1.2 +++ b/src/testsuite/channel-test.e 27 Dec 2003 13:01:12 -0000 1.3 @@ -1,4 +1,4 @@ -# $Id: channel-test.e,v 1.2 2002/09/09 21:26:00 alex Exp $ +# $Id: channel-test.e,v 1.3 2003/12/27 13:01:12 alex Exp $ spawn telnet localhost 6789 expect { @@ -16,7 +16,7 @@ expect { send "join #channel\r" expect { timeout { exit 1 } - ":nick!~user@* JOIN :#channel" + "@* JOIN :#channel" } expect { timeout { exit 1 } @@ -26,13 +26,17 @@ expect { send "topic #channel :Test-Topic\r" expect { timeout { exit 1 } - ":nick!~user@* TOPIC #channel :Test-Topic" + "@* TOPIC #channel :Test-Topic" } send "who #channel\r" expect { timeout { exit 1 } - "352 nick #channel ~user * nick H@ :0 User" + "352 nick #channel" +} +expect { + timeout { exit 1 } + "* nick H@ :0 User" } expect { timeout { exit 1 } @@ -62,7 +66,7 @@ expect { send "part #channel\r" expect { timeout { exit 1 } - ":nick!~user@* PART #channel :nick" + "@* PART #channel :nick" } send "quit\r" Index: src/testsuite/getpid.sh =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/getpid.sh,v retrieving revision 1.2.4.2 retrieving revision 1.4 diff -u -p -r1.2.4.2 -r1.4 --- a/src/testsuite/getpid.sh 7 Nov 2003 20:51:11 -0000 1.2.4.2 +++ b/src/testsuite/getpid.sh 22 Aug 2003 11:31:18 -0000 1.4 @@ -1,6 +1,6 @@ #!/bin/sh # ngIRCd Test Suite -# $Id: getpid.sh,v 1.2.4.2 2003/11/07 20:51:11 alex Exp $ +# $Id: getpid.sh,v 1.4 2003/08/22 11:31:18 alex Exp $ # did we get a name? [ $# -ne 1 ] && exit 1 Index: src/testsuite/mode-test.e =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/mode-test.e,v retrieving revision 1.4 retrieving revision 1.6 diff -u -p -r1.4 -r1.6 --- a/src/testsuite/mode-test.e 15 Dec 2002 15:52:34 -0000 1.4 +++ b/src/testsuite/mode-test.e 10 Mar 2004 20:40:06 -0000 1.6 @@ -1,4 +1,4 @@ -# $Id: mode-test.e,v 1.4 2002/12/15 15:52:34 alex Exp $ +# $Id: mode-test.e,v 1.6 2004/03/10 20:40:06 alex Exp $ spawn telnet localhost 6789 expect { @@ -16,7 +16,7 @@ expect { send "mode nick +i\r" expect { timeout { exit 1 } - ":nick!~user@* MODE nick +i" + "@* MODE nick :+i" } send "mode nick\r" @@ -28,7 +28,7 @@ expect { send "mode nick -i\r" expect { timeout { exit 1 } - ":nick!~user@* MODE nick -i" + "@* MODE nick :-i" } send "oper TestOp 123\r" @@ -50,7 +50,7 @@ expect { send "join #channel\r" expect { timeout { exit 1 } - ":nick!~user@* JOIN :#channel" + "@* JOIN :#channel" } expect { timeout { exit 1 } @@ -60,7 +60,7 @@ expect { send "mode #channel +tn\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel +tn" + "@* MODE #channel +tn" } send "mode #channel\r" @@ -72,31 +72,31 @@ expect { send "mode #channel +v nick\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel +v nick" + "@* MODE #channel +v nick" } send "mode #channel +I nick1\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel +I nick1!*@*" + "@* MODE #channel +I nick1!*@*" } send "mode #channel +b nick2@domain\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel +b nick2!*@domain" + "@* MODE #channel +b nick2!*@domain" } send "mode #channel +I nick3!user\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel +I nick3!user@*" + "@* MODE #channel +I nick3!user@*" } send "mode #channel -vo nick nick\r" expect { timeout { exit 1 } - ":nick!~user@* MODE #channel -vo nick nick" + "@* MODE #channel -vo nick nick" } send "quit\r" Index: src/testsuite/ngircd-test.conf =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/ngircd-test.conf,v retrieving revision 1.3.4.1 retrieving revision 1.4 diff -u -p -r1.3.4.1 -r1.4 --- a/src/testsuite/ngircd-test.conf 7 Nov 2003 20:51:11 -0000 1.3.4.1 +++ b/src/testsuite/ngircd-test.conf 5 Nov 2003 23:31:43 -0000 1.4 @@ -1,4 +1,4 @@ -# $Id: ngircd-test.conf,v 1.3.4.1 2003/11/07 20:51:11 alex Exp $ +# $Id: ngircd-test.conf,v 1.4 2003/11/05 23:31:43 alex Exp $ [Global] Name = ngircd.test.server Index: src/testsuite/start-server.sh =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/start-server.sh,v retrieving revision 1.10.4.1 retrieving revision 1.11 diff -u -p -r1.10.4.1 -r1.11 --- a/src/testsuite/start-server.sh 7 Nov 2003 20:51:11 -0000 1.10.4.1 +++ b/src/testsuite/start-server.sh 22 Aug 2003 11:31:18 -0000 1.11 @@ -1,6 +1,6 @@ #!/bin/sh # ngIRCd Test Suite -# $Id: start-server.sh,v 1.10.4.1 2003/11/07 20:51:11 alex Exp $ +# $Id: start-server.sh,v 1.11 2003/08/22 11:31:18 alex Exp $ [ -z "$srcdir" ] && srcdir=`dirname $0` Index: src/testsuite/stop-server.sh =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/stop-server.sh,v retrieving revision 1.9.4.1 retrieving revision 1.10 diff -u -p -r1.9.4.1 -r1.10 --- a/src/testsuite/stop-server.sh 7 Nov 2003 20:51:11 -0000 1.9.4.1 +++ b/src/testsuite/stop-server.sh 22 Aug 2003 11:31:18 -0000 1.10 @@ -1,6 +1,6 @@ #!/bin/sh # ngIRCd Test Suite -# $Id: stop-server.sh,v 1.9.4.1 2003/11/07 20:51:11 alex Exp $ +# $Id: stop-server.sh,v 1.10 2003/08/22 11:31:18 alex Exp $ [ -z "$srcdir" ] && srcdir=`dirname $0` Index: src/testsuite/stress-server.sh =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/stress-server.sh,v retrieving revision 1.6.4.2 retrieving revision 1.8 diff -u -p -r1.6.4.2 -r1.8 --- a/src/testsuite/stress-server.sh 7 Nov 2003 20:51:11 -0000 1.6.4.2 +++ b/src/testsuite/stress-server.sh 22 Aug 2003 11:31:18 -0000 1.8 @@ -1,6 +1,6 @@ #!/bin/sh # ngIRCd Test Suite -# $Id: stress-server.sh,v 1.6.4.2 2003/11/07 20:51:11 alex Exp $ +# $Id: stress-server.sh,v 1.8 2003/08/22 11:31:18 alex Exp $ [ -z "$srcdir" ] && srcdir=`dirname $0` Index: src/testsuite/tests.sh =================================================================== RCS file: /usr/local/CVS/ngircd/ngircd/src/testsuite/tests.sh,v retrieving revision 1.3.6.1 retrieving revision 1.4 diff -u -p -r1.3.6.1 -r1.4 --- a/src/testsuite/tests.sh 7 Nov 2003 20:51:11 -0000 1.3.6.1 +++ b/src/testsuite/tests.sh 22 Aug 2003 11:31:18 -0000 1.4 @@ -1,6 +1,6 @@ #!/bin/sh # ngIRCd Test Suite -# $Id: tests.sh,v 1.3.6.1 2003/11/07 20:51:11 alex Exp $ +# $Id: tests.sh,v 1.4 2003/08/22 11:31:18 alex Exp $ name=`basename $0` test=`echo ${name} | cut -d '.' -f 1`