Browse Source

Import upstream version 18

Alexander Barton 12 years ago
parent
commit
df8ad4f01d
100 changed files with 9885 additions and 11283 deletions
  1. 2 3
      AUTHORS
  2. 113 4
      ChangeLog
  3. 54 20
      INSTALL
  4. 17 11
      Makefile.am
  5. 165 72
      Makefile.in
  6. 76 3
      NEWS
  7. 2 3
      README
  8. 217 107
      aclocal.m4
  9. 4288 8964
      configure
  10. 11 74
      configure.in
  11. 496 0
      contrib/Anope/0001-Revert-Removed-ngircd.patch
  12. 60 0
      contrib/Anope/0002-ngircd-whitespace-fixes.patch
  13. 20 0
      contrib/Anope/Makefile.am
  14. 361 0
      contrib/Anope/Makefile.in
  15. 36 0
      contrib/Anope/README
  16. 43 12
      contrib/Debian/Makefile.in
  17. 18 0
      contrib/Debian/changelog
  18. 112 37
      contrib/MacOSX/Makefile.in
  19. 0 10
      contrib/MacOSX/config.h
  20. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/01ngircd-contents.xml
  21. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/01ngircd.xml
  22. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/02de-contents.xml
  23. 1 1
      contrib/MacOSX/ngIRCd.pmdoc/02de.xml
  24. 43 12
      contrib/MacOSX/ngIRCd.pmdoc/Makefile.in
  25. 70 22
      contrib/MacOSX/ngIRCd.pmdoc/index.xml
  26. 43 12
      contrib/MacOSX/ngIRCd.xcodeproj/Makefile.in
  27. 3 11
      contrib/MacOSX/ngIRCd.xcodeproj/project.pbxproj
  28. 3 3
      contrib/Makefile.am
  29. 115 40
      contrib/Makefile.in
  30. 5 3
      contrib/README
  31. BIN
      contrib/ngIRCd-Logo.gif
  32. 1 1
      contrib/ngircd.spec
  33. 2 2
      contrib/platformtest.sh
  34. 64 23
      depcomp
  35. 11 2
      doc/GIT.txt
  36. 1 1
      doc/Makefile.am
  37. 114 40
      doc/Makefile.in
  38. 19 17
      doc/Platforms.txt
  39. 22 2
      doc/Protocol.txt
  40. 3 3
      doc/SSL.txt
  41. 33 6
      doc/Services.txt
  42. 0 39
      doc/Zeroconf.txt
  43. 126 89
      doc/sample-ngircd.conf.tmpl
  44. 36 25
      doc/src/Doxyfile
  45. 2 2
      doc/src/Makefile.am
  46. 45 14
      doc/src/Makefile.in
  47. 0 10
      doc/src/header.inc.html
  48. 0 77
      doc/src/ngircd-doc.css
  49. 3 2
      install-sh
  50. 143 92
      man/Makefile.in
  51. 28 3
      man/ngircd.8.tmpl
  52. 251 169
      man/ngircd.conf.5.tmpl
  53. 29 20
      missing
  54. 113 38
      src/Makefile.in
  55. 3 28
      src/config.h.in
  56. 77 29
      src/ipaddr/Makefile.in
  57. 1 1
      src/ipaddr/ansi2knr.c
  58. 5 2
      src/ipaddr/ng_ipaddr.c
  59. 5 2
      src/ipaddr/ng_ipaddr.h
  60. 2 2
      src/ngircd/Makefile.am
  61. 142 68
      src/ngircd/Makefile.in
  62. 13 38
      src/ngircd/array.c
  63. 5 2
      src/ngircd/array.h
  64. 77 7
      src/ngircd/channel.c
  65. 9 4
      src/ngircd/channel.h
  66. 34 15
      src/ngircd/client.c
  67. 8 4
      src/ngircd/client.h
  68. 5 1
      src/ngircd/conf-ssl.h
  69. 882 437
      src/ngircd/conf.c
  70. 108 69
      src/ngircd/conf.h
  71. 5 3
      src/ngircd/conn-func.c
  72. 4 3
      src/ngircd/conn-func.h
  73. 10 5
      src/ngircd/conn-ssl.c
  74. 5 1
      src/ngircd/conn-ssl.h
  75. 8 5
      src/ngircd/conn-zip.c
  76. 4 7
      src/ngircd/conn-zip.h
  77. 303 133
      src/ngircd/conn.c
  78. 12 4
      src/ngircd/conn.h
  79. 6 10
      src/ngircd/defines.h
  80. 54 49
      src/ngircd/hash.c
  81. 5 7
      src/ngircd/hash.h
  82. 4 3
      src/ngircd/io.c
  83. 5 4
      src/ngircd/io.h
  84. 163 43
      src/ngircd/irc-channel.c
  85. 4 7
      src/ngircd/irc-channel.h
  86. 180 74
      src/ngircd/irc-info.c
  87. 4 7
      src/ngircd/irc-info.h
  88. 226 30
      src/ngircd/irc-login.c
  89. 6 4
      src/ngircd/irc-login.h
  90. 31 28
      src/ngircd/irc-mode.c
  91. 4 7
      src/ngircd/irc-mode.h
  92. 5 3
      src/ngircd/irc-op.c
  93. 4 7
      src/ngircd/irc-op.h
  94. 5 3
      src/ngircd/irc-oper.c
  95. 4 7
      src/ngircd/irc-oper.h
  96. 11 4
      src/ngircd/irc-server.c
  97. 4 7
      src/ngircd/irc-server.h
  98. 5 3
      src/ngircd/irc-write.c
  99. 5 2
      src/ngircd/irc-write.h
  100. 0 0
      src/ngircd/irc.c

+ 2 - 3
AUTHORS

@@ -1,9 +1,8 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2009 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 

+ 113 - 4
ChangeLog

@@ -1,15 +1,124 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
                                -- ChangeLog --
                                -- ChangeLog --
 
 
 
 
+ngIRCd Release 18 (2011-07-10)
+
+  - Update timestamp of ngircd(8) manual page.
+  - Add preliminary ngIRCd protocol module for Anope 1.9 to contrib/Anope/.
+  - Don't register WHOWAS information when "MorePrivacy" option is in effect.
+
+  ngIRCd 18~rc2 (2011-06-29)
+  - Update documentation, fix some wording, and use a spellchecker :-)
+  - ngircd.conf.5: strip "SSL" prefix from variables in [SSL] section.
+  - ngircd.8: document debugging options.
+  - GnuTLS: use 1024 bits as minimum size of the DH prime. This enables
+    ngIRCd to accept incoming connections from other servers and clients
+    that "only" use at least 1024 bits again, like ngIRCd 17 did (and no
+    longer requires 2048 bits for incoming connections).
+
+  ngIRCd 18~rc1 (2011-06-27)
+  - PAM warning message: make clear which "Password" config option is ignored.
+  - New configuration option "MorePrivacy" to "censor" some user information.
+    When enabled, signon time and idle time is left out. Part and quit
+    messages are made to look the same. WHOWAS requests are silently dropped.
+    All of this is useful if one wish to conceal users that access the ngircd
+    servers from TOR or I2P.
+  - New configuration option "ScrubCTCP" to scrub incoming CTCP commands. If
+    activated, the server silently drops incoming CTCP requests from both
+    other servers and from users. The server that scrubs CTCP will not forward
+    the CTCP requests to other servers in the network either, which can spell
+    trouble if not every oper knows about the CTCP-scrubbing. Scrubbing CTCP
+    commands also means that it is not possible to send files between users.
+    There is one exception to the CTCP scrubbing performed: ACTION ("/me
+    commands") requests are not scrubbed.
+  - Display configuration errors more prominent on "--configtest".
+  - Restructure ngIRCd configuration file: introduce new [Limits], [Options],
+    and [SSL] sections. The intention of this restructuring is to make the
+    [Global] section much cleaner, so that it only contains variables that
+    most installations must adjust to the local requirements. All the optional
+    variables are moved to [Limits], for configurable limits and timers of
+    ngIRCd, and [Options], for optional features. All SSL-related variables
+    are moved to [SSL] and the "SSL"-prefix is stripped. The old variables in
+    the [Global] section are deprecated now, but are still recognized.
+    => Don't forget to check your configuration, use "ngircd --configtest"!
+  - New documentation "how to contribute": doc/Contributing.txt.
+  - Slightly fix error handling when connecting to remote servers.
+  - GnuTLS: bump DH-bitsize to 2048: this solves the problem that some clients
+    refuse to connect to severs that only offer 1024. For interoperability it
+    would be best to just use 4096 bits, but that takes minutes, even on
+    current hardware ...
+  - contrib/platformtest.sh: fix gcc version detection.
+  - Avoid needlessly scary 'buffer overflow' messages: When the write buffer
+    space grows too large, ngIRCd has to disconnect the client to avoid
+    wasting too much memory, which is logged with a scary 'write buffer
+    overflow' message. Change this to a more descriptive wording.
+  - Require server prefixes for most commands on RFC2812 links. RFC1459 links
+    (often used by services, for example) are not affected.
+  - Mac OS X: update installer functionality, texts, and add our logo :-)
+  - New configuration option "RequireAuthPing": PING-PONG on login. When
+    enabled, this configuration option lets ngIRCd send a PING with an numeric
+    "token" to clients logging in; and it will not become registered in the
+    network until the client responds with the correct PONG.
+  - New configuration option "NoticeAuth": send NOTICE AUTH on connect. When
+    active, ngircd will send "NOTICE AUTH" messages on client connect time
+    like e.g. snircd (QuakeNet) does.
+  - Generate WALLOPS message on SQUIT from IRC operators; so SQUIT now behaves
+    like CONNECT and DISCONNECT commands, when called by an IRC operator.
+  - Allow servers to send more commands in the first 10 seconds ("burst"). This
+    helps to speed up server login and network synchronization.
+  - Add support for up to 3 targets in WHOIS queries, also allow up to one
+    wildcard query from local hosts. Follows ircd 2.10 implementation rather
+    than RFC 2812. At most 10 entries are returned per wildcard expansion.
+  - ngircd.conf(5) manual page: describe types of configuration variables
+    (booleans, text strings, integer numbers) and add type information to each
+    variable description.
+  - Don't use "the.net" in sample-ngircd.conf, use "example.net".
+  - Terminate incoming connections on HTTP commands "GET" and "POST".
+  - New configuration option "CloakHost": when set, this hostname is used for
+    every client instead of the real DNS hostname (or IP address).
+  - New configuration option "CloakUserToNick": when enabled, ngIRCd sets
+    every clients' user name to their nick name and hides the user name
+    supplied by the IRC client.
+  - doc/Protocol.txt: Update description of the CHANINFO and WEBIRC commands.
+  - Doxygen'ify (document) much more source files; code cleanup ...
+  - Make write buffers bigger, but flush early. Before this change, a client
+    got disconnected if the buffer flushing at 4k failed, now regular clients
+    can store up to 32k and servers up 64k even if flushing is not possible at
+    the moment. This enhances reliability on slow links.
+  - Don't access possibly free'd CLIENT structure. Ooops.
+  - Allow "Port = 0" in [Server] blocks. Port number 0 marks remote servers
+    that try to connect to this daemon, but where this daemon never tries to
+    establish a connection on its own: only incoming connections are allowed.
+  - Configuration: fix 'Value of "..." is not a number!' for negative values.
+  - Enable WHOIS command to return information about services.
+  - Implement channel mode 'O': "IRC operators only". This channel mode is
+    used on DALnet (bahamut), for example.
+  - Remove support for ZeroConf/Bonjour/Rendezvous service registration
+    including the "[No]ZeroConf" configuration option.
+  - TOPIC command: test for channel admin rights correctly: this enables other
+    servers, services and IRC operators to change channel topics, even when
+    the client is not joined to this channel.
+  - Deprecate NoXX-Options in ngircd.conf and move new variants into our new
+    [Options] section: 'NoDNS=no' => 'DNS=yes', 'NoIdent=no' => 'Ident=yes',
+    'NoPAM=no' => 'PAM=yes', and 'NoZeroConf=no' => 'ZeroConf=yes' (and
+    vice-versa). The defaults are adjusted accordingly and the old variables
+    in [Global] are still accepted, so there is no functional change.
+  - Fix confusing "adding to invite list" debug messages: adding entries to
+    ban list produced 'invite list' debug output ...
+  - Don't throttle services and servers being registered.
+  - Xcode: correctly sort files :-)
+  - Don't assert() when searching a client for an invalid server token (this is
+    only relevant when a trusted server on a server-server link sends invalid
+    commands).
+
 ngIRCd Release 17.1 (2010-12-19)
 ngIRCd Release 17.1 (2010-12-19)
 
 
   - --configtest: remember if MOTD is configured by file or phrase
   - --configtest: remember if MOTD is configured by file or phrase
@@ -17,7 +126,7 @@ ngIRCd Release 17.1 (2010-12-19)
   - Reset ID of outgoing server link on DNS error correctly
   - Reset ID of outgoing server link on DNS error correctly
   - Don't log critical (or worse) messages to stderr
   - Don't log critical (or worse) messages to stderr
   - Manual page ngircd(8): add SIGNALS section
   - Manual page ngircd(8): add SIGNALS section
-  - Manual pages: update and simplyfy AUTHORS section
+  - Manual pages: update and simplify AUTHORS section
   - Remove "error file" when compiled with debug code enabled
   - Remove "error file" when compiled with debug code enabled
   - README: Updated list of implemented commands
   - README: Updated list of implemented commands
   - add doc/README-Interix.txt and doc/Bopm.txt to distribution tarball
   - add doc/README-Interix.txt and doc/Bopm.txt to distribution tarball

+ 54 - 20
INSTALL

@@ -1,9 +1,8 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
@@ -13,6 +12,43 @@
 I. Upgrade Information
 I. Upgrade Information
 ~~~~~~~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~~~~~~~
 
 
+Differences to version 17
+
+- Support for ZeroConf/Bonjour/Rendezvous service registration has been
+  removed. The configuration option "NoZeroconf" is no longer available.
+
+- The structure of ngircd.conf has been cleaned up and three new configuration
+  sections have been introduced: [Limits], [Options], and [SSL].
+  Lots of configuration variables stored in the [Global] section are now
+  deprecated there and should be stored in one of these new sections (but
+  still work in [Global]):
+    "AllowRemoteOper"    -> [Options]
+    "ChrootDir"          -> [Options]
+    "ConnectIPv4"        -> [Options]
+    "ConnectIPv6"        -> [Options]
+    "ConnectRetry"       -> [Limits]
+    "MaxConnections"     -> [Limits]
+    "MaxConnectionsIP"   -> [Limits]
+    "MaxJoins"           -> [Limits]
+    "MaxNickLength"      -> [Limits]
+    "NoDNS"              -> [Options], and renamed to "DNS"
+    "NoIdent"            -> [Options], and renamed to "Ident"
+    "NoPAM"              -> [Options], and renamed to "PAM"
+    "OperCanUseMode"     -> [Options]
+    "OperServerMode"     -> [Options]
+    "PingTimeout"        -> [Limits]
+    "PongTimeout"        -> [Limits]
+    "PredefChannelsOnly" -> [Options]
+    "SSLCertFile"        -> [SSL], and renamed to "CertFile"
+    "SSLDHFile"          -> [SSL], and renamed to "DHFile"
+    "SSLKeyFile"         -> [SSL], and renamed to "KeyFile"
+    "SSLKeyFilePassword" -> [SSL], and renamed to "KeyFilePassword"
+    "SSLPorts"           -> [SSL], and renamed to "Ports"
+    "SyslogFacility"     -> [Options]
+    "WebircPassword"     -> [Options]
+  You should adjust your ngircd.conf and run "ngircd --configtest" to make
+  sure that your settings are correct and up to date!
+
 Differences to version 16
 Differences to version 16
 
 
 - Changes to the "MotdFile" specified in ngircd.conf now require a ngircd
 - Changes to the "MotdFile" specified in ngircd.conf now require a ngircd
@@ -69,7 +105,8 @@ location, /usr/local/sbin/.
 
 
 The next step is to configure and afterwards starting the daemon. Please
 The next step is to configure and afterwards starting the daemon. Please
 have a look at the ngircd(8) and ngircd.conf(5) manual pages for details
 have a look at the ngircd(8) and ngircd.conf(5) manual pages for details
-and all possible options.
+and all possible options -- and don't forget to run "ngircd --configtest"
+to validate your configuration file!
 
 
 If no previous version of the configuration file exists (the standard name
 If no previous version of the configuration file exists (the standard name
 is /usr/local/etc/ngircd.conf), a sample configuration file containing all
 is /usr/local/etc/ngircd.conf), a sample configuration file containing all
@@ -97,7 +134,7 @@ Again: "end users" do not need this step!
 
 
 The configure-script is used to detect local system dependencies.
 The configure-script is used to detect local system dependencies.
 
 
-In the perfect case, configure should recognise all needed libraries, header
+In the perfect case, configure should recognize all needed libraries, header
 files and so on. If this shouldn't work, "./configure --help" shows all
 files and so on. If this shouldn't work, "./configure --help" shows all
 possible options.
 possible options.
 
 
@@ -124,11 +161,12 @@ the local system. Normally, root privileges are necessary to complete this
 step. If there is already an older configuration file present, it won't be
 step. If there is already an older configuration file present, it won't be
 overwritten.
 overwritten.
 
 
-This files will be installed by default:
+These files and folders will be installed by default:
 
 
 - /usr/local/sbin/ngircd: executable server
 - /usr/local/sbin/ngircd: executable server
 - /usr/local/etc/ngircd.conf: sample configuration (if not already present)
 - /usr/local/etc/ngircd.conf: sample configuration (if not already present)
 - /usr/local/share/doc/ngircd/: documentation
 - /usr/local/share/doc/ngircd/: documentation
+- /usr/local/share/man/: manual pages
 
 
 
 
 III. Additional features
 III. Additional features
@@ -174,13 +212,6 @@ standard locations.
   Include support for IDENT ("AUTH") lookups. The "ident" library is
   Include support for IDENT ("AUTH") lookups. The "ident" library is
   required for this option.
   required for this option.
 
 
-* ZeroConf Support:
-  --with-zeroconf[=<path>] 
-
-  Compile ngIRCd with support for ZeroConf multicast DNS service registration.
-  Either the Apple ZeroConf implementation (e. g. Mac OS X) or the Howl
-  library is required. Which one is available is autodetected.
-
 * TCP-Wrappers:
 * TCP-Wrappers:
   --with-tcp-wrappers[=<path>] 
   --with-tcp-wrappers[=<path>] 
 
 
@@ -229,19 +260,20 @@ V. Sample configuration file ngircd.conf
 In the sample configuration file, there are comments beginning with "#" OR
 In the sample configuration file, there are comments beginning with "#" OR
 ";" -- this is only for the better understanding of the file.
 ";" -- this is only for the better understanding of the file.
 
 
-The file is separated in four blocks: [Global], [Operator], [Server], and
-[Channel].
+The file is separated in five blocks: [Global], [Features], [Operator],
+[Server], and [Channel].
 
 
 In the [Global] section, there is the main configuration like the server
 In the [Global] section, there is the main configuration like the server
-name and the ports, on which the server should be listening. IRC operators
-of this server are defined in [Operator] blocks. [Server] is the section
-where server links are configured. And [Channel] blocks are used to
-configure pre-defined ("persistent") IRC channels.
+name and the ports, on which the server should be listening. Options in
+the [Features] section enable or disable functionality in the daemon.
+IRC operators of this server are defined in [Operator] blocks, remote
+servers are configured in [Server] sections, and [Channel] blocks are
+used to configure pre-defined ("persistent") IRC channels.
 
 
 The meaning of the variables in the configuration file is explained in the 
 The meaning of the variables in the configuration file is explained in the 
 "doc/sample-ngircd.conf", which is used as sample configuration file in
 "doc/sample-ngircd.conf", which is used as sample configuration file in
 /usr/local/etc after running "make install" (if you don't already have one)
 /usr/local/etc after running "make install" (if you don't already have one)
-and in the "ngircd.conf" manual page.
+and in the ngircd.conf(5) manual page.
 
 
 
 
 VI. Command line options
 VI. Command line options
@@ -266,3 +298,5 @@ These parameters could be passed to the ngIRCd:
 Use "--help" to see a short help text describing all available parameters
 Use "--help" to see a short help text describing all available parameters
 the server understands, with "--version" the ngIRCd shows its version
 the server understands, with "--version" the ngIRCd shows its version
 number. In both cases the server exits after the output.
 number. In both cases the server exits after the output.
+
+Please see the ngircd(8) manual page for complete details!

+ 17 - 11
Makefile.am

@@ -1,6 +1,6 @@
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -37,6 +37,10 @@ have-xcodebuild:
 	 >/dev/null 2>&1 \
 	 >/dev/null 2>&1 \
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 
 
+have-packagemaker:
+	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
+	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
+
 xcode: have-xcodebuild
 xcode: have-xcodebuild
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
@@ -55,10 +59,15 @@ deb:
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	dpkg-buildpackage -rfakeroot -i
 	dpkg-buildpackage -rfakeroot -i
 
 
-osxpkg: have-xcodebuild
-	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
-	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
-	make clean
+osxpkg: have-packagemaker osxpkg-dest
+	cd contrib/MacOSX && packagemaker \
+	 --doc ngIRCd.pmdoc \
+	 --out ../../$(distdir).mpkg
+	rm -f $(distdir).mpkg.zip
+	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
+	rm -rf ngircd.dest $(distdir).mpkg
+
+osxpkg-dest: have-xcodebuild clean
 	./configure --prefix=/opt/ngircd
 	./configure --prefix=/opt/ngircd
 	make xcode
 	make xcode
 	make -C contrib/MacOSX de.barton.ngircd.plist
 	make -C contrib/MacOSX de.barton.ngircd.plist
@@ -71,11 +80,8 @@ osxpkg: have-xcodebuild
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	chmod -R a-s,og-w,a+rX ngircd.dest
 	chmod -R a-s,og-w,a+rX ngircd.dest
-	cd contrib/MacOSX && packagemaker \
-	 --doc ngIRCd.pmdoc \
-	 --out ../../$(distdir).mpkg
-	rm -f $(distdir).mpkg.zip
-	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
-	rm -rf ngircd.dest $(distdir).mpkg
+
+.PHONY: deb have-packagemaker have-xcodebuild lint osxpkg osxpkg-dest rpm \
+	srcdoc testsuite xcode xcode-clean
 
 
 # -eof-
 # -eof-

+ 165 - 72
Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -16,7 +17,7 @@
 
 
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -57,6 +59,13 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -68,6 +77,9 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir dist dist-all distcheck
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
 DIST_SUBDIRS = $(SUBDIRS)
@@ -75,15 +87,41 @@ DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
 distdir = $(PACKAGE)-$(VERSION)
 top_distdir = $(distdir)
 top_distdir = $(distdir)
 am__remove_distdir = \
 am__remove_distdir = \
-  { test ! -d $(distdir) \
-    || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \
-         && rm -fr $(distdir); }; }
+  { test ! -d "$(distdir)" \
+    || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
+         && rm -fr "$(distdir)"; }; }
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 DIST_ARCHIVES = $(distdir).tar.gz
 DIST_ARCHIVES = $(distdir).tar.gz
 GZIP_ENV = --best
 GZIP_ENV = --best
 distuninstallcheck_listfiles = find . -type f -print
 distuninstallcheck_listfiles = find . -type f -print
 distcleancheck_listfiles = find . -type f -print
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -120,6 +158,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -179,6 +218,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = gnu
 AUTOMAKE_OPTIONS = gnu
@@ -192,15 +232,15 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \
-	      cd $(srcdir) && $(AUTOMAKE) --gnu  \
+	      echo ' cd $(srcdir) && $(AUTOMAKE) --gnu'; \
+	      $(am__cd) $(srcdir) && $(AUTOMAKE) --gnu \
 		&& exit 0; \
 		&& exit 0; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -216,9 +256,10 @@ $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENC
 	$(SHELL) ./config.status --recheck
 	$(SHELL) ./config.status --recheck
 
 
 $(top_srcdir)/configure:  $(am__configure_deps)
 $(top_srcdir)/configure:  $(am__configure_deps)
-	cd $(srcdir) && $(AUTOCONF)
+	$(am__cd) $(srcdir) && $(AUTOCONF)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
-	cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+	$(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+$(am__aclocal_m4_deps):
 
 
 # This directory's subdirectories are mostly independent; you can cd
 # This directory's subdirectories are mostly independent; you can cd
 # into them and run `make' without going through this Makefile.
 # into them and run `make' without going through this Makefile.
@@ -227,7 +268,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 #     (which will cause the Makefiles to be regenerated when you run `make');
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -244,7 +285,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
 	if test "$$dot_seen" = "no"; then \
@@ -252,7 +293,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 	fi; test -z "$$fail"
 
 
 $(RECURSIVE_CLEAN_TARGETS):
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -278,16 +319,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 	done && test -z "$$fail"
 tags-recursive:
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 	done
 ctags-recursive:
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 	done
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -295,14 +336,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
 	  include_option=--etags-include; \
@@ -314,7 +355,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	  fi; \
 	done; \
 	done; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
@@ -323,36 +364,41 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
 
 distdir: $(DISTFILES)
 distdir: $(DISTFILES)
 	$(am__remove_distdir)
 	$(am__remove_distdir)
-	test -d $(distdir) || mkdir $(distdir)
+	test -d "$(distdir)" || mkdir "$(distdir)"
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
 	list='$(DISTFILES)'; \
@@ -368,38 +414,55 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	        distdir) \
 	      || exit 1; \
 	      || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	-find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \
+	-test -n "$(am__skip_mode_fix)" \
+	|| find "$(distdir)" -type d ! -perm -755 \
+		-exec chmod u+rwx,go+rx {} \; -o \
 	  ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
 	  ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
 	  ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
-	|| chmod -R a+r $(distdir)
+	|| chmod -R a+r "$(distdir)"
 dist-gzip: distdir
 dist-gzip: distdir
 	tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
 	tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
 	$(am__remove_distdir)
 	$(am__remove_distdir)
@@ -412,6 +475,10 @@ dist-lzma: distdir
 	tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
 	tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
 	$(am__remove_distdir)
 	$(am__remove_distdir)
 
 
+dist-xz: distdir
+	tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz
+	$(am__remove_distdir)
+
 dist-tarZ: distdir
 dist-tarZ: distdir
 	tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
 	tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
 	$(am__remove_distdir)
 	$(am__remove_distdir)
@@ -435,15 +502,17 @@ dist dist-all: distdir
 distcheck: dist
 distcheck: dist
 	case '$(DIST_ARCHIVES)' in \
 	case '$(DIST_ARCHIVES)' in \
 	*.tar.gz*) \
 	*.tar.gz*) \
-	  GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\
+	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
 	*.tar.bz2*) \
 	*.tar.bz2*) \
-	  bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\
+	  bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
 	*.tar.lzma*) \
 	*.tar.lzma*) \
-	  unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\
+	  lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
+	*.tar.xz*) \
+	  xz -dc $(distdir).tar.xz | $(am__untar) ;;\
 	*.tar.Z*) \
 	*.tar.Z*) \
 	  uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
 	  uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
 	*.shar.gz*) \
 	*.shar.gz*) \
-	  GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\
+	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
 	*.zip*) \
 	*.zip*) \
 	  unzip $(distdir).zip ;;\
 	  unzip $(distdir).zip ;;\
 	esac
 	esac
@@ -451,9 +520,11 @@ distcheck: dist
 	mkdir $(distdir)/_build
 	mkdir $(distdir)/_build
 	mkdir $(distdir)/_inst
 	mkdir $(distdir)/_inst
 	chmod a-w $(distdir)
 	chmod a-w $(distdir)
+	test -d $(distdir)/_build || exit 0; \
 	dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
 	dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
 	  && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
 	  && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
-	  && cd $(distdir)/_build \
+	  && am__cwd=`pwd` \
+	  && $(am__cd) $(distdir)/_build \
 	  && ../configure --srcdir=.. --prefix="$$dc_install_base" \
 	  && ../configure --srcdir=.. --prefix="$$dc_install_base" \
 	    $(DISTCHECK_CONFIGURE_FLAGS) \
 	    $(DISTCHECK_CONFIGURE_FLAGS) \
 	  && $(MAKE) $(AM_MAKEFLAGS) \
 	  && $(MAKE) $(AM_MAKEFLAGS) \
@@ -475,13 +546,15 @@ distcheck: dist
 	  && rm -rf "$$dc_destdir" \
 	  && rm -rf "$$dc_destdir" \
 	  && $(MAKE) $(AM_MAKEFLAGS) dist \
 	  && $(MAKE) $(AM_MAKEFLAGS) dist \
 	  && rm -rf $(DIST_ARCHIVES) \
 	  && rm -rf $(DIST_ARCHIVES) \
-	  && $(MAKE) $(AM_MAKEFLAGS) distcleancheck
+	  && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
+	  && cd "$$am__cwd" \
+	  || exit 1
 	$(am__remove_distdir)
 	$(am__remove_distdir)
 	@(echo "$(distdir) archives ready for distribution: "; \
 	@(echo "$(distdir) archives ready for distribution: "; \
 	  list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
 	  list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
 	  sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
 	  sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
 distuninstallcheck:
 distuninstallcheck:
-	@cd $(distuninstallcheck_dir) \
+	@$(am__cd) '$(distuninstallcheck_dir)' \
 	&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
 	&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
 	   || { echo "ERROR: files left after uninstall:" ; \
 	   || { echo "ERROR: files left after uninstall:" ; \
 	        if test -n "$(DESTDIR)"; then \
 	        if test -n "$(DESTDIR)"; then \
@@ -523,6 +596,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -542,6 +616,8 @@ dvi-am:
 
 
 html: html-recursive
 html: html-recursive
 
 
+html-am:
+
 info: info-recursive
 info: info-recursive
 
 
 info-am:
 info-am:
@@ -550,18 +626,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-recursive
 install-dvi: install-dvi-recursive
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-recursive
 install-html: install-html-recursive
 
 
+install-html-am:
+
 install-info: install-info-recursive
 install-info: install-info-recursive
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-recursive
 install-pdf: install-pdf-recursive
 
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 install-ps: install-ps-recursive
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-recursive
 maintainer-clean: maintainer-clean-recursive
@@ -585,21 +671,21 @@ ps-am:
 
 
 uninstall-am:
 uninstall-am:
 
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+	install-am install-strip tags-recursive
 
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am am--refresh check check-am clean clean-generic \
 	all all-am am--refresh check check-am clean clean-generic \
 	clean-local ctags ctags-recursive dist dist-all dist-bzip2 \
 	clean-local ctags ctags-recursive dist dist-all dist-bzip2 \
-	dist-gzip dist-lzma dist-shar dist-tarZ dist-zip distcheck \
-	distclean distclean-generic distclean-tags distcleancheck \
-	distdir distuninstallcheck dvi dvi-am html html-am info \
-	info-am install install-am install-data install-data-am \
-	install-dvi install-dvi-am install-exec install-exec-am \
-	install-html install-html-am install-info install-info-am \
-	install-man install-pdf install-pdf-am install-ps \
-	install-ps-am install-strip installcheck installcheck-am \
-	installdirs installdirs-am maintainer-clean \
+	dist-gzip dist-lzma dist-shar dist-tarZ dist-xz dist-zip \
+	distcheck distclean distclean-generic distclean-tags \
+	distcleancheck distdir distuninstallcheck dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am install-info \
+	install-info-am install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic maintainer-clean-local mostlyclean \
 	maintainer-clean-generic maintainer-clean-local mostlyclean \
 	mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \
 	mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \
 	uninstall uninstall-am
 	uninstall uninstall-am
@@ -629,6 +715,10 @@ have-xcodebuild:
 	 >/dev/null 2>&1 \
 	 >/dev/null 2>&1 \
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 	 || ( echo; echo "Error: \"xcodebuild\" not found!"; echo; exit 1 )
 
 
+have-packagemaker:
+	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
+	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
+
 xcode: have-xcodebuild
 xcode: have-xcodebuild
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	rel=`git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'`; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
 	 def="GCC_PREPROCESSOR_DEFINITIONS=\"VERSION=\\\"$$rel\\\"\""; \
@@ -647,10 +737,15 @@ deb:
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	[ -f debian/rules ] || ln -s contrib/Debian debian
 	dpkg-buildpackage -rfakeroot -i
 	dpkg-buildpackage -rfakeroot -i
 
 
-osxpkg: have-xcodebuild
-	@packagemaker >/dev/null 2>&1; [ $$? -le 1 ] \
-	 || ( echo; echo "Error: \"packagemaker\" not found!"; echo; exit 2)
-	make clean
+osxpkg: have-packagemaker osxpkg-dest
+	cd contrib/MacOSX && packagemaker \
+	 --doc ngIRCd.pmdoc \
+	 --out ../../$(distdir).mpkg
+	rm -f $(distdir).mpkg.zip
+	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
+	rm -rf ngircd.dest $(distdir).mpkg
+
+osxpkg-dest: have-xcodebuild clean
 	./configure --prefix=/opt/ngircd
 	./configure --prefix=/opt/ngircd
 	make xcode
 	make xcode
 	make -C contrib/MacOSX de.barton.ngircd.plist
 	make -C contrib/MacOSX de.barton.ngircd.plist
@@ -663,14 +758,12 @@ osxpkg: have-xcodebuild
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	rm ngircd.dest/opt/ngircd/etc/ngircd.conf
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	echo "Have a nice day IRCing!" >ngircd.dest/opt/ngircd/etc/ngircd.motd
 	chmod -R a-s,og-w,a+rX ngircd.dest
 	chmod -R a-s,og-w,a+rX ngircd.dest
-	cd contrib/MacOSX && packagemaker \
-	 --doc ngIRCd.pmdoc \
-	 --out ../../$(distdir).mpkg
-	rm -f $(distdir).mpkg.zip
-	zip -ro9 $(distdir).mpkg.zip $(distdir).mpkg
-	rm -rf ngircd.dest $(distdir).mpkg
+
+.PHONY: deb have-packagemaker have-xcodebuild lint osxpkg osxpkg-dest rpm \
+	srcdoc testsuite xcode xcode-clean
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 76 - 3
NEWS

@@ -1,14 +1,87 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2010 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
                                   -- NEWS --
                                   -- NEWS --
 
 
+ngIRCd Release 18 (2011-07-10)
+
+  - Add preliminary ngIRCd protocol module for Anope 1.9 to contrib/Anope/.
+
+  ngIRCd 18~rc2 (2011-06-29)
+  - GnuTLS: use 1024 bits as minimum size of the DH prime. This enables
+    ngIRCd to accept incoming connections from other servers and clients
+    that "only" use at least 1024 bits again, like ngIRCd 17 did (and no
+    longer requires 2048 bits for incoming connections).
+
+  ngIRCd 18~rc1 (2011-06-27)
+  - New configuration option "MorePrivacy" to "censor" some user information.
+    When enabled, signon time and idle time is left out. Part and quit
+    messages are made to look the same. WHOWAS requests are silently dropped.
+    All of this is useful if one wish to conceal users that access the ngircd
+    servers from TOR or I2P.
+  - New configuration option "ScrubCTCP" to scrub incoming CTCP commands. If
+    activated, the server silently drops incoming CTCP requests from both
+    other servers and from users. The server that scrubs CTCP will not forward
+    the CTCP requests to other servers in the network either, which can spell
+    trouble if not every oper knows about the CTCP-scrubbing. Scrubbing CTCP
+    commands also means that it is not possible to send files between users.
+    There is one exception to the CTCP scrubbing performed: ACTION ("/me
+    commands") requests are not scrubbed.
+  - Restructure ngIRCd configuration file: introduce new [Limits], [Options],
+    and [SSL] sections. The intention of this restructuring is to make the
+    [Global] section much cleaner, so that it only contains variables that
+    most installations must adjust to the local requirements. All the optional
+    variables are moved to [Limits], for configurable limits and timers of
+    ngIRCd, and [Options], for optional features. All SSL-related variables
+    are moved to [SSL] and the "SSL"-prefix is stripped. The old variables in
+    the [Global] section are deprecated now, but are still recognized.
+    => Don't forget to check your configuration, use "ngircd --configtest"!
+  - New documentation "how to contribute": doc/Contributing.txt.
+  - Avoid needlessly scary 'buffer overflow' messages: When the write buffer
+    space grows too large, ngIRCd has to disconnect the client to avoid
+    wasting too much memory, which is logged with a scary 'write buffer
+    overflow' message. Change this to a more descriptive wording.
+  - New configuration option "RequireAuthPing": PING-PONG on login. When
+    enabled, this configuration option lets ngIRCd send a PING with an numeric
+    "token" to clients logging in; and it will not become registered in the
+    network until the client responds with the correct PONG.
+  - New configuration option "NoticeAuth": send NOTICE AUTH on connect. When
+    active, ngircd will send "NOTICE AUTH" messages on client connect time
+    like e.g. snircd (QuakeNet) does.
+  - Add support for up to 3 targets in WHOIS queries, also allow up to one
+    wildcard query from local hosts. Follows ircd 2.10 implementation rather
+    than RFC 2812. At most 10 entries are returned per wildcard expansion.
+  - ngircd.conf(5) manual page: describe types of configuration variables
+    (booleans, text strings, integer numbers) and add type information to each
+    variable description.
+  - Terminate incoming connections on HTTP commands "GET" and "POST".
+  - New configuration option "CloakHost": when set, this hostname is used for
+    every client instead of the real DNS hostname (or IP address).
+  - New configuration option "CloakUserToNick": when enabled, ngIRCd sets
+    every clients' user name to their nick name and hides the user name
+    supplied by the IRC client.
+  - Make write buffers bigger, but flush early. Before this change, a client
+    got disconnected if the buffer flushing at 4k failed, now regular clients
+    can store up to 32k and servers up 64k even if flushing is not possible at
+    the moment. This enhances reliability on slow links.
+  - Allow "Port = 0" in [Server] blocks. Port number 0 marks remote servers
+    that try to connect to this daemon, but where this daemon never tries to
+    establish a connection on its own: only incoming connections are allowed.
+  - Enable WHOIS command to return information about services.
+  - Implement channel mode 'O': "IRC operators only". This channel mode is
+    used on DALnet (bahamut), for example.
+  - Remove support for ZeroConf/Bonjour/Rendezvous service registration
+    including the "[No]ZeroConf" configuration option.
+  - Deprecate NoXX-Options in ngircd.conf and move new variants into our new
+    [Options] section: 'NoDNS=no' => 'DNS=yes', 'NoIdent=no' => 'Ident=yes',
+    'NoPAM=no' => 'PAM=yes', and 'NoZeroConf=no' => 'ZeroConf=yes' (and
+    vice-versa). The defaults are adjusted accordingly and the old variables
+    in [Global] are still accepted, so there is no functional change.
 
 
 ngIRCd Release 17.1 (2010-12-19)
 ngIRCd Release 17.1 (2010-12-19)
 
 

+ 2 - 3
README

@@ -1,9 +1,8 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2007 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 

+ 217 - 107
aclocal.m4

@@ -1,7 +1,7 @@
-# generated automatically by aclocal 1.10.1 -*- Autoconf -*-
+# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
 
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2009  Free Software Foundation, Inc.
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -13,13 +13,13 @@
 
 
 m4_ifndef([AC_AUTOCONF_VERSION],
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(AC_AUTOCONF_VERSION, [2.61],,
-[m4_warning([this file was generated for autoconf 2.61.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
+[m4_warning([this file was generated for autoconf 2.67.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically `autoreconf'.])])
 To do so, use the procedure documented by the package, typically `autoreconf'.])])
 
 
-# Copyright (C) 2002, 2003, 2005, 2006, 2007  Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
@@ -31,10 +31,10 @@ To do so, use the procedure documented by the package, typically `autoreconf'.])
 # generated from the m4 files accompanying Automake X.Y.
 # generated from the m4 files accompanying Automake X.Y.
 # (This private macro should not be called outside this file.)
 # (This private macro should not be called outside this file.)
 AC_DEFUN([AM_AUTOMAKE_VERSION],
 AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.10'
+[am__api_version='1.11'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.10.1], [],
+m4_if([$1], [1.11.1], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 ])
 
 
@@ -48,12 +48,12 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # AM_SET_CURRENT_AUTOMAKE_VERSION
 # AM_SET_CURRENT_AUTOMAKE_VERSION
 # -------------------------------
 # -------------------------------
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
-# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
+# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.10.1])dnl
+[AM_AUTOMAKE_VERSION([1.11.1])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-_AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)])
+_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
 
@@ -110,14 +110,14 @@ am_aux_dir=`cd $ac_aux_dir && pwd`
 
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
 
-# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
+# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
 # Free Software Foundation, Inc.
 # Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 8
+# serial 9
 
 
 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
 # -------------------------------------
 # -------------------------------------
@@ -130,6 +130,7 @@ AC_SUBST([$1_TRUE])dnl
 AC_SUBST([$1_FALSE])dnl
 AC_SUBST([$1_FALSE])dnl
 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
+m4_define([_AM_COND_VALUE_$1], [$2])dnl
 if $2; then
 if $2; then
   $1_TRUE=
   $1_TRUE=
   $1_FALSE='#'
   $1_FALSE='#'
@@ -143,14 +144,14 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 fi])])
 
 
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
 # Free Software Foundation, Inc.
 # Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 9
+# serial 10
 
 
 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
 # written in clear, in which case automake, when reading aclocal.m4,
 # written in clear, in which case automake, when reading aclocal.m4,
@@ -207,6 +208,16 @@ AC_CACHE_CHECK([dependency style of $depcc],
   if test "$am_compiler_list" = ""; then
   if test "$am_compiler_list" = ""; then
      am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
      am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
   fi
   fi
+  am__universal=false
+  m4_case([$1], [CC],
+    [case " $depcc " in #(
+     *\ -arch\ *\ -arch\ *) am__universal=true ;;
+     esac],
+    [CXX],
+    [case " $depcc " in #(
+     *\ -arch\ *\ -arch\ *) am__universal=true ;;
+     esac])
+
   for depmode in $am_compiler_list; do
   for depmode in $am_compiler_list; do
     # Setup a source with many dependencies, because some compilers
     # Setup a source with many dependencies, because some compilers
     # like to wrap large dependency lists on column 80 (with \), and
     # like to wrap large dependency lists on column 80 (with \), and
@@ -224,7 +235,17 @@ AC_CACHE_CHECK([dependency style of $depcc],
     done
     done
     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
 
 
+    # We check with `-c' and `-o' for the sake of the "dashmstdout"
+    # mode.  It turns out that the SunPro C++ compiler does not properly
+    # handle `-M -o', and we need to detect this.  Also, some Intel
+    # versions had trouble with output in subdirs
+    am__obj=sub/conftest.${OBJEXT-o}
+    am__minus_obj="-o $am__obj"
     case $depmode in
     case $depmode in
+    gcc)
+      # This depmode causes a compiler race in universal mode.
+      test "$am__universal" = false || continue
+      ;;
     nosideeffect)
     nosideeffect)
       # after this tag, mechanisms are not by side-effect, so they'll
       # after this tag, mechanisms are not by side-effect, so they'll
       # only be used when explicitly requested
       # only be used when explicitly requested
@@ -234,19 +255,23 @@ AC_CACHE_CHECK([dependency style of $depcc],
 	break
 	break
       fi
       fi
       ;;
       ;;
+    msvisualcpp | msvcmsys)
+      # This compiler won't grok `-c -o', but also, the minuso test has
+      # not run yet.  These depmodes are late enough in the game, and
+      # so weak that their functioning should not be impacted.
+      am__obj=conftest.${OBJEXT-o}
+      am__minus_obj=
+      ;;
     none) break ;;
     none) break ;;
     esac
     esac
-    # We check with `-c' and `-o' for the sake of the "dashmstdout"
-    # mode.  It turns out that the SunPro C++ compiler does not properly
-    # handle `-M -o', and we need to detect this.
     if depmode=$depmode \
     if depmode=$depmode \
-       source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
+       source=sub/conftest.c object=$am__obj \
        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
-       $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
+       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
          >/dev/null 2>conftest.err &&
          >/dev/null 2>conftest.err &&
        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
-       grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
       # icc doesn't choke on unknown options, it will just issue warnings
       # icc doesn't choke on unknown options, it will just issue warnings
       # or remarks (even with -Werror).  So we grep stderr for any message
       # or remarks (even with -Werror).  So we grep stderr for any message
@@ -303,57 +328,68 @@ _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
 
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
 
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
 # Free Software Foundation, Inc.
 # Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-#serial 3
+#serial 5
 
 
 # _AM_OUTPUT_DEPENDENCY_COMMANDS
 # _AM_OUTPUT_DEPENDENCY_COMMANDS
 # ------------------------------
 # ------------------------------
 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
-[for mf in $CONFIG_FILES; do
-  # Strip MF so we end up with the name of the file.
-  mf=`echo "$mf" | sed -e 's/:.*$//'`
-  # Check whether this is an Automake generated Makefile or not.
-  # We used to match only the files named `Makefile.in', but
-  # some people rename them; so instead we look at the file content.
-  # Grep'ing the first line is not enough: some people post-process
-  # each Makefile.in and add a new line on top of each file to say so.
-  # Grep'ing the whole file is not good either: AIX grep has a line
-  # limit of 2048, but all sed's we know have understand at least 4000.
-  if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
-    dirpart=`AS_DIRNAME("$mf")`
-  else
-    continue
-  fi
-  # Extract the definition of DEPDIR, am__include, and am__quote
-  # from the Makefile without running `make'.
-  DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
-  test -z "$DEPDIR" && continue
-  am__include=`sed -n 's/^am__include = //p' < "$mf"`
-  test -z "am__include" && continue
-  am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
-  # When using ansi2knr, U may be empty or an underscore; expand it
-  U=`sed -n 's/^U = //p' < "$mf"`
-  # Find all dependency output files, they are included files with
-  # $(DEPDIR) in their names.  We invoke sed twice because it is the
-  # simplest approach to changing $(DEPDIR) to its actual value in the
-  # expansion.
-  for file in `sed -n "
-    s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
-       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
-    # Make sure the directory exists.
-    test -f "$dirpart/$file" && continue
-    fdir=`AS_DIRNAME(["$file"])`
-    AS_MKDIR_P([$dirpart/$fdir])
-    # echo "creating $dirpart/$file"
-    echo '# dummy' > "$dirpart/$file"
+[{
+  # Autoconf 2.62 quotes --file arguments for eval, but not when files
+  # are listed without --file.  Let's play safe and only enable the eval
+  # if we detect the quoting.
+  case $CONFIG_FILES in
+  *\'*) eval set x "$CONFIG_FILES" ;;
+  *)   set x $CONFIG_FILES ;;
+  esac
+  shift
+  for mf
+  do
+    # Strip MF so we end up with the name of the file.
+    mf=`echo "$mf" | sed -e 's/:.*$//'`
+    # Check whether this is an Automake generated Makefile or not.
+    # We used to match only the files named `Makefile.in', but
+    # some people rename them; so instead we look at the file content.
+    # Grep'ing the first line is not enough: some people post-process
+    # each Makefile.in and add a new line on top of each file to say so.
+    # Grep'ing the whole file is not good either: AIX grep has a line
+    # limit of 2048, but all sed's we know have understand at least 4000.
+    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
+      dirpart=`AS_DIRNAME("$mf")`
+    else
+      continue
+    fi
+    # Extract the definition of DEPDIR, am__include, and am__quote
+    # from the Makefile without running `make'.
+    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
+    test -z "$DEPDIR" && continue
+    am__include=`sed -n 's/^am__include = //p' < "$mf"`
+    test -z "am__include" && continue
+    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
+    # When using ansi2knr, U may be empty or an underscore; expand it
+    U=`sed -n 's/^U = //p' < "$mf"`
+    # Find all dependency output files, they are included files with
+    # $(DEPDIR) in their names.  We invoke sed twice because it is the
+    # simplest approach to changing $(DEPDIR) to its actual value in the
+    # expansion.
+    for file in `sed -n "
+      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
+	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
+      # Make sure the directory exists.
+      test -f "$dirpart/$file" && continue
+      fdir=`AS_DIRNAME(["$file"])`
+      AS_MKDIR_P([$dirpart/$fdir])
+      # echo "creating $dirpart/$file"
+      echo '# dummy' > "$dirpart/$file"
+    done
   done
   done
-done
+}
 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 
 
 
 
@@ -385,13 +421,13 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
 # Do all the work for Automake.                             -*- Autoconf -*-
 # Do all the work for Automake.                             -*- Autoconf -*-
 
 
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2008 Free Software Foundation, Inc.
+# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 13
+# serial 16
 
 
 # This macro actually does too much.  Some checks are only needed if
 # This macro actually does too much.  Some checks are only needed if
 # your package does certain things.  But this isn't really a big deal.
 # your package does certain things.  But this isn't really a big deal.
@@ -408,7 +444,7 @@ AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
 # arguments mandatory, and then we can depend on a new Autoconf
 # arguments mandatory, and then we can depend on a new Autoconf
 # release and drop the old call support.
 # release and drop the old call support.
 AC_DEFUN([AM_INIT_AUTOMAKE],
 AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_PREREQ([2.60])dnl
+[AC_PREREQ([2.62])dnl
 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 dnl the ones we care about.
 dnl the ones we care about.
 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@@ -459,8 +495,8 @@ AM_MISSING_PROG(AUTOCONF, autoconf)
 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
 AM_MISSING_PROG(AUTOHEADER, autoheader)
 AM_MISSING_PROG(AUTOHEADER, autoheader)
 AM_MISSING_PROG(MAKEINFO, makeinfo)
 AM_MISSING_PROG(MAKEINFO, makeinfo)
-AM_PROG_INSTALL_SH
-AM_PROG_INSTALL_STRIP
+AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
+AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
 # We need awk for the "check" target.  The system "awk" is bad on
 # We need awk for the "check" target.  The system "awk" is bad on
 # some platforms.
 # some platforms.
@@ -468,24 +504,37 @@ AC_REQUIRE([AC_PROG_AWK])dnl
 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
-              [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
-	      		     [_AM_PROG_TAR([v7])])])
+	      [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
+			     [_AM_PROG_TAR([v7])])])
 _AM_IF_OPTION([no-dependencies],,
 _AM_IF_OPTION([no-dependencies],,
 [AC_PROVIDE_IFELSE([AC_PROG_CC],
 [AC_PROVIDE_IFELSE([AC_PROG_CC],
-                  [_AM_DEPENDENCIES(CC)],
-                  [define([AC_PROG_CC],
-                          defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
+		  [_AM_DEPENDENCIES(CC)],
+		  [define([AC_PROG_CC],
+			  defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
 AC_PROVIDE_IFELSE([AC_PROG_CXX],
 AC_PROVIDE_IFELSE([AC_PROG_CXX],
-                  [_AM_DEPENDENCIES(CXX)],
-                  [define([AC_PROG_CXX],
-                          defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
+		  [_AM_DEPENDENCIES(CXX)],
+		  [define([AC_PROG_CXX],
+			  defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
-                  [_AM_DEPENDENCIES(OBJC)],
-                  [define([AC_PROG_OBJC],
-                          defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
+		  [_AM_DEPENDENCIES(OBJC)],
+		  [define([AC_PROG_OBJC],
+			  defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
 ])
 ])
+_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
+dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
+dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
+dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
+AC_CONFIG_COMMANDS_PRE(dnl
+[m4_provide_if([_AM_COMPILER_EXEEXT],
+  [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 ])
 ])
 
 
+dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
+dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
+dnl mangled by Autoconf and run in a shell conditional statement.
+m4_define([_AC_COMPILER_EXEEXT],
+m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
+
 
 
 # When config.status generates a header, we must update the stamp-h file.
 # When config.status generates a header, we must update the stamp-h file.
 # This file resides in the same directory as the config header
 # This file resides in the same directory as the config header
@@ -508,7 +557,7 @@ for _am_header in $config_headers :; do
 done
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
 
-# Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2003, 2005, 2008  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
@@ -519,7 +568,14 @@ echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_co
 # Define $install_sh.
 # Define $install_sh.
 AC_DEFUN([AM_PROG_INSTALL_SH],
 AC_DEFUN([AM_PROG_INSTALL_SH],
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
-install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
+if test x"${install_sh}" != xset; then
+  case $am_aux_dir in
+  *\ * | *\	*)
+    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
+  *)
+    install_sh="\${SHELL} $am_aux_dir/install-sh"
+  esac
+fi
 AC_SUBST(install_sh)])
 AC_SUBST(install_sh)])
 
 
 # Copyright (C) 2003, 2005  Free Software Foundation, Inc.
 # Copyright (C) 2003, 2005  Free Software Foundation, Inc.
@@ -545,13 +601,13 @@ AC_SUBST([am__leading_dot])])
 
 
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 
 
-# Copyright (C) 2001, 2002, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2005, 2009  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 3
+# serial 4
 
 
 # AM_MAKE_INCLUDE()
 # AM_MAKE_INCLUDE()
 # -----------------
 # -----------------
@@ -560,7 +616,7 @@ AC_DEFUN([AM_MAKE_INCLUDE],
 [am_make=${MAKE-make}
 [am_make=${MAKE-make}
 cat > confinc << 'END'
 cat > confinc << 'END'
 am__doit:
 am__doit:
-	@echo done
+	@echo this is the am__doit target
 .PHONY: am__doit
 .PHONY: am__doit
 END
 END
 # If we don't find an include directive, just comment out the code.
 # If we don't find an include directive, just comment out the code.
@@ -570,24 +626,24 @@ am__quote=
 _am_result=none
 _am_result=none
 # First try GNU make style include.
 # First try GNU make style include.
 echo "include confinc" > confmf
 echo "include confinc" > confmf
-# We grep out `Entering directory' and `Leaving directory'
-# messages which can occur if `w' ends up in MAKEFLAGS.
-# In particular we don't look at `^make:' because GNU make might
-# be invoked under some other name (usually "gmake"), in which
-# case it prints its new name instead of `make'.
-if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
-   am__include=include
-   am__quote=
-   _am_result=GNU
-fi
+# Ignore all kinds of additional output from `make'.
+case `$am_make -s -f confmf 2> /dev/null` in #(
+*the\ am__doit\ target*)
+  am__include=include
+  am__quote=
+  _am_result=GNU
+  ;;
+esac
 # Now try BSD make style include.
 # Now try BSD make style include.
 if test "$am__include" = "#"; then
 if test "$am__include" = "#"; then
    echo '.include "confinc"' > confmf
    echo '.include "confinc"' > confmf
-   if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
-      am__include=.include
-      am__quote="\""
-      _am_result=BSD
-   fi
+   case `$am_make -s -f confmf 2> /dev/null` in #(
+   *the\ am__doit\ target*)
+     am__include=.include
+     am__quote="\""
+     _am_result=BSD
+     ;;
+   esac
 fi
 fi
 AC_SUBST([am__include])
 AC_SUBST([am__include])
 AC_SUBST([am__quote])
 AC_SUBST([am__quote])
@@ -597,14 +653,14 @@ rm -f confinc confmf
 
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
 
-# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
+# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
 # Free Software Foundation, Inc.
 # Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 5
+# serial 6
 
 
 # AM_MISSING_PROG(NAME, PROGRAM)
 # AM_MISSING_PROG(NAME, PROGRAM)
 # ------------------------------
 # ------------------------------
@@ -621,7 +677,14 @@ AC_SUBST($1)])
 AC_DEFUN([AM_MISSING_HAS_RUN],
 AC_DEFUN([AM_MISSING_HAS_RUN],
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 AC_REQUIRE_AUX_FILE([missing])dnl
 AC_REQUIRE_AUX_FILE([missing])dnl
-test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
+if test x"${MISSING+set}" != xset; then
+  case $am_aux_dir in
+  *\ * | *\	*)
+    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
+  *)
+    MISSING="\${SHELL} $am_aux_dir/missing" ;;
+  esac
+fi
 # Use eval to expand $SHELL
 # Use eval to expand $SHELL
 if eval "$MISSING --run true"; then
 if eval "$MISSING --run true"; then
   am_missing_run="$MISSING --run "
   am_missing_run="$MISSING --run "
@@ -659,13 +722,13 @@ esac
 
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 # Helper functions for option handling.                     -*- Autoconf -*-
 
 
-# Copyright (C) 2001, 2002, 2003, 2005  Free Software Foundation, Inc.
+# Copyright (C) 2001, 2002, 2003, 2005, 2008  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 3
+# serial 4
 
 
 # _AM_MANGLE_OPTION(NAME)
 # _AM_MANGLE_OPTION(NAME)
 # -----------------------
 # -----------------------
@@ -682,7 +745,7 @@ AC_DEFUN([_AM_SET_OPTION],
 # ----------------------------------
 # ----------------------------------
 # OPTIONS is a space-separated list of Automake options.
 # OPTIONS is a space-separated list of Automake options.
 AC_DEFUN([_AM_SET_OPTIONS],
 AC_DEFUN([_AM_SET_OPTIONS],
-[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
+[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 
 
 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 # -------------------------------------------
 # -------------------------------------------
@@ -718,14 +781,14 @@ AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES])
 
 
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
 
-# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
+# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
 # Free Software Foundation, Inc.
 # Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
-# serial 4
+# serial 5
 
 
 # AM_SANITY_CHECK
 # AM_SANITY_CHECK
 # ---------------
 # ---------------
@@ -734,16 +797,29 @@ AC_DEFUN([AM_SANITY_CHECK],
 # Just in case
 # Just in case
 sleep 1
 sleep 1
 echo timestamp > conftest.file
 echo timestamp > conftest.file
+# Reject unsafe characters in $srcdir or the absolute working directory
+# name.  Accept space and tab only in the latter.
+am_lf='
+'
+case `pwd` in
+  *[[\\\"\#\$\&\'\`$am_lf]]*)
+    AC_MSG_ERROR([unsafe absolute working directory name]);;
+esac
+case $srcdir in
+  *[[\\\"\#\$\&\'\`$am_lf\ \	]]*)
+    AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
+esac
+
 # Do `set' in a subshell so we don't clobber the current shell's
 # Do `set' in a subshell so we don't clobber the current shell's
 # arguments.  Must try -L first in case configure is actually a
 # arguments.  Must try -L first in case configure is actually a
 # symlink; some systems play weird games with the mod time of symlinks
 # symlink; some systems play weird games with the mod time of symlinks
 # (eg FreeBSD returns the mod time of the symlink's containing
 # (eg FreeBSD returns the mod time of the symlink's containing
 # directory).
 # directory).
 if (
 if (
-   set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
+   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
    if test "$[*]" = "X"; then
    if test "$[*]" = "X"; then
       # -L didn't work.
       # -L didn't work.
-      set X `ls -t $srcdir/configure conftest.file`
+      set X `ls -t "$srcdir/configure" conftest.file`
    fi
    fi
    rm -f conftest.file
    rm -f conftest.file
    if test "$[*]" != "X $srcdir/configure conftest.file" \
    if test "$[*]" != "X $srcdir/configure conftest.file" \
@@ -768,6 +844,33 @@ Check your system clock])
 fi
 fi
 AC_MSG_RESULT(yes)])
 AC_MSG_RESULT(yes)])
 
 
+# Copyright (C) 2009  Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# serial 1
+
+# AM_SILENT_RULES([DEFAULT])
+# --------------------------
+# Enable less verbose build rules; with the default set to DEFAULT
+# (`yes' being less verbose, `no' or empty being verbose).
+AC_DEFUN([AM_SILENT_RULES],
+[AC_ARG_ENABLE([silent-rules],
+[  --enable-silent-rules          less verbose build output (undo: `make V=1')
+  --disable-silent-rules         verbose build output (undo: `make V=0')])
+case $enable_silent_rules in
+yes) AM_DEFAULT_VERBOSITY=0;;
+no)  AM_DEFAULT_VERBOSITY=1;;
+*)   AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
+esac
+AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
+AM_BACKSLASH='\'
+AC_SUBST([AM_BACKSLASH])dnl
+_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
+])
+
 # Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
 # Copyright (C) 2001, 2003, 2005  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
@@ -796,18 +899,25 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
 
-# Copyright (C) 2006  Free Software Foundation, Inc.
+# Copyright (C) 2006, 2008  Free Software Foundation, Inc.
 #
 #
 # This file is free software; the Free Software Foundation
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
 
 
+# serial 2
+
 # _AM_SUBST_NOTMAKE(VARIABLE)
 # _AM_SUBST_NOTMAKE(VARIABLE)
 # ---------------------------
 # ---------------------------
 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 # This macro is traced by Automake.
 # This macro is traced by Automake.
 AC_DEFUN([_AM_SUBST_NOTMAKE])
 AC_DEFUN([_AM_SUBST_NOTMAKE])
 
 
+# AM_SUBST_NOTMAKE(VARIABLE)
+# ---------------------------
+# Public sister of _AM_SUBST_NOTMAKE.
+AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
+
 # Check how to create a tarball.                            -*- Autoconf -*-
 # Check how to create a tarball.                            -*- Autoconf -*-
 
 
 # Copyright (C) 2004, 2005  Free Software Foundation, Inc.
 # Copyright (C) 2004, 2005  Free Software Foundation, Inc.

File diff suppressed because it is too large
+ 4288 - 8964
configure


+ 11 - 74
configure.in

@@ -1,6 +1,6 @@
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2010 Alexander Barton <alex@barton.de>
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -33,7 +33,6 @@ AH_TEMPLATE([ZLIB], [Define if zlib compression should be enabled])
 AH_TEMPLATE([TCPWRAP], [Define if TCP wrappers should be used])
 AH_TEMPLATE([TCPWRAP], [Define if TCP wrappers should be used])
 AH_TEMPLATE([IRCPLUS], [Define if IRC+ protocol should be used])
 AH_TEMPLATE([IRCPLUS], [Define if IRC+ protocol should be used])
 AH_TEMPLATE([WANT_IPV6], [Define if IPV6 protocol should be enabled])
 AH_TEMPLATE([WANT_IPV6], [Define if IPV6 protocol should be enabled])
-AH_TEMPLATE([ZEROCONF], [Define if support for Zeroconf should be included])
 AH_TEMPLATE([IDENTAUTH], [Define if the server should do IDENT requests])
 AH_TEMPLATE([IDENTAUTH], [Define if the server should do IDENT requests])
 AH_TEMPLATE([PAM], [Define if PAM should be used])
 AH_TEMPLATE([PAM], [Define if PAM should be used])
 AH_TEMPLATE([HAVE_sockaddr_in_len], [Define if sockaddr_in.sin_len exists])
 AH_TEMPLATE([HAVE_sockaddr_in_len], [Define if sockaddr_in.sin_len exists])
@@ -163,7 +162,7 @@ AC_CHECK_FUNCS([ \
 	bind gethostbyaddr gethostbyname gethostname inet_ntoa \
 	bind gethostbyaddr gethostbyname gethostname inet_ntoa \
 	setsid setsockopt socket strcasecmp waitpid],,AC_MSG_ERROR([required function missing!]))
 	setsid setsockopt socket strcasecmp waitpid],,AC_MSG_ERROR([required function missing!]))
 
 
-AC_CHECK_FUNCS(getaddrinfo getnameinfo inet_aton isdigit sigaction sigprocmask snprintf \
+AC_CHECK_FUNCS(getaddrinfo getnameinfo inet_aton sigaction sigprocmask snprintf \
  vsnprintf strdup strlcpy strlcat strtok_r)
  vsnprintf strdup strlcpy strlcat strtok_r)
 
 
 # -- Configuration options --
 # -- Configuration options --
@@ -411,56 +410,6 @@ int deny_severity = 0;
 	]
 	]
 )
 )
 
 
-# include support for "zeroconf"?
-
-x_zeroconf_on=no
-AC_ARG_WITH(zeroconf,
-	[  --with-zeroconf         enable support for "Zeroconf"],
-	[	if test "$withval" != "no"; then
-			if test "$withval" != "yes"; then
-				CFLAGS="-I$withval/include $CFLAGS"
-				CPPFLAGS="-I$withval/include $CPPFLAGS"
-				LDFLAGS="-L$withval/lib $LDFLAGS"
-			fi
-			AC_CHECK_FUNCS(DNSServiceRegistrationCreate, x_zeroconf_on=osx,
-			[
-				AC_CHECK_LIB(pthread, pthread_mutexattr_init)
-				AC_CHECK_LIB(howl, sw_discovery_init)
-				AC_CHECK_FUNCS(sw_discovery_init, \
-				 x_zeroconf_on=howl, \
-				 AC_MSG_ERROR([Can't enable Zeroconf!]))
-			])
-		fi
-	]
-)
-if test "$x_zeroconf_on" = "osx"; then
-	AC_CHECK_HEADERS([DNSServiceDiscovery/DNSServiceDiscovery.h \
-	 mach/port.h],,AC_MSG_ERROR([required C header missing!]))
-	AC_DEFINE(ZEROCONF, 1)
-fi
-if test "$x_zeroconf_on" = "howl"; then
-	for dir in /usr/local/include /usr/local/include/howl* \
-	 /usr/include /usr/include/howl* \
-	 /usr/local/include/avahi* /usr/include/avahi*; do
-	 	test -d "$dir" || continue
-		AC_MSG_CHECKING([for Howl headers in $dir])
-		if test -f "$dir/rendezvous/rendezvous.h"; then
-			if test "$dir" != "/usr/local/include" -a \
-			 "$dir" != "/usr/include"; then
-				CFLAGS="-I$dir $CFLAGS"
-				CPPFLAGS="-I$dir $CPPFLAGS"
-			fi
-			AC_MSG_RESULT(yes)
-			break
-		else
-			AC_MSG_RESULT(no)
-		fi
-	done
-	AC_CHECK_HEADERS([rendezvous/rendezvous.h],, \
-	 AC_MSG_ERROR([required C header missing!]))
-	AC_DEFINE(ZEROCONF, 1)
-fi
-
 # do IDENT requests using libident?
 # do IDENT requests using libident?
 
 
 x_identauth_on=no
 x_identauth_on=no
@@ -595,6 +544,7 @@ AC_OUTPUT([ \
 	src/testsuite/Makefile \
 	src/testsuite/Makefile \
 	man/Makefile \
 	man/Makefile \
 	contrib/Makefile \
 	contrib/Makefile \
+	contrib/Anope/Makefile \
 	contrib/Debian/Makefile \
 	contrib/Debian/Makefile \
 	contrib/MacOSX/Makefile \
 	contrib/MacOSX/Makefile \
 	contrib/MacOSX/ngIRCd.xcodeproj/Makefile \
 	contrib/MacOSX/ngIRCd.xcodeproj/Makefile \
@@ -663,42 +613,29 @@ test "$x_strict_rfc_on" = "yes" \
 	&& echo "yes" \
 	&& echo "yes" \
 	|| echo "no"
 	|| echo "no"
 
 
-echo $ECHO_N "   Zeroconf support: $ECHO_C"
-case "$x_zeroconf_on" in
-	osx)
-		echo $ECHO_N "Apple $ECHO_C"
-		;;
-	howl)
-		echo $ECHO_N "Howl  $ECHO_C"
-		;;
-	*)
-		echo $ECHO_N "no    $ECHO_C"
-		;;
-esac
+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_N "      IRC+ protocol: $ECHO_C"
 echo $ECHO_N "      IRC+ protocol: $ECHO_C"
 test "$x_ircplus_on" = "yes" \
 test "$x_ircplus_on" = "yes" \
 	&& echo "yes" \
 	&& echo "yes" \
 	|| echo "no"
 	|| echo "no"
 
 
-echo $ECHO_N "      IDENT support: $ECHO_C"
-test "$x_identauth_on" = "yes" \
+echo $ECHO_N "      IPv6 protocol: $ECHO_C"
+test "$x_ipv6_on" = "yes" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	|| echo $ECHO_N "no    $ECHO_C"
 	|| echo $ECHO_N "no    $ECHO_C"
 echo $ECHO_N "        I/O backend: $ECHO_C"
 echo $ECHO_N "        I/O backend: $ECHO_C"
 	echo "\"$x_io_backend\""
 	echo "\"$x_io_backend\""
 
 
-echo $ECHO_N "      IPv6 protocol: $ECHO_C"
-test "$x_ipv6_on" = "yes" \
+echo $ECHO_N "        PAM support: $ECHO_C"
+test "$x_pam_on" = "yes" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	&& echo $ECHO_N "yes   $ECHO_C" \
 	|| echo $ECHO_N "no    $ECHO_C"
 	|| echo $ECHO_N "no    $ECHO_C"
 echo $ECHO_N "        SSL support: $ECHO_C"
 echo $ECHO_N "        SSL support: $ECHO_C"
 echo "$x_ssl_lib"
 echo "$x_ssl_lib"
 
 
-echo $ECHO_N "        PAM support: $ECHO_C"
-test "$x_pam_on" = "yes" \
-	&& echo "yes" \
-	|| echo "no"
-
 echo
 echo
 
 
 # -eof-
 # -eof-

+ 496 - 0
contrib/Anope/0001-Revert-Removed-ngircd.patch

@@ -0,0 +1,496 @@
+From bc5023fdba8091ab7eee29fe0deeca6843159743 Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Mon, 16 May 2011 18:23:01 +0200
+Subject: [PATCH 1/2] Revert "Removed ngircd as we've decided not to support it at this time"
+
+This reverts commit 605b5d57171d2f0fac56ee2ee3e1b1bbdadeb24f and re-enables
+the ngIRCd protocol module for Anope.
+---
+ modules/protocol/ngircd.cpp |  475 +++++++++++++++++++++++++++++++++++++++++++
+ 1 files changed, 475 insertions(+), 0 deletions(-)
+ create mode 100644 modules/protocol/ngircd.cpp
+
+diff --git a/modules/protocol/ngircd.cpp b/modules/protocol/ngircd.cpp
+new file mode 100644
+index 0000000..6e1f21f
+--- /dev/null
++++ b/modules/protocol/ngircd.cpp
+@@ -0,0 +1,475 @@
++/* ngIRCd IRCD functions
++ *
++ * (C) 2003-2011 Anope Team
++ * Contact us at team@anope.org
++ *
++ * Please read COPYING and README for further details.
++ *
++ * Based on the original code of Epona by Lara.
++ * Based on the original code of Services by Andy Church.
++ */
++
++#include "services.h"
++#include "modules.h"
++
++IRCDVar myIrcd[] = {
++	{"ngIRCd",	/* ircd name */
++	 "+oi",		/* Modes used by pseudoclients */
++	 0,		/* SVSNICK */
++	 0,		/* Vhost */
++	 0,		/* Supports SNlines */
++	 0,		/* Supports SQlines */
++	 0,		/* Supports SZlines */
++	 0,		/* Join 2 Message */
++	 0,		/* Chan SQlines */
++	 1,		/* Quit on Kill */
++	 0,		/* vidents */
++	 0,		/* svshold */
++	 0,		/* time stamp on mode */
++	 0,		/* UMODE */
++	 0,		/* O:LINE */
++	 0,		/* No Knock requires +i */
++	 0,		/* Can remove User Channel Modes with SVSMODE */
++	 0,		/* Sglines are not enforced until user reconnects */
++	 0,		/* ts6 */
++	 "$",		/* TLD Prefix for Global */
++	 20,		/* Max number of modes we can send per line */
++	 0,		/* IRCd sends a SSL users certificate fingerprint */
++	 }
++	,
++	{NULL}
++};
++
++/* PASS */
++class ngIRCdProto : public IRCDProto
++{
++	void SendAkill(User *u, const XLine *x)
++	{
++		if (SGLine && u == NULL)
++			for (Anope::insensitive_map<User *>::iterator it = UserListByNick.begin(); it != UserListByNick.end();)
++			{
++				u = it->second;
++				++it;
++				if (SGLine->Check(u) != NULL)
++					break;
++			}
++	}
++
++	void SendAkillDel(const XLine*) { }
++
++	void SendGlobopsInternal(const BotInfo *source, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->ServerName, "WALLOPS :%s", buf.c_str());
++	}
++
++	void SendJoin(BotInfo *user, Channel *c, const ChannelStatus *status)
++	{
++		send_cmd(user->nick, "JOIN %s", c->name.c_str());
++		if (status)
++			for (unsigned i = 0; i < ModeManager::ChannelModes.size(); ++i)
++				if (status->HasFlag(ModeManager::ChannelModes[i]->Name))
++					c->SetMode(user, ModeManager::ChannelModes[i], user->nick, false);
++	}
++
++	void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->ServerName, "KILL %s :%s", user->nick.c_str(), buf.c_str());
++	}
++
++	/* SERVER name hop descript */
++	void SendServer(const Server *server)
++	{
++		send_cmd("", "SERVER %s %d :%s", server->GetName().c_str(), server->GetHops(), server->GetDescription().c_str());
++	}
++
++	void SendConnect()
++	{
++		send_cmd("", "PASS %s 0210-IRC+ Anope|%s:CLHSo P", uplink_server->password.c_str(), Anope::VersionShort().c_str());
++		/* Make myself known to myself in the serverlist */
++		SendServer(Me);
++		/* finish the enhanced server handshake and register the connection */
++		this->SendNumeric(Config->ServerName, 376, "*", ":End of MOTD command");
++	}
++
++	// Received: :dev.anope.de NICK DukeP 1 ~DukePyro p57ABF9C9.dip.t-dialin.net 1 +i :DukePyrolator
++	void SendClientIntroduction(const User *u, const Anope::string &modes)
++	{
++		EnforceQlinedNick(u->nick, "");
++		send_cmd(Config->ServerName, "NICK %s 1 %s %s 1 %s :%s", u->nick.c_str(), u->GetIdent().c_str(), u->host.c_str(), modes.c_str(), u->realname.c_str());
++	}
++
++	void SendPartInternal(const BotInfo *bi, const Channel *chan, const Anope::string &buf)
++	{
++		if (!buf.empty())
++			send_cmd(bi->nick, "PART %s :%s", chan->name.c_str(), buf.c_str());
++		else
++			send_cmd(bi->nick, "PART %s", chan->name.c_str());
++	}
++
++	void SendModeInternal(const BotInfo *bi, const Channel *dest, const Anope::string &buf)
++	{
++		send_cmd(bi ? bi->nick : Config->ServerName, "MODE %s %s", dest->name.c_str(), buf.c_str());
++	}
++
++	void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf)
++	{
++		send_cmd(bi ? bi->nick : Config->ServerName, "MODE %s %s", u->nick.c_str(), buf.c_str());
++	}
++
++	void SendKickInternal(const BotInfo *bi, const Channel *chan, const User *user, const Anope::string &buf)
++	{
++		if (!buf.empty())
++			send_cmd(bi->nick, "KICK %s %s :%s", chan->name.c_str(), user->nick.c_str(), buf.c_str());
++		else
++			send_cmd(bi->nick, "KICK %s %s", chan->name.c_str(), user->nick.c_str());
++	}
++
++	void SendNoticeChanopsInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf)
++	{
++		send_cmd(source ? source->nick : Config->s_ChanServ, "NOTICE @%s :%s", dest->name.c_str(), buf.c_str());
++	}
++
++	/* INVITE */
++	void SendInvite(BotInfo *source, const Anope::string &chan, const Anope::string &nick)
++	{
++		send_cmd(source->nick, "INVITE %s %s", nick.c_str(), chan.c_str());
++	}
++
++	void SendChannel(Channel *c)
++	{
++		Anope::string mlock_modes = get_mlock_modes(c->ci, true);
++		if (mlock_modes.empty())
++			mlock_modes = "+";
++		send_cmd(Config->ServerName, "CHANINFO %s %s", c->name.c_str(), mlock_modes.c_str());
++	}
++	void SendTopic(BotInfo *bi, Channel *c)
++	{
++		send_cmd(bi->nick, "TOPIC %s :%s", c->name.c_str(), c->topic.c_str());
++	}
++};
++
++class ngIRCdIRCdMessage : public IRCdMessage
++{
++ public:
++	bool OnSJoin(const Anope::string&, const std::vector<Anope::string>&) { return false; }
++
++	/*
++	 * Received: :dev.anope.de MODE #anope +b *!*@*aol*
++	 */
++	bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() < 2)
++			return true;
++
++		Anope::string modes = params[1];
++		for (unsigned i = 2; i < params.size(); ++i)
++			modes += " " + params[i];
++
++		if (params[0][0] == '#' || params[0][0] == '&')
++			do_cmode(source, params[0], modes, "");
++		else
++			do_umode(params[0], params[1]);
++
++		return true;
++	}
++
++	/*
++	  Received: :DukeP_ NICK :test2
++	  Received: :dev.anope.de NICK DukeP_ 1 ~DukePyro ip-2-201-236-154.web.vodafone.de 1 + :DukePyrolator
++	  source = nickname on nickchange, servername on newuser
++	  params[0] = nick
++	  params[1] = <unknown>
++	  params[2] = username
++	  params[3] = host
++	  params[4] = <unknown>
++	  params[5] = modes
++	  params[6] = info
++	*/
++	bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() == 1)
++		{
++			// we have a nickchange
++			do_nick(source, params[0], "", "", "", "", Anope::CurTime, "", "", "", "");
++		}
++		else if (params.size() == 7)
++		{
++			// a new user is connecting to the network
++			User *user = do_nick("", params[0], params[2], params[3], source, params[6], Anope::CurTime, "", "", "", params[5]);
++			if (user)
++				validate_user(user);
++		}
++		else
++		{
++			Log() << "Received NICK with invalid number of parameters. source = " << source << "param[0] = " << params[0] << "params.size() = " << params.size();
++		}
++		return true;
++	}
++
++	bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (params.size() == 3)
++			do_server("", params[0], 0, params[2], params[1]);
++		else
++			do_server(source, params[0], params[1].is_pos_number_only() ? convertTo<unsigned>(params[1]) : 0, params[3], params[2]);
++		return true;
++	}
++
++	bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		Channel *c = findchan(params[0]);
++		if (!c)
++		{
++			Log() << "TOPIC for nonexistant channel " << params[0];
++			return true;
++		}
++
++		c->ChangeTopicInternal(source, params[1]);
++		return true;
++	}
++
++	/*
++	 * <@po||ux> DukeP: RFC 2813, 4.2.1: the JOIN command on server-server links
++	 * separates the modes ("o") with ASCII 7, not space. And you can't see ASCII 7.
++	 *
++	 * if a user joins a new channel, the ircd sends <channelname>\7<umode>
++	 */
++	bool OnJoin (const Anope::string &source, const std::vector<Anope::string> &params)
++	{
++		if (!params.empty())
++		{
++			size_t pos = params[0].find('\7');
++			if (pos != Anope::string::npos)
++			{
++				Anope::string channel = params[0].substr(0, pos);
++				Anope::string mode = '+' + params[0].substr(pos, params[0].length()) + " " + source;
++				do_join(source, channel, "");
++				do_cmode(source, channel, mode, "");
++			}
++			else
++				do_join(source, params[0], "");
++		}
++		return true;
++	}
++};
++
++/*
++ * CHANINFO <chan> +<modes>
++ * CHANINFO <chan> +<modes> :<topic>
++ * CHANINFO <chan> +<modes> <key> <limit> :<topic>
++ */
++bool event_chaninfo(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++
++	Channel *c = findchan(params[0]);
++	if (!c)
++		c = new Channel(params[0]);
++
++	Anope::string modes = params[1];
++	
++	if (params.size() == 3)
++	{
++		c->ChangeTopicInternal(source, params[2], Anope::CurTime);
++	} 
++	else if (params.size() == 5)
++	{
++		for (size_t i = 0, end = params[1].length(); i < end; ++i)
++		{
++			switch(params[1][i])
++			{
++				case 'k':
++					modes += " " + params[2];
++					continue;
++				case 'l':
++					modes += " " + params[3];
++					continue;
++			}
++		}
++		c->ChangeTopicInternal(source, params[4], Anope::CurTime);
++	}
++
++	c->SetModesInternal(NULL, modes);
++
++	return true;
++}
++
++/*
++ * Received: :dev.anope.de NJOIN #test :DukeP2,@DukeP
++ */
++bool event_njoin(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	Channel *c = findchan(params[0]);
++	commasepstream sep(params[1]);
++	Anope::string buf;
++
++	if (!c)
++	{
++		c = new Channel(params[0], Anope::CurTime);
++		c->SetFlag(CH_SYNCING);
++	}
++	
++	while (sep.GetToken(buf))
++	{
++		std::list<ChannelMode *> Status;
++		char ch;
++
++		/* Get prefixes from the nick */
++		while ((ch = ModeManager::GetStatusChar(buf[0])))
++		{
++			buf.erase(buf.begin());
++			ChannelMode *cm = ModeManager::FindChannelModeByChar(ch);
++			if (!cm)
++			{
++				Log() << "Received unknown mode prefix " << ch << " in NJOIN string.";
++				continue;
++			}
++			Status.push_back(cm);
++		}
++		User *u = finduser(buf);
++		if (!u)
++		{
++			Log(LOG_DEBUG) << "NJOIN for nonexistant user " << buf << " on " << c->name;
++			continue;
++		}
++
++		EventReturn MOD_RESULT;
++		FOREACH_RESULT(I_OnPreJoinChannel, OnPreJoinChannel(u, c));
++
++		/* Add the user to the Channel */
++		c->JoinUser(u);
++
++		/* Update their status internally on the channel
++		 * This will enforce secureops etc on the user
++		 */
++		for (std::list<ChannelMode *>::iterator it = Status.begin(), it_end = Status.end(); it != it_end; ++it)
++			c->SetModeInternal(*it, buf);
++		/* Now set whatever modes this user is allowed to have on the channel */
++		chan_set_correct_modes(u, c, 1);
++
++		/* Check to see if modules want the user to join, if they do
++		 * check to see if they are allowed to join (CheckKick will kick/ban them)
++		 * Don't trigger OnJoinChannel event then as the user will be destroyed
++		 */
++		if (MOD_RESULT != EVENT_STOP && c->ci && c->ci->CheckKick(u))
++			continue;
++
++		FOREACH_MOD(I_OnJoinChannel, OnJoinChannel(u, c));
++	} /* while */
++
++	if (c->HasFlag(CH_SYNCING))
++	{
++		c->UnsetFlag(CH_SYNCING);
++		c->Sync();
++	}
++
++	return true;
++}
++
++bool event_kick(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	if (params.size() > 2)
++		do_kick(source, params[0], params[1], params[2]);
++	return true;
++}
++
++bool event_pass(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++bool event_005(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	size_t pos;
++	Anope::string name, data;
++	for (unsigned i = 0, end = params.size(); i < end; ++i)
++	{
++		pos = params[i].find('=');
++		if (pos != Anope::string::npos)
++		{
++			name = params[i].substr(0, pos);
++			data = params[i].substr(pos+1, params[i].length());
++			if (name == "NICKLEN")
++			{
++				unsigned newlen = convertTo<unsigned>(data);
++				if (Config->NickLen != newlen)
++				{
++					Log() << "Config->NickLen changed from " << Config->NickLen << " to " << newlen;
++					Config->NickLen = newlen;
++				}
++			}
++		}
++	}
++	return true;
++}
++
++bool event_442(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++bool event_376(const Anope::string &source, const std::vector<Anope::string> &params)
++{
++	return true;
++}
++
++
++class ProtongIRCd : public Module
++{
++	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005, 
++		message_442, message_376;
++	
++	ngIRCdProto ircd_proto;
++	ngIRCdIRCdMessage ircd_message;
++
++	void AddModes()
++	{
++		/* Add user modes */
++		ModeManager::AddUserMode(new UserMode(UMODE_ADMIN, 'a'));
++		ModeManager::AddUserMode(new UserMode(UMODE_INVIS, 'i'));
++		ModeManager::AddUserMode(new UserMode(UMODE_OPER, 'o'));
++		ModeManager::AddUserMode(new UserMode(UMODE_RESTRICTED, 'r'));
++		ModeManager::AddUserMode(new UserMode(UMODE_SNOMASK, 's'));
++		ModeManager::AddUserMode(new UserMode(UMODE_WALLOPS, 'w'));
++		ModeManager::AddUserMode(new UserMode(UMODE_CLOAK, 'x'));
++
++		/* b/e/I */
++		ModeManager::AddChannelMode(new ChannelModeBan(CMODE_BAN, 'b'));
++		ModeManager::AddChannelMode(new ChannelModeList(CMODE_INVITEOVERRIDE, 'I'));
++
++		/* v/h/o/a/q */
++		ModeManager::AddChannelMode(new ChannelModeStatus(CMODE_VOICE, 'v', '+'));
++		ModeManager::AddChannelMode(new ChannelModeStatus(CMODE_OP, 'o', '@'));
++
++		/* Add channel modes */
++		// channel modes: biIklmnoPstvz
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_INVITE, 'i'));
++		ModeManager::AddChannelMode(new ChannelModeKey('k'));
++		ModeManager::AddChannelMode(new ChannelModeParam(CMODE_LIMIT, 'l'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_MODERATED, 'm'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_NOEXTERNAL, 'n'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_PERM, 'P'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_SECRET, 's'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_TOPIC, 't'));
++		ModeManager::AddChannelMode(new ChannelMode(CMODE_SSL, 'z'));
++	}
++
++ public:
++	ProtongIRCd(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator),
++		message_kick("KICK", event_kick), message_pass("PASS", event_pass),
++		message_njoin("NJOIN", event_njoin), message_chaninfo("CHANINFO", event_chaninfo),
++		message_005("005", event_005), message_442("442", event_442), message_376("376", event_376)
++	{
++		this->SetAuthor("Anope");
++		this->SetType(PROTOCOL);
++		
++		Capab.SetFlag(CAPAB_QS);
++
++		pmodule_ircd_var(myIrcd);
++		pmodule_ircd_proto(&this->ircd_proto);
++		pmodule_ircd_message(&this->ircd_message);
++
++		this->AddModes();
++	}
++};
++
++MODULE_INIT(ProtongIRCd)
+-- 
+1.7.2.5
+

+ 60 - 0
contrib/Anope/0002-ngircd-whitespace-fixes.patch

@@ -0,0 +1,60 @@
+From 1ea1dd2095e63cef34edbebb729edc687f410a96 Mon Sep 17 00:00:00 2001
+From: Alexander Barton <alex@barton.de>
+Date: Mon, 16 May 2011 18:26:56 +0200
+Subject: [PATCH 2/2] ngircd: whitespace fixes
+
+---
+ modules/protocol/ngircd.cpp |   12 ++++++------
+ 1 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/modules/protocol/ngircd.cpp b/modules/protocol/ngircd.cpp
+index 6e1f21f..e546d05 100644
+--- a/modules/protocol/ngircd.cpp
++++ b/modules/protocol/ngircd.cpp
+@@ -266,11 +266,11 @@ bool event_chaninfo(const Anope::string &source, const std::vector<Anope::string
+ 		c = new Channel(params[0]);
+ 
+ 	Anope::string modes = params[1];
+-	
++
+ 	if (params.size() == 3)
+ 	{
+ 		c->ChangeTopicInternal(source, params[2], Anope::CurTime);
+-	} 
++	}
+ 	else if (params.size() == 5)
+ 	{
+ 		for (size_t i = 0, end = params[1].length(); i < end; ++i)
+@@ -307,7 +307,7 @@ bool event_njoin(const Anope::string &source, const std::vector<Anope::string> &
+ 		c = new Channel(params[0], Anope::CurTime);
+ 		c->SetFlag(CH_SYNCING);
+ 	}
+-	
++
+ 	while (sep.GetToken(buf))
+ 	{
+ 		std::list<ChannelMode *> Status;
+@@ -415,9 +415,9 @@ bool event_376(const Anope::string &source, const std::vector<Anope::string> &pa
+ 
+ class ProtongIRCd : public Module
+ {
+-	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005, 
++	Message message_kick, message_pass, message_njoin, message_chaninfo, message_005,
+ 		message_442, message_376;
+-	
++
+ 	ngIRCdProto ircd_proto;
+ 	ngIRCdIRCdMessage ircd_message;
+ 
+@@ -461,7 +461,7 @@ class ProtongIRCd : public Module
+ 	{
+ 		this->SetAuthor("Anope");
+ 		this->SetType(PROTOCOL);
+-		
++
+ 		Capab.SetFlag(CAPAB_QS);
+ 
+ 		pmodule_ircd_var(myIrcd);
+-- 
+1.7.2.5
+

+ 20 - 0
contrib/Anope/Makefile.am

@@ -0,0 +1,20 @@
+#
+# ngIRCd -- The Next Generation IRC Daemon
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
+#
+# 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.
+#
+
+EXTRA_DIST = \
+	README \
+	0001-Revert-Removed-ngircd.patch \
+	0002-ngircd-whitespace-fixes.patch
+
+maintainer-clean-local:
+	rm -f Makefile Makefile.in
+
+# -eof-

+ 361 - 0
contrib/Anope/Makefile.in

@@ -0,0 +1,361 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+#
+# ngIRCd -- The Next Generation IRC Daemon
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
+#
+# 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.
+#
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = contrib/Anope
+DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+	$(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/src/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LDFLAGS = @LDFLAGS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAKEINFO = @MAKEINFO@
+MKDIR_P = @MKDIR_P@
+OBJEXT = @OBJEXT@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+RANLIB = @RANLIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+U = @U@
+VERSION = @VERSION@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+	README \
+	0001-Revert-Removed-ngircd.patch \
+	0002-ngircd-whitespace-fixes.patch
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
+	@for dep in $?; do \
+	  case '$(am__configure_deps)' in \
+	    *$$dep*) \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
+	      exit 1;; \
+	  esac; \
+	done; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/Anope/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/Anope/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+	@case '$?' in \
+	  *config.status*) \
+	    cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+	  *) \
+	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+	esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure:  $(am__configure_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4):  $(am__aclocal_m4_deps)
+	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+	list='$(DISTFILES)'; \
+	  dist_files=`for file in $$list; do echo $$file; done | \
+	  sed -e "s|^$$srcdirstrip/||;t" \
+	      -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+	case $$dist_files in \
+	  */*) $(MKDIR_P) `echo "$$dist_files" | \
+			   sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+			   sort -u` ;; \
+	esac; \
+	for file in $$dist_files; do \
+	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+	  if test -d $$d/$$file; then \
+	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+	  else \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
+	    || exit 1; \
+	  fi; \
+	done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+	$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+	  install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+	  `test -z '$(STRIP)' || \
+	    echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+	@echo "This command is intended for maintainers to use"
+	@echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic mostlyclean-am
+
+distclean: distclean-am
+	-rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+	-rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic \
+	maintainer-clean-local
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic distclean \
+	distclean-generic distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-pdf install-pdf-am install-ps install-ps-am \
+	install-strip installcheck installcheck-am installdirs \
+	maintainer-clean maintainer-clean-generic \
+	maintainer-clean-local mostlyclean mostlyclean-generic pdf \
+	pdf-am ps ps-am uninstall uninstall-am
+
+
+maintainer-clean-local:
+	rm -f Makefile Makefile.in
+
+# -eof-
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:

+ 36 - 0
contrib/Anope/README

@@ -0,0 +1,36 @@
+
+                     ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
+
+               (c)2001-2011 Alexander Barton and Contributors.
+               ngIRCd is free software and published under the
+                   terms of the GNU General Public License.
+
+                          -- contrib/Anope/README --
+
+
+This directory contains two preliminary patches that (re-) add a ngIRCd
+protocol module to the Anope 1.9 development branch. It has been tested
+with Anope 1.9.4, there is no guarantee that it will work with other
+versions as Anope 1.9.x is under heavy development ...
+
+To build this Anope protocol module, you have to
+
+ - Download the Anope 1.9.x sources (tested with 1.9.4),
+ - Patch in the ngIRCd protocol module,
+ - Build and install Anope as usual,
+ - Configure Anope as usual, use "ngircd" as protocol module.
+
+So the command sequence can be something like this:
+
+ $ tar xzf anope-1.9.4-source.tar.gz
+ $ cd anope-1.9.4-source
+ $ patch -p1 < .../ngircd/contrib/Anope/0001-Revert-Removed-ngircd.patch
+ $ patch -p1 < .../ngircd/contrib/Anope/0002-ngircd-whitespace-fixes.patch
+ $ ./Config
+ $ cd build
+ $ make
+ $ make install
+
+Please have a look at the file doc/Services.txt for more information about
+how to set up ngIRCd and Anope.

+ 43 - 12
contrib/Debian/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,11 +54,19 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -93,6 +103,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -152,6 +163,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 EXTRA_DIST = rules changelog compat control copyright \
 EXTRA_DIST = rules changelog compat control copyright \
@@ -164,14 +176,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  contrib/Debian/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  contrib/Debian/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/Debian/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/Debian/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -189,6 +201,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 tags: TAGS
 tags: TAGS
 TAGS:
 TAGS:
 
 
@@ -212,13 +225,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -246,6 +263,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -264,6 +282,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -272,18 +292,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -334,6 +364,7 @@ clean-local:
 	rm -f files
 	rm -f files
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 18 - 0
contrib/Debian/changelog

@@ -1,3 +1,21 @@
+ngircd (18-0ab1) unstable; urgency=low
+
+  * New "upstream" release: ngIRCd 18.
+
+ -- Alexander Barton <alex@barton.de>  Sun, 10 Jul 2011 20:03:20 +0200
+
+ngircd (18~rc2-0ab1) unstable; urgency=low
+
+  * New "upstream" release candidate 2 for ngIRCd Release 18.
+
+ -- Alexander Barton <alex@barton.de>  Wed, 29 Jun 2011 10:20:51 +0200
+
+ngircd (18~rc1-0ab1) unstable; urgency=low
+
+  * New "upstream" release candidate 1 for ngIRCd Release 18.
+
+ -- Alexander Barton <alex@barton.de>  Mon, 27 Jun 2011 22:58:36 +0200
+
 ngircd (17.1-0ab1) unstable; urgency=low
 ngircd (17.1-0ab1) unstable; urgency=low
 
 
   * New "upstream" release: ngIRCd 17.1.
   * New "upstream" release: ngIRCd 17.1.

+ 112 - 37
contrib/MacOSX/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,6 +54,13 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -63,12 +72,41 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -105,6 +143,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -164,6 +203,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 SUBDIRS = ngIRCd.xcodeproj ngIRCd.pmdoc
 SUBDIRS = ngIRCd.xcodeproj ngIRCd.pmdoc
@@ -177,14 +217,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  contrib/MacOSX/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  contrib/MacOSX/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/MacOSX/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/MacOSX/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -202,6 +242,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 
 
 # This directory's subdirectories are mostly independent; you can cd
 # This directory's subdirectories are mostly independent; you can cd
 # into them and run `make' without going through this Makefile.
 # into them and run `make' without going through this Makefile.
@@ -210,7 +251,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 #     (which will cause the Makefiles to be regenerated when you run `make');
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -227,7 +268,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
 	if test "$$dot_seen" = "no"; then \
@@ -235,7 +276,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 	fi; test -z "$$fail"
 
 
 $(RECURSIVE_CLEAN_TARGETS):
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -261,16 +302,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 	done && test -z "$$fail"
 tags-recursive:
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 	done
 ctags-recursive:
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 	done
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -278,14 +319,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
 	  include_option=--etags-include; \
@@ -297,7 +338,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	  fi; \
 	done; \
 	done; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
@@ -306,29 +347,34 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -349,29 +395,44 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	        distdir) \
 	      || exit 1; \
 	      || exit 1; \
 	  fi; \
 	  fi; \
@@ -401,6 +462,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -419,6 +481,8 @@ dvi-am:
 
 
 html: html-recursive
 html: html-recursive
 
 
+html-am:
+
 info: info-recursive
 info: info-recursive
 
 
 info-am:
 info-am:
@@ -427,18 +491,28 @@ install-data-am: install-data-local
 
 
 install-dvi: install-dvi-recursive
 install-dvi: install-dvi-recursive
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-recursive
 install-html: install-html-recursive
 
 
+install-html-am:
+
 install-info: install-info-recursive
 install-info: install-info-recursive
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-recursive
 install-pdf: install-pdf-recursive
 
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 install-ps: install-ps-recursive
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-recursive
 maintainer-clean: maintainer-clean-recursive
@@ -460,8 +534,8 @@ ps-am:
 
 
 uninstall-am:
 uninstall-am:
 
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+	install-am install-strip tags-recursive
 
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am check check-am clean clean-generic clean-local \
 	all all-am check check-am clean clean-generic clean-local \
@@ -513,6 +587,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 0 - 10
contrib/MacOSX/config.h

@@ -42,9 +42,6 @@
 /* Define if TCP wrappers should be used */
 /* Define if TCP wrappers should be used */
 /*#define TCPWRAP 1*/
 /*#define TCPWRAP 1*/
 
 
-/* Define if support for Zeroconf should be included */
-/*#define ZEROCONF 1*/
-
 /* Define if zlib compression should be enabled */
 /* Define if zlib compression should be enabled */
 #define ZLIB 1
 #define ZLIB 1
 
 
@@ -103,13 +100,6 @@
 /* Define if socklen_t exists */
 /* Define if socklen_t exists */
 #define HAVE_socklen_t 1
 #define HAVE_socklen_t 1
 
 
-#ifdef ZEROCONF
-/* Define to 1 if you have the <DNSServiceDiscovery/DNSServiceDiscovery.h> header file. */
-#define HAVE_DNSSERVICEDISCOVERY_DNSSERVICEDISCOVERY_H 1
-/* Define to 1 if you have the `DNSServiceRegistrationCreate' function. */
-#define HAVE_DNSSERVICEREGISTRATIONCREATE 1
-#endif
-
 #ifdef PAM
 #ifdef PAM
 /* Define to 1 if you have the `pam_authenticate' function. */
 /* Define to 1 if you have the `pam_authenticate' function. */
 #define HAVE_PAM_AUTHENTICATE 1
 #define HAVE_PAM_AUTHENTICATE 1

File diff suppressed because it is too large
+ 1 - 1
contrib/MacOSX/ngIRCd.pmdoc/01ngircd-contents.xml


File diff suppressed because it is too large
+ 1 - 1
contrib/MacOSX/ngIRCd.pmdoc/01ngircd.xml


+ 1 - 1
contrib/MacOSX/ngIRCd.pmdoc/02de-contents.xml

@@ -1 +1 @@
-<pkg-contents spec="1.12"/>
+<pkg-contents spec="1.12"><f n="de.barton.ngircd.plist" o="root" g="wheel" p="33188" pt="/Users/alex/Develop/ngircd/alex.git/contrib/MacOSX/de.barton.ngircd.plist" m="false" t="file"><mod>group</mod><mod>owner</mod></f></pkg-contents>

File diff suppressed because it is too large
+ 1 - 1
contrib/MacOSX/ngIRCd.pmdoc/02de.xml


+ 43 - 12
contrib/MacOSX/ngIRCd.pmdoc/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,11 +54,19 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -93,6 +103,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -152,6 +163,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 EXTRA_DIST = index.xml \
 EXTRA_DIST = index.xml \
@@ -164,14 +176,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  contrib/MacOSX/ngIRCd.pmdoc/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  contrib/MacOSX/ngIRCd.pmdoc/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/MacOSX/ngIRCd.pmdoc/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/MacOSX/ngIRCd.pmdoc/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -189,6 +201,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 tags: TAGS
 tags: TAGS
 TAGS:
 TAGS:
 
 
@@ -212,13 +225,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -246,6 +263,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -264,6 +282,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -272,18 +292,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -323,6 +353,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

File diff suppressed because it is too large
+ 70 - 22
contrib/MacOSX/ngIRCd.pmdoc/index.xml


+ 43 - 12
contrib/MacOSX/ngIRCd.xcodeproj/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,11 +54,19 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -93,6 +103,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -152,6 +163,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 EXTRA_DIST = project.pbxproj
 EXTRA_DIST = project.pbxproj
@@ -162,14 +174,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  contrib/MacOSX/ngIRCd.xcodeproj/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  contrib/MacOSX/ngIRCd.xcodeproj/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/MacOSX/ngIRCd.xcodeproj/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/MacOSX/ngIRCd.xcodeproj/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -187,6 +199,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 tags: TAGS
 tags: TAGS
 TAGS:
 TAGS:
 
 
@@ -210,13 +223,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -244,6 +261,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -262,6 +280,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -270,18 +290,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -321,6 +351,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 3 - 11
contrib/MacOSX/ngIRCd.xcodeproj/project.pbxproj

@@ -32,7 +32,6 @@
 		FA322D490CEF74B1001761B3 /* match.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D030CEF74B1001761B3 /* match.c */; };
 		FA322D490CEF74B1001761B3 /* match.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D030CEF74B1001761B3 /* match.c */; };
 		FA322D4A0CEF74B1001761B3 /* ngircd.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D060CEF74B1001761B3 /* ngircd.c */; };
 		FA322D4A0CEF74B1001761B3 /* ngircd.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D060CEF74B1001761B3 /* ngircd.c */; };
 		FA322D4B0CEF74B1001761B3 /* parse.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D080CEF74B1001761B3 /* parse.c */; };
 		FA322D4B0CEF74B1001761B3 /* parse.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D080CEF74B1001761B3 /* parse.c */; };
-		FA322D4C0CEF74B1001761B3 /* rendezvous.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D0A0CEF74B1001761B3 /* rendezvous.c */; };
 		FA322D4D0CEF74B1001761B3 /* resolve.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D0C0CEF74B1001761B3 /* resolve.c */; };
 		FA322D4D0CEF74B1001761B3 /* resolve.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D0C0CEF74B1001761B3 /* resolve.c */; };
 		FA322DBE0CEF7766001761B3 /* tool.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D330CEF74B1001761B3 /* tool.c */; };
 		FA322DBE0CEF7766001761B3 /* tool.c in Sources */ = {isa = PBXBuildFile; fileRef = FA322D330CEF74B1001761B3 /* tool.c */; };
 		FA322DC10CEF77CB001761B3 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = FA322DC00CEF77CB001761B3 /* libz.dylib */; };
 		FA322DC10CEF77CB001761B3 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = FA322DC00CEF77CB001761B3 /* libz.dylib */; };
@@ -113,8 +112,6 @@
 		FA322D070CEF74B1001761B3 /* ngircd.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = ngircd.h; sourceTree = "<group>"; };
 		FA322D070CEF74B1001761B3 /* ngircd.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = ngircd.h; sourceTree = "<group>"; };
 		FA322D080CEF74B1001761B3 /* parse.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = parse.c; sourceTree = "<group>"; };
 		FA322D080CEF74B1001761B3 /* parse.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = parse.c; sourceTree = "<group>"; };
 		FA322D090CEF74B1001761B3 /* parse.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = parse.h; sourceTree = "<group>"; };
 		FA322D090CEF74B1001761B3 /* parse.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = parse.h; sourceTree = "<group>"; };
-		FA322D0A0CEF74B1001761B3 /* rendezvous.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = rendezvous.c; sourceTree = "<group>"; };
-		FA322D0B0CEF74B1001761B3 /* rendezvous.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = rendezvous.h; sourceTree = "<group>"; };
 		FA322D0C0CEF74B1001761B3 /* resolve.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = resolve.c; sourceTree = "<group>"; };
 		FA322D0C0CEF74B1001761B3 /* resolve.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = resolve.c; sourceTree = "<group>"; };
 		FA322D0D0CEF74B1001761B3 /* resolve.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = resolve.h; sourceTree = "<group>"; };
 		FA322D0D0CEF74B1001761B3 /* resolve.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = resolve.h; sourceTree = "<group>"; };
 		FA322D100CEF74B1001761B3 /* ansi2knr.1 */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.man; path = ansi2knr.1; sourceTree = "<group>"; };
 		FA322D100CEF74B1001761B3 /* ansi2knr.1 */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.man; path = ansi2knr.1; sourceTree = "<group>"; };
@@ -184,14 +181,12 @@
 		FA322D9E0CEF752C001761B3 /* README-AUX.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "README-AUX.txt"; sourceTree = "<group>"; };
 		FA322D9E0CEF752C001761B3 /* README-AUX.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "README-AUX.txt"; sourceTree = "<group>"; };
 		FA322D9F0CEF752C001761B3 /* README-BeOS.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "README-BeOS.txt"; sourceTree = "<group>"; };
 		FA322D9F0CEF752C001761B3 /* README-BeOS.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "README-BeOS.txt"; sourceTree = "<group>"; };
 		FA322DA00CEF752C001761B3 /* RFC.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = RFC.txt; sourceTree = "<group>"; };
 		FA322DA00CEF752C001761B3 /* RFC.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = RFC.txt; sourceTree = "<group>"; };
-		FA322DA10CEF752C001761B3 /* sample-ngircd.conf */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = "sample-ngircd.conf"; sourceTree = "<group>"; };
 		FA322DA40CEF752C001761B3 /* Doxyfile */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Doxyfile; sourceTree = "<group>"; };
 		FA322DA40CEF752C001761B3 /* Doxyfile */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Doxyfile; sourceTree = "<group>"; };
 		FA322DA50CEF752C001761B3 /* footer.inc.html */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.html; path = footer.inc.html; sourceTree = "<group>"; };
 		FA322DA50CEF752C001761B3 /* footer.inc.html */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.html; path = footer.inc.html; sourceTree = "<group>"; };
 		FA322DA60CEF752C001761B3 /* header.inc.html */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.html; path = header.inc.html; sourceTree = "<group>"; };
 		FA322DA60CEF752C001761B3 /* header.inc.html */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.html; path = header.inc.html; sourceTree = "<group>"; };
 		FA322DA70CEF752C001761B3 /* Makefile.am */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Makefile.am; sourceTree = "<group>"; };
 		FA322DA70CEF752C001761B3 /* Makefile.am */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Makefile.am; sourceTree = "<group>"; };
 		FA322DA80CEF752C001761B3 /* ngircd-doc.css */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.css; path = "ngircd-doc.css"; sourceTree = "<group>"; };
 		FA322DA80CEF752C001761B3 /* ngircd-doc.css */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text.css; path = "ngircd-doc.css"; sourceTree = "<group>"; };
 		FA322DA90CEF752C001761B3 /* SSL.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = SSL.txt; sourceTree = "<group>"; };
 		FA322DA90CEF752C001761B3 /* SSL.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = SSL.txt; sourceTree = "<group>"; };
-		FA322DAA0CEF752C001761B3 /* Zeroconf.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Zeroconf.txt; sourceTree = "<group>"; };
 		FA322DAD0CEF7538001761B3 /* Makefile.am */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Makefile.am; sourceTree = "<group>"; };
 		FA322DAD0CEF7538001761B3 /* Makefile.am */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = Makefile.am; sourceTree = "<group>"; };
 		FA322DAE0CEF7538001761B3 /* ngircd.8.tmpl */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = ngircd.8.tmpl; sourceTree = "<group>"; };
 		FA322DAE0CEF7538001761B3 /* ngircd.8.tmpl */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = ngircd.8.tmpl; sourceTree = "<group>"; };
 		FA322DAF0CEF7538001761B3 /* ngircd.conf.5.tmpl */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = ngircd.conf.5.tmpl; sourceTree = "<group>"; };
 		FA322DAF0CEF7538001761B3 /* ngircd.conf.5.tmpl */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = ngircd.conf.5.tmpl; sourceTree = "<group>"; };
@@ -201,6 +196,7 @@
 		FA407F2C0DB159F400271AF1 /* ng_ipaddr.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; name = ng_ipaddr.c; path = ipaddr/ng_ipaddr.c; sourceTree = "<group>"; };
 		FA407F2C0DB159F400271AF1 /* ng_ipaddr.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; name = ng_ipaddr.c; path = ipaddr/ng_ipaddr.c; sourceTree = "<group>"; };
 		FA407F2D0DB159F400271AF1 /* ng_ipaddr.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; name = ng_ipaddr.h; path = ipaddr/ng_ipaddr.h; sourceTree = "<group>"; };
 		FA407F2D0DB159F400271AF1 /* ng_ipaddr.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; name = ng_ipaddr.h; path = ipaddr/ng_ipaddr.h; sourceTree = "<group>"; };
 		FA407F380DB15AC700271AF1 /* GIT.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = GIT.txt; sourceTree = "<group>"; };
 		FA407F380DB15AC700271AF1 /* GIT.txt */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = text; path = GIT.txt; sourceTree = "<group>"; };
+		FA77849A133FB9FF00740057 /* sample-ngircd.conf.tmpl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = "sample-ngircd.conf.tmpl"; sourceTree = "<group>"; };
 		FA85178A0FA061EC006A1F5A /* op.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = op.h; sourceTree = "<group>"; };
 		FA85178A0FA061EC006A1F5A /* op.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = op.h; sourceTree = "<group>"; };
 		FA85178B0FA061EC006A1F5A /* op.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = op.c; sourceTree = "<group>"; };
 		FA85178B0FA061EC006A1F5A /* op.c */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.c; path = op.c; sourceTree = "<group>"; };
 		FA99428A10E82A27007F27ED /* proc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = proc.h; sourceTree = "<group>"; };
 		FA99428A10E82A27007F27ED /* proc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = proc.h; sourceTree = "<group>"; };
@@ -348,14 +344,12 @@
 				FA322D070CEF74B1001761B3 /* ngircd.h */,
 				FA322D070CEF74B1001761B3 /* ngircd.h */,
 				FAE5CC2D0CF2308A007D69B6 /* numeric.c */,
 				FAE5CC2D0CF2308A007D69B6 /* numeric.c */,
 				FAE5CC2C0CF2308A007D69B6 /* numeric.h */,
 				FAE5CC2C0CF2308A007D69B6 /* numeric.h */,
-				FA85178A0FA061EC006A1F5A /* op.h */,
 				FA85178B0FA061EC006A1F5A /* op.c */,
 				FA85178B0FA061EC006A1F5A /* op.c */,
+				FA85178A0FA061EC006A1F5A /* op.h */,
 				FA322D080CEF74B1001761B3 /* parse.c */,
 				FA322D080CEF74B1001761B3 /* parse.c */,
 				FA322D090CEF74B1001761B3 /* parse.h */,
 				FA322D090CEF74B1001761B3 /* parse.h */,
 				FA99428B10E82A27007F27ED /* proc.c */,
 				FA99428B10E82A27007F27ED /* proc.c */,
 				FA99428A10E82A27007F27ED /* proc.h */,
 				FA99428A10E82A27007F27ED /* proc.h */,
-				FA322D0A0CEF74B1001761B3 /* rendezvous.c */,
-				FA322D0B0CEF74B1001761B3 /* rendezvous.h */,
 				FA322D0C0CEF74B1001761B3 /* resolve.c */,
 				FA322D0C0CEF74B1001761B3 /* resolve.c */,
 				FA322D0D0CEF74B1001761B3 /* resolve.h */,
 				FA322D0D0CEF74B1001761B3 /* resolve.h */,
 				FAA97C55124A271400D5BBA9 /* sighandlers.c */,
 				FAA97C55124A271400D5BBA9 /* sighandlers.c */,
@@ -567,10 +561,9 @@
 				FA322D9E0CEF752C001761B3 /* README-AUX.txt */,
 				FA322D9E0CEF752C001761B3 /* README-AUX.txt */,
 				FA322D9F0CEF752C001761B3 /* README-BeOS.txt */,
 				FA322D9F0CEF752C001761B3 /* README-BeOS.txt */,
 				FA322DA00CEF752C001761B3 /* RFC.txt */,
 				FA322DA00CEF752C001761B3 /* RFC.txt */,
-				FA322DA10CEF752C001761B3 /* sample-ngircd.conf */,
+				FA77849A133FB9FF00740057 /* sample-ngircd.conf.tmpl */,
 				FA322DA20CEF752C001761B3 /* src */,
 				FA322DA20CEF752C001761B3 /* src */,
 				FA322DA90CEF752C001761B3 /* SSL.txt */,
 				FA322DA90CEF752C001761B3 /* SSL.txt */,
-				FA322DAA0CEF752C001761B3 /* Zeroconf.txt */,
 			);
 			);
 			name = doc;
 			name = doc;
 			path = ../../doc;
 			path = ../../doc;
@@ -701,7 +694,6 @@
 				FA322D490CEF74B1001761B3 /* match.c in Sources */,
 				FA322D490CEF74B1001761B3 /* match.c in Sources */,
 				FA322D4A0CEF74B1001761B3 /* ngircd.c in Sources */,
 				FA322D4A0CEF74B1001761B3 /* ngircd.c in Sources */,
 				FA322D4B0CEF74B1001761B3 /* parse.c in Sources */,
 				FA322D4B0CEF74B1001761B3 /* parse.c in Sources */,
-				FA322D4C0CEF74B1001761B3 /* rendezvous.c in Sources */,
 				FA322D4D0CEF74B1001761B3 /* resolve.c in Sources */,
 				FA322D4D0CEF74B1001761B3 /* resolve.c in Sources */,
 				FA322DBE0CEF7766001761B3 /* tool.c in Sources */,
 				FA322DBE0CEF7766001761B3 /* tool.c in Sources */,
 				FAE5CC2E0CF2308A007D69B6 /* numeric.c in Sources */,
 				FAE5CC2E0CF2308A007D69B6 /* numeric.c in Sources */,

+ 3 - 3
contrib/Makefile.am

@@ -1,6 +1,6 @@
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2009 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -9,10 +9,10 @@
 # Please read the file COPYING, README and AUTHORS for more information.
 # Please read the file COPYING, README and AUTHORS for more information.
 #
 #
 
 
-SUBDIRS = Debian MacOSX
+SUBDIRS = Anope Debian MacOSX
 
 
 EXTRA_DIST = README ngircd.spec systrace.policy ngindent ngircd-bsd.sh \
 EXTRA_DIST = README ngircd.spec systrace.policy ngindent ngircd-bsd.sh \
-	ngircd-redhat.init platformtest.sh
+	ngIRCd-Logo.gif ngircd-redhat.init platformtest.sh
 
 
 maintainer-clean-local:
 maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in

+ 115 - 40
contrib/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -16,7 +17,7 @@
 
 
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2009 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,6 +54,13 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -63,12 +72,41 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -105,6 +143,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -164,11 +203,12 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
-SUBDIRS = Debian MacOSX
+SUBDIRS = Anope Debian MacOSX
 EXTRA_DIST = README ngircd.spec systrace.policy ngindent ngircd-bsd.sh \
 EXTRA_DIST = README ngircd.spec systrace.policy ngindent ngircd-bsd.sh \
-	ngircd-redhat.init platformtest.sh
+	ngIRCd-Logo.gif ngircd-redhat.init platformtest.sh
 
 
 all: all-recursive
 all: all-recursive
 
 
@@ -177,14 +217,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  contrib/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  contrib/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu contrib/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu contrib/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -202,6 +242,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 
 
 # This directory's subdirectories are mostly independent; you can cd
 # This directory's subdirectories are mostly independent; you can cd
 # into them and run `make' without going through this Makefile.
 # into them and run `make' without going through this Makefile.
@@ -210,7 +251,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 #     (which will cause the Makefiles to be regenerated when you run `make');
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -227,7 +268,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
 	if test "$$dot_seen" = "no"; then \
@@ -235,7 +276,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 	fi; test -z "$$fail"
 
 
 $(RECURSIVE_CLEAN_TARGETS):
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -261,16 +302,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 	done && test -z "$$fail"
 tags-recursive:
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 	done
 ctags-recursive:
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 	done
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -278,14 +319,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
 	  include_option=--etags-include; \
@@ -297,7 +338,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	  fi; \
 	done; \
 	done; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
@@ -306,29 +347,34 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -349,29 +395,44 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	        distdir) \
 	      || exit 1; \
 	      || exit 1; \
 	  fi; \
 	  fi; \
@@ -401,6 +462,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -419,6 +481,8 @@ dvi-am:
 
 
 html: html-recursive
 html: html-recursive
 
 
+html-am:
+
 info: info-recursive
 info: info-recursive
 
 
 info-am:
 info-am:
@@ -427,18 +491,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-recursive
 install-dvi: install-dvi-recursive
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-recursive
 install-html: install-html-recursive
 
 
+install-html-am:
+
 install-info: install-info-recursive
 install-info: install-info-recursive
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-recursive
 install-pdf: install-pdf-recursive
 
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 install-ps: install-ps-recursive
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-recursive
 maintainer-clean: maintainer-clean-recursive
@@ -460,8 +534,8 @@ ps-am:
 
 
 uninstall-am:
 uninstall-am:
 
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+	install-am install-strip tags-recursive
 
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am check check-am clean clean-generic ctags \
 	all all-am check check-am clean clean-generic ctags \
@@ -481,6 +555,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 5 - 3
contrib/README

@@ -1,15 +1,17 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2009 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
                             -- Contributions --
                             -- Contributions --
 
 
 
 
+Anope/
+ - A preliminary patch that adds a ngIRCd protocol module to Anope 1.9.
+
 Debian/
 Debian/
  - Various files for building Debian GNU/Linux packages (".deb's").
  - Various files for building Debian GNU/Linux packages (".deb's").
 
 

BIN
contrib/ngIRCd-Logo.gif


+ 1 - 1
contrib/ngircd.spec

@@ -1,5 +1,5 @@
 %define name    ngircd
 %define name    ngircd
-%define version 17.1
+%define version 18
 %define release 1
 %define release 1
 %define prefix  %{_prefix}
 %define prefix  %{_prefix}
 
 

+ 2 - 2
contrib/platformtest.sh

@@ -96,8 +96,8 @@ if [ -r "Makefile" ]; then
 	CC=$(grep "^CC = " Makefile | cut -d' ' -f3)
 	CC=$(grep "^CC = " Makefile | cut -d' ' -f3)
 	$CC --version 2>&1 | grep -i "GCC" >/dev/null
 	$CC --version 2>&1 | grep -i "GCC" >/dev/null
 	if [ $? -eq 0 ]; then
 	if [ $? -eq 0 ]; then
-		COMPILER=$($CC --version | head -1 | awk "{ print \$3 }" \
-		 | cut -d'-' -f1)
+		COMPILER=$($CC --version | head -1 \
+		  | cut -d')' -f2 | cut -d' ' -f2)
 		COMPILER="gcc $COMPILER"
 		COMPILER="gcc $COMPILER"
 	else
 	else
 		case "$CC" in
 		case "$CC" in

+ 64 - 23
depcomp

@@ -1,10 +1,10 @@
 #! /bin/sh
 #! /bin/sh
 # depcomp - compile a program generating dependencies as side-effects
 # depcomp - compile a program generating dependencies as side-effects
 
 
-scriptversion=2007-03-29.01
+scriptversion=2009-04-28.21; # UTC
 
 
-# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007 Free Software
-# Foundation, Inc.
+# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free
+# Software Foundation, Inc.
 
 
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -17,9 +17,7 @@ scriptversion=2007-03-29.01
 # GNU General Public License for more details.
 # GNU General Public License for more details.
 
 
 # You should have received a copy of the GNU General Public License
 # You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-# 02110-1301, USA.
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 
 # As a special exception to the GNU General Public License, if you
 # As a special exception to the GNU General Public License, if you
 # distribute this file as part of a program that contains a
 # distribute this file as part of a program that contains a
@@ -87,6 +85,15 @@ if test "$depmode" = dashXmstdout; then
    depmode=dashmstdout
    depmode=dashmstdout
 fi
 fi
 
 
+cygpath_u="cygpath -u -f -"
+if test "$depmode" = msvcmsys; then
+   # This is just like msvisualcpp but w/o cygpath translation.
+   # Just convert the backslash-escaped backslashes to single forward
+   # slashes to satisfy depend.m4
+   cygpath_u="sed s,\\\\\\\\,/,g"
+   depmode=msvisualcpp
+fi
+
 case "$depmode" in
 case "$depmode" in
 gcc3)
 gcc3)
 ## gcc 3 implements dependency tracking that does exactly what
 ## gcc 3 implements dependency tracking that does exactly what
@@ -192,14 +199,14 @@ sgi)
 ' < "$tmpdepfile" \
 ' < "$tmpdepfile" \
     | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
     | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
     tr '
     tr '
-' ' ' >> $depfile
-    echo >> $depfile
+' ' ' >> "$depfile"
+    echo >> "$depfile"
 
 
     # The second pass generates a dummy entry for each header file.
     # The second pass generates a dummy entry for each header file.
     tr ' ' '
     tr ' ' '
 ' < "$tmpdepfile" \
 ' < "$tmpdepfile" \
    | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
    | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
-   >> $depfile
+   >> "$depfile"
   else
   else
     # The sourcefile does not contain any dependencies, so just
     # The sourcefile does not contain any dependencies, so just
     # store a dummy comment line, to avoid errors with the Makefile
     # store a dummy comment line, to avoid errors with the Makefile
@@ -328,7 +335,12 @@ hp2)
   if test -f "$tmpdepfile"; then
   if test -f "$tmpdepfile"; then
     sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
     sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
     # Add `dependent.h:' lines.
     # Add `dependent.h:' lines.
-    sed -ne '2,${; s/^ *//; s/ \\*$//; s/$/:/; p;}' "$tmpdepfile" >> "$depfile"
+    sed -ne '2,${
+	       s/^ *//
+	       s/ \\*$//
+	       s/$/:/
+	       p
+	     }' "$tmpdepfile" >> "$depfile"
   else
   else
     echo "#dummy" > "$depfile"
     echo "#dummy" > "$depfile"
   fi
   fi
@@ -404,7 +416,7 @@ dashmstdout)
 
 
   # Remove the call to Libtool.
   # Remove the call to Libtool.
   if test "$libtool" = yes; then
   if test "$libtool" = yes; then
-    while test $1 != '--mode=compile'; do
+    while test "X$1" != 'X--mode=compile'; do
       shift
       shift
     done
     done
     shift
     shift
@@ -455,32 +467,39 @@ makedepend)
   "$@" || exit $?
   "$@" || exit $?
   # Remove any Libtool call
   # Remove any Libtool call
   if test "$libtool" = yes; then
   if test "$libtool" = yes; then
-    while test $1 != '--mode=compile'; do
+    while test "X$1" != 'X--mode=compile'; do
       shift
       shift
     done
     done
     shift
     shift
   fi
   fi
   # X makedepend
   # X makedepend
   shift
   shift
-  cleared=no
-  for arg in "$@"; do
+  cleared=no eat=no
+  for arg
+  do
     case $cleared in
     case $cleared in
     no)
     no)
       set ""; shift
       set ""; shift
       cleared=yes ;;
       cleared=yes ;;
     esac
     esac
+    if test $eat = yes; then
+      eat=no
+      continue
+    fi
     case "$arg" in
     case "$arg" in
     -D*|-I*)
     -D*|-I*)
       set fnord "$@" "$arg"; shift ;;
       set fnord "$@" "$arg"; shift ;;
     # Strip any option that makedepend may not understand.  Remove
     # Strip any option that makedepend may not understand.  Remove
     # the object too, otherwise makedepend will parse it as a source file.
     # the object too, otherwise makedepend will parse it as a source file.
+    -arch)
+      eat=yes ;;
     -*|$object)
     -*|$object)
       ;;
       ;;
     *)
     *)
       set fnord "$@" "$arg"; shift ;;
       set fnord "$@" "$arg"; shift ;;
     esac
     esac
   done
   done
-  obj_suffix="`echo $object | sed 's/^.*\././'`"
+  obj_suffix=`echo "$object" | sed 's/^.*\././'`
   touch "$tmpdepfile"
   touch "$tmpdepfile"
   ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
   ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
   rm -f "$depfile"
   rm -f "$depfile"
@@ -500,7 +519,7 @@ cpp)
 
 
   # Remove the call to Libtool.
   # Remove the call to Libtool.
   if test "$libtool" = yes; then
   if test "$libtool" = yes; then
-    while test $1 != '--mode=compile'; do
+    while test "X$1" != 'X--mode=compile'; do
       shift
       shift
     done
     done
     shift
     shift
@@ -538,13 +557,27 @@ cpp)
 
 
 msvisualcpp)
 msvisualcpp)
   # Important note: in order to support this mode, a compiler *must*
   # Important note: in order to support this mode, a compiler *must*
-  # always write the preprocessed file to stdout, regardless of -o,
-  # because we must use -o when running libtool.
+  # always write the preprocessed file to stdout.
   "$@" || exit $?
   "$@" || exit $?
+
+  # Remove the call to Libtool.
+  if test "$libtool" = yes; then
+    while test "X$1" != 'X--mode=compile'; do
+      shift
+    done
+    shift
+  fi
+
   IFS=" "
   IFS=" "
   for arg
   for arg
   do
   do
     case "$arg" in
     case "$arg" in
+    -o)
+      shift
+      ;;
+    $object)
+      shift
+      ;;
     "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
     "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
 	set fnord "$@"
 	set fnord "$@"
 	shift
 	shift
@@ -557,16 +590,23 @@ msvisualcpp)
 	;;
 	;;
     esac
     esac
   done
   done
-  "$@" -E |
-  sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile"
+  "$@" -E 2>/dev/null |
+  sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
   rm -f "$depfile"
   rm -f "$depfile"
   echo "$object : \\" > "$depfile"
   echo "$object : \\" > "$depfile"
-  . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::	\1 \\:p' >> "$depfile"
+  sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::	\1 \\:p' >> "$depfile"
   echo "	" >> "$depfile"
   echo "	" >> "$depfile"
-  . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile"
+  sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
   rm -f "$tmpdepfile"
   rm -f "$tmpdepfile"
   ;;
   ;;
 
 
+msvcmsys)
+  # This case exists only to let depend.m4 do its work.  It works by
+  # looking at the text of this script.  This case will never be run,
+  # since it is checked for above.
+  exit 1
+  ;;
+
 none)
 none)
   exec "$@"
   exec "$@"
   ;;
   ;;
@@ -585,5 +625,6 @@ exit 0
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # time-stamp-start: "scriptversion="
 # time-stamp-start: "scriptversion="
 # time-stamp-format: "%:y-%02m-%02d.%02H"
 # time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-end: "$"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
 # End:
 # End:

+ 11 - 2
doc/GIT.txt

@@ -1,10 +1,18 @@
+
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
+
+               (c)2001-2011 Alexander Barton and Contributors.
+               ngIRCd is free software and published under the
+                   terms of the GNU General Public License.
 
 
                                  -- GIT.txt --
                                  -- GIT.txt --
 
 
+
 The source code of ngIRCd is maintained using git, the stupid content
 The source code of ngIRCd is maintained using git, the stupid content
 tracker.
 tracker.
 
 
+
 I. Getting the source code
 I. Getting the source code
 ~~~~~~~~~~~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~~~~~~~~~~~
 To access the source tree anonymously, run:
 To access the source tree anonymously, run:
@@ -20,7 +28,8 @@ git commands will be executed from within this directory in the future.
 Please note: When checking out a fresh copy of ngIRCd using git, the
 Please note: When checking out a fresh copy of ngIRCd using git, the
 configure script doesn't exist; you have to run the autogen.sh shell script
 configure script doesn't exist; you have to run the autogen.sh shell script
 (which is included in the source tree) to generate it. This requires you to
 (which is included in the source tree) to generate it. This requires you to
-have GNU automake and GNU autoconf installed on your system.
+have GNU automake and GNU autoconf installed on your system. Please see the
+file INSTALL for details!
 
 
 To update the git tree:
 To update the git tree:
 
 
@@ -28,6 +37,7 @@ To update the git tree:
 
 
 This retrieves all changes and merges them into the current branch.
 This retrieves all changes and merges them into the current branch.
 
 
+
 II. Contributing
 II. Contributing
 ~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~
 
 
@@ -42,4 +52,3 @@ III. Write Access
 ~~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~~
 If you want to contribute a couple of patches and write access to the git
 If you want to contribute a couple of patches and write access to the git
 repository would be handy, please contact Alex Barton, <alex@barton.de>.
 repository would be handy, please contact Alex Barton, <alex@barton.de>.
-

+ 1 - 1
doc/Makefile.am

@@ -19,7 +19,7 @@ SUFFIXES = .tmpl
 
 
 static_docs = Bopm.txt FAQ.txt GIT.txt HowToRelease.txt PAM.txt Platforms.txt \
 static_docs = Bopm.txt FAQ.txt GIT.txt HowToRelease.txt PAM.txt Platforms.txt \
 	Protocol.txt README-AUX.txt README-BeOS.txt README-Interix.txt RFC.txt \
 	Protocol.txt README-AUX.txt README-BeOS.txt README-Interix.txt RFC.txt \
-	SSL.txt Services.txt Zeroconf.txt
+	SSL.txt Services.txt
 
 
 doc_templates = sample-ngircd.conf.tmpl
 doc_templates = sample-ngircd.conf.tmpl
 
 

+ 114 - 40
doc/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -27,8 +28,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -53,6 +55,13 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -64,12 +73,41 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -106,6 +144,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -165,12 +204,13 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 SUFFIXES = .tmpl
 SUFFIXES = .tmpl
 static_docs = Bopm.txt FAQ.txt GIT.txt HowToRelease.txt PAM.txt Platforms.txt \
 static_docs = Bopm.txt FAQ.txt GIT.txt HowToRelease.txt PAM.txt Platforms.txt \
 	Protocol.txt README-AUX.txt README-BeOS.txt README-Interix.txt RFC.txt \
 	Protocol.txt README-AUX.txt README-BeOS.txt README-Interix.txt RFC.txt \
-	SSL.txt Services.txt Zeroconf.txt
+	SSL.txt Services.txt
 
 
 doc_templates = sample-ngircd.conf.tmpl
 doc_templates = sample-ngircd.conf.tmpl
 generated_docs = sample-ngircd.conf
 generated_docs = sample-ngircd.conf
@@ -186,14 +226,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  doc/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  doc/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu doc/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu doc/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -211,6 +251,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 
 
 # This directory's subdirectories are mostly independent; you can cd
 # This directory's subdirectories are mostly independent; you can cd
 # into them and run `make' without going through this Makefile.
 # into them and run `make' without going through this Makefile.
@@ -219,7 +260,7 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 #     (which will cause the Makefiles to be regenerated when you run `make');
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -236,7 +277,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
 	if test "$$dot_seen" = "no"; then \
@@ -244,7 +285,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 	fi; test -z "$$fail"
 
 
 $(RECURSIVE_CLEAN_TARGETS):
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -270,16 +311,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 	done && test -z "$$fail"
 tags-recursive:
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 	done
 ctags-recursive:
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 	done
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -287,14 +328,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
 	  include_option=--etags-include; \
@@ -306,7 +347,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	  fi; \
 	done; \
 	done; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
@@ -315,29 +356,34 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -358,29 +404,44 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	        distdir) \
 	      || exit 1; \
 	      || exit 1; \
 	  fi; \
 	  fi; \
@@ -411,6 +472,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -429,6 +491,8 @@ dvi-am:
 
 
 html: html-recursive
 html: html-recursive
 
 
+html-am:
+
 info: info-recursive
 info: info-recursive
 
 
 info-am:
 info-am:
@@ -436,21 +500,30 @@ info-am:
 install-data-am:
 install-data-am:
 	@$(NORMAL_INSTALL)
 	@$(NORMAL_INSTALL)
 	$(MAKE) $(AM_MAKEFLAGS) install-data-hook
 	$(MAKE) $(AM_MAKEFLAGS) install-data-hook
-
 install-dvi: install-dvi-recursive
 install-dvi: install-dvi-recursive
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-recursive
 install-html: install-html-recursive
 
 
+install-html-am:
+
 install-info: install-info-recursive
 install-info: install-info-recursive
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-recursive
 install-pdf: install-pdf-recursive
 
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 install-ps: install-ps-recursive
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-recursive
 maintainer-clean: maintainer-clean-recursive
@@ -473,9 +546,9 @@ ps-am:
 uninstall-am:
 uninstall-am:
 	@$(NORMAL_INSTALL)
 	@$(NORMAL_INSTALL)
 	$(MAKE) $(AM_MAKEFLAGS) uninstall-hook
 	$(MAKE) $(AM_MAKEFLAGS) uninstall-hook
-
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-data-am install-strip uninstall-am
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+	install-am install-data-am install-strip tags-recursive \
+	uninstall-am
 
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am check check-am clean clean-generic ctags \
 	all all-am check check-am clean clean-generic ctags \
@@ -522,6 +595,7 @@ srcdoc:
 	make -C src srcdoc
 	make -C src srcdoc
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 19 - 17
doc/Platforms.txt

@@ -1,9 +1,8 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2010 Alexander Barton
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
@@ -32,21 +31,22 @@ hppa1.1/unknown/linux-gnu   gcc 3.3.3    0.8.0      04-05-30 alex   Y Y Y Y
 hppa2.0/unknown/linux-gnu   gcc 3.3.5    13~rc1     08-12-02 alex   Y Y Y Y
 hppa2.0/unknown/linux-gnu   gcc 3.3.5    13~rc1     08-12-02 alex   Y Y Y Y
 hppa2.0w-hp-hpux11.11       gcc 4.2.3    14.1       09-07-22 goetz  Y Y Y Y
 hppa2.0w-hp-hpux11.11       gcc 4.2.3    14.1       09-07-22 goetz  Y Y Y Y
 i386/apple/darwin9.7.0      gcc 4.0.1    14.1       09-08-04 alex   Y Y Y Y (3)
 i386/apple/darwin9.7.0      gcc 4.0.1    14.1       09-08-04 alex   Y Y Y Y (3)
-i386/apple/darwin10.4.0     gcc 4.2.1    17         10-11-07 alex   Y Y Y Y (3)
+i386/apple/darwin10.7.0     gcc 4.2.1    18         11-07-05 alex   Y Y Y Y (3)
+i386/apple/darwin11.0.0     gcc 4.2.1    18         11-07-02 alex   Y Y Y Y (3)
 i386/pc/solaris2.9          gcc 3.2.2    CVSHEAD    04-02-24 alex   Y Y Y Y
 i386/pc/solaris2.9          gcc 3.2.2    CVSHEAD    04-02-24 alex   Y Y Y Y
-i386/pc/solaris2.11         gcc 3.4.3    17         10-11-07 alex   Y Y N Y (4)
+i386/pc/solaris2.11         gcc 3.4.3    18         11-07-10 alex   Y Y N Y (4)
 i386/unknown/freebsd5.2.1   gcc 3.3.3    0.8.0      04-05-30 alex   Y Y Y Y
 i386/unknown/freebsd5.2.1   gcc 3.3.3    0.8.0      04-05-30 alex   Y Y Y Y
-i386/unknown/freebsd6.2     gcc 3.4.6    17         10-11-07 alex   Y Y Y Y (3)
-i386/unknown/freebsd7.3     gcc 4.2.1    17         10-11-07 alex   Y Y Y Y (3)
-i686/unknown/gnu0.3         gcc 4.4.5    17         10-11-07 alex   Y Y Y Y
+i386/unknown/freebsd6.2     gcc 3.4.6    18         11-07-10 alex   Y Y Y Y (3)
+i386/unknown/freebsd7.3     gcc 4.2.1    18         11-07-1ß alex   Y Y Y Y (3)
+i686/unknown/gnu0.3         gcc 4.4.5    18         11-07-10 alex   Y Y Y Y
 i686/unkn./kfreebsd7.2-gnu  gcc 4.3.4    15         09-12-02 alex   Y Y Y Y (3)
 i686/unkn./kfreebsd7.2-gnu  gcc 4.3.4    15         09-12-02 alex   Y Y Y Y (3)
-i386/unknown/netbsdelf1.6.1 gcc 2.95.3   CVSHEAD    04-02-24 alex   Y Y Y Y
+i386/unknown/netbsdelf1.6.2 gcc 2.95.3   18         11-07-10 goetz  Y Y Y Y
 i386/unknown/netbsdelf3.0.1 gcc 3.3.3    0.10.0-p1  06-08-30 alex   Y Y Y Y (3)
 i386/unknown/netbsdelf3.0.1 gcc 3.3.3    0.10.0-p1  06-08-30 alex   Y Y Y Y (3)
-i386/unknown/netbsdelf4.0   gcc 4.1.2    17         10-11-07 alex   Y Y Y Y (3)
-i386/unknown/netbsdelf5.0.2 gcc 4.1.3    17         10-11-07 alex   Y Y Y Y (3)
+i386/unknown/netbsdelf4.0   gcc 4.1.2    18         11-07-10 alex   Y Y Y Y (3)
+i386/unknown/netbsdelf5.0.2 gcc 4.1.3    18         11-07-10 alex   Y Y Y Y (3)
 i386/unknown/openbsd3.9     gcc 3.3.5    0.10.0-p1  06-08-30 alex   Y Y Y Y (3)
 i386/unknown/openbsd3.9     gcc 3.3.5    0.10.0-p1  06-08-30 alex   Y Y Y Y (3)
 i386/unknown/openbsd4.1     gcc 3.3.5    16         10-04-11 alex   Y Y Y Y (3)
 i386/unknown/openbsd4.1     gcc 3.3.5    16         10-04-11 alex   Y Y Y Y (3)
-i586/pc/interix3.5          gcc 3.3      15         10-01-22 alex   Y Y N Y
+i586/pc/interix3.5          gcc 3.3      18         11-07-10 alex   Y Y N Y
 i686/pc/cygwin              gcc 3.3.1    0.8.0      04-05-30 alex   Y Y N Y
 i686/pc/cygwin              gcc 3.3.1    0.8.0      04-05-30 alex   Y Y N Y
 i686/pc/linux-gnu           gcc 2.95.4   0.8.0      04-05-30 alex   Y Y Y Y (1)
 i686/pc/linux-gnu           gcc 2.95.4   0.8.0      04-05-30 alex   Y Y Y Y (1)
 i686/pc/linux-gnu           gcc 3.3.5    14.1       09-08-04 alex   Y Y Y Y (1)
 i686/pc/linux-gnu           gcc 3.3.5    14.1       09-08-04 alex   Y Y Y Y (1)
@@ -54,20 +54,22 @@ i386/pc/linux-gnu           gcc 4.1.2    13~rc1     08-12-05 alex   Y Y Y Y (1)
 i686/pc/linux-gnu           gcc 4.3.2    14.1       09-08-04 alex   Y Y Y Y (1)
 i686/pc/linux-gnu           gcc 4.3.2    14.1       09-08-04 alex   Y Y Y Y (1)
 m68k/apple/aux3.0.1         gcc 2.7.2    17         10-11-07 alex   Y Y N Y
 m68k/apple/aux3.0.1         gcc 2.7.2    17         10-11-07 alex   Y Y N Y
 m68k/apple/aux3.0.1         Orig. A/UX   17         10-11-07 alex   Y Y N Y (2)
 m68k/apple/aux3.0.1         Orig. A/UX   17         10-11-07 alex   Y Y N Y (2)
-m68k/apple/aux3.1.1         Orig. A/UX   0.7.x-CVS  03-04-22 alex   Y Y Y Y (2)
+m68k/apple/aux3.1.1         gcc 2.7.2    18         11-07-02 alex   Y Y N Y
+m68k/apple/aux3.1.1         Orig. A/UX   18         11-07-02 alex   Y Y N Y (2)
 m68k/hp/hp-ux9.10           Orig. HPUX   0.7.x-CVS  03-04-30 goetz  Y Y Y Y
 m68k/hp/hp-ux9.10           Orig. HPUX   0.7.x-CVS  03-04-30 goetz  Y Y Y Y
 m88k/dg/dgux5.4R3.10        gcc 2.5.8    CVSHEAD    04-03-15 alex   Y Y ? ?
 m88k/dg/dgux5.4R3.10        gcc 2.5.8    CVSHEAD    04-03-15 alex   Y Y ? ?
+mipsel/unknown/linux-gnu    gcc 4.1.2    18         11-07-05 goetz  Y Y N Y (1)
 powerpc/apple/darwin6.5     gcc 3.1      0.7.x-CVS  03-04-23 alex   Y Y Y Y
 powerpc/apple/darwin6.5     gcc 3.1      0.7.x-CVS  03-04-23 alex   Y Y Y Y
 powerpc/apple/darwin7.9.0   gcc 3.3      CVSHEAD    06-05-07 fw     Y Y Y Y (3)
 powerpc/apple/darwin7.9.0   gcc 3.3      CVSHEAD    06-05-07 fw     Y Y Y Y (3)
-powerpc/apple/darwin8.1.0   gcc 4.0      0.9.x-CVS  05-06-27 alex   Y Y Y Y
+powerpc/apple/darwin8.11.0  gcc 4.0.1    18         11-07-02 goetz  Y Y Y Y (3)
 powerpc/unknown/linux-gnu   gcc 3.3.3    0.8.0      04-05-30 alex   Y Y Y Y
 powerpc/unknown/linux-gnu   gcc 3.3.3    0.8.0      04-05-30 alex   Y Y Y Y
 powerpc/unknown/openbsd3.6  gcc 2.95.3   0.10.0     06-10-08 alex   Y Y N Y
 powerpc/unknown/openbsd3.6  gcc 2.95.3   0.10.0     06-10-08 alex   Y Y N Y
 sparc/sun/solaris2.6        gcc 2.95.3   0.7.x-CVS  03-04-22 alex   Y Y Y Y
 sparc/sun/solaris2.6        gcc 2.95.3   0.7.x-CVS  03-04-22 alex   Y Y Y Y
 sparc/sun/solaris2.7        gcc 3.3      0.8.0      04-05-30 alex   Y Y Y Y
 sparc/sun/solaris2.7        gcc 3.3      0.8.0      04-05-30 alex   Y Y Y Y
 sparc/unkn./netbsdelf1.6.1  gcc 2.95.3   0.8.0      04-05-30 alex   Y Y Y Y
 sparc/unkn./netbsdelf1.6.1  gcc 2.95.3   0.8.0      04-05-30 alex   Y Y Y Y
-x86_64/unknown/freebsd8.1   gcc 4.2.1    17         10-11-07 alex   Y Y Y Y (3)
-x86_64/unknown/linux-gnu    gcc 4.3.2    17         10-11-07 alex   Y Y Y Y (1)
-x86_64/unknown/openbsd4.7   gcc 3.3.5    17         10-11-07 alex   Y Y Y Y (3)
+x86_64/unknown/freebsd8.1   gcc 4.2.1    18         11-07-10 alex   Y Y Y Y (3)
+x86_64/unknown/linux-gnu    gcc 4.4.5    18         11-07-02 alex   Y Y Y Y (1)
+x86_64/unknown/openbsd4.7   gcc 3.3.5    18         11-07-10 alex   Y Y Y Y (3)
 
 
 
 
 Notes
 Notes

+ 22 - 2
doc/Protocol.txt

@@ -141,11 +141,17 @@ therefore to disconnect the peer prior to registering it in the network.
 II.3 Exchange channel-modes, topics, and persistent channels
 II.3 Exchange channel-modes, topics, and persistent channels
 
 
      Command: CHANINFO
      Command: CHANINFO
-  Parameters: <channel> +<modes> <key> <limit> [<topic>]
+  Parameters: <channel> +<modes> [[<key> <limit>] <topic>]
      Used by: servers only
      Used by: servers only
 
 
 CHANINFO is used by servers to inform each other about a channel: its
 CHANINFO is used by servers to inform each other about a channel: its
-modes, channel key, user limits and its topic. <topic> is optional.
+modes, channel key, user limits and its topic. The parameter combination
+<key> and <limit> is optional, as well as the <topic> parameter, so that
+there are three possible forms of this command:
+
+  CHANINFO <channel> +<modes>
+  CHANINFO <channel> +<modes> <topic>
+  CHANINFO <channel> +<modes> <key> <limit> <topic>
 
 
 If the channel already exists on the server receiving the CHANINFO command,
 If the channel already exists on the server receiving the CHANINFO command,
 it only adopts the <modes> (or the <topic>) if there are no modes (or topic)
 it only adopts the <modes> (or the <topic>) if there are no modes (or topic)
@@ -161,3 +167,17 @@ and therefore can't be omitted. The parameter <limit> must be ignored when
 a channel has no user limit (the parameter <modes> doesn't list the "l"
 a channel has no user limit (the parameter <modes> doesn't list the "l"
 channel mode). In this case <limit> should be "0".
 channel mode). In this case <limit> should be "0".
 
 
+
+II.4 Update webchat/proxy client information
+
+     Command: WEBIRC
+  Parameters: <password> <username> <hostname> <ip-address>
+     Used by: unregistered clients only
+
+The WEBIRC command is used by some Web-to-IRC gateways to set the correct
+user name and host name of users instead of their own. It must be the very
+first command sent to the server, even before USER and NICK commands!
+
+The <password> must be set in the server configuration file to prevent
+unauthorized clients to fake their identity; it is an arbitrary string.
+

+ 3 - 3
doc/SSL.txt

@@ -34,7 +34,7 @@ possible to handle unencrypted and encrypted connections on the same port!
 This is a limitation of the IRC protocol ...
 This is a limitation of the IRC protocol ...
 
 
 You have to set (at least) the following configuration variables in the
 You have to set (at least) the following configuration variables in the
-[GLOBAL] section of ngircd.conf(5): SSLPorts, SSLKeyFile, and SSLCertFile.
+[SSL] section of ngircd.conf(5): Ports, KeyFile, and CertFile.
 
 
 Now IRC clients are able to connect using SSL on the configured port(s).
 Now IRC clients are able to connect using SSL on the configured port(s).
 (Using port 6697 for encrypted connections is common.)
 (Using port 6697 for encrypted connections is common.)
@@ -51,7 +51,7 @@ OpenSSL:
 Creating a self-signed certificate and key:
 Creating a self-signed certificate and key:
  $ openssl req -newkey rsa:2048 -x509 -keyout server-key.pem -out server-cert.pem -days 1461
  $ openssl req -newkey rsa:2048 -x509 -keyout server-key.pem -out server-cert.pem -days 1461
 Create DH parameters (optional):
 Create DH parameters (optional):
- $ openssl dhparam -2 -out dhparams.pem 2048
+ $ openssl dhparam -2 -out dhparams.pem 4096
 
 
 GnuTLS:
 GnuTLS:
 
 
@@ -59,7 +59,7 @@ Creating a self-signed certificate and key:
  $ certtool --generate-privkey --bits 2048 --outfile server-key.pem
  $ certtool --generate-privkey --bits 2048 --outfile server-key.pem
  $ certtool --generate-self-signed --load-privkey server-key.pem --outfile server-cert.pem
  $ certtool --generate-self-signed --load-privkey server-key.pem --outfile server-cert.pem
 Create DH parameters (optional):
 Create DH parameters (optional):
- $ certtool  --generate-dh-params --bits 2048 --outfile dhparams.pem
+ $ certtool  --generate-dh-params --bits 4096 --outfile dhparams.pem
 
 
 
 
 Alternate approach using stunnel(1)
 Alternate approach using stunnel(1)

+ 33 - 6
doc/Services.txt

@@ -1,9 +1,8 @@
 
 
                      ngIRCd - Next Generation IRC Server
                      ngIRCd - Next Generation IRC Server
+                           http://ngircd.barton.de/
 
 
-                        (c)2001-2008 Alexander Barton,
-                    alex@barton.de, http://www.barton.de/
-
+               (c)2001-2011 Alexander Barton and Contributors.
                ngIRCd is free software and published under the
                ngIRCd is free software and published under the
                    terms of the GNU General Public License.
                    terms of the GNU General Public License.
 
 
@@ -14,9 +13,11 @@ At the moment, ngIRCd doesn't implement a "special IRC services interface".
 But services acting as a "regular server" are supported, either using the IRC
 But services acting as a "regular server" are supported, either using the IRC
 protocol defined in RFC 1459 or RFC 2812.
 protocol defined in RFC 1459 or RFC 2812.
 
 
-Services have been tested using "IRC Services" version 5.x by Andrew Church,
-homepage: <http://www.ircservices.za.net/>. This document describes setting up
-ngIRCd and these services.
+Support for Services has been tested using "IRC Services" version 5.x by
+Andrew Church (<http://achurch.org/services/>), and a Anope 1.9 using a
+preliminary protocol module for ngIRCd (<http://www.anope.org/>).
+
+This document describes setting up ngIRCd and these services.
 
 
 
 
 Setting up ngIRCd
 Setting up ngIRCd
@@ -36,6 +37,31 @@ Example:
      ServiceMask = *Serv
      ServiceMask = *Serv
 
 
 
 
+Setting up Anope 1.9.x
+~~~~~~~~~~~~~~~~~~~~~~
+
+Anope 1.9.4 (and above) can be used with ngIRCd using a preliminary "ngircd"
+protocol module contained in our contrib/Anope/ directory. Please see the
+file contrib/Anope/README for installation instructions!
+
+After patching and installing Anope, at least the following configuration
+variables have to be adjusted in data/services.conf, in addition to all the
+settings marked as required:
+
+  uplink
+  {
+	host = "server.irc.net"
+	port = 6667
+	password = "123abc"
+  }
+
+  serverinfo
+  {
+	name = "services.irc.net"
+	type = "ngircd"
+  }
+
+
 Setting up IRC Services 5.1.x
 Setting up IRC Services 5.1.x
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 
@@ -66,5 +92,6 @@ In modules.conf:
 The documentation of IRC Services can be found here:
 The documentation of IRC Services can be found here:
 <http://www.ircservices.za.net/docs/>
 <http://www.ircservices.za.net/docs/>
 
 
+
 Please let us know if you are successfully using other IRC service packages or
 Please let us know if you are successfully using other IRC service packages or
 which problems you encounter, thanks!
 which problems you encounter, thanks!

+ 0 - 39
doc/Zeroconf.txt

@@ -1,40 +0,0 @@
-
-                     ngIRCd - Next Generation IRC Server
-
-                        (c)2001-2006 Alexander Barton
-                    alex@barton.de, http://www.barton.de/
-
-               ngIRCd is free software and published under the
-                   terms of the GNU General Public License.
-
-			      -- Zeroconf.txt --
-
-
-ngIRCd supports one aspect of Zeroconf Networking[1]: Multicast DNS (mDNS[2])
-with DNS Service Discovery (DNS-SD[3]).
-
-To use this features you can use one of two APIs:
-
-  a) Apple "Bonjour" API as used by Mac OS X,
-  b) the Howl[4] Zeroconf library or the Howl compatibility layer
-     of the newer Avahi[5] library.
-
-When calling the configure script using the "--with-zeroconf" switch the
-available API will be autodetected and the required additional libraries will
-be linked to the ngircd binary as required.
-
-ngIRCd then registers a DNS-SD service for each port it is listening on using
-the service type "_ircu._tcp.".
-
-
-Links:
-
- [1] http://www.zeroconf.org/
- [2] http://www.multicastdns.org/
- [3] http://www.dns-sd.org/
- [4] http://www.porchdogsoft.com/products/howl/
- [5] http://avahi.org/
-
-
-$Id: Zeroconf.txt,v 1.2 2006/08/03 14:37:29 alex Exp $

+ 126 - 89
doc/sample-ngircd.conf.tmpl

@@ -12,30 +12,20 @@
 # Use "ngircd --configtest" (see manual page ngircd(8)) to validate that the
 # Use "ngircd --configtest" (see manual page ngircd(8)) to validate that the
 # server interprets the configuration file as expected!
 # server interprets the configuration file as expected!
 #
 #
-# Please see ngircd.conf(5) for a complete list of configuration options.
+# Please see ngircd.conf(5) for a complete list of configuration options
+# and their descriptions.
 #
 #
 
 
 [Global]
 [Global]
 	# The [Global] section of this file is used to define the main
 	# The [Global] section of this file is used to define the main
 	# configuration of the server, like the server name and the ports
 	# configuration of the server, like the server name and the ports
 	# on which the server should be listening.
 	# on which the server should be listening.
+	# These settings depend on your personal preferences, so you should
+	# make sure that they correspond to your installation and setup!
 
 
 	# Server name in the IRC network, must contain at least one dot
 	# Server name in the IRC network, must contain at least one dot
 	# (".") and be unique in the IRC network. Required!
 	# (".") and be unique in the IRC network. Required!
-	Name = irc.the.net
-
-	# 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.
-	# (Default: not set)
-	;Password = abc
-
-	# Password required for using the WEBIRC command used by some
-	# Web-to-IRC gateways. If not set/empty, the WEBIRC command can't
-	# be used. (Default: not set)
-	;WebircPassword = xyz
+	Name = irc.example.net
 
 
 	# Information about the server and the administrator, used by the
 	# Information about the server and the administrator, used by the
 	# ADMIN command. Not required by server but by RFC!
 	# ADMIN command. Not required by server but by RFC!
@@ -43,38 +33,16 @@
 	;AdminInfo2 = Location
 	;AdminInfo2 = Location
 	;AdminEMail = admin@irc.server
 	;AdminEMail = admin@irc.server
 
 
-	# Ports on which the server should listen. There may be more than
-	# one port, separated with ",". (Default: 6667)
-	;Ports = 6667, 6668, 6669
-
-	# Additional Listen Ports that expect SSL/TLS encrypted connections
-	;SSLPorts = 6697, 9999
-
-	# SSL Server Key
-	;SSLKeyFile = :ETCDIR:/ssl/server-key.pem
-
-	# password to decrypt SSLKeyFile (OpenSSL only)
-	;SSLKeyFilePassword = secret
-
-	# SSL Server Key Certificate
-	;SSLCertFile = :ETCDIR:/ssl/server-cert.pem
-
-	# Diffie-Hellman parameters
-	;SSLDHFile = :ETCDIR:/ssl/dhparams.pem
+	# Info text of the server. This will be shown by WHOIS and
+	# LINKS requests for example.
+	Info = Server Info Text
 
 
-	# comma separated list of IP addresses on which the server should
+	# Comma separated list of IP addresses on which the server should
 	# listen. Default values are:
 	# listen. Default values are:
 	# "0.0.0.0" or (if compiled with IPv6 support) "::,0.0.0.0"
 	# "0.0.0.0" or (if compiled with IPv6 support) "::,0.0.0.0"
 	# so the server listens on all IP addresses of the system by default.
 	# so the server listens on all IP addresses of the system by default.
 	;Listen = 127.0.0.1,192.168.0.1
 	;Listen = 127.0.0.1,192.168.0.1
 
 
-	# Syslog "facility" to which ngIRCd should send log messages.
-	# Possible values are system dependant, but most probably auth, daemon,
-	# user and local1 through local7 are possible values; see syslog(3).
-	# Default is "local5" for historical reasons, you probably want to
-	# change this to "daemon", for example.
-	SyslogFacility = local1
-
 	# Text file with the "message of the day" (MOTD). This message will
 	# Text file with the "message of the day" (MOTD). This message will
 	# be shown to all users connecting to the server:
 	# be shown to all users connecting to the server:
 	;MotdFile = :ETCDIR:/ngircd.motd
 	;MotdFile = :ETCDIR:/ngircd.motd
@@ -82,6 +50,25 @@
 	# A simple Phrase (<256 chars) if you don't want to use a motd file.
 	# A simple Phrase (<256 chars) if you don't want to use a motd file.
 	;MotdPhrase = "Hello world!"
 	;MotdPhrase = "Hello world!"
 
 
+	# Global password for all users needed to connect to the server.
+	# (Default: not set)
+	;Password = abc
+
+	# This tells ngIRCd to write its current process ID to a file.
+	# Note that the pidfile is written AFTER chroot and switching the
+	# user ID, e.g. the directory the pidfile resides in must be
+	# writable by the ngIRCd user and exist in the chroot directory.
+	;PidFile = /var/run/ngircd/ngircd.pid
+
+	# Ports on which the server should listen. There may be more than
+	# one port, separated with ",". (Default: 6667)
+	;Ports = 6667, 6668, 6669
+
+	# Group ID under which the ngIRCd should run; you can use the name
+	# of the group or the numerical ID. ATTENTION: For this to work the
+	# server must have been started with root privileges!
+	;ServerGID = 65534
+
 	# User ID under which the server should run; you can use the name
 	# 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
 	# of the user or the numerical ID. ATTENTION: For this to work the
 	# server must have been started with root privileges! In addition,
 	# server must have been started with root privileges! In addition,
@@ -89,23 +76,29 @@
 	# otherwise RESTART and REHASH won't work!
 	# otherwise RESTART and REHASH won't work!
 	;ServerUID = 65534
 	;ServerUID = 65534
 
 
-	# Group ID under which the ngircd should run; you can use the name
-	# of the group or the numerical ID. ATTENTION: For this to work the
-	# server must have been started with root privileges!
-	;ServerGID = 65534
+[Limits]
+	# Define some limits and timeouts for this ngIRCd instance. Default
+	# values should be safe, but it is wise to double-check :-)
 
 
-	# 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
+	# The server tries every <ConnectRetry> seconds to establish a link
+	# to not yet (or no longer) connected servers.
+	;ConnectRetry = 60
 
 
-	# This tells ngircd to write its current process id to a file.
-	# Note that the pidfile is written AFTER chroot and switching uid,
-	# i. e. the Directory the pidfile resides in must be writeable by
-	# the ngircd user and exist in the chroot directory.
-	;PidFile = /var/run/ngircd/ngircd.pid
+	# Maximum number of simultaneous in- and outbound connections the
+	# server is allowed to accept (0: unlimited):
+	;MaxConnections = 0
+
+	# Maximum number of simultaneous connections from a single IP address
+	# the server will accept (0: unlimited):
+	;MaxConnectionsIP = 5
+
+	# Maximum number of channels a user can be member of (0: no limit):
+	;MaxJoins = 10
+
+	# Maximum length of an user nick name (Default: 9, as in RFC 2812).
+	# Please note that all servers in an IRC network MUST use the same
+	# maximum nick name length!
+	;MaxNickLength = 9
 
 
 	# After <PingTimeout> seconds of inactivity the server will send a
 	# After <PingTimeout> seconds of inactivity the server will send a
 	# PING to the peer to test whether it is alive or not.
 	# PING to the peer to test whether it is alive or not.
@@ -115,9 +108,48 @@
 	# seconds, it will be disconnected by the server.
 	# seconds, it will be disconnected by the server.
 	;PongTimeout = 20
 	;PongTimeout = 20
 
 
-	# The server tries every <ConnectRetry> seconds to establish a link
-	# to not yet (or no longer) connected servers.
-	;ConnectRetry = 60
+[Options]
+	# Optional features and configuration options to further tweak the
+	# behavior of ngIRCd. If you want to get started quickly, you most
+	# probably don't have to make changes here -- they are all optional.
+
+	# Are remote IRC operators allowed to control this server, e.g.
+	# use commands like CONNECT, SQUIT, DIE, ...?
+	;AllowRemoteOper = no
+
+	# 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
+
+	# Set this hostname for every client instead of the real one.
+	# Please note: don't use the percentage sign ("%"), it is reserved for
+	# future extensions!
+	;CloakHost = irc.example.net
+
+	# Set every clients' user name to their nick name
+	;CloakUserToNick = yes
+
+	# Try to connect to other IRC servers using IPv4 and IPv6, if possible.
+	;ConnectIPv6 = yes
+	;ConnectIPv4 = yes
+
+	# Do any DNS lookups when a client connects to the server.
+	;DNS = yes
+
+	# Do IDENT lookups if ngIRCd has been compiled with support for it.
+	;Ident = yes
+
+	# Enhance user privacy slightly (useful for IRC server on TOR or I2P)
+	# by censoring some information like idle time, logon time, etc.
+	;MorePrivacy = no
+
+	# Normally ngIRCd doesn't send any messages to a client until it is
+	# registered. Enable this option to let the daemon send "NOTICE AUTH"
+	# messages to clients while connecting.
+	;NoticeAuth = no
 
 
 	# Should IRC Operators be allowed to use the MODE command even if
 	# Should IRC Operators be allowed to use the MODE command even if
 	# they are not(!) channel-operators?
 	# they are not(!) channel-operators?
@@ -127,46 +159,51 @@
 	# server? (This is a compatibility hack for ircd-irc2 servers)
 	# server? (This is a compatibility hack for ircd-irc2 servers)
 	;OperServerMode = no
 	;OperServerMode = no
 
 
-	# Are remote IRC operators allowed to control this server, e. g.
-	# use commands like CONNECT, SQUIT, DIE, ...?
-	;AllowRemoteOper = no
+	# Use PAM if ngIRCd has been compiled with support for it.
+	;PAM = no
 
 
 	# Allow Pre-Defined Channels only (see Section [Channels])
 	# Allow Pre-Defined Channels only (see Section [Channels])
 	;PredefChannelsOnly = no
 	;PredefChannelsOnly = no
 
 
-	# Don't do any DNS lookups when a client connects to the server.
-	;NoDNS = no
+	# Let ngIRCd send an "authentication PING" when a new client connects,
+	# and register this client only after receiving the corresponding
+	# "PONG" reply.
+	;RequireAuthPing = no
 
 
-	# Don't do any IDENT lookups, even if ngIRCd has been compiled
-	# with support for it.
-	;NoIdent = no
+	# Silently drop all incoming CTCP requests.
+	;ScrubCTCP = no
 
 
-	# Don't use PAM, even if ngIRCd has been compiled with support for it.
-	;NoPAM = no
+	# Syslog "facility" to which ngIRCd should send log messages.
+	# Possible values are system dependent, but most probably auth, daemon,
+	# user and local1 through local7 are possible values; see syslog(3).
+	# Default is "local5" for historical reasons, you probably want to
+	# change this to "daemon", for example.
+	;SyslogFacility = local1
 
 
-	# Don't use ZeroConf service registration, even if ngIRCd has been
-	# compiled with support for it (e.g. Howl, Avahi, Mac OS X).
-	;NoZeroConf = no
+	# Password required for using the WEBIRC command used by some
+	# Web-to-IRC gateways. If not set/empty, the WEBIRC command can't
+	# be used. (Default: not set)
+	;WebircPassword = xyz
 
 
-	# try to connect to other irc servers using ipv4 and ipv6, if possible
-	;ConnectIPv6 = yes
-	;ConnectIPv4 = yes
+;[SSL]
+	# SSL-related configuration options. Please note that this section
+	# is only available when ngIRCd is compiled with support for SSL!
+	# So don't forget to remove the ";" above if this is the case ...
 
 
-	# Maximum number of simultaneous in- and outbound connections the
-	# server is allowed to accept (0: unlimited):
-	;MaxConnections = 0
+	# SSL Server Key Certificate
+	;CertFile = :ETCDIR:/ssl/server-cert.pem
 
 
-	# Maximum number of simultaneous connections from a single IP address
-	# the server will accept (0: unlimited):
-	;MaxConnectionsIP = 5
+	# Diffie-Hellman parameters
+	;DHFile = :ETCDIR:/ssl/dhparams.pem
 
 
-	# Maximum number of channels a user can be member of (0: no limit):
-	;MaxJoins = 10
+	# SSL Server Key
+	;KeyFile = :ETCDIR:/ssl/server-key.pem
 
 
-	# Maximum length of an user nick name (Default: 9, as in RFC 2812).
-	# Please note that all servers in an IRC network MUST use the same
-	# maximum nick name length!
-	;MaxNickLength = 9
+	# password to decrypt SSLKeyFile (OpenSSL only)
+	;KeyFilePassword = secret
+
+	# Additional Listen Ports that expect SSL/TLS encrypted connections
+	;Ports = 6697, 9999
 
 
 [Operator]
 [Operator]
 	# [Operator] sections are used to define IRC Operators. There may be
 	# [Operator] sections are used to define IRC Operators. There may be
@@ -200,11 +237,11 @@
 
 
 	# IRC name of the remote server, must match the "Name" variable in
 	# IRC name of the remote server, must match the "Name" variable in
 	# the [Global] section of the other server (when using ngIRCd).
 	# the [Global] section of the other server (when using ngIRCd).
-	;Name = irc2.the.net
+	;Name = irc2.example.net
 
 
 	# Internet host name or IP address of the peer (only required when
 	# Internet host name or IP address of the peer (only required when
 	# this server should establish the connection).
 	# this server should establish the connection).
-	;Host = connect-to-host.the.net
+	;Host = connect-to-host.example.net
 
 
 	# IP address to use as _source_ address for the connection. if
 	# IP address to use as _source_ address for the connection. if
 	# unspecified, ngircd will let the operating system pick an address.
 	# unspecified, ngircd will let the operating system pick an address.

+ 36 - 25
doc/src/Doxyfile

@@ -1,6 +1,6 @@
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2005 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -8,11 +8,9 @@
 # (at your option) any later version.
 # (at your option) any later version.
 # Please read the file COPYING, README and AUTHORS for more information.
 # Please read the file COPYING, README and AUTHORS for more information.
 #
 #
-# $Id: Doxyfile,v 1.2 2005/07/23 00:48:38 alex Exp $
-#
-
 # This file describes the settings to be used by the documentation system
 # This file describes the settings to be used by the documentation system
 # doxygen (www.doxygen.org) for ngIRCd.
 # doxygen (www.doxygen.org) for ngIRCd.
+#
 
 
 #---------------------------------------------------------------------------
 #---------------------------------------------------------------------------
 # Project related configuration options
 # Project related configuration options
@@ -47,13 +45,6 @@ STRIP_FROM_PATH        = ../..
 
 
 JAVADOC_AUTOBRIEF      = YES
 JAVADOC_AUTOBRIEF      = YES
 
 
-# If the DETAILS_AT_TOP tag is set to YES then Doxygen 
-# will output the detailed description near the top, like JavaDoc.
-# If set to NO, the detailed description appears after the member 
-# documentation.
-
-DETAILS_AT_TOP         = NO
-
 # Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C 
 # Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C 
 # sources only. Doxygen will then generate output that is more tailored for C. 
 # sources only. Doxygen will then generate output that is more tailored for C. 
 # For instance, some of the names that are used will be different. The list 
 # For instance, some of the names that are used will be different. The list 
@@ -72,21 +63,16 @@ OPTIMIZE_OUTPUT_FOR_C  = YES
 
 
 EXTRACT_ALL            = YES
 EXTRACT_ALL            = YES
 
 
-# If the EXTRACT_PRIVATE tag is set to YES all private members of a class 
-# will be included in the documentation.
-
-EXTRACT_PRIVATE        = YES
-
 # If the EXTRACT_STATIC tag is set to YES all static members of a file 
 # If the EXTRACT_STATIC tag is set to YES all static members of a file 
 # will be included in the documentation.
 # will be included in the documentation.
 
 
 EXTRACT_STATIC         = YES
 EXTRACT_STATIC         = YES
 
 
-# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) 
-# defined locally in source files will be included in the documentation. 
-# If set to NO only classes defined in header files are included.
+# If the sources in your project are distributed over multiple directories
+# then setting the SHOW_DIRECTORIES tag to YES will show the directory
+# hierarchy in the documentation. The default is NO.
 
 
-EXTRACT_LOCAL_CLASSES  = YES
+SHOW_DIRECTORIES       = YES
 
 
 #---------------------------------------------------------------------------
 #---------------------------------------------------------------------------
 # configuration options related to the input files
 # configuration options related to the input files
@@ -116,18 +102,43 @@ RECURSIVE              = YES
 
 
 SOURCE_BROWSER         = YES
 SOURCE_BROWSER         = YES
 
 
+# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct
+# doxygen to hide any special comment blocks from generated source code
+# fragments. Normal C and C++ comments will always remain visible.
+
+STRIP_CODE_COMMENTS    = NO
+
+# If the REFERENCED_BY_RELATION tag is set to YES then for each documented
+# function all documented functions referencing it will be listed.
+
+REFERENCED_BY_RELATION = YES
+
+# If the REFERENCES_RELATION tag is set to YES then for each documented
+# function all documented entities called/used by that function will be listed.
+
+REFERENCES_RELATION    = YES
+
 #---------------------------------------------------------------------------
 #---------------------------------------------------------------------------
 # Output formats
 # Output formats
 #---------------------------------------------------------------------------
 #---------------------------------------------------------------------------
 
 
 GENERATE_HTML          = YES
 GENERATE_HTML          = YES
 
 
-HTML_OUTPUT            = html
-HTML_FILE_EXTENSION    = .html
-HTML_HEADER            = header.inc.html
+# The HTML_FOOTER tag can be used to specify a personal HTML footer for each
+# generated HTML page. If it is left blank doxygen will generate a standard
+# footer.
+
 HTML_FOOTER            = footer.inc.html
 HTML_FOOTER            = footer.inc.html
-HTML_STYLESHEET        = ngircd-doc.css
 
 
+# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML
+# documentation will contain sections that can be hidden and shown after the
+# page has loaded. For this to work a browser that supports JavaScript and
+# DHTML is required (for instance Mozilla 1.0+, Firefox Netscape 6.0+,
+# Internet explorer 5.0+, Konqueror, or Safari).
+
+HTML_DYNAMIC_SECTIONS  = YES
+
+GENERATE_DOCSET        = NO
 GENERATE_HTMLHELP      = NO
 GENERATE_HTMLHELP      = NO
 GENERATE_LATEX         = NO
 GENERATE_LATEX         = NO
 GENERATE_RTF           = NO
 GENERATE_RTF           = NO
@@ -148,6 +159,6 @@ GENERATE_PERLMOD       = NO
 # undefined via #undef or recursively expanded use the := operator 
 # undefined via #undef or recursively expanded use the := operator 
 # instead of the = operator.
 # instead of the = operator.
 
 
-PREDEFINED             = CONN_MODULE __client_c__
+PREDEFINED             = DEBUG ZLIB PAM ZEROCONF CONN_MODULE __client_c__
 
 
 # -eof-
 # -eof-

+ 2 - 2
doc/src/Makefile.am

@@ -1,6 +1,6 @@
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2008 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -9,7 +9,7 @@
 # Please read the file COPYING, README and AUTHORS for more information.
 # Please read the file COPYING, README and AUTHORS for more information.
 #
 #
 
 
-EXTRA_DIST = Doxyfile header.inc.html footer.inc.html ngircd-doc.css
+EXTRA_DIST = Doxyfile footer.inc.html
 
 
 maintainer-clean-local:
 maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in

+ 45 - 14
doc/src/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -16,7 +17,7 @@
 
 
 #
 #
 # ngIRCd -- The Next Generation IRC Daemon
 # ngIRCd -- The Next Generation IRC Daemon
-# Copyright (c)2001-2008 Alexander Barton (alex@barton.de)
+# Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
 #
 #
 # This program is free software; you can redistribute it and/or modify
 # 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
 # it under the terms of the GNU General Public License as published by
@@ -26,8 +27,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -52,11 +54,19 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -93,6 +103,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -152,9 +163,10 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
-EXTRA_DIST = Doxyfile header.inc.html footer.inc.html ngircd-doc.css
+EXTRA_DIST = Doxyfile footer.inc.html
 all: all-am
 all: all-am
 
 
 .SUFFIXES:
 .SUFFIXES:
@@ -162,14 +174,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  doc/src/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  doc/src/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu doc/src/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu doc/src/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -187,6 +199,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 tags: TAGS
 tags: TAGS
 TAGS:
 TAGS:
 
 
@@ -210,13 +223,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -244,6 +261,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -262,6 +280,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -270,18 +290,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -329,6 +359,7 @@ srcdoc:
 	doxygen
 	doxygen
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 0 - 10
doc/src/header.inc.html

@@ -1,10 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html lang="en">
-
-<head>
-  <meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
-  <title>ngIRCd Source Documentation</title>
-  <link href="ngircd-doc.css" rel="stylesheet" type="text/css">
-</head>
-<body>
-

+ 0 - 77
doc/src/ngircd-doc.css

@@ -1,77 +0,0 @@
-/*
- * Cascading Style Sheet for the ngIRCd source documentation
- *
- * $Id: ngircd-doc.css,v 1.2 2005/07/22 21:23:22 alex Exp $
- */
-
-BODY {
-	background-color: white;
-	color: black;
-	margin: 30px;
-	font-family: Geneva, sans-serif;
-	font-size: 12px;
-}
-
-A:visited { color: purple; background: transparent; }
-A:link { color: navy; background: transparent; }
-A:active { color: red; background: transparent; }
-A:hover { background: #ffa; }
-
-H1, H2, H3 {
-	font-family: Verdana, sans-serif;
-	background-color: white;
-	color: #005555;
-}
-H1 { margin-bottom: 10px; }
-H2 {
-	margin-top: 20px;
-	margin-bottom: 10px;
-}
-
-P, LI, TD, TH, DT {
-	font-family: Geneva, sans-serif;
-	font-size: 12px;
-	line-height: 1.2
-}
-
-DD { margin-bottom: 1em; }
-
-UL { list-style-type: square; }
-
-HR { margin: 2em 0px; }
-
-BODY>TABLE { padding: 1em 0px; }
-
-TD.mdRow {
-	border: 1px dotted silver;
-	background-color: #fff9dd;
-}
-
-TD.md { font-weight: bold; }
-
-TD.memItemLeft { padding-top: 4px; }
-TD.memItemRight { padding-top: 4px; }
-TD.mdescRight { font-style: italic; }
-
-DIV.qindex {
-	background-color: #eee;
-	border: 1px dotted silver;
-	padding: 3px;
-	margin-bottom: 2px;
-}
-
-DIV.nav {
-	margin: 1em 0px;
-}
-
-HR.footer { margin-top: 50px; }
-
-.comment {
-	color: gray;
-	font-style: italic;
-}
-.preprocessor { color: #f90; }
-.keyword, .keywordflow, .keywordtype { color: red; }
-.stringliteral { color: green; }
-
-/* -eof- */

+ 3 - 2
install-sh

@@ -1,7 +1,7 @@
 #!/bin/sh
 #!/bin/sh
 # install - install a program, script, or datafile
 # install - install a program, script, or datafile
 
 
-scriptversion=2006-12-25.00
+scriptversion=2009-04-28.21; # UTC
 
 
 # This originates from X11R5 (mit/util/scripts/install.sh), which was
 # This originates from X11R5 (mit/util/scripts/install.sh), which was
 # later released in X11R6 (xc/config/util/install.sh) with the
 # later released in X11R6 (xc/config/util/install.sh) with the
@@ -515,5 +515,6 @@ done
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # time-stamp-start: "scriptversion="
 # time-stamp-start: "scriptversion="
 # time-stamp-format: "%:y-%02m-%02d.%02H"
 # time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-end: "$"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
 # End:
 # End:

+ 143 - 92
man/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -29,8 +30,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -55,8 +57,36 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
 man5dir = $(mandir)/man5
 man5dir = $(mandir)/man5
 am__installdirs = "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"
 am__installdirs = "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"
 man8dir = $(mandir)/man8
 man8dir = $(mandir)/man8
@@ -65,6 +95,7 @@ MANS = $(man_MANS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -101,6 +132,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -160,6 +192,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 TEMPLATE_MANS = ngircd.conf.5.tmpl ngircd.8.tmpl
 TEMPLATE_MANS = ngircd.conf.5.tmpl ngircd.8.tmpl
@@ -175,14 +208,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  man/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  man/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu man/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu man/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -200,96 +233,83 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-install-man5: $(man5_MANS) $(man_MANS)
+$(am__aclocal_m4_deps):
+install-man5: $(man_MANS)
 	@$(NORMAL_INSTALL)
 	@$(NORMAL_INSTALL)
 	test -z "$(man5dir)" || $(MKDIR_P) "$(DESTDIR)$(man5dir)"
 	test -z "$(man5dir)" || $(MKDIR_P) "$(DESTDIR)$(man5dir)"
-	@list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \
-	l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
-	for i in $$l2; do \
-	  case "$$i" in \
-	    *.5*) list="$$list $$i" ;; \
-	  esac; \
+	@list=''; test -n "$(man5dir)" || exit 0; \
+	{ for i in $$list; do echo "$$i"; done; \
+	l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
+	  sed -n '/\.5[a-z]*$$/p'; \
+	} | while read p; do \
+	  if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
+	  echo "$$d$$p"; echo "$$p"; \
+	done | \
+	sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \
+	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
+	sed 'N;N;s,\n, ,g' | { \
+	list=; while read file base inst; do \
+	  if test "$$base" = "$$inst"; then list="$$list $$file"; else \
+	    echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \
+	    $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst" || exit $$?; \
+	  fi; \
 	done; \
 	done; \
-	for i in $$list; do \
-	  if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
-	  else file=$$i; fi; \
-	  ext=`echo $$i | sed -e 's/^.*\\.//'`; \
-	  case "$$ext" in \
-	    5*) ;; \
-	    *) ext='5' ;; \
-	  esac; \
-	  inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
-	  inst=`echo $$inst | sed -e 's/^.*\///'`; \
-	  inst=`echo $$inst | sed '$(transform)'`.$$ext; \
-	  echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \
-	  $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst"; \
-	done
+	for i in $$list; do echo "$$i"; done | $(am__base_list) | \
+	while read files; do \
+	  test -z "$$files" || { \
+	    echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man5dir)'"; \
+	    $(INSTALL_DATA) $$files "$(DESTDIR)$(man5dir)" || exit $$?; }; \
+	done; }
+
 uninstall-man5:
 uninstall-man5:
 	@$(NORMAL_UNINSTALL)
 	@$(NORMAL_UNINSTALL)
-	@list='$(man5_MANS) $(dist_man5_MANS) $(nodist_man5_MANS)'; \
-	l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
-	for i in $$l2; do \
-	  case "$$i" in \
-	    *.5*) list="$$list $$i" ;; \
-	  esac; \
-	done; \
-	for i in $$list; do \
-	  ext=`echo $$i | sed -e 's/^.*\\.//'`; \
-	  case "$$ext" in \
-	    5*) ;; \
-	    *) ext='5' ;; \
-	  esac; \
-	  inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
-	  inst=`echo $$inst | sed -e 's/^.*\///'`; \
-	  inst=`echo $$inst | sed '$(transform)'`.$$ext; \
-	  echo " rm -f '$(DESTDIR)$(man5dir)/$$inst'"; \
-	  rm -f "$(DESTDIR)$(man5dir)/$$inst"; \
-	done
-install-man8: $(man8_MANS) $(man_MANS)
+	@list=''; test -n "$(man5dir)" || exit 0; \
+	files=`{ for i in $$list; do echo "$$i"; done; \
+	l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
+	  sed -n '/\.5[a-z]*$$/p'; \
+	} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \
+	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
+	test -z "$$files" || { \
+	  echo " ( cd '$(DESTDIR)$(man5dir)' && rm -f" $$files ")"; \
+	  cd "$(DESTDIR)$(man5dir)" && rm -f $$files; }
+install-man8: $(man_MANS)
 	@$(NORMAL_INSTALL)
 	@$(NORMAL_INSTALL)
 	test -z "$(man8dir)" || $(MKDIR_P) "$(DESTDIR)$(man8dir)"
 	test -z "$(man8dir)" || $(MKDIR_P) "$(DESTDIR)$(man8dir)"
-	@list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \
-	l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
-	for i in $$l2; do \
-	  case "$$i" in \
-	    *.8*) list="$$list $$i" ;; \
-	  esac; \
+	@list=''; test -n "$(man8dir)" || exit 0; \
+	{ for i in $$list; do echo "$$i"; done; \
+	l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
+	  sed -n '/\.8[a-z]*$$/p'; \
+	} | while read p; do \
+	  if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
+	  echo "$$d$$p"; echo "$$p"; \
+	done | \
+	sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
+	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \
+	sed 'N;N;s,\n, ,g' | { \
+	list=; while read file base inst; do \
+	  if test "$$base" = "$$inst"; then list="$$list $$file"; else \
+	    echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \
+	    $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \
+	  fi; \
 	done; \
 	done; \
-	for i in $$list; do \
-	  if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
-	  else file=$$i; fi; \
-	  ext=`echo $$i | sed -e 's/^.*\\.//'`; \
-	  case "$$ext" in \
-	    8*) ;; \
-	    *) ext='8' ;; \
-	  esac; \
-	  inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
-	  inst=`echo $$inst | sed -e 's/^.*\///'`; \
-	  inst=`echo $$inst | sed '$(transform)'`.$$ext; \
-	  echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \
-	  $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst"; \
-	done
+	for i in $$list; do echo "$$i"; done | $(am__base_list) | \
+	while read files; do \
+	  test -z "$$files" || { \
+	    echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \
+	    $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \
+	done; }
+
 uninstall-man8:
 uninstall-man8:
 	@$(NORMAL_UNINSTALL)
 	@$(NORMAL_UNINSTALL)
-	@list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \
-	l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
-	for i in $$l2; do \
-	  case "$$i" in \
-	    *.8*) list="$$list $$i" ;; \
-	  esac; \
-	done; \
-	for i in $$list; do \
-	  ext=`echo $$i | sed -e 's/^.*\\.//'`; \
-	  case "$$ext" in \
-	    8*) ;; \
-	    *) ext='8' ;; \
-	  esac; \
-	  inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
-	  inst=`echo $$inst | sed -e 's/^.*\///'`; \
-	  inst=`echo $$inst | sed '$(transform)'`.$$ext; \
-	  echo " rm -f '$(DESTDIR)$(man8dir)/$$inst'"; \
-	  rm -f "$(DESTDIR)$(man8dir)/$$inst"; \
-	done
+	@list=''; test -n "$(man8dir)" || exit 0; \
+	files=`{ for i in $$list; do echo "$$i"; done; \
+	l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \
+	  sed -n '/\.8[a-z]*$$/p'; \
+	} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \
+	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
+	test -z "$$files" || { \
+	  echo " ( cd '$(DESTDIR)$(man8dir)' && rm -f" $$files ")"; \
+	  cd "$(DESTDIR)$(man8dir)" && rm -f $$files; }
 tags: TAGS
 tags: TAGS
 TAGS:
 TAGS:
 
 
@@ -298,6 +318,19 @@ CTAGS:
 
 
 
 
 distdir: $(DISTFILES)
 distdir: $(DISTFILES)
+	@list='$(MANS)'; if test -n "$$list"; then \
+	  list=`for p in $$list; do \
+	    if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
+	    if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
+	  if test -n "$$list" && \
+	    grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
+	    echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \
+	    grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/         /' >&2; \
+	    echo "       to fix them, install help2man, remove and regenerate the man pages;" >&2; \
+	    echo "       typically \`make maintainer-clean' will remove them" >&2; \
+	    exit 1; \
+	  else :; fi; \
+	else :; fi
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
 	list='$(DISTFILES)'; \
@@ -313,13 +346,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -351,6 +388,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -369,6 +407,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -377,18 +417,28 @@ install-data-am: install-man
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man: install-man5 install-man8
 install-man: install-man5 install-man8
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -438,6 +488,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 28 - 3
man/ngircd.8.tmpl

@@ -1,7 +1,7 @@
 .\"
 .\"
 .\" ngircd(8) manual page template
 .\" ngircd(8) manual page template
 .\"
 .\"
-.TH ngircd 8 "Dec 2010" ngircd "ngIRCd Manual"
+.TH ngircd 8 "Jul 2011" ngircd "ngIRCd Manual"
 .SH NAME
 .SH NAME
 ngIRCd \- the next generation IRC daemon
 ngIRCd \- the next generation IRC daemon
 .SH SYNOPSIS
 .SH SYNOPSIS
@@ -26,7 +26,7 @@ there are good chances that it also supports other UNIX-based operating
 systems as well. By default, ngIRCd writes diagnostic and informational messages using
 systems as well. By default, ngIRCd writes diagnostic and informational messages using
 the syslog mechanism.
 the syslog mechanism.
 .SH OPTIONS
 .SH OPTIONS
-The default behaviour of
+The default behavior of
 .BR ngircd
 .BR ngircd
 is to read its standard configuration file (see below), to detach from the
 is to read its standard configuration file (see below), to detach from the
 controlling terminal and to wait for clients.
 controlling terminal and to wait for clients.
@@ -68,7 +68,7 @@ Default "message of the day" (MOTD).
 The daemon understands the following signals:
 The daemon understands the following signals:
 .TP
 .TP
 \fBTERM\fR
 \fBTERM\fR
-Shut down all conections and terminate the daemon.
+Shut down all connections and terminate the daemon.
 .TP
 .TP
 \fBHUP\fR
 \fBHUP\fR
 Shut down all listening sockets, re-read the configuration file and
 Shut down all listening sockets, re-read the configuration file and
@@ -76,6 +76,31 @@ re-initialize the daemon.
 .SH HINTS
 .SH HINTS
 It's wise to use "ngircd \-\-configtest" to validate the configuration file
 It's wise to use "ngircd \-\-configtest" to validate the configuration file
 after changing it.
 after changing it.
+.SH DEBUGGING
+When ngIRCd is compiled with debug code, that is, its source code has
+been ./configure'd with "--enable-debug" and/or "--enable-sniffer" (witch
+enables debug mode automatically as well), you can use two more command
+line options and two more signals to debug problems with the daemon itself
+or IRC clients:
+.PP
+\fBOptions:\fR
+.TP
+\fB\-d\fR, \fB\-\-debug\fR
+Enable debug mode and log extra messages.
+.TP
+\fB\-s\fR, \fB\-\-sniffer\fR
+Enable IRC protocol sniffer, which logs all sent and received IRC commands to
+the console/syslog. This option requires that ngIRCd has been ./configure'd
+with "--enable-sniffer" and enables debug mode automatically, too.
+.PP
+\fBSignals:\fR
+.TP
+\fBUSR1\fR
+Toggle debug mode on and off during runtime.
+.TP
+\fBUSR2\fR
+Dump internal server state to the console/syslog when debug mode is on (use
+command line option \-\-debug or signal USR1).
 .SH AUTHORS
 .SH AUTHORS
 Alexander Barton, <alex@barton.de>
 Alexander Barton, <alex@barton.de>
 .br
 .br

+ 251 - 169
man/ngircd.conf.5.tmpl

@@ -1,7 +1,7 @@
 .\"
 .\"
 .\" ngircd.conf(5) manual page template
 .\" ngircd.conf(5) manual page template
 .\"
 .\"
-.TH ngircd.conf 5 "Dec 2010" ngircd "ngIRCd Manual"
+.TH ngircd.conf 5 "Jun 2011" ngircd "ngIRCd Manual"
 .SH NAME
 .SH NAME
 ngircd.conf \- configuration file of ngIRCd
 ngircd.conf \- configuration file of ngIRCd
 .SH SYNOPSIS
 .SH SYNOPSIS
@@ -10,11 +10,12 @@ ngircd.conf \- configuration file of ngIRCd
 .BR ngircd.conf
 .BR ngircd.conf
 is the configuration file of the
 is the configuration file of the
 .BR ngircd (8)
 .BR ngircd (8)
-Internet Relay Chat (IRC) daemon which you should adept to your local
+Internet Relay Chat (IRC) daemon, which must be customized to the local
 preferences and needs.
 preferences and needs.
 .PP
 .PP
 Most variables can be modified while the ngIRCd daemon is already running:
 Most variables can be modified while the ngIRCd daemon is already running:
-It will reload its configuration when a HUP signal is received.
+It will reload its configuration file when a HUP signal or REHASH command
+is received.
 .SH "FILE FORMAT"
 .SH "FILE FORMAT"
 The file consists of sections and parameters. A section begins with the name
 The file consists of sections and parameters. A section begins with the name
 of the section in square brackets and continues until the next section
 of the section in square brackets and continues until the next section
@@ -36,237 +37,318 @@ The file format is line-based - that means, each non-empty newline-terminated
 line represents either a comment, a section name, or a parameter.
 line represents either a comment, a section name, or a parameter.
 .PP
 .PP
 Section and parameter names are not case sensitive.
 Section and parameter names are not case sensitive.
+.PP
+There are three types of variables:
+.I booleans,
+.I text strings,
+and
+.I numbers.
+Boolean values are
+.I true
+if they are "yes", "true", or any non-null integer. Text strings are used 1:1
+without leading and following spaces; there is no way to quote strings. And
+for numbers all decimal integer values are valid.
+.PP
+In addition, some string or numerical variables accept lists of values,
+separated by commas (",").
 .SH "SECTION OVERVIEW"
 .SH "SECTION OVERVIEW"
-The file can contain blocks of four types: [Global], [Operator], [Server],
-and [Channel].
+The file can contain blocks of seven types: [Global], [Limits], [Options],
+[SSL], [Operator], [Server], and [Channel].
 .PP
 .PP
 The main configuration of the server is stored in the
 The main configuration of the server is stored in the
 .I [Global]
 .I [Global]
-section, like the server name, administrative information and the
-ports on which the server should be listening. IRC operators of this
-server are defined in
+section, like the server name, administrative information and the ports on
+which the server should be listening. The variables in this section have to be
+adjusted to the local requirements most of the time, whereas all the variables
+in the other sections can be left on there defaults very often.
+.PP
+Options in the
+.I [Limits]
+block are used to tweak different limits and timeouts of the daemon, like the
+maximum number of clients allowed to connect to this server. Variables in the
+.I [Options]
+section can be used to enable or disable specific features of ngIRCd, like
+support for IDENT, PAM, IPv6, and protocol and cloaking features. The
+.I [SSL]
+block contains all SSL-related configuration variables. These three sections
+are all optional.
+.PP
+IRC operators of this server are defined in
 .I [Operator]
 .I [Operator]
-blocks.
+blocks. Links to remote servers are configured in
 .I [Server]
 .I [Server]
-is the section where server links are configured. And
+sections. And
 .I [Channel]
 .I [Channel]
 blocks are used to configure pre-defined ("persistent") IRC channels.
 blocks are used to configure pre-defined ("persistent") IRC channels.
 .PP
 .PP
-There can be more than one [Operator], [Server] and [Channel] sections
-per configuration file, but only one [Global] section.
+There can be more than one [Operator], [Server] and [Channel] section per
+configuration file (one for each operator, server, and channel), but only
+exactly one [Global], one [Limits], one [Options], and one [SSL] section.
 .SH [GLOBAL]
 .SH [GLOBAL]
 The
 The
 .I [Global]
 .I [Global]
-section is used to define the server main configuration, like the server
-name and the ports on which the server should be listening.
+section of this file is used to define the main configuration of the server,
+like the server name and the ports on which the server should be listening.
+These settings depend on your personal preferences, so you should make sure
+that they correspond to your installation and setup!
 .TP
 .TP
-\fBName\fR
+\fBName\fR (string; required)
 Server name in the IRC network. This is an individual name of the IRC
 Server name in the IRC network. This is an individual name of the IRC
 server, it is not related to the DNS host name. It must be unique in the
 server, it is not related to the DNS host name. It must be unique in the
 IRC network and must contain at least one dot (".") character.
 IRC network and must contain at least one dot (".") character.
 .TP
 .TP
-\fBInfo\fR
-Info text of the server. This will be shown by WHOIS and LINKS requests for
-example.
-.TP
-\fBPassword\fR
-Global password for all users needed to connect to the server. The default
-is empty, so no password is required.
-.TP
-\fBWebircPassword\fR
-Password required for using the WEBIRC command used by some Web-to-IRC
-gateways. If not set or empty, the WEBIRC command can't be used.
-Default: not set.
-.TP
-\fBAdminInfo1\fR, \fBAdminInfo2\fR, \fBAdminEMail\fR
+\fBAdminInfo1\fR, \fBAdminInfo2\fR, \fBAdminEMail\fR (string)
 Information about the server and the administrator, used by the ADMIN
 Information about the server and the administrator, used by the ADMIN
-command.
-.TP
-\fBPorts\fR
-Ports on which the server should listen. There may be more than one port,
-separated with commas (","). Default: 6667, unless \fBSSL_Ports\fR are also
-specified.
+command. This information is not required by the server but by RFC!
 .TP
 .TP
-\fBSSLPorts\fR
-Same as \fBPorts\fR , except that ngIRCd will expect incoming connections
-to be SSL/TLS encrypted. Common port numbers for SSL-encrypted IRC are 6669
-and 6697. Default: none.
-.TP
-\fBSSLKeyFile\fR
-Filename of SSL Server Key to be used for SSL connections. This is required for
-SSL/TLS support.
-.TP
-\fBSSLKeyFilePassword\fR
-(OpenSSL only:) Password to decrypt private key.
-.TP
-\fBSSLCertFile\fR
-Certificate file of the private key.
-.TP
-\fBSSLDHFile\fR
-Name of the Diffie-Hellman Parameter file. Can be created with gnutls
-"certtool \-\-generate-dh-params" or "openssl dhparam".
-If this file is not present, it will be generated on startup when ngIRCd
-was compiled with gnutls support (this may take some time). If ngIRCd
-was compiled with OpenSSL, then (Ephemeral)-Diffie-Hellman Key Exchanges and several
-Cipher Suites will not be available.
+\fBInfo\fR (string)
+Info text of the server. This will be shown by WHOIS and LINKS requests for
+example.
 .TP
 .TP
-\fBListen\fR
+\fBListen\fR (list of strings)
 A comma separated list of IP address on which the server should listen.
 A comma separated list of IP address on which the server should listen.
 If unset, the defaults value is "0.0.0.0" or, if ngIRCd was compiled
 If unset, the defaults value is "0.0.0.0" or, if ngIRCd was compiled
 with IPv6 support, "::,0.0.0.0". So the server listens on all configured
 with IPv6 support, "::,0.0.0.0". So the server listens on all configured
 IP addresses and interfaces by default.
 IP addresses and interfaces by default.
 .TP
 .TP
-\fBSyslogFacility\fR
-Syslog "facility" to which ngIRCd should send log messages. Possible
-values are system dependant, but most probably "auth", "daemon", "user"
-and "local1" through "local7" are possible values; see syslog(3).
-Default is "local5" for historical reasons, you probably want to
-change this to "daemon", for example.
-.TP
-\fBMotdFile\fR
-Text file with the "message of the day" (MOTD). This message will be shown
-to all users connecting to the server. Changes made to this file
-take effect when ngircd is instructed to re-read its configuration file.
+\fBMotdFile\fR (string)
+Text file with the "message of the day" (MOTD). This message will be shown to
+all users connecting to the server. Please note: Changes made to this file
+take effect when ngircd starts up or is instructed to re-read its
+configuration file.
 .TP
 .TP
-\fBMotdPhrase\fR
+\fBMotdPhrase\fR (string)
 A simple Phrase (<256 chars) if you don't want to use a MOTD file.
 A simple Phrase (<256 chars) if you don't want to use a MOTD file.
 .TP
 .TP
-\fBServerUID\fR
-User ID under which the server should run; you can use the name of the user
-or the numerical ID.
-.PP
-.RS
-.B Attention:
-.br
-For this to work the server must have been
-started with root privileges! In addition, the configuration and MOTD files
-must be readable by this user, otherwise RESTART and REHASH won't work!
-.RE
+\fBPassword\fR (string)
+Global password for all users needed to connect to the server. The default is
+empty, so no password is required. Please note: This feature is not available
+if ngIRCd is using PAM!
 .TP
 .TP
-\fBServerGID\fR
+\fBPidFile\fR (string)
+This tells ngIRCd to write its current process ID to a file. Note that the
+pidfile is written AFTER chroot and switching the user ID, e.g. the directory
+the pidfile resides in must be writable by the ngIRCd user and exist in the
+chroot directory (if configured, see above).
+.TP
+\fBPorts\fR (list of numbers)
+Ports on which the server should listen. There may be more than one port,
+separated with commas (","). Default: 6667, unless \fBSSL_Ports\fR are also
+specified.
+.TP
+\fBServerGID\fR (string or number)
 Group ID under which the ngIRCd should run; you can use the name of the
 Group ID under which the ngIRCd should run; you can use the name of the
 group or the numerical ID.
 group or the numerical ID.
 .PP
 .PP
 .RS
 .RS
 .B Attention:
 .B Attention:
 .br
 .br
-For this to work the server must have
-been started with root privileges!
+For this to work the server must have been started with root privileges!
 .RE
 .RE
 .TP
 .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.
+\fBServerUID\fR (string or number)
+User ID under which the server should run; you can use the name of the user
+or the numerical ID.
 .PP
 .PP
 .RS
 .RS
 .B Attention:
 .B Attention:
 .br
 .br
-For this to work the server must have
-been started with root privileges!
+For this to work the server must have been started with root privileges! In
+addition, the configuration and MOTD files must be readable by this user,
+otherwise RESTART and REHASH won't work!
 .RE
 .RE
+.SH [LIMITS]
+Define some limits and timeouts for this ngIRCd instance. Default values
+should be safe, but it is wise to double-check :-)
 .TP
 .TP
-\fBPidFile\fR
-This tells ngIRCd to write its current process ID to a file. Note that the
-pidfile is written AFTER chroot and switching the user ID, i. e. the
-directory the pidfile resides in must be writeable by the ngIRCd user and
-exist in the chroot directory (if configured, see above).
-.RE
+\fBConnectRetry\fR (number)
+The server tries every <ConnectRetry> seconds to establish a link to not yet
+(or no longer) connected servers. Default: 60.
+.TP
+\fBMaxConnections\fR (number)
+Maximum number of simultaneous in- and outbound connections the server is
+allowed to accept (0: unlimited). Default: 0.
+.TP
+\fBMaxConnectionsIP\fR (number)
+Maximum number of simultaneous connections from a single IP address that
+the server will accept (0: unlimited). This configuration options lowers
+the risk of denial of service attacks (DoS). Default: 5.
+.TP
+\fBMaxJoins\fR (number)
+Maximum number of channels a user can be member of (0: no limit).
+Default: 10.
+.TP
+\fBMaxNickLength\fR (number)
+Maximum length of an user nick name (Default: 9, as in RFC 2812). Please
+note that all servers in an IRC network MUST use the same maximum nick name
+length!
 .TP
 .TP
-\fBPingTimeout\fR
+\fBPingTimeout\fR (number)
 After <PingTimeout> seconds of inactivity the server will send a PING to
 After <PingTimeout> seconds of inactivity the server will send a PING to
 the peer to test whether it is alive or not. Default: 120.
 the peer to test whether it is alive or not. Default: 120.
 .TP
 .TP
-\fBPongTimeout\fR
+\fBPongTimeout\fR (number)
 If a client fails to answer a PING with a PONG within <PongTimeout>
 If a client fails to answer a PING with a PONG within <PongTimeout>
 seconds, it will be disconnected by the server. Default: 20.
 seconds, it will be disconnected by the server. Default: 20.
+.SH [OPTIONS]
+Optional features and configuration options to further tweak the behavior of
+ngIRCd. If you want to get started quickly, you most probably don't have to
+make changes here -- they are all optional.
 .TP
 .TP
-\fBConnectRetry\fR
-The server tries every <ConnectRetry> seconds to establish a link to not yet
-(or no longer) connected servers. Default: 60.
+\fBAllowRemoteOper\fR (boolean)
+Are IRC operators connected to remote servers allowed to control this server,
+e.g. are they allowed to use administrative commands like CONNECT, DIE,
+SQUIT, ... that affect this server? Default: no.
 .TP
 .TP
-\fBOperCanUseMode\fR
-Should IRC Operators be allowed to use the MODE command even if they are
-not(!) channel-operators? Default: no.
+\fBChrootDir\fR (string)
+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
 .TP
-\fBOperServerMode\fR
-If \fBOperCanUseMode\fR is enabled, this may lead the compatibility problems with
-Servers that run the ircd-irc2 Software. This Option "masks" mode requests
-by non-chanops as if they were coming from the server. Default: no.
+\fBCloakHost\fR (string)
+Set this hostname for every client instead of the real one. Default: empty,
+don't change.
+.PP
+.RS
+.B Please note:
+.br
+Don't use the percentage sign ("%"), it is reserved for future extensions!
+.RE
 .TP
 .TP
-\fBAllowRemoteOper\fR
-Are IRC operators connected to remote servers allowed to control this server,
-e. g. are they allowed to use administrative commands like CONNECT, DIE,
-SQUIT, ... that affect this server? Default: no.
+\fBCloakUserToNick\fR (boolean)
+Set every clients' user name to their nick name and hide the one supplied
+by the IRC client. Default: no.
 .TP
 .TP
-\fBPredefChannelsOnly\fR
-If enabled, no new channels can be created. Useful if
-you do not want to have channels other than those defined in
-[Channel] sections in the configuration file.
-Default: no.
+\fBConnectIPv4\fR (boolean)
+Set this to no if you do not want ngIRCd to connect to other IRC servers using
+the IPv4 protocol. This allows the usage of ngIRCd in IPv6-only setups.
+Default: yes.
 .TP
 .TP
-\fBNoDNS\fR
-If set to true, ngIRCd will not make DNS lookups when clients connect.
+\fBConnectIPv6\fR (boolean)
+Set this to no if you do not want ngIRCd to connect to other IRC servers using
+the IPv6 protocol.
+Default: yes.
+.TP
+\fBDNS\fR (boolean)
+If set to false, ngIRCd will not make any DNS lookups when clients connect.
 If you configure the daemon to connect to other servers, ngIRCd may still
 If you configure the daemon to connect to other servers, ngIRCd may still
 perform a DNS lookup if required.
 perform a DNS lookup if required.
-Default: no.
+Default: yes.
 .TP
 .TP
-\fBNoIdent\fR
+\fBIdent\fR (boolean)
 If ngIRCd is compiled with IDENT support this can be used to disable IDENT
 If ngIRCd is compiled with IDENT support this can be used to disable IDENT
 lookups at run time.
 lookups at run time.
+Default: yes.
+.TP
+\fBMorePrivacy\fR (boolean)
+This will cause ngIRCd to censor user idle time, logon time as well as the
+part/quit messages (that are sometimes used to inform everyone about which
+client software is being used). WHOWAS requests are also silently ignored.
+This option is most useful when ngIRCd is being used together with
+anonymizing software such as TOR or I2P and one does not wish to make it
+too easy to collect statistics on the users.
 Default: no.
 Default: no.
 .TP
 .TP
-\fBNoPAM\fR
+\fBNoticeAuth\fR (boolean)
+Normally ngIRCd doesn't send any messages to a client until it is registered.
+Enable this option to let the daemon send "NOTICE AUTH" messages to clients
+while connecting. Default: no.
+.TP
+\fBOperCanUseMode\fR (boolean)
+Should IRC Operators be allowed to use the MODE command even if they are
+not(!) channel-operators? Default: no.
+.TP
+\fBOperServerMode\fR (boolean)
+If \fBOperCanUseMode\fR is enabled, this may lead the compatibility problems
+with Servers that run the ircd-irc2 Software. This Option "masks" mode
+requests by non-chanops as if they were coming from the server. Default: no;
+only enable it if you have ircd-irc2 servers in your IRC network.
+.TP
+\fBPAM\fR (boolean)
 If ngIRCd is compiled with PAM support this can be used to disable all calls
 If ngIRCd is compiled with PAM support this can be used to disable all calls
 to the PAM library at runtime; all users connecting without password are
 to the PAM library at runtime; all users connecting without password are
 allowed to connect, all passwords given will fail.
 allowed to connect, all passwords given will fail.
-Default: no.
-.TP
-\fBNoZeroConf\fR
-If ngIRCd is compiled to register its services using ZeroConf (e.g. using
-Howl, Avahi or on Mac OS X) this parameter can be used to disable service
-registration at runtime.
-Default: no.
-.TP
-\fBConnectIPv4\fR
-Set this to no if you do not want ngIRCd to connect to other IRC servers using
-IPv4. This allows usage of ngIRCd in IPv6-only setups.
 Default: yes.
 Default: yes.
 .TP
 .TP
-\fBConnectIPv6\fR
-Set this to no if you do not want ngIRCd to connect to other irc servers using IPv6.
-Default: yes.
+\fBPredefChannelsOnly\fR (boolean)
+If enabled, no new channels can be created. Useful if you do not want to have
+other channels than those defined in [Channel] sections in the configuration
+file on this server.
+Default: no.
 .TP
 .TP
-\fBMaxConnections\fR
-Maximum number of simultaneous in- and outbound connections the server is
-allowed to accept (0: unlimited). Default: 0.
+\fBRequireAuthPing\fR (boolean)
+Let ngIRCd send an "authentication PING" when a new client connects, and
+register this client only after receiving the corresponding "PONG" reply.
+Default: no.
 .TP
 .TP
-\fBMaxConnectionsIP\fR
-Maximum number of simultaneous connections from a single IP address that
-the server will accept (0: unlimited). This configuration options lowers
-the risk of denial of service attacks (DoS). Default: 5.
+\fBScrubCTCP\fR (boolean)
+If set to true, ngIRCd will silently drop all CTCP requests sent to it from
+both clients and servers. It will also not forward CTCP requests to any
+other servers. CTCP requests can be used to query user clients about which
+software they are using and which versions said software is. CTCP can also be
+used to reveal clients IP numbers. ACTION CTCP requests are not blocked,
+this means that /me commands will not be dropped, but please note that
+blocking CTCP will disable file sharing between users!
+Default: no.
 .TP
 .TP
-\fBMaxJoins\fR
-Maximum number of channels a user can be member of (0: no limit).
-Default: 10.
+\fBSyslogFacility\fR (string)
+Syslog "facility" to which ngIRCd should send log messages. Possible
+values are system dependent, but most probably "auth", "daemon", "user"
+and "local1" through "local7" are possible values; see syslog(3).
+Default is "local5" for historical reasons, you probably want to
+change this to "daemon", for example.
 .TP
 .TP
-\fBMaxNickLength\fR
-Maximum length of an user nick name (Default: 9, as in RFC 2812). Please
-note that all servers in an IRC network MUST use the same maximum nick name
-length!
+\fBWebircPassword\fR (string)
+Password required for using the WEBIRC command used by some Web-to-IRC
+gateways. If not set or empty, the WEBIRC command can't be used.
+Default: not set.
+.SH [SSL]
+All SSL-related configuration variables are located in the
+.I [SSL]
+section. Please note that this whole section is only recognized by ngIRCd
+when it is compiled with support for SSL using OpenSSL or GnuTLS!
+.TP
+\fBCertFile\fR (string)
+SSL Certificate file of the private server key.
+.TP
+\fBDHFile\fR (string)
+Name of the Diffie-Hellman Parameter file. Can be created with GnuTLS
+"certtool \-\-generate-dh-params" or "openssl dhparam". If this file is not
+present, it will be generated on startup when ngIRCd was compiled with GnuTLS
+support (this may take some time). If ngIRCd was compiled with OpenSSL, then
+(Ephemeral)-Diffie-Hellman Key Exchanges and several Cipher Suites will not be
+available.
+.TP
+\fBKeyFile\fR (string)
+Filename of SSL Server Key to be used for SSL connections. This is required
+for SSL/TLS support.
+.TP
+\fBKeyFilePassword\fR (string)
+OpenSSL only: Password to decrypt the private key file.
+.TP
+\fBPorts\fR (list of numbers)
+Same as \fBPorts\fR , except that ngIRCd will expect incoming connections
+to be SSL/TLS encrypted. Common port numbers for SSL-encrypted IRC are 6669
+and 6697. Default: none.
 .SH [OPERATOR]
 .SH [OPERATOR]
 .I [Operator]
 .I [Operator]
 sections are used to define IRC Operators. There may be more than one
 sections are used to define IRC Operators. There may be more than one
 .I [Operator]
 .I [Operator]
 block, one for each local operator.
 block, one for each local operator.
 .TP
 .TP
-\fBName\fR
+\fBName\fR (string)
 ID of the operator (may be different of the nick name).
 ID of the operator (may be different of the nick name).
 .TP
 .TP
-\fBPassword\fR
+\fBPassword\fR (string)
 Password of the IRC operator.
 Password of the IRC operator.
 .TP
 .TP
-\fBMask\fR
+\fBMask\fR (string)
 Mask that is to be checked before an /OPER for this account is accepted.
 Mask that is to be checked before an /OPER for this account is accepted.
 Example: nick!ident@*.example.com
 Example: nick!ident@*.example.com
 .SH [SERVER]
 .SH [SERVER]
@@ -287,40 +369,40 @@ There may be more than one
 .I [Server]
 .I [Server]
 block.
 block.
 .TP
 .TP
-\fBName\fR
+\fBName\fR (string)
 IRC name of the remote server.
 IRC name of the remote server.
 .TP
 .TP
-\fBHost\fR
+\fBHost\fR (string)
 Internet host name (or IP address) of the peer.
 Internet host name (or IP address) of the peer.
 .TP
 .TP
-\fBBind\fR
+\fBBind\fR (string)
 IP address to use as source IP for the outgoing connection. Default is
 IP address to use as source IP for the outgoing connection. Default is
 to let the operating system decide.
 to let the operating system decide.
 .TP
 .TP
-\fBPort\fR
+\fBPort\fR (number)
 Port of the remote server to which ngIRCd should connect (active).
 Port of the remote server to which ngIRCd should connect (active).
 If no port is assigned to a configured server, the daemon only waits for
 If no port is assigned to a configured server, the daemon only waits for
 incoming connections (passive, default).
 incoming connections (passive, default).
 .TP
 .TP
-\fBMyPassword\fR
+\fBMyPassword\fR (string)
 Own password for this connection. This password has to be configured as
 Own password for this connection. This password has to be configured as
 \fBPeerPassword\fR on the other server. Must not have ':' as first character.
 \fBPeerPassword\fR on the other server. Must not have ':' as first character.
 .TP
 .TP
-\fBPeerPassword\fR
+\fBPeerPassword\fR (string)
 Foreign password for this connection. This password has to be configured as
 Foreign password for this connection. This password has to be configured as
 \fBMyPassword\fR on the other server.
 \fBMyPassword\fR on the other server.
 .TP
 .TP
-\fBGroup\fR
+\fBGroup\fR (number)
 Group of this server (optional).
 Group of this server (optional).
 .TP
 .TP
-\fBPassive\fR
+\fBPassive\fR (boolean)
 Disable automatic connection even if port value is specified. Default: false.
 Disable automatic connection even if port value is specified. Default: false.
 You can use the IRC Operator command CONNECT later on to create the link.
 You can use the IRC Operator command CONNECT later on to create the link.
 .TP
 .TP
-\fBSSLConnect\fR
+\fBSSLConnect\fR (boolean)
 Connect to the remote server using TLS/SSL. Default: false.
 Connect to the remote server using TLS/SSL. Default: false.
 .TP
 .TP
-\fBServiceMask\fR
+\fBServiceMask\fR (string)
 Define a (case insensitive) mask matching nick names that should be treated as
 Define a (case insensitive) mask matching nick names that should be treated as
 IRC services when introduced via this remote server. REGULAR SERVERS DON'T NEED
 IRC services when introduced via this remote server. REGULAR SERVERS DON'T NEED
 this parameter, so leave it empty (which is the default).
 this parameter, so leave it empty (which is the default).
@@ -342,19 +424,19 @@ There may be more than one
 .I [Channel]
 .I [Channel]
 block.
 block.
 .TP
 .TP
-\fBName\fR
+\fBName\fR (string)
 Name of the channel, including channel prefix ("#" or "&").
 Name of the channel, including channel prefix ("#" or "&").
 .TP
 .TP
-\fBTopic\fR
+\fBTopic\fR (string)
 Topic for this channel.
 Topic for this channel.
 .TP
 .TP
-\fBModes\fR
+\fBModes\fR (string)
 Initial channel modes.
 Initial channel modes.
 .TP
 .TP
-\fBKey\fR
+\fBKey\fR (string)
 Sets initial channel key (only relevant if channel mode "k" is set).
 Sets initial channel key (only relevant if channel mode "k" is set).
 .TP
 .TP
-\fBKeyFile\fR
+\fBKeyFile\fR (string)
 Path and file name of a "key file" containing individual channel keys for
 Path and file name of a "key file" containing individual channel keys for
 different users. The file consists of plain text lines with the following
 different users. The file consists of plain text lines with the following
 syntax (without spaces!):
 syntax (without spaces!):
@@ -397,7 +479,7 @@ without problems, but moving or deleting the file will have not effect until
 the daemon re-reads its configuration!
 the daemon re-reads its configuration!
 .RE
 .RE
 .TP
 .TP
-\fBMaxUsers\fR
+\fBMaxUsers\fR (number)
 Set maximum user limit for this channel (only relevant if channel mode "l"
 Set maximum user limit for this channel (only relevant if channel mode "l"
 is set).
 is set).
 .SH HINTS
 .SH HINTS

+ 29 - 20
missing

@@ -1,10 +1,10 @@
 #! /bin/sh
 #! /bin/sh
 # Common stub for a few missing GNU programs while installing.
 # Common stub for a few missing GNU programs while installing.
 
 
-scriptversion=2006-05-10.23
+scriptversion=2009-04-28.21; # UTC
 
 
-# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006
-#   Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,
+# 2008, 2009 Free Software Foundation, Inc.
 # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
 # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
 
 
 # This program is free software; you can redistribute it and/or modify
 # This program is free software; you can redistribute it and/or modify
@@ -18,9 +18,7 @@ scriptversion=2006-05-10.23
 # GNU General Public License for more details.
 # GNU General Public License for more details.
 
 
 # You should have received a copy of the GNU General Public License
 # You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-# 02110-1301, USA.
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 
 # As a special exception to the GNU General Public License, if you
 # As a special exception to the GNU General Public License, if you
 # distribute this file as part of a program that contains a
 # distribute this file as part of a program that contains a
@@ -89,6 +87,9 @@ Supported PROGRAM values:
   tar          try tar, gnutar, gtar, then tar without non-portable flags
   tar          try tar, gnutar, gtar, then tar without non-portable flags
   yacc         create \`y.tab.[ch]', if possible, from existing .[ch]
   yacc         create \`y.tab.[ch]', if possible, from existing .[ch]
 
 
+Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and
+\`g' are ignored when checking the name.
+
 Send bug reports to <bug-automake@gnu.org>."
 Send bug reports to <bug-automake@gnu.org>."
     exit $?
     exit $?
     ;;
     ;;
@@ -106,15 +107,22 @@ Send bug reports to <bug-automake@gnu.org>."
 
 
 esac
 esac
 
 
+# normalize program name to check for.
+program=`echo "$1" | sed '
+  s/^gnu-//; t
+  s/^gnu//; t
+  s/^g//; t'`
+
 # Now exit if we have it, but it failed.  Also exit now if we
 # Now exit if we have it, but it failed.  Also exit now if we
 # don't have it and --version was passed (most likely to detect
 # don't have it and --version was passed (most likely to detect
-# the program).
+# the program).  This is about non-GNU programs, so use $1 not
+# $program.
 case $1 in
 case $1 in
-  lex|yacc)
+  lex*|yacc*)
     # Not GNU programs, they don't have --version.
     # Not GNU programs, they don't have --version.
     ;;
     ;;
 
 
-  tar)
+  tar*)
     if test -n "$run"; then
     if test -n "$run"; then
        echo 1>&2 "ERROR: \`tar' requires --run"
        echo 1>&2 "ERROR: \`tar' requires --run"
        exit 1
        exit 1
@@ -138,7 +146,7 @@ esac
 
 
 # If it does not exist, or fails to run (possibly an outdated version),
 # If it does not exist, or fails to run (possibly an outdated version),
 # try to emulate it.
 # try to emulate it.
-case $1 in
+case $program in
   aclocal*)
   aclocal*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
@@ -148,7 +156,7 @@ WARNING: \`$1' is $msg.  You should only need it if
     touch aclocal.m4
     touch aclocal.m4
     ;;
     ;;
 
 
-  autoconf)
+  autoconf*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
          you modified \`${configure_ac}'.  You might want to install the
          you modified \`${configure_ac}'.  You might want to install the
@@ -157,7 +165,7 @@ WARNING: \`$1' is $msg.  You should only need it if
     touch configure
     touch configure
     ;;
     ;;
 
 
-  autoheader)
+  autoheader*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
          you modified \`acconfig.h' or \`${configure_ac}'.  You might want
          you modified \`acconfig.h' or \`${configure_ac}'.  You might want
@@ -187,7 +195,7 @@ WARNING: \`$1' is $msg.  You should only need it if
 	   while read f; do touch "$f"; done
 	   while read f; do touch "$f"; done
     ;;
     ;;
 
 
-  autom4te)
+  autom4te*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is needed, but is $msg.
 WARNING: \`$1' is needed, but is $msg.
          You might have modified some files without having the
          You might have modified some files without having the
@@ -210,7 +218,7 @@ WARNING: \`$1' is needed, but is $msg.
     fi
     fi
     ;;
     ;;
 
 
-  bison|yacc)
+  bison*|yacc*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' $msg.  You should only need it if
 WARNING: \`$1' $msg.  You should only need it if
          you modified a \`.y' file.  You may need the \`Bison' package
          you modified a \`.y' file.  You may need the \`Bison' package
@@ -240,7 +248,7 @@ WARNING: \`$1' $msg.  You should only need it if
     fi
     fi
     ;;
     ;;
 
 
-  lex|flex)
+  lex*|flex*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
          you modified a \`.l' file.  You may need the \`Flex' package
          you modified a \`.l' file.  You may need the \`Flex' package
@@ -263,7 +271,7 @@ WARNING: \`$1' is $msg.  You should only need it if
     fi
     fi
     ;;
     ;;
 
 
-  help2man)
+  help2man*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
 	 you modified a dependency of a manual page.  You may need the
 	 you modified a dependency of a manual page.  You may need the
@@ -277,11 +285,11 @@ WARNING: \`$1' is $msg.  You should only need it if
     else
     else
 	test -z "$file" || exec >$file
 	test -z "$file" || exec >$file
 	echo ".ab help2man is required to generate this page"
 	echo ".ab help2man is required to generate this page"
-	exit 1
+	exit $?
     fi
     fi
     ;;
     ;;
 
 
-  makeinfo)
+  makeinfo*)
     echo 1>&2 "\
     echo 1>&2 "\
 WARNING: \`$1' is $msg.  You should only need it if
 WARNING: \`$1' is $msg.  You should only need it if
          you modified a \`.texi' or \`.texinfo' file, or any other file
          you modified a \`.texi' or \`.texinfo' file, or any other file
@@ -310,7 +318,7 @@ WARNING: \`$1' is $msg.  You should only need it if
     touch $file
     touch $file
     ;;
     ;;
 
 
-  tar)
+  tar*)
     shift
     shift
 
 
     # We have already tried tar in the generic part.
     # We have already tried tar in the generic part.
@@ -363,5 +371,6 @@ exit 0
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # time-stamp-start: "scriptversion="
 # time-stamp-start: "scriptversion="
 # time-stamp-format: "%:y-%02m-%02d.%02H"
 # time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-end: "$"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
 # End:
 # End:

+ 113 - 38
src/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -28,8 +29,9 @@
 #
 #
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -55,6 +57,13 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = config.h
 CONFIG_HEADER = config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 SOURCES =
 SOURCES =
 DIST_SOURCES =
 DIST_SOURCES =
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -66,12 +75,41 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
 	ps-recursive uninstall-recursive
 	ps-recursive uninstall-recursive
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
   distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+	distdir
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
 DIST_SUBDIRS = $(SUBDIRS)
 DIST_SUBDIRS = $(SUBDIRS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+  dir0=`pwd`; \
+  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+  sed_rest='s,^[^/]*/*,,'; \
+  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+  sed_butlast='s,/*[^/]*$$,,'; \
+  while test -n "$$dir1"; do \
+    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+    if test "$$first" != "."; then \
+      if test "$$first" = ".."; then \
+        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+      else \
+        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+        if test "$$first2" = "$$first"; then \
+          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+        else \
+          dir2="../$$dir2"; \
+        fi; \
+        dir0="$$dir0"/"$$first"; \
+      fi; \
+    fi; \
+    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+  done; \
+  reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -108,6 +146,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -167,6 +206,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 SUBDIRS = portab tool ipaddr ngircd testsuite
 SUBDIRS = portab tool ipaddr ngircd testsuite
@@ -178,14 +218,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  src/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  src/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu src/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -203,6 +243,7 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 
 
 config.h: stamp-h1
 config.h: stamp-h1
 	@if test ! -f $@; then \
 	@if test ! -f $@; then \
@@ -214,7 +255,7 @@ stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
 	@rm -f stamp-h1
 	@rm -f stamp-h1
 	cd $(top_builddir) && $(SHELL) ./config.status src/config.h
 	cd $(top_builddir) && $(SHELL) ./config.status src/config.h
 $(srcdir)/config.h.in:  $(am__configure_deps) 
 $(srcdir)/config.h.in:  $(am__configure_deps) 
-	cd $(top_srcdir) && $(AUTOHEADER)
+	($(am__cd) $(top_srcdir) && $(AUTOHEADER))
 	rm -f stamp-h1
 	rm -f stamp-h1
 	touch $@
 	touch $@
 
 
@@ -228,7 +269,7 @@ distclean-hdr:
 #     (which will cause the Makefiles to be regenerated when you run `make');
 #     (which will cause the Makefiles to be regenerated when you run `make');
 # (2) otherwise, pass the desired values on the `make' command line.
 # (2) otherwise, pass the desired values on the `make' command line.
 $(RECURSIVE_TARGETS):
 $(RECURSIVE_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -245,7 +286,7 @@ $(RECURSIVE_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done; \
 	done; \
 	if test "$$dot_seen" = "no"; then \
 	if test "$$dot_seen" = "no"; then \
@@ -253,7 +294,7 @@ $(RECURSIVE_TARGETS):
 	fi; test -z "$$fail"
 	fi; test -z "$$fail"
 
 
 $(RECURSIVE_CLEAN_TARGETS):
 $(RECURSIVE_CLEAN_TARGETS):
-	@failcom='exit 1'; \
+	@fail= failcom='exit 1'; \
 	for f in x $$MAKEFLAGS; do \
 	for f in x $$MAKEFLAGS; do \
 	  case $$f in \
 	  case $$f in \
 	    *=* | --[!k]*);; \
 	    *=* | --[!k]*);; \
@@ -279,16 +320,16 @@ $(RECURSIVE_CLEAN_TARGETS):
 	  else \
 	  else \
 	    local_target="$$target"; \
 	    local_target="$$target"; \
 	  fi; \
 	  fi; \
-	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
 	  || eval $$failcom; \
 	  || eval $$failcom; \
 	done && test -z "$$fail"
 	done && test -z "$$fail"
 tags-recursive:
 tags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
 	done
 	done
 ctags-recursive:
 ctags-recursive:
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
 	done
 	done
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -296,14 +337,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
 	  include_option=--etags-include; \
 	  include_option=--etags-include; \
@@ -315,7 +356,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	list='$(SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test ! -f $$subdir/TAGS || \
 	    test ! -f $$subdir/TAGS || \
-	      tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	  fi; \
 	done; \
 	done; \
 	list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
@@ -324,29 +365,34 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -367,29 +413,44 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
-	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
 	  if test "$$subdir" = .; then :; else \
 	  if test "$$subdir" = .; then :; else \
 	    test -d "$(distdir)/$$subdir" \
 	    test -d "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || $(MKDIR_P) "$(distdir)/$$subdir" \
 	    || exit 1; \
 	    || exit 1; \
-	    distdir=`$(am__cd) $(distdir) && pwd`; \
-	    top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
-	    (cd $$subdir && \
+	  fi; \
+	done
+	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+	  if test "$$subdir" = .; then :; else \
+	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+	    $(am__relativize); \
+	    new_distdir=$$reldir; \
+	    dir1=$$subdir; dir2="$(top_distdir)"; \
+	    $(am__relativize); \
+	    new_top_distdir=$$reldir; \
+	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+	    ($(am__cd) $$subdir && \
 	      $(MAKE) $(AM_MAKEFLAGS) \
 	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$top_distdir" \
-	        distdir="$$distdir/$$subdir" \
+	        top_distdir="$$new_top_distdir" \
+	        distdir="$$new_distdir" \
 		am__remove_distdir=: \
 		am__remove_distdir=: \
 		am__skip_length_check=: \
 		am__skip_length_check=: \
+		am__skip_mode_fix=: \
 	        distdir) \
 	        distdir) \
 	      || exit 1; \
 	      || exit 1; \
 	  fi; \
 	  fi; \
@@ -419,6 +480,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -437,6 +499,8 @@ dvi-am:
 
 
 html: html-recursive
 html: html-recursive
 
 
+html-am:
+
 info: info-recursive
 info: info-recursive
 
 
 info-am:
 info-am:
@@ -445,18 +509,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-recursive
 install-dvi: install-dvi-recursive
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-recursive
 install-html: install-html-recursive
 
 
+install-html-am:
+
 install-info: install-info-recursive
 install-info: install-info-recursive
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-recursive
 install-pdf: install-pdf-recursive
 
 
+install-pdf-am:
+
 install-ps: install-ps-recursive
 install-ps: install-ps-recursive
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-recursive
 maintainer-clean: maintainer-clean-recursive
@@ -478,8 +552,8 @@ ps-am:
 
 
 uninstall-am:
 uninstall-am:
 
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
-	install-strip
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all \
+	ctags-recursive install-am install-strip tags-recursive
 
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
 	all all-am check check-am clean clean-generic ctags \
 	all all-am check check-am clean clean-generic ctags \
@@ -499,6 +573,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in config.h config.h.in stamp-h.in
 	rm -f Makefile Makefile.in config.h config.h.in stamp-h.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 3 - 28
src/config.h.in

@@ -18,13 +18,6 @@
 /* Define to 1 if you have the `deflate' function. */
 /* Define to 1 if you have the `deflate' function. */
 #undef HAVE_DEFLATE
 #undef HAVE_DEFLATE
 
 
-/* Define to 1 if you have the <DNSServiceDiscovery/DNSServiceDiscovery.h>
-   header file. */
-#undef HAVE_DNSSERVICEDISCOVERY_DNSSERVICEDISCOVERY_H
-
-/* Define to 1 if you have the `DNSServiceRegistrationCreate' function. */
-#undef HAVE_DNSSERVICEREGISTRATIONCREATE
-
 /* Define to 1 if you have the `epoll_create' function. */
 /* Define to 1 if you have the `epoll_create' function. */
 #undef HAVE_EPOLL_CREATE
 #undef HAVE_EPOLL_CREATE
 
 
@@ -70,9 +63,6 @@
 /* Define to 1 if you have the <inttypes.h> header file. */
 /* Define to 1 if you have the <inttypes.h> header file. */
 #undef HAVE_INTTYPES_H
 #undef HAVE_INTTYPES_H
 
 
-/* Define to 1 if you have the `isdigit' function. */
-#undef HAVE_ISDIGIT
-
 /* Define to 1 if you have the `kqueue' function. */
 /* Define to 1 if you have the `kqueue' function. */
 #undef HAVE_KQUEUE
 #undef HAVE_KQUEUE
 
 
@@ -85,18 +75,12 @@
 /* Define to 1 if you have the `gnutls' library (-lgnutls). */
 /* Define to 1 if you have the `gnutls' library (-lgnutls). */
 #undef HAVE_LIBGNUTLS
 #undef HAVE_LIBGNUTLS
 
 
-/* Define to 1 if you have the `howl' library (-lhowl). */
-#undef HAVE_LIBHOWL
-
 /* Define to 1 if you have the `ident' library (-lident). */
 /* Define to 1 if you have the `ident' library (-lident). */
 #undef HAVE_LIBIDENT
 #undef HAVE_LIBIDENT
 
 
 /* Define to 1 if you have the `pam' library (-lpam). */
 /* Define to 1 if you have the `pam' library (-lpam). */
 #undef HAVE_LIBPAM
 #undef HAVE_LIBPAM
 
 
-/* Define to 1 if you have the `pthread' library (-lpthread). */
-#undef HAVE_LIBPTHREAD
-
 /* Define to 1 if you have the `socket' library (-lsocket). */
 /* Define to 1 if you have the `socket' library (-lsocket). */
 #undef HAVE_LIBSOCKET
 #undef HAVE_LIBSOCKET
 
 
@@ -109,9 +93,6 @@
 /* Define to 1 if you have the `z' library (-lz). */
 /* Define to 1 if you have the `z' library (-lz). */
 #undef HAVE_LIBZ
 #undef HAVE_LIBZ
 
 
-/* Define to 1 if you have the <mach/port.h> header file. */
-#undef HAVE_MACH_PORT_H
-
 /* Define to 1 if you have the <malloc.h> header file. */
 /* Define to 1 if you have the <malloc.h> header file. */
 #undef HAVE_MALLOC_H
 #undef HAVE_MALLOC_H
 
 
@@ -142,9 +123,6 @@
 /* Define to 1 if you have the `poll' function. */
 /* Define to 1 if you have the `poll' function. */
 #undef HAVE_POLL
 #undef HAVE_POLL
 
 
-/* Define to 1 if you have the <rendezvous/rendezvous.h> header file. */
-#undef HAVE_RENDEZVOUS_RENDEZVOUS_H
-
 /* Define to 1 if you have the <security/pam_appl.h> header file. */
 /* Define to 1 if you have the <security/pam_appl.h> header file. */
 #undef HAVE_SECURITY_PAM_APPL_H
 #undef HAVE_SECURITY_PAM_APPL_H
 
 
@@ -208,9 +186,6 @@
 /* Define to 1 if you have the `strtok_r' function. */
 /* Define to 1 if you have the `strtok_r' function. */
 #undef HAVE_STRTOK_R
 #undef HAVE_STRTOK_R
 
 
-/* Define to 1 if you have the `sw_discovery_init' function. */
-#undef HAVE_SW_DISCOVERY_INIT
-
 /* Define to 1 if you have the `syslog' function. */
 /* Define to 1 if you have the `syslog' function. */
 #undef HAVE_SYSLOG
 #undef HAVE_SYSLOG
 
 
@@ -289,6 +264,9 @@
 /* Define to the one symbol short name of this package. */
 /* Define to the one symbol short name of this package. */
 #undef PACKAGE_TARNAME
 #undef PACKAGE_TARNAME
 
 
+/* Define to the home page for this package. */
+#undef PACKAGE_URL
+
 /* Define to the version of this package. */
 /* Define to the version of this package. */
 #undef PACKAGE_VERSION
 #undef PACKAGE_VERSION
 
 
@@ -334,9 +312,6 @@
 /* Define if IPV6 protocol should be enabled */
 /* Define if IPV6 protocol should be enabled */
 #undef WANT_IPV6
 #undef WANT_IPV6
 
 
-/* Define if support for Zeroconf should be included */
-#undef ZEROCONF
-
 /* Define if zlib compression should be enabled */
 /* Define if zlib compression should be enabled */
 #undef ZLIB
 #undef ZLIB
 
 

+ 77 - 29
src/ipaddr/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -17,8 +18,9 @@
 
 
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -45,9 +47,16 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
 LIBRARIES = $(noinst_LIBRARIES)
 AR = ar
 AR = ar
 ARFLAGS = cru
 ARFLAGS = cru
+AM_V_AR = $(am__v_AR_$(V))
+am__v_AR_ = $(am__v_AR_$(AM_DEFAULT_VERBOSITY))
+am__v_AR_0 = @echo "  AR    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 libngipaddr_a_AR = $(AR) $(ARFLAGS)
 libngipaddr_a_AR = $(AR) $(ARFLAGS)
 libngipaddr_a_LIBADD =
 libngipaddr_a_LIBADD =
 am_libngipaddr_a_OBJECTS = ng_ipaddr$U.$(OBJEXT)
 am_libngipaddr_a_OBJECTS = ng_ipaddr$U.$(OBJEXT)
@@ -55,10 +64,20 @@ libngipaddr_a_OBJECTS = $(am_libngipaddr_a_OBJECTS)
 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
 depcomp = $(SHELL) $(top_srcdir)/depcomp
 depcomp = $(SHELL) $(top_srcdir)/depcomp
 am__depfiles_maybe = depfiles
 am__depfiles_maybe = depfiles
+am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
 CCLD = $(CC)
 CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(libngipaddr_a_SOURCES)
 SOURCES = $(libngipaddr_a_SOURCES)
 DIST_SOURCES = $(libngipaddr_a_SOURCES)
 DIST_SOURCES = $(libngipaddr_a_SOURCES)
 HEADERS = $(noinst_HEADERS)
 HEADERS = $(noinst_HEADERS)
@@ -67,6 +86,7 @@ CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -103,6 +123,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -162,6 +183,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = ansi2knr
 AUTOMAKE_OPTIONS = ansi2knr
@@ -177,14 +199,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  src/ipaddr/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  src/ipaddr/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/ipaddr/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu src/ipaddr/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -202,13 +224,14 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 
 
 clean-noinstLIBRARIES:
 clean-noinstLIBRARIES:
 	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
 	-test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
 libngipaddr.a: $(libngipaddr_a_OBJECTS) $(libngipaddr_a_DEPENDENCIES) 
 libngipaddr.a: $(libngipaddr_a_OBJECTS) $(libngipaddr_a_DEPENDENCIES) 
-	-rm -f libngipaddr.a
-	$(libngipaddr_a_AR) libngipaddr.a $(libngipaddr_a_OBJECTS) $(libngipaddr_a_LIBADD)
-	$(RANLIB) libngipaddr.a
+	$(AM_V_at)-rm -f libngipaddr.a
+	$(AM_V_AR)$(libngipaddr_a_AR) libngipaddr.a $(libngipaddr_a_OBJECTS) $(libngipaddr_a_LIBADD)
+	$(AM_V_at)$(RANLIB) libngipaddr.a
 
 
 mostlyclean-compile:
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
 	-rm -f *.$(OBJEXT)
@@ -228,15 +251,17 @@ mostlyclean-kr:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ng_ipaddr$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ng_ipaddr$U.Po@am__quote@
 
 
 .c.o:
 .c.o:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 
 .c.obj:
 .c.obj:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
@@ -249,14 +274,14 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
@@ -264,29 +289,34 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -307,13 +337,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -341,6 +375,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -362,6 +397,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -370,18 +407,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am:
 install-exec-am:
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -424,6 +471,7 @@ maintainer-clean-local:
 	rm -f Makefile Makefile.in
 	rm -f Makefile Makefile.in
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 1 - 1
src/ipaddr/ansi2knr.c

@@ -1,6 +1,6 @@
 /* Copyright (C) 1989, 2000 Aladdin Enterprises.  All rights reserved. */
 /* Copyright (C) 1989, 2000 Aladdin Enterprises.  All rights reserved. */
 
 
-/*$Id: ansi2knr.c,v 1.3 2000/04/13 03:41:48 lpd Exp $*/
+/*$Id: ansi2knr.c,v 1.14 2003/09/06 05:36:56 eggert Exp $*/
 /* Convert ANSI C function definitions to K&R ("traditional C") syntax */
 /* Convert ANSI C function definitions to K&R ("traditional C") syntax */
 
 
 /*
 /*

+ 5 - 2
src/ipaddr/ng_ipaddr.c

@@ -1,11 +1,14 @@
 /*
 /*
- * Functions for AF_ agnostic ipv4/ipv6 handling.
- *
  * (c) 2008 Florian Westphal <fw@strlen.de>, public domain.
  * (c) 2008 Florian Westphal <fw@strlen.de>, public domain.
  */
  */
 
 
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Functions for AF_ agnostic ipv4/ipv6 handling.
+ */
+
 #include <assert.h>
 #include <assert.h>
 #include <stdio.h>
 #include <stdio.h>
 #include <string.h>
 #include <string.h>

+ 5 - 2
src/ipaddr/ng_ipaddr.h

@@ -1,6 +1,4 @@
 /*
 /*
- * Functions for AF_ agnostic ipv4/ipv6 handling.
- *
  * (c) 2008 Florian Westphal <fw@strlen.de>, public domain.
  * (c) 2008 Florian Westphal <fw@strlen.de>, public domain.
  */
  */
 
 
@@ -8,6 +6,11 @@
 #define NG_IPADDR_HDR
 #define NG_IPADDR_HDR
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Functions for AF_ agnostic ipv4/ipv6 handling (header).
+ */
+
 #include <assert.h>
 #include <assert.h>
 #include <sys/socket.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 #include <netinet/in.h>

+ 2 - 2
src/ngircd/Makefile.am

@@ -21,7 +21,7 @@ sbin_PROGRAMS = ngircd
 ngircd_SOURCES = ngircd.c array.c channel.c client.c conf.c conn.c conn-func.c \
 ngircd_SOURCES = ngircd.c array.c channel.c client.c conf.c conn.c conn-func.c \
 	conn-ssl.c conn-zip.c hash.c io.c irc.c irc-channel.c irc-info.c irc-login.c \
 	conn-ssl.c conn-zip.c hash.c io.c irc.c irc-channel.c irc-info.c irc-login.c \
 	irc-mode.c irc-op.c irc-oper.c irc-server.c irc-write.c lists.c log.c \
 	irc-mode.c irc-op.c irc-oper.c irc-server.c irc-write.c lists.c log.c \
-	match.c op.c numeric.c pam.c parse.c proc.c rendezvous.c resolve.c sighandlers.c
+	match.c op.c numeric.c pam.c parse.c proc.c resolve.c sighandlers.c
 
 
 ngircd_LDFLAGS = -L../portab -L../tool -L../ipaddr
 ngircd_LDFLAGS = -L../portab -L../tool -L../ipaddr
 
 
@@ -31,7 +31,7 @@ noinst_HEADERS = ngircd.h array.h channel.h client.h conf.h conf-ssl.h conn.h \
 	conn-func.h conn-ssl.h conn-zip.h hash.h io.h irc.h irc-channel.h \
 	conn-func.h conn-ssl.h conn-zip.h hash.h io.h irc.h irc-channel.h \
 	irc-info.h irc-login.h irc-mode.h irc-op.h irc-oper.h irc-server.h \
 	irc-info.h irc-login.h irc-mode.h irc-op.h irc-oper.h irc-server.h \
 	irc-write.h lists.h log.h match.h numeric.h op.h pam.h parse.h proc.h \
 	irc-write.h lists.h log.h match.h numeric.h op.h pam.h parse.h proc.h \
-	rendezvous.h resolve.h sighandlers.h defines.h messages.h
+	resolve.h sighandlers.h defines.h messages.h
 
 
 clean-local:
 clean-local:
 	rm -f check-version check-help lint.out
 	rm -f check-version check-help lint.out

+ 142 - 68
src/ngircd/Makefile.in

@@ -1,8 +1,9 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
 # @configure_input@
 # @configure_input@
 
 
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009  Free Software Foundation,
+# Inc.
 # This Makefile.in is free software; the Free Software Foundation
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 # with or without modifications, as long as this notice is preserved.
@@ -28,8 +29,9 @@
 
 
 VPATH = @srcdir@
 VPATH = @srcdir@
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_DATA = $(install_sh) -c -m 644
 install_sh_PROGRAM = $(install_sh) -c
 install_sh_PROGRAM = $(install_sh) -c
@@ -57,8 +59,8 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 mkinstalldirs = $(install_sh) -d
 mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_HEADER = $(top_builddir)/src/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
 am__installdirs = "$(DESTDIR)$(sbindir)"
 am__installdirs = "$(DESTDIR)$(sbindir)"
-sbinPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
 PROGRAMS = $(sbin_PROGRAMS)
 PROGRAMS = $(sbin_PROGRAMS)
 am_ngircd_OBJECTS = ngircd$U.$(OBJEXT) array$U.$(OBJEXT) \
 am_ngircd_OBJECTS = ngircd$U.$(OBJEXT) array$U.$(OBJEXT) \
 	channel$U.$(OBJEXT) client$U.$(OBJEXT) conf$U.$(OBJEXT) \
 	channel$U.$(OBJEXT) client$U.$(OBJEXT) conf$U.$(OBJEXT) \
@@ -70,8 +72,7 @@ am_ngircd_OBJECTS = ngircd$U.$(OBJEXT) array$U.$(OBJEXT) \
 	irc-write$U.$(OBJEXT) lists$U.$(OBJEXT) log$U.$(OBJEXT) \
 	irc-write$U.$(OBJEXT) lists$U.$(OBJEXT) log$U.$(OBJEXT) \
 	match$U.$(OBJEXT) op$U.$(OBJEXT) numeric$U.$(OBJEXT) \
 	match$U.$(OBJEXT) op$U.$(OBJEXT) numeric$U.$(OBJEXT) \
 	pam$U.$(OBJEXT) parse$U.$(OBJEXT) proc$U.$(OBJEXT) \
 	pam$U.$(OBJEXT) parse$U.$(OBJEXT) proc$U.$(OBJEXT) \
-	rendezvous$U.$(OBJEXT) resolve$U.$(OBJEXT) \
-	sighandlers$U.$(OBJEXT)
+	resolve$U.$(OBJEXT) sighandlers$U.$(OBJEXT)
 ngircd_OBJECTS = $(am_ngircd_OBJECTS)
 ngircd_OBJECTS = $(am_ngircd_OBJECTS)
 ngircd_DEPENDENCIES =
 ngircd_DEPENDENCIES =
 ngircd_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ngircd_LDFLAGS) \
 ngircd_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ngircd_LDFLAGS) \
@@ -79,18 +80,34 @@ ngircd_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ngircd_LDFLAGS) \
 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
 DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
 depcomp = $(SHELL) $(top_srcdir)/depcomp
 depcomp = $(SHELL) $(top_srcdir)/depcomp
 am__depfiles_maybe = depfiles
 am__depfiles_maybe = depfiles
+am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_$(V))
+am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY))
+am__v_CC_0 = @echo "  CC    " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
 CCLD = $(CC)
 CCLD = $(CC)
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_$(V))
+am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY))
+am__v_CCLD_0 = @echo "  CCLD  " $@;
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo "  GEN   " $@;
 SOURCES = $(ngircd_SOURCES)
 SOURCES = $(ngircd_SOURCES)
 DIST_SOURCES = $(ngircd_SOURCES)
 DIST_SOURCES = $(ngircd_SOURCES)
 HEADERS = $(noinst_HEADERS)
 HEADERS = $(noinst_HEADERS)
 ETAGS = etags
 ETAGS = etags
 CTAGS = ctags
 CTAGS = ctags
+am__tty_colors = \
+red=; grn=; lgn=; blu=; std=
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AUTOCONF = @AUTOCONF@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
 AUTOHEADER = @AUTOHEADER@
 AUTOMAKE = @AUTOMAKE@
 AUTOMAKE = @AUTOMAKE@
@@ -127,6 +144,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_NAME = @PACKAGE_NAME@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_STRING = @PACKAGE_STRING@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
 PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PACKAGE_VERSION = @PACKAGE_VERSION@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 PATH_SEPARATOR = @PATH_SEPARATOR@
 RANLIB = @RANLIB@
 RANLIB = @RANLIB@
@@ -186,6 +204,7 @@ target_alias = @target_alias@
 target_cpu = @target_cpu@
 target_cpu = @target_cpu@
 target_os = @target_os@
 target_os = @target_os@
 target_vendor = @target_vendor@
 target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = ../portab/ansi2knr
 AUTOMAKE_OPTIONS = ../portab/ansi2knr
@@ -196,7 +215,7 @@ LINTARGS = -weak -warnunixlib +unixlib -booltype BOOLEAN \
 ngircd_SOURCES = ngircd.c array.c channel.c client.c conf.c conn.c conn-func.c \
 ngircd_SOURCES = ngircd.c array.c channel.c client.c conf.c conn.c conn-func.c \
 	conn-ssl.c conn-zip.c hash.c io.c irc.c irc-channel.c irc-info.c irc-login.c \
 	conn-ssl.c conn-zip.c hash.c io.c irc.c irc-channel.c irc-info.c irc-login.c \
 	irc-mode.c irc-op.c irc-oper.c irc-server.c irc-write.c lists.c log.c \
 	irc-mode.c irc-op.c irc-oper.c irc-server.c irc-write.c lists.c log.c \
-	match.c op.c numeric.c pam.c parse.c proc.c rendezvous.c resolve.c sighandlers.c
+	match.c op.c numeric.c pam.c parse.c proc.c resolve.c sighandlers.c
 
 
 ngircd_LDFLAGS = -L../portab -L../tool -L../ipaddr
 ngircd_LDFLAGS = -L../portab -L../tool -L../ipaddr
 ngircd_LDADD = -lngportab -lngtool -lngipaddr
 ngircd_LDADD = -lngportab -lngtool -lngipaddr
@@ -204,7 +223,7 @@ noinst_HEADERS = ngircd.h array.h channel.h client.h conf.h conf-ssl.h conn.h \
 	conn-func.h conn-ssl.h conn-zip.h hash.h io.h irc.h irc-channel.h \
 	conn-func.h conn-ssl.h conn-zip.h hash.h io.h irc.h irc-channel.h \
 	irc-info.h irc-login.h irc-mode.h irc-op.h irc-oper.h irc-server.h \
 	irc-info.h irc-login.h irc-mode.h irc-op.h irc-oper.h irc-server.h \
 	irc-write.h lists.h log.h match.h numeric.h op.h pam.h parse.h proc.h \
 	irc-write.h lists.h log.h match.h numeric.h op.h pam.h parse.h proc.h \
-	rendezvous.h resolve.h sighandlers.h defines.h messages.h
+	resolve.h sighandlers.h defines.h messages.h
 
 
 TESTS = check-version check-help
 TESTS = check-version check-help
 all: all-am
 all: all-am
@@ -215,14 +234,14 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
 	    *$$dep*) \
-	      cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
-		&& exit 0; \
+	      ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+	        && { if test -f $@; then exit 0; else break; fi; }; \
 	      exit 1;; \
 	      exit 1;; \
 	  esac; \
 	  esac; \
 	done; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu  src/ngircd/Makefile'; \
-	cd $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu  src/ngircd/Makefile
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/ngircd/Makefile'; \
+	$(am__cd) $(top_srcdir) && \
+	  $(AUTOMAKE) --gnu src/ngircd/Makefile
 .PRECIOUS: Makefile
 .PRECIOUS: Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	@case '$?' in \
@@ -240,32 +259,47 @@ $(top_srcdir)/configure:  $(am__configure_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
 install-sbinPROGRAMS: $(sbin_PROGRAMS)
 install-sbinPROGRAMS: $(sbin_PROGRAMS)
 	@$(NORMAL_INSTALL)
 	@$(NORMAL_INSTALL)
 	test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)"
 	test -z "$(sbindir)" || $(MKDIR_P) "$(DESTDIR)$(sbindir)"
-	@list='$(sbin_PROGRAMS)'; for p in $$list; do \
-	  p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
-	  if test -f $$p \
-	  ; then \
-	    f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
-	   echo " $(INSTALL_PROGRAM_ENV) $(sbinPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(sbindir)/$$f'"; \
-	   $(INSTALL_PROGRAM_ENV) $(sbinPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(sbindir)/$$f" || exit 1; \
-	  else :; fi; \
-	done
+	@list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \
+	for p in $$list; do echo "$$p $$p"; done | \
+	sed 's/$(EXEEXT)$$//' | \
+	while read p p1; do if test -f $$p; \
+	  then echo "$$p"; echo "$$p"; else :; fi; \
+	done | \
+	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
+	sed 'N;N;N;s,\n, ,g' | \
+	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
+	  { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+	    if ($$2 == $$4) files[d] = files[d] " " $$1; \
+	    else { print "f", $$3 "/" $$4, $$1; } } \
+	  END { for (d in files) print "f", d, files[d] }' | \
+	while read type dir files; do \
+	    if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+	    test -z "$$files" || { \
+	      echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \
+	      $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \
+	    } \
+	; done
 
 
 uninstall-sbinPROGRAMS:
 uninstall-sbinPROGRAMS:
 	@$(NORMAL_UNINSTALL)
 	@$(NORMAL_UNINSTALL)
-	@list='$(sbin_PROGRAMS)'; for p in $$list; do \
-	  f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
-	  echo " rm -f '$(DESTDIR)$(sbindir)/$$f'"; \
-	  rm -f "$(DESTDIR)$(sbindir)/$$f"; \
-	done
+	@list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \
+	files=`for p in $$list; do echo "$$p"; done | \
+	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
+	      -e 's/$$/$(EXEEXT)/' `; \
+	test -n "$$list" || exit 0; \
+	echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \
+	cd "$(DESTDIR)$(sbindir)" && rm -f $$files
 
 
 clean-sbinPROGRAMS:
 clean-sbinPROGRAMS:
 	-test -z "$(sbin_PROGRAMS)" || rm -f $(sbin_PROGRAMS)
 	-test -z "$(sbin_PROGRAMS)" || rm -f $(sbin_PROGRAMS)
 ngircd$(EXEEXT): $(ngircd_OBJECTS) $(ngircd_DEPENDENCIES) 
 ngircd$(EXEEXT): $(ngircd_OBJECTS) $(ngircd_DEPENDENCIES) 
 	@rm -f ngircd$(EXEEXT)
 	@rm -f ngircd$(EXEEXT)
-	$(ngircd_LINK) $(ngircd_OBJECTS) $(ngircd_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(ngircd_LINK) $(ngircd_OBJECTS) $(ngircd_LDADD) $(LIBS)
 
 
 mostlyclean-compile:
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
 	-rm -f *.$(OBJEXT)
@@ -273,7 +307,7 @@ mostlyclean-compile:
 distclean-compile:
 distclean-compile:
 	-rm -f *.tab.c
 	-rm -f *.tab.c
 ../portab/ansi2knr:
 ../portab/ansi2knr:
-	cd ../portab && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr
+	$(am__cd) ../portab && $(MAKE) $(AM_MAKEFLAGS) ./ansi2knr
 
 
 mostlyclean-kr:
 mostlyclean-kr:
 	-test "$U" = "" || rm -f *_.c
 	-test "$U" = "" || rm -f *_.c
@@ -306,20 +340,21 @@ mostlyclean-kr:
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pam$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pam$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parse$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proc$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proc$U.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rendezvous$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/resolve$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/resolve$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sighandlers$U.Po@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sighandlers$U.Po@am__quote@
 
 
 .c.o:
 .c.o:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 @am__fastdepCC_FALSE@	$(COMPILE) -c $<
 
 
 .c.obj:
 .c.obj:
-@am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
-@am__fastdepCC_TRUE@	mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@am__fastdepCC_FALSE@	$(AM_V_CC) @AM_BACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
 @am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
@@ -379,8 +414,6 @@ parse_.c: parse.c $(ANSI2KNR)
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse.c; then echo $(srcdir)/parse.c; else echo parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/parse.c; then echo $(srcdir)/parse.c; else echo parse.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 proc_.c: proc.c $(ANSI2KNR)
 proc_.c: proc.c $(ANSI2KNR)
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/proc.c; then echo $(srcdir)/proc.c; else echo proc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/proc.c; then echo $(srcdir)/proc.c; else echo proc.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
-rendezvous_.c: rendezvous.c $(ANSI2KNR)
-	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/rendezvous.c; then echo $(srcdir)/rendezvous.c; else echo rendezvous.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 resolve_.c: resolve.c $(ANSI2KNR)
 resolve_.c: resolve.c $(ANSI2KNR)
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/resolve.c; then echo $(srcdir)/resolve.c; else echo resolve.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 	$(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) `if test -f $(srcdir)/resolve.c; then echo $(srcdir)/resolve.c; else echo resolve.c; fi` | sed 's/^# \([0-9]\)/#line \1/' | $(ANSI2KNR) > $@ || rm -f $@
 sighandlers_.c: sighandlers.c $(ANSI2KNR)
 sighandlers_.c: sighandlers.c $(ANSI2KNR)
@@ -393,22 +426,21 @@ irc-mode_.$(OBJEXT) irc-op_.$(OBJEXT) irc-oper_.$(OBJEXT) \
 irc-server_.$(OBJEXT) irc-write_.$(OBJEXT) lists_.$(OBJEXT) \
 irc-server_.$(OBJEXT) irc-write_.$(OBJEXT) lists_.$(OBJEXT) \
 log_.$(OBJEXT) match_.$(OBJEXT) ngircd_.$(OBJEXT) numeric_.$(OBJEXT) \
 log_.$(OBJEXT) match_.$(OBJEXT) ngircd_.$(OBJEXT) numeric_.$(OBJEXT) \
 op_.$(OBJEXT) pam_.$(OBJEXT) parse_.$(OBJEXT) proc_.$(OBJEXT) \
 op_.$(OBJEXT) pam_.$(OBJEXT) parse_.$(OBJEXT) proc_.$(OBJEXT) \
-rendezvous_.$(OBJEXT) resolve_.$(OBJEXT) sighandlers_.$(OBJEXT) : \
-$(ANSI2KNR)
+resolve_.$(OBJEXT) sighandlers_.$(OBJEXT) : $(ANSI2KNR)
 
 
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
 	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
+	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	mkid -fID $$unique
 	mkid -fID $$unique
 tags: TAGS
 tags: TAGS
 
 
 TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
+	set x; \
 	here=`pwd`; \
 	here=`pwd`; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
@@ -416,37 +448,43 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
 	  test -n "$$unique" || unique=$$empty_fix; \
-	  $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
-	    $$tags $$unique; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
 	fi
 	fi
 ctags: CTAGS
 ctags: CTAGS
 CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 		$(TAGS_FILES) $(LISP)
 		$(TAGS_FILES) $(LISP)
-	tags=; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
 	unique=`for i in $$list; do \
 	unique=`for i in $$list; do \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
 	  done | \
 	  done | \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
 	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	test -z "$(CTAGS_ARGS)$$tags$$unique" \
+	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
-	     $$tags $$unique
+	     $$unique
 
 
 GTAGS:
 GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	here=`$(am__cd) $(top_builddir) && pwd` \
-	  && cd $(top_srcdir) \
-	  && gtags -i $(GTAGS_ARGS) $$here
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
 
 
 distclean-tags:
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
 
 check-TESTS: $(TESTS)
 check-TESTS: $(TESTS)
-	@failed=0; all=0; xfail=0; xpass=0; skip=0; ws='[	 ]'; \
+	@failed=0; all=0; xfail=0; xpass=0; skip=0; \
 	srcdir=$(srcdir); export srcdir; \
 	srcdir=$(srcdir); export srcdir; \
 	list=' $(TESTS) '; \
 	list=' $(TESTS) '; \
+	$(am__tty_colors); \
 	if test -n "$$list"; then \
 	if test -n "$$list"; then \
 	  for tst in $$list; do \
 	  for tst in $$list; do \
 	    if test -f ./$$tst; then dir=./; \
 	    if test -f ./$$tst; then dir=./; \
@@ -455,49 +493,63 @@ check-TESTS: $(TESTS)
 	    if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
 	    if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
 	      all=`expr $$all + 1`; \
 	      all=`expr $$all + 1`; \
 	      case " $(XFAIL_TESTS) " in \
 	      case " $(XFAIL_TESTS) " in \
-	      *$$ws$$tst$$ws*) \
+	      *[\ \	]$$tst[\ \	]*) \
 		xpass=`expr $$xpass + 1`; \
 		xpass=`expr $$xpass + 1`; \
 		failed=`expr $$failed + 1`; \
 		failed=`expr $$failed + 1`; \
-		echo "XPASS: $$tst"; \
+		col=$$red; res=XPASS; \
 	      ;; \
 	      ;; \
 	      *) \
 	      *) \
-		echo "PASS: $$tst"; \
+		col=$$grn; res=PASS; \
 	      ;; \
 	      ;; \
 	      esac; \
 	      esac; \
 	    elif test $$? -ne 77; then \
 	    elif test $$? -ne 77; then \
 	      all=`expr $$all + 1`; \
 	      all=`expr $$all + 1`; \
 	      case " $(XFAIL_TESTS) " in \
 	      case " $(XFAIL_TESTS) " in \
-	      *$$ws$$tst$$ws*) \
+	      *[\ \	]$$tst[\ \	]*) \
 		xfail=`expr $$xfail + 1`; \
 		xfail=`expr $$xfail + 1`; \
-		echo "XFAIL: $$tst"; \
+		col=$$lgn; res=XFAIL; \
 	      ;; \
 	      ;; \
 	      *) \
 	      *) \
 		failed=`expr $$failed + 1`; \
 		failed=`expr $$failed + 1`; \
-		echo "FAIL: $$tst"; \
+		col=$$red; res=FAIL; \
 	      ;; \
 	      ;; \
 	      esac; \
 	      esac; \
 	    else \
 	    else \
 	      skip=`expr $$skip + 1`; \
 	      skip=`expr $$skip + 1`; \
-	      echo "SKIP: $$tst"; \
+	      col=$$blu; res=SKIP; \
 	    fi; \
 	    fi; \
+	    echo "$${col}$$res$${std}: $$tst"; \
 	  done; \
 	  done; \
+	  if test "$$all" -eq 1; then \
+	    tests="test"; \
+	    All=""; \
+	  else \
+	    tests="tests"; \
+	    All="All "; \
+	  fi; \
 	  if test "$$failed" -eq 0; then \
 	  if test "$$failed" -eq 0; then \
 	    if test "$$xfail" -eq 0; then \
 	    if test "$$xfail" -eq 0; then \
-	      banner="All $$all tests passed"; \
+	      banner="$$All$$all $$tests passed"; \
 	    else \
 	    else \
-	      banner="All $$all tests behaved as expected ($$xfail expected failures)"; \
+	      if test "$$xfail" -eq 1; then failures=failure; else failures=failures; fi; \
+	      banner="$$All$$all $$tests behaved as expected ($$xfail expected $$failures)"; \
 	    fi; \
 	    fi; \
 	  else \
 	  else \
 	    if test "$$xpass" -eq 0; then \
 	    if test "$$xpass" -eq 0; then \
-	      banner="$$failed of $$all tests failed"; \
+	      banner="$$failed of $$all $$tests failed"; \
 	    else \
 	    else \
-	      banner="$$failed of $$all tests did not behave as expected ($$xpass unexpected passes)"; \
+	      if test "$$xpass" -eq 1; then passes=pass; else passes=passes; fi; \
+	      banner="$$failed of $$all $$tests did not behave as expected ($$xpass unexpected $$passes)"; \
 	    fi; \
 	    fi; \
 	  fi; \
 	  fi; \
 	  dashes="$$banner"; \
 	  dashes="$$banner"; \
 	  skipped=""; \
 	  skipped=""; \
 	  if test "$$skip" -ne 0; then \
 	  if test "$$skip" -ne 0; then \
-	    skipped="($$skip tests were not run)"; \
+	    if test "$$skip" -eq 1; then \
+	      skipped="($$skip test was not run)"; \
+	    else \
+	      skipped="($$skip tests were not run)"; \
+	    fi; \
 	    test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
 	    test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
 	      dashes="$$skipped"; \
 	      dashes="$$skipped"; \
 	  fi; \
 	  fi; \
@@ -508,11 +560,15 @@ check-TESTS: $(TESTS)
 	      dashes="$$report"; \
 	      dashes="$$report"; \
 	  fi; \
 	  fi; \
 	  dashes=`echo "$$dashes" | sed s/./=/g`; \
 	  dashes=`echo "$$dashes" | sed s/./=/g`; \
-	  echo "$$dashes"; \
+	  if test "$$failed" -eq 0; then \
+	    echo "$$grn$$dashes"; \
+	  else \
+	    echo "$$red$$dashes"; \
+	  fi; \
 	  echo "$$banner"; \
 	  echo "$$banner"; \
 	  test -z "$$skipped" || echo "$$skipped"; \
 	  test -z "$$skipped" || echo "$$skipped"; \
 	  test -z "$$report" || echo "$$report"; \
 	  test -z "$$report" || echo "$$report"; \
-	  echo "$$dashes"; \
+	  echo "$$dashes$$std"; \
 	  test "$$failed" -eq 0; \
 	  test "$$failed" -eq 0; \
 	else :; fi
 	else :; fi
 
 
@@ -532,13 +588,17 @@ distdir: $(DISTFILES)
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
 	  if test -d $$d/$$file; then \
 	  if test -d $$d/$$file; then \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
 	    dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+	    if test -d "$(distdir)/$$file"; then \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+	    fi; \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
 	    if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
-	      cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+	      cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+	      find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
 	    fi; \
 	    fi; \
-	    cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+	    cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
 	  else \
 	  else \
-	    test -f $(distdir)/$$file \
-	    || cp -p $$d/$$file $(distdir)/$$file \
+	    test -f "$(distdir)/$$file" \
+	    || cp -p $$d/$$file "$(distdir)/$$file" \
 	    || exit 1; \
 	    || exit 1; \
 	  fi; \
 	  fi; \
 	done
 	done
@@ -570,6 +630,7 @@ clean-generic:
 
 
 distclean-generic:
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 
 
 maintainer-clean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "This command is intended for maintainers to use"
@@ -590,6 +651,8 @@ dvi-am:
 
 
 html: html-am
 html: html-am
 
 
+html-am:
+
 info: info-am
 info: info-am
 
 
 info-am:
 info-am:
@@ -598,18 +661,28 @@ install-data-am:
 
 
 install-dvi: install-dvi-am
 install-dvi: install-dvi-am
 
 
+install-dvi-am:
+
 install-exec-am: install-sbinPROGRAMS
 install-exec-am: install-sbinPROGRAMS
 
 
 install-html: install-html-am
 install-html: install-html-am
 
 
+install-html-am:
+
 install-info: install-info-am
 install-info: install-info-am
 
 
+install-info-am:
+
 install-man:
 install-man:
 
 
 install-pdf: install-pdf-am
 install-pdf: install-pdf-am
 
 
+install-pdf-am:
+
 install-ps: install-ps-am
 install-ps: install-ps-am
 
 
+install-ps-am:
+
 installcheck-am:
 installcheck-am:
 
 
 maintainer-clean: maintainer-clean-am
 maintainer-clean: maintainer-clean-am
@@ -632,7 +705,7 @@ ps-am:
 
 
 uninstall-am: uninstall-sbinPROGRAMS
 uninstall-am: uninstall-sbinPROGRAMS
 
 
-.MAKE: install-am install-strip
+.MAKE: ../portab/ansi2knr check-am install-am install-strip
 
 
 .PHONY: CTAGS GTAGS all all-am check check-TESTS check-am clean \
 .PHONY: CTAGS GTAGS all all-am check check-TESTS check-am clean \
 	clean-generic clean-local clean-sbinPROGRAMS ctags distclean \
 	clean-generic clean-local clean-sbinPROGRAMS ctags distclean \
@@ -692,6 +765,7 @@ lint:
 	echo; [ $$warnings -gt 0 ] && exit 1
 	echo; [ $$warnings -gt 0 ] && exit 1
 
 
 # -eof-
 # -eof-
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
 .NOEXPORT:

+ 13 - 38
src/ngircd/array.c

@@ -5,17 +5,18 @@
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
  *
  *
- * functions to dynamically allocate arrays.
+ * libarray - dynamically allocate arrays.
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
- *
  */
  */
 
 
-#include "array.h"
+/**
+ * @file
+ * Functions to dynamically allocate arrays.
+ */
 
 
-static char UNUSED id[] = "$Id: array.c,v 1.15 2007/11/18 15:05:35 alex Exp $";
+#include "array.h"
 
 
 #include <assert.h>
 #include <assert.h>
-
 #include <stdlib.h>
 #include <stdlib.h>
 #include <string.h>
 #include <string.h>
 
 
@@ -24,13 +25,7 @@ static char UNUSED id[] = "$Id: array.c,v 1.15 2007/11/18 15:05:35 alex Exp $";
 /* Enable more Debug messages in alloc / append / memmove code. */
 /* Enable more Debug messages in alloc / append / memmove code. */
 /* #define DEBUG_ARRAY */
 /* #define DEBUG_ARRAY */
 
 
-
-
-#define array_UNUSABLE(x)	( !(x)->mem || (0 == (x)->allocated) )
-
-#define ALIGN_32U(x)            (((x)+(unsigned)31  ) & ~((unsigned)31))
-#define ALIGN_1024U(x)          (((x)+(unsigned)1023) & ~((unsigned)1023))
-#define ALIGN_4096U(x)          (((x)+(unsigned)4095) & ~((unsigned)4095))
+#define array_UNUSABLE(x)	( !(x)->mem )
 
 
 
 
 static bool
 static bool
@@ -61,7 +56,6 @@ void *
 array_alloc(array * a, size_t size, size_t pos)
 array_alloc(array * a, size_t size, size_t pos)
 {
 {
 	size_t alloc, pos_plus1 = pos + 1;
 	size_t alloc, pos_plus1 = pos + 1;
-	size_t aligned = 0;
 	char *tmp;
 	char *tmp;
 
 
 	assert(size > 0);
 	assert(size > 0);
@@ -70,43 +64,22 @@ array_alloc(array * a, size_t size, size_t pos)
 		return NULL;
 		return NULL;
 
 
 	if (a->allocated < alloc) {
 	if (a->allocated < alloc) {
-		if (alloc < 128) {
-			aligned = ALIGN_32U(alloc);
-		} else {
-			if (alloc < 4096) {
-				aligned = ALIGN_1024U(alloc);
-			} else {
-				aligned = ALIGN_4096U(alloc);
-			}
-		}
-#ifdef DEBUG_ARRAY
-		Log(LOG_DEBUG, "array_alloc(): rounded %u to %u bytes.", alloc, aligned);
-#endif
-
-		assert(aligned >= alloc);
-
-		if (aligned < alloc)	/* rounding overflow */
-			return NULL;
-
-		alloc = aligned;
 #ifdef DEBUG_ARRAY
 #ifdef DEBUG_ARRAY
 		Log(LOG_DEBUG, "array_alloc(): changing size from %u to %u bytes.",
 		Log(LOG_DEBUG, "array_alloc(): changing size from %u to %u bytes.",
-		    a->allocated, aligned);
+		    a->allocated, alloc);
 #endif
 #endif
-
 		tmp = realloc(a->mem, alloc);
 		tmp = realloc(a->mem, alloc);
 		if (!tmp)
 		if (!tmp)
 			return NULL;
 			return NULL;
 
 
 		a->mem = tmp;
 		a->mem = tmp;
 		a->allocated = alloc;
 		a->allocated = alloc;
-
-		assert(a->allocated > a->used);
-
 		memset(a->mem + a->used, 0, a->allocated - a->used);
 		memset(a->mem + a->used, 0, a->allocated - a->used);
-
 		a->used = alloc;
 		a->used = alloc;
 	}
 	}
+
+	assert(a->allocated >= a->used);
+
 	return a->mem + (pos * size);
 	return a->mem + (pos * size);
 }
 }
 
 
@@ -121,6 +94,7 @@ array_length(const array * const a, size_t membersize)
 	if (array_UNUSABLE(a))
 	if (array_UNUSABLE(a))
 		return 0;
 		return 0;
 
 
+	assert(a->allocated);
 	return membersize ? a->used / membersize : 0;
 	return membersize ? a->used / membersize : 0;
 }
 }
 
 
@@ -132,6 +106,7 @@ array_copy(array * dest, const array * const src)
 	if (array_UNUSABLE(src))
 	if (array_UNUSABLE(src))
 		return false;
 		return false;
 
 
+	assert(src->allocated);
 	return array_copyb(dest, src->mem, src->used);
 	return array_copyb(dest, src->mem, src->used);
 }
 }
 
 

+ 5 - 2
src/ngircd/array.h

@@ -7,13 +7,16 @@
  *
  *
  * libarray - dynamically allocate arrays.
  * libarray - dynamically allocate arrays.
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
- *
- * $Id: array.h,v 1.4 2005/08/30 13:36:32 fw Exp $
  */
  */
 
 
 #ifndef array_h_included
 #ifndef array_h_included
 #define array_h_included
 #define array_h_included
 
 
+/**
+ * @file
+ * Functions to dynamically allocate arrays (header).
+ */
+
 #include "portab.h"
 #include "portab.h"
 
 
 typedef struct {
 typedef struct {

+ 77 - 7
src/ngircd/channel.c

@@ -1,22 +1,23 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2009 Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Channel management
  */
  */
 
 
-
 #define __channel_c__
 #define __channel_c__
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Channel management
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdlib.h>
 #include <stdlib.h>
@@ -262,6 +263,9 @@ Channel_Part(CLIENT * Client, CLIENT * Origin, const char *Name, const char *Rea
 		return false;
 		return false;
 	}
 	}
 
 
+	if (Conf_MorePrivacy)
+		Reason = "";
+
 	/* Part client from channel */
 	/* Part client from channel */
 	if (!Remove_Client(REMOVE_PART, chan, Client, Origin, Reason, true))
 	if (!Remove_Client(REMOVE_PART, chan, Client, Origin, Reason, true))
 		return false;
 		return false;
@@ -330,6 +334,9 @@ Channel_Quit( CLIENT *Client, const char *Reason )
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( Reason != NULL );
 	assert( Reason != NULL );
 
 
+	if (Conf_MorePrivacy)
+		Reason = "";
+
 	IRC_WriteStrRelatedPrefix( Client, Client, false, "QUIT :%s", Reason );
 	IRC_WriteStrRelatedPrefix( Client, Client, false, "QUIT :%s", Reason );
 
 
 	c = My_Channels;
 	c = My_Channels;
@@ -960,6 +967,9 @@ Remove_Client( int Type, CHANNEL *Chan, CLIENT *Client, CLIENT *Origin, const ch
 				Client_Mask( Client ), c->name, Client_ID(Origin), Reason);
 				Client_Mask( Client ), c->name, Client_ID(Origin), Reason);
 			break;
 			break;
 		default: /* PART */
 		default: /* PART */
+			if (Conf_MorePrivacy)
+				Reason = "";
+
 			if (InformServer)
 			if (InformServer)
 				IRC_WriteStrServersPrefix(Origin, Client, "PART %s :%s", c->name, Reason);
 				IRC_WriteStrServersPrefix(Origin, Client, "PART %s :%s", c->name, Reason);
 
 
@@ -989,6 +999,7 @@ GLOBAL bool
 Channel_AddBan(CHANNEL *c, const char *mask )
 Channel_AddBan(CHANNEL *c, const char *mask )
 {
 {
 	struct list_head *h = Channel_GetListBans(c);
 	struct list_head *h = Channel_GetListBans(c);
+	LogDebug("Adding \"%s\" to \"%s\" %s list", mask, Channel_Name(c), "ban");
 	return Lists_Add(h, mask, false);
 	return Lists_Add(h, mask, false);
 }
 }
 
 
@@ -997,6 +1008,7 @@ GLOBAL bool
 Channel_AddInvite(CHANNEL *c, const char *mask, bool onlyonce)
 Channel_AddInvite(CHANNEL *c, const char *mask, bool onlyonce)
 {
 {
 	struct list_head *h = Channel_GetListInvites(c);
 	struct list_head *h = Channel_GetListInvites(c);
+	LogDebug("Adding \"%s\" to \"%s\" %s list", mask, Channel_Name(c), "invite");
 	return Lists_Add(h, mask, onlyonce);
 	return Lists_Add(h, mask, onlyonce);
 }
 }
 
 
@@ -1079,10 +1091,10 @@ Channel_CheckKey(CHANNEL *Chan, CLIENT *Client, const char *Key)
 
 
 	if (!strchr(Chan->modes, 'k'))
 	if (!strchr(Chan->modes, 'k'))
 		return true;
 		return true;
-	if (strcmp(Chan->key, Key) == 0)
-		return true;
 	if (*Key == '\0')
 	if (*Key == '\0')
 		return false;
 		return false;
+	if (strcmp(Chan->key, Key) == 0)
+		return true;
 
 
 	file_name = array_start(&Chan->keyfile);
 	file_name = array_start(&Chan->keyfile);
 	if (!file_name)
 	if (!file_name)
@@ -1117,6 +1129,64 @@ Channel_CheckKey(CHANNEL *Chan, CLIENT *Client, const char *Key)
 } /* Channel_CheckKey */
 } /* Channel_CheckKey */
 
 
 
 
+/**
+ * Check wether a client is allowed to administer a channel or not.
+ *
+ * @param Chan		The channel to test.
+ * @param Client	The client from which the command has been received.
+ * @param Origin	The originator of the command (or NULL).
+ * @param OnChannel	Set to true if the originator is member of the channel.
+ * @param AdminOk	Set to true if the client is allowed to do
+ *			administrative tasks on this channel.
+ * @param UseServerMode	Set to true if ngIRCd should emulate "server mode",
+ *			that is send commands as if originating from a server
+ *			and not the originator of the command.
+ */
+GLOBAL void
+Channel_CheckAdminRights(CHANNEL *Chan, CLIENT *Client, CLIENT *Origin,
+			 bool *OnChannel, bool *AdminOk, bool *UseServerMode)
+{
+	assert (Chan != NULL);
+	assert (Client != NULL);
+	assert (OnChannel != NULL);
+	assert (AdminOk != NULL);
+	assert (UseServerMode != NULL);
+
+	/* Use the client as origin, if no origin has been given (no prefix?) */
+	if (!Origin)
+		Origin = Client;
+
+	*OnChannel = false;
+	*AdminOk = false;
+	*UseServerMode = false;
+
+	if (Client_Type(Client) != CLIENT_USER
+	    && Client_Type(Client) != CLIENT_SERVER
+	    && Client_Type(Client) != CLIENT_SERVICE)
+		return;
+
+	/* Allow channel administration if the client is a server or service */
+	if (Client_Type(Client) != CLIENT_USER) {
+		*AdminOk = true;
+		return;
+	}
+
+	*OnChannel = Channel_IsMemberOf(Chan, Origin);
+
+	if (*OnChannel && strchr(Channel_UserModes(Chan, Origin), 'o')) {
+		/* User is a channel operator */
+		*AdminOk = true;
+	} else if (Conf_OperCanMode) {
+		/* IRC operators are allowed to administer channels as well */
+		if (Client_OperByMe(Origin)) {
+			*AdminOk = true;
+			if (Conf_OperServerMode)
+				*UseServerMode = true;
+		}
+	}
+} /* Channel_CheckAdminRights */
+
+
 static CL2CHAN *
 static CL2CHAN *
 Get_First_Cl2Chan( CLIENT *Client, CHANNEL *Chan )
 Get_First_Cl2Chan( CLIENT *Client, CHANNEL *Chan )
 {
 {

+ 9 - 4
src/ngircd/channel.h

@@ -1,20 +1,21 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2008 by Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Channel management (header)
  */
  */
 
 
-
 #ifndef __channel_h__
 #ifndef __channel_h__
 #define __channel_h__
 #define __channel_h__
 
 
+/**
+ * @file
+ * Channel management (header)
+ */
 
 
 #if defined(__channel_c__) | defined(S_SPLINT_S)
 #if defined(__channel_c__) | defined(S_SPLINT_S)
 
 
@@ -133,6 +134,10 @@ GLOBAL void Channel_LogServer PARAMS((const char *msg));
 GLOBAL bool Channel_CheckKey PARAMS((CHANNEL *Chan, CLIENT *Client,
 GLOBAL bool Channel_CheckKey PARAMS((CHANNEL *Chan, CLIENT *Client,
 				     const char *Key));
 				     const char *Key));
 
 
+GLOBAL void Channel_CheckAdminRights PARAMS((CHANNEL *Chan, CLIENT *Client,
+					     CLIENT *Origin, bool *OnChannel,
+					     bool *AdminOk, bool *UseServerMode));
+
 #define Channel_IsLocal(c) (Channel_Name(c)[0] == '&')
 #define Channel_IsLocal(c) (Channel_Name(c)[0] == '&')
 #define Channel_IsModeless(c) (Channel_Name(c)[0] == '+')
 #define Channel_IsModeless(c) (Channel_Name(c)[0] == '+')
 
 

+ 34 - 15
src/ngircd/client.c

@@ -7,16 +7,17 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Client management.
  */
  */
 
 
-
 #define __client_c__
 #define __client_c__
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Client management.
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <unistd.h>
 #include <unistd.h>
@@ -43,10 +44,8 @@
 
 
 #include <exp.h>
 #include <exp.h>
 
 
-
 #define GETID_LEN (CLIENT_NICK_LEN-1) + 1 + (CLIENT_USER_LEN-1) + 1 + (CLIENT_HOST_LEN-1) + 1
 #define GETID_LEN (CLIENT_NICK_LEN-1) + 1 + (CLIENT_USER_LEN-1) + 1 + (CLIENT_HOST_LEN-1) + 1
 
 
-
 static CLIENT *This_Server, *My_Clients;
 static CLIENT *This_Server, *My_Clients;
 
 
 static WHOWAS My_Whowas[MAX_WHOWAS];
 static WHOWAS My_Whowas[MAX_WHOWAS];
@@ -93,7 +92,7 @@ Client_Init( void )
 	This_Server->hops = 0;
 	This_Server->hops = 0;
 
 
 	gethostname( This_Server->host, CLIENT_HOST_LEN );
 	gethostname( This_Server->host, CLIENT_HOST_LEN );
-	if (!Conf_NoDNS) {
+	if (Conf_DNS) {
 		h = gethostbyname( This_Server->host );
 		h = gethostbyname( This_Server->host );
 		if (h) strlcpy(This_Server->host, h->h_name, sizeof(This_Server->host));
 		if (h) strlcpy(This_Server->host, h->h_name, sizeof(This_Server->host));
 	}
 	}
@@ -320,7 +319,11 @@ Client_SetHostname( CLIENT *Client, const char *Hostname )
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( Hostname != NULL );
 	assert( Hostname != NULL );
 
 
-	strlcpy( Client->host, Hostname, sizeof( Client->host ));
+	if (strlen(Conf_CloakHost)) {
+		strlcpy( Client->host, Conf_CloakHost, sizeof( Client->host ));
+	} else {
+		strlcpy( Client->host, Hostname, sizeof( Client->host ));
+	}
 } /* Client_SetHostname */
 } /* Client_SetHostname */
 
 
 
 
@@ -332,6 +335,11 @@ Client_SetID( CLIENT *Client, const char *ID )
 	
 	
 	strlcpy( Client->id, ID, sizeof( Client->id ));
 	strlcpy( Client->id, ID, sizeof( Client->id ));
 
 
+	if (Conf_CloakUserToNick) {
+		strlcpy( Client->user, ID, sizeof( Client->user ));
+		strlcpy( Client->info, ID, sizeof( Client->info ));
+	}
+
 	/* Hash */
 	/* Hash */
 	Client->hash = Hash( Client->id );
 	Client->hash = Hash( Client->id );
 } /* Client_SetID */
 } /* Client_SetID */
@@ -345,7 +353,9 @@ Client_SetUser( CLIENT *Client, const char *User, bool Idented )
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( User != NULL );
 	assert( User != NULL );
 
 
-	if (Idented) {
+	if (Conf_CloakUserToNick) {
+		strlcpy(Client->user, Client->id, sizeof(Client->user));
+	} else if (Idented) {
 		strlcpy(Client->user, User, sizeof(Client->user));
 		strlcpy(Client->user, User, sizeof(Client->user));
 	} else {
 	} else {
 		Client->user[0] = '~';
 		Client->user[0] = '~';
@@ -382,7 +392,10 @@ Client_SetInfo( CLIENT *Client, const char *Info )
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( Info != NULL );
 	assert( Info != NULL );
 
 
-	strlcpy(Client->info, Info, sizeof(Client->info));
+	if (Conf_CloakUserToNick)
+		strlcpy(Client->info, Client->id, sizeof(Client->info));
+	else
+		strlcpy(Client->info, Info, sizeof(Client->info));
 } /* Client_SetInfo */
 } /* Client_SetInfo */
 
 
 
 
@@ -553,17 +566,19 @@ Client_Search( const char *Nick )
 } /* Client_Search */
 } /* Client_Search */
 
 
 
 
+/**
+ * Get client structure ("introducer") identfied by a server token.
+ * @return CLIENT structure or NULL if none could be found.
+ */
 GLOBAL CLIENT *
 GLOBAL CLIENT *
 Client_GetFromToken( CLIENT *Client, int Token )
 Client_GetFromToken( CLIENT *Client, int Token )
 {
 {
-	/* Client-Struktur, die den entsprechenden Introducer (=Client)
-	 * und das gegebene Token hat, liefern. Wird keine gefunden,
-	 * so wird NULL geliefert. */
-
 	CLIENT *c;
 	CLIENT *c;
 
 
 	assert( Client != NULL );
 	assert( Client != NULL );
-	assert( Token > 0 );
+
+	if (!Token)
+		return NULL;
 
 
 	c = My_Clients;
 	c = My_Clients;
 	while (c) {
 	while (c) {
@@ -1177,6 +1192,10 @@ Client_RegisterWhowas( CLIENT *Client )
 
 
 	assert( Client != NULL );
 	assert( Client != NULL );
 
 
+	/* Don't register WHOWAS information when "MorePrivacy" is enabled. */
+	if (Conf_MorePrivacy)
+		return;
+
 	now = time(NULL);
 	now = time(NULL);
 	/* Don't register clients that were connected less than 30 seconds. */
 	/* Don't register clients that were connected less than 30 seconds. */
 	if( now - Client->starttime < 30 )
 	if( now - Client->starttime < 30 )

+ 8 - 4
src/ngircd/client.h

@@ -7,13 +7,16 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Client management (header)
  */
  */
 
 
 #ifndef __client_h__
 #ifndef __client_h__
 #define __client_h__
 #define __client_h__
 
 
+/**
+ * @file
+ * Client management (header)
+ */
+
 #define CLIENT_UNKNOWN 1		/* connection of unknown type */
 #define CLIENT_UNKNOWN 1		/* connection of unknown type */
 #define CLIENT_GOTPASS 2		/* client did send PASS */
 #define CLIENT_GOTPASS 2		/* client did send PASS */
 #define CLIENT_GOTNICK 4		/* client did send NICK */
 #define CLIENT_GOTNICK 4		/* client did send NICK */
@@ -23,6 +26,9 @@
 #define CLIENT_SERVICE 64		/* client is a service */
 #define CLIENT_SERVICE 64		/* client is a service */
 #define CLIENT_UNKNOWNSERVER 128	/* unregistered server connection */
 #define CLIENT_UNKNOWNSERVER 128	/* unregistered server connection */
 #define CLIENT_GOTPASS_2813 256		/* client did send PASS, RFC 2813 style */
 #define CLIENT_GOTPASS_2813 256		/* client did send PASS, RFC 2813 style */
+#ifndef STRICT_RFC
+# define CLIENT_WAITAUTHPING 512	/* waiting for AUTH PONG from client */
+#endif
 
 
 #define CLIENT_TYPE int
 #define CLIENT_TYPE int
 
 
@@ -161,8 +167,6 @@ GLOBAL const char *Client_TypeText PARAMS((CLIENT *Client));
 GLOBAL void Client_DebugDump PARAMS((void));
 GLOBAL void Client_DebugDump PARAMS((void));
 #endif
 #endif
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 5 - 1
src/ngircd/conf-ssl.h

@@ -1,11 +1,15 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * SSL defines.
  */
  */
 
 
 #ifndef conf_ssl_h
 #ifndef conf_ssl_h
 #define conf_ssl_h
 #define conf_ssl_h
 
 
+/**
+ * @file
+ * SSL related definitions
+ */
+
 #ifdef HAVE_LIBSSL
 #ifdef HAVE_LIBSSL
 #define SSL_SUPPORT
 #define SSL_SUPPORT
 #include <openssl/ssl.h>
 #include <openssl/ssl.h>

File diff suppressed because it is too large
+ 882 - 437
src/ngircd/conf.c


+ 108 - 69
src/ngircd/conf.h

@@ -1,20 +1,22 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Configuration management (header)
  */
  */
 
 
-
 #ifndef __conf_h__
 #ifndef __conf_h__
 #define __conf_h__
 #define __conf_h__
 
 
+/**
+ * @file
+ * Configuration management (header)
+ */
+
 #include <time.h>
 #include <time.h>
 
 
 #include "defines.h"
 #include "defines.h"
@@ -25,54 +27,66 @@
 #include "proc.h"
 #include "proc.h"
 #include "conf-ssl.h"
 #include "conf-ssl.h"
 
 
-
+/**
+ * Configured IRC operator.
+ * Please note the the name of the IRC operaor and his nick have nothing to
+ * do with each other! The IRC operator is only identified by the name and
+ * password configured in this structure.
+ */
 struct Conf_Oper {
 struct Conf_Oper {
-	char name[CLIENT_PASS_LEN];	/* Name (ID) of IRC operator */
-	char pwd[CLIENT_PASS_LEN];	/* Password */
-	char *mask;			/* allowed host mask */
+	char name[CLIENT_PASS_LEN];	/**< Name (ID) */
+	char pwd[CLIENT_PASS_LEN];	/**< Password */
+	char *mask;			/**< Allowed host mask */
 };
 };
 
 
+/**
+ * Configured server.
+ * Peers to which this daemon should establish an outgoing server link must
+ * have set a port number; all other servers are allowed to connect to this one.
+ */
 typedef struct _Conf_Server
 typedef struct _Conf_Server
 {
 {
-	char host[HOST_LEN];		/* Hostname */
-	char name[CLIENT_ID_LEN];	/* IRC-Client-ID */
-	char pwd_in[CLIENT_PASS_LEN];	/* Password which must be received */
-	char pwd_out[CLIENT_PASS_LEN];	/* Password to send to peer */
-	UINT16 port;			/* Server port */
-	int group;			/* Group of server */
-	time_t lasttry;			/* Last connect attempt */
-	PROC_STAT res_stat;		/* Status of the resolver */
-	int flags;			/* Flags */
-	CONN_ID conn_id;		/* ID of server connection or NONE */
-	ng_ipaddr_t bind_addr;		/* source address to use for outgoing
-					   connections */
-	ng_ipaddr_t dst_addr[2];	/* list of addresses to connect to */
+	char host[HOST_LEN];		/**< Hostname */
+	char name[CLIENT_ID_LEN];	/**< IRC client ID */
+	char pwd_in[CLIENT_PASS_LEN];	/**< Password which must be received */
+	char pwd_out[CLIENT_PASS_LEN];	/**< Password to send to the peer */
+	UINT16 port;			/**< Server port to connect to */
+	int group;			/**< Group ID of this server */
+	time_t lasttry;			/**< Time of last connection attempt */
+	PROC_STAT res_stat;		/**< Status of the resolver */
+	int flags;			/**< Server flags */
+	CONN_ID conn_id;		/**< ID of server connection or NONE */
+	ng_ipaddr_t bind_addr;		/**< Source address to use for outgoing
+					     connections */
+	ng_ipaddr_t dst_addr[2];	/**< List of addresses to connect to */
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
-	bool SSLConnect;		/* connect() using SSL? */
+	bool SSLConnect;		/**< Establish connection using SSL? */
 #endif
 #endif
-	char svs_mask[CLIENT_ID_LEN];	/* Mask of nick names that are
-					   services */
+	char svs_mask[CLIENT_ID_LEN];	/**< Mask of nick names that should be
+					     treated and counted as services */
 } CONF_SERVER;
 } CONF_SERVER;
 
 
 
 
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
+/** Configuration options required for SSL support */
 struct SSLOptions {
 struct SSLOptions {
-	char *KeyFile;
-	char *CertFile;
-	char *DHFile;
-	array ListenPorts;
-	array KeyFilePassword;
+	char *KeyFile;			/**< SSL key file */
+	char *CertFile;			/**< SSL certificate file */
+	char *DHFile;			/**< File containing DH parameters */
+	array ListenPorts;		/**< Array of listening SSL ports */
+	array KeyFilePassword;		/**< Key file password */
 };
 };
 #endif
 #endif
 
 
 
 
+/** Pre-defined channels */
 struct Conf_Channel {
 struct Conf_Channel {
-	char name[CHANNEL_NAME_LEN];	/* Name of the channel */
-	char modes[CHANNEL_MODE_LEN];	/* Initial channel modes */
-	char key[CLIENT_PASS_LEN];      /* Channel key ("password", mode "k" ) */
-	char topic[COMMAND_LEN];	/* Initial topic */
-	char keyfile[512];		/* Path and name of channel key file */
-	unsigned long maxusers;		/* maximum usercount for this channel, mode "l" */
+	char name[CHANNEL_NAME_LEN];	/**< Name of the channel */
+	char modes[CHANNEL_MODE_LEN];	/**< Initial channel modes */
+	char key[CLIENT_PASS_LEN];      /**< Channel key ("password", mode "k" ) */
+	char topic[COMMAND_LEN];	/**< Initial topic */
+	char keyfile[512];		/**< Path and name of channel key file */
+	unsigned long maxusers;		/**< User limit for this channel, mode "l" */
 };
 };
 
 
 
 
@@ -80,80 +94,98 @@ struct Conf_Channel {
 #define CONF_SFLAG_DISABLED 2		/* This server configuration entry is disabled */
 #define CONF_SFLAG_DISABLED 2		/* This server configuration entry is disabled */
 
 
 
 
-/* Name ("Nick") of the servers */
+/** Name (ID, "nick") of this server */
 GLOBAL char Conf_ServerName[CLIENT_ID_LEN];
 GLOBAL char Conf_ServerName[CLIENT_ID_LEN];
 
 
-/* Server info text */
+/** Server info text */
 GLOBAL char Conf_ServerInfo[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerInfo[CLIENT_INFO_LEN];
 
 
-/* Global server passwort */
+/** Global server passwort */
 GLOBAL char Conf_ServerPwd[CLIENT_PASS_LEN];
 GLOBAL char Conf_ServerPwd[CLIENT_PASS_LEN];
 
 
-/* Administrative information */
+/** Administrative information */
 GLOBAL char Conf_ServerAdmin1[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerAdmin1[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerAdmin2[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerAdmin2[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerAdminMail[CLIENT_INFO_LEN];
 GLOBAL char Conf_ServerAdminMail[CLIENT_INFO_LEN];
 
 
-/* Message of the Day */
+/** Message of the day (MOTD) of this server */
 GLOBAL array Conf_Motd;
 GLOBAL array Conf_Motd;
 
 
-/* Ports the server should listen on */
+/** Array of ports this server should listen on */
 GLOBAL array Conf_ListenPorts;
 GLOBAL array Conf_ListenPorts;
 
 
-/* Address to which the socket should be bound or empty (=all) */
+/** Address to which sockets should be bound to or empty (=all) */
 GLOBAL char *Conf_ListenAddress;
 GLOBAL char *Conf_ListenAddress;
 
 
-/* User and group ID the server should run with */
+/** User and group ID this daemon should run with */
 GLOBAL uid_t Conf_UID;
 GLOBAL uid_t Conf_UID;
 GLOBAL gid_t Conf_GID;
 GLOBAL gid_t Conf_GID;
 
 
-/* A directory to chroot() in */
+/** The directory to chroot() into */
 GLOBAL char Conf_Chroot[FNAME_LEN];
 GLOBAL char Conf_Chroot[FNAME_LEN];
 
 
-/* File with PID of daemon */
+/** Full path and name of a file to which the PID of daemon should be written */
 GLOBAL char Conf_PidFile[FNAME_LEN];
 GLOBAL char Conf_PidFile[FNAME_LEN];
 
 
-/* Timeouts for PING and PONG */
+/** Timeout (in seconds) for PING commands */
 GLOBAL int Conf_PingTimeout;
 GLOBAL int Conf_PingTimeout;
+
+/** Timeout (in seconds) for PONG replies */
 GLOBAL int Conf_PongTimeout;
 GLOBAL int Conf_PongTimeout;
 
 
-/* Seconds between connect attempts to other servers */
+/** Seconds between connection attempts to other servers */
 GLOBAL int Conf_ConnectRetry;
 GLOBAL int Conf_ConnectRetry;
 
 
-/* Operators */
+/** Array of configured IRC operators */
 GLOBAL array Conf_Opers;
 GLOBAL array Conf_Opers;
 
 
-/* Servers */
+/** Array of configured IRC servers */
 GLOBAL CONF_SERVER Conf_Server[MAX_SERVERS];
 GLOBAL CONF_SERVER Conf_Server[MAX_SERVERS];
 
 
-/* Pre-defined channels */
+/** Array of pre-defined channels */
 GLOBAL array Conf_Channels;
 GLOBAL array Conf_Channels;
 
 
-/* Pre-defined channels only */
+/** Flag indicating if only pre-defined channels are allowed (true) or not */
 GLOBAL bool Conf_PredefChannelsOnly;
 GLOBAL bool Conf_PredefChannelsOnly;
 
 
-/* Are IRC operators allowed to always use MODE? */
+/** Flag indicating if IRC operators are allowed to always use MODE (true) */
 GLOBAL bool Conf_OperCanMode;
 GLOBAL bool Conf_OperCanMode;
 
 
-/* If an IRC op gives chanop privileges without being a chanop,
- * ircd2 will ignore the command. This enables a workaround:
- * It masks the command as coming from the server */
+/**
+ * If true, mask channel MODE commands of IRC operators to the server.
+ * Background: ircd2 will ignore channel MODE commands if an IRC operator
+ * gives chanel operator privileges to someone without being a channel operator
+ * himself. This enables a workaround: it masks the MODE command as coming
+ * from the IRC server and not the IRC operator.
+ */
 GLOBAL bool Conf_OperServerMode;
 GLOBAL bool Conf_OperServerMode;
 
 
-/* Are remote IRC operators allowed to manage this server? */
+/** Flag indicating if remote IRC operators are allowed to manage this server */
 GLOBAL bool Conf_AllowRemoteOper;
 GLOBAL bool Conf_AllowRemoteOper;
 
 
-/* Disable all DNS functions? */
-GLOBAL bool Conf_NoDNS;
+/** Cloaked hostname of the clients */
+GLOBAL char Conf_CloakHost[CLIENT_ID_LEN];
+
+/** Use nick name as user name? */
+GLOBAL bool Conf_CloakUserToNick;
+
+/** Enable all DNS functions? */
+GLOBAL bool Conf_DNS;
+
+/** Enable IDENT lookups, even when compiled with support for it */
+GLOBAL bool Conf_Ident;
+
+/** Enable "more privacy" mode and "censor" some user-related information */
+GLOBAL bool Conf_MorePrivacy;
 
 
-/* Disable IDENT lookups, even when compiled with support for it */
-GLOBAL bool Conf_NoIdent;
+/** Enable NOTICE AUTH messages on connect */
+GLOBAL bool Conf_NoticeAuth;
 
 
-/* Disable all usage of PAM, even when compiled with support for it */
-GLOBAL bool Conf_NoPAM;
+/** Enable all usage of PAM, even when compiled with support for it */
+GLOBAL bool Conf_PAM;
 
 
-/* Disable service registration using "ZeroConf" */
-GLOBAL bool Conf_NoZeroConf;
+/** Disable all CTCP commands except for /me ? */
+GLOBAL bool Conf_ScrubCTCP;
 
 
 /*
 /*
  * try to connect to remote systems using the ipv6 protocol,
  * try to connect to remote systems using the ipv6 protocol,
@@ -161,21 +193,28 @@ GLOBAL bool Conf_NoZeroConf;
  */
  */
 GLOBAL bool Conf_ConnectIPv6;
 GLOBAL bool Conf_ConnectIPv6;
 
 
-/* same as above, but for ipv4 hosts, default: yes  */
+/** Try to connect to remote systems using the IPv4 protocol (true) */
 GLOBAL bool Conf_ConnectIPv4;
 GLOBAL bool Conf_ConnectIPv4;
 
 
-/* Maximum number of connections to this server */
+/** Maximum number of simultaneous connections to this server */
 GLOBAL long Conf_MaxConnections;
 GLOBAL long Conf_MaxConnections;
 
 
-/* Maximum number of channels a user can join */
+/** Maximum number of channels a user can join */
 GLOBAL int Conf_MaxJoins;
 GLOBAL int Conf_MaxJoins;
 
 
-/* Maximum number of connections per IP address */
+/** Maximum number of connections per IP address */
 GLOBAL int Conf_MaxConnectionsIP;
 GLOBAL int Conf_MaxConnectionsIP;
 
 
-/* Maximum length of a nick name */
+/** Maximum length of a nick name */
 GLOBAL unsigned int Conf_MaxNickLength;
 GLOBAL unsigned int Conf_MaxNickLength;
 
 
+#ifndef STRICT_RFC
+
+/** Require "AUTH PING-PONG" on login */
+GLOBAL bool Conf_AuthPing;
+
+#endif
+
 #ifdef SYSLOG
 #ifdef SYSLOG
 
 
 /* Syslog "facility" */
 /* Syslog "facility" */

+ 5 - 3
src/ngircd/conn-func.c

@@ -7,15 +7,17 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Connection management: Global functions
  */
  */
 
 
-
 #define CONN_MODULE
 #define CONN_MODULE
 
 
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Connection management: Global functions
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <string.h>
 #include <string.h>

+ 4 - 3
src/ngircd/conn-func.h

@@ -7,14 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Connection management: Global functions (header)
  */
  */
 
 
-
 #ifndef __conn_func_h__
 #ifndef __conn_func_h__
 #define __conn_func_h__
 #define __conn_func_h__
 
 
+/**
+ * @file
+ * Connection management: Global functions (header)
+ */
 
 
 /* Include the header conn.h if this header is _not_ included by any module
 /* Include the header conn.h if this header is _not_ included by any module
  * containing connection handling functions. So other modules must only
  * containing connection handling functions. So other modules must only

+ 10 - 5
src/ngircd/conn-ssl.c

@@ -1,11 +1,15 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- *
- * SSL wrapper functions.
  * Copyright (c) 2005-2008 Florian Westphal <fw@strlen.de>
  * Copyright (c) 2005-2008 Florian Westphal <fw@strlen.de>
  */
  */
 
 
 #include "portab.h"
 #include "portab.h"
+
+/**
+ * @file
+ * SSL wrapper functions
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include "conf-ssl.h"
 #include "conf-ssl.h"
 
 
@@ -47,10 +51,11 @@ static bool ConnSSL_LoadServerKey_openssl PARAMS(( SSL_CTX *c ));
 #include <unistd.h>
 #include <unistd.h>
 #include <gnutls/x509.h>
 #include <gnutls/x509.h>
 
 
-#define DH_BITS 1024
+#define DH_BITS 2048
+#define DH_BITS_MIN 1024
+
 static gnutls_certificate_credentials_t x509_cred;
 static gnutls_certificate_credentials_t x509_cred;
 static gnutls_dh_params_t dh_params;
 static gnutls_dh_params_t dh_params;
-
 static bool ConnSSL_LoadServerKey_gnutls PARAMS(( void ));
 static bool ConnSSL_LoadServerKey_gnutls PARAMS(( void ));
 #endif
 #endif
 
 
@@ -422,7 +427,7 @@ ConnSSL_Init_SSL(CONNECTION *c)
 		ConnSSL_Free(c);
 		ConnSSL_Free(c);
 		return false;
 		return false;
 	}
 	}
-	gnutls_dh_set_prime_bits(c->ssl_state.gnutls_session, DH_BITS);
+	gnutls_dh_set_prime_bits(c->ssl_state.gnutls_session, DH_BITS_MIN);
 #endif
 #endif
 	Conn_OPTION_ADD(c, CONN_SSL);
 	Conn_OPTION_ADD(c, CONN_SSL);
 	return true;
 	return true;

+ 5 - 1
src/ngircd/conn-ssl.h

@@ -1,11 +1,15 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * SSL wrapper functions. (header)
  */
  */
 
 
 #ifndef conn_ssl_h
 #ifndef conn_ssl_h
 #define conn_ssl_h
 #define conn_ssl_h
 
 
+/**
+ * @file
+ * SSL wrapper functions (header)
+ */
+
 #include "conf-ssl.h"
 #include "conf-ssl.h"
 #include "conn.h"
 #include "conn.h"
 #include "conf.h"
 #include "conf.h"

+ 8 - 5
src/ngircd/conn-zip.c

@@ -7,12 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Connection compression using ZLIB
  */
  */
 
 
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Connection compression using ZLIB
+ */
+
 #define CONN_MODULE
 #define CONN_MODULE
 
 
 #ifdef ZLIB
 #ifdef ZLIB
@@ -105,8 +108,8 @@ Zip_Buffer( CONN_ID Idx, const char *Data, size_t Len )
 	 * otherwise the zip wbuf would grow too large */
 	 * otherwise the zip wbuf would grow too large */
 	buflen = array_bytes(&My_Connections[Idx].zip.wbuf);
 	buflen = array_bytes(&My_Connections[Idx].zip.wbuf);
 	if (buflen + Len >= WRITEBUFFER_SLINK_LEN) {
 	if (buflen + Len >= WRITEBUFFER_SLINK_LEN) {
-		Log(LOG_ALERT, "Zip Write Buffer overflow: %lu bytes\n", buflen + Len);
-		Conn_Close(Idx, "Zip Write buffer overflow", NULL, false);
+		Log(LOG_ALERT, "Zip Write buffer space exhausted: %lu bytes", buflen + Len);
+		Conn_Close(Idx, "Zip Write buffer space exhausted", NULL, false);
 		return false;
 		return false;
 	}
 	}
 	return array_catb(&My_Connections[Idx].zip.wbuf, Data, Len);
 	return array_catb(&My_Connections[Idx].zip.wbuf, Data, Len);
@@ -155,7 +158,7 @@ Zip_Flush( CONN_ID Idx )
 	if (out->avail_out <= 0) {
 	if (out->avail_out <= 0) {
 		/* Not all data was compressed, because data became
 		/* Not all data was compressed, because data became
 		 * bigger while compressing it. */
 		 * bigger while compressing it. */
-		Log (LOG_ALERT, "Compression error: buffer overvlow!?");
+		Log(LOG_ALERT, "Compression error: buffer overflow!?");
 		Conn_Close(Idx, "Compression error!", NULL, false);
 		Conn_Close(Idx, "Compression error!", NULL, false);
 		return false;
 		return false;
 	}
 	}

+ 4 - 7
src/ngircd/conn-zip.h

@@ -7,18 +7,17 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: conn-zip.h,v 1.4 2006/05/10 21:24:01 alex Exp $
- *
- * Connection compression using ZLIB (header)
  */
  */
 
 
-
 #ifdef ZLIB
 #ifdef ZLIB
 
 
 #ifndef __conn_zip_h__
 #ifndef __conn_zip_h__
 #define __conn_zip_h__
 #define __conn_zip_h__
 
 
+/**
+ * @file
+ * Connection compression using ZLIB (header)
+ */
 
 
 GLOBAL bool Zip_InitConn PARAMS(( CONN_ID Idx ));
 GLOBAL bool Zip_InitConn PARAMS(( CONN_ID Idx ));
 
 
@@ -29,10 +28,8 @@ GLOBAL bool Unzip_Buffer PARAMS(( CONN_ID Idx ));
 GLOBAL long Zip_SendBytes PARAMS(( CONN_ID Idx ));
 GLOBAL long Zip_SendBytes PARAMS(( CONN_ID Idx ));
 GLOBAL long Zip_RecvBytes PARAMS(( CONN_ID Idx ));
 GLOBAL long Zip_RecvBytes PARAMS(( CONN_ID Idx ));
 
 
-
 #endif /* __conn_zip_h__ */
 #endif /* __conn_zip_h__ */
 
 
 #endif /* ZLIB */
 #endif /* ZLIB */
 
 
-
 /* -eof- */
 /* -eof- */

+ 303 - 133
src/ngircd/conn.c

@@ -7,17 +7,19 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Connection management
  */
  */
 
 
-
 #define CONN_MODULE
 #define CONN_MODULE
 
 
 #include "portab.h"
 #include "portab.h"
 #include "conf-ssl.h"
 #include "conf-ssl.h"
 #include "io.h"
 #include "io.h"
 
 
+/**
+ * @file
+ * Connection management
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #ifdef PROTOTYPES
 #ifdef PROTOTYPES
@@ -71,10 +73,6 @@
 #include "resolve.h"
 #include "resolve.h"
 #include "tool.h"
 #include "tool.h"
 
 
-#ifdef ZEROCONF
-# include "rendezvous.h"
-#endif
-
 #include "exp.h"
 #include "exp.h"
 
 
 
 
@@ -82,6 +80,7 @@
 
 
 #define MAX_COMMANDS 3
 #define MAX_COMMANDS 3
 #define MAX_COMMANDS_SERVER 10
 #define MAX_COMMANDS_SERVER 10
+#define MAX_COMMANDS_SERVICE MAX_COMMANDS_SERVER
 
 
 
 
 static bool Handle_Write PARAMS(( CONN_ID Idx ));
 static bool Handle_Write PARAMS(( CONN_ID Idx ));
@@ -124,8 +123,9 @@ static void cb_clientserver PARAMS((int sock, short what));
 /**
 /**
  * IO callback for listening sockets: handle new connections. This callback
  * IO callback for listening sockets: handle new connections. This callback
  * gets called when a new non-SSL connection should be accepted.
  * gets called when a new non-SSL connection should be accepted.
- * @param sock Socket descriptor
- * @param irrelevant (ignored IO specification)
+ *
+ * @param sock		Socket descriptor.
+ * @param irrelevant	(ignored IO specification)
  */
  */
 static void
 static void
 cb_listen(int sock, short irrelevant)
 cb_listen(int sock, short irrelevant)
@@ -139,8 +139,9 @@ cb_listen(int sock, short irrelevant)
 /**
 /**
  * IO callback for listening SSL sockets: handle new connections. This callback
  * IO callback for listening SSL sockets: handle new connections. This callback
  * gets called when a new SSL-enabled connection should be accepted.
  * gets called when a new SSL-enabled connection should be accepted.
- * @param sock Socket descriptor
- * @param irrelevant (ignored IO specification)
+ *
+ * @param sock		Socket descriptor.
+ * @param irrelevant	(ignored IO specification)
  */
  */
 static void
 static void
 cb_listen_ssl(int sock, short irrelevant)
 cb_listen_ssl(int sock, short irrelevant)
@@ -158,8 +159,9 @@ cb_listen_ssl(int sock, short irrelevant)
 
 
 /**
 /**
  * IO callback for new outgoing non-SSL server connections.
  * IO callback for new outgoing non-SSL server connections.
- * @param sock Socket descriptor
- * @param what IO specification (IO_WANTREAD/IO_WANTWRITE/...)
+ *
+ * @param sock	Socket descriptor.
+ * @param what	IO specification (IO_WANTREAD/IO_WANTWRITE/...).
  */
  */
 static void
 static void
 cb_connserver(int sock, UNUSED short what)
 cb_connserver(int sock, UNUSED short what)
@@ -236,13 +238,16 @@ cb_connserver(int sock, UNUSED short what)
 
 
 /**
 /**
  * Login to a remote server.
  * Login to a remote server.
- * @param idx Connection index
+ *
+ * @param idx	Connection index.
  */
  */
 static void
 static void
 server_login(CONN_ID idx)
 server_login(CONN_ID idx)
 {
 {
-	Log( LOG_INFO, "Connection %d with \"%s:%d\" established. Now logging in ...", idx,
-			My_Connections[idx].host, Conf_Server[Conf_GetServer( idx )].port );
+	Log(LOG_INFO,
+	    "Connection %d (socket %d) with \"%s:%d\" established. Now logging in ...",
+	    idx, My_Connections[idx].sock, My_Connections[idx].host,
+	    Conf_Server[Conf_GetServer(idx)].port);
 
 
 	io_event_setcb( My_Connections[idx].sock, cb_clientserver);
 	io_event_setcb( My_Connections[idx].sock, cb_clientserver);
 	io_event_add( My_Connections[idx].sock, IO_WANTREAD|IO_WANTWRITE);
 	io_event_add( My_Connections[idx].sock, IO_WANTREAD|IO_WANTWRITE);
@@ -256,8 +261,9 @@ server_login(CONN_ID idx)
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
 /**
 /**
  * IO callback for new outgoing SSL-enabled server connections.
  * IO callback for new outgoing SSL-enabled server connections.
- * @param sock Socket descriptor
- * @param what IO specification (IO_WANTREAD/IO_WANTWRITE/...)
+ *
+ * @param sock		Socket descriptor.
+ * @param unused	(ignored IO specification)
  */
  */
 static void
 static void
 cb_connserver_login_ssl(int sock, short unused)
 cb_connserver_login_ssl(int sock, short unused)
@@ -290,8 +296,9 @@ cb_connserver_login_ssl(int sock, short unused)
 
 
 /**
 /**
  * IO callback for established non-SSL client and server connections.
  * IO callback for established non-SSL client and server connections.
- * @param sock Socket descriptor
- * @param what IO specification (IO_WANTREAD/IO_WANTWRITE/...)
+ *
+ * @param sock	Socket descriptor.
+ * @param what	IO specification (IO_WANTREAD/IO_WANTWRITE/...).
  */
  */
 static void
 static void
 cb_clientserver(int sock, short what)
 cb_clientserver(int sock, short what)
@@ -323,8 +330,9 @@ cb_clientserver(int sock, short what)
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
 /**
 /**
  * IO callback for established SSL-enabled client and server connections.
  * IO callback for established SSL-enabled client and server connections.
- * @param sock Socket descriptor
- * @param what IO specification (IO_WANTREAD/IO_WANTWRITE/...)
+ *
+ * @param sock	Socket descriptor.
+ * @param what	IO specification (IO_WANTREAD/IO_WANTWRITE/...).
  */
  */
 static void
 static void
 cb_clientserver_ssl(int sock, short what)
 cb_clientserver_ssl(int sock, short what)
@@ -436,6 +444,14 @@ Conn_CloseAllSockets(void)
 }
 }
 
 
 
 
+/**
+ * Initialize listening ports.
+ *
+ * @param a		Array containing the ports the daemon should listen on.
+ * @param listen_addr	Address the socket should listen on (can be "0.0.0.0").
+ * @param func		IO callback function to register.
+ * @returns		Number of listening sockets created.
+ */
 static unsigned int
 static unsigned int
 ports_initlisteners(array *a, const char *listen_addr, void (*func)(int,short))
 ports_initlisteners(array *a, const char *listen_addr, void (*func)(int,short))
 {
 {
@@ -468,7 +484,8 @@ ports_initlisteners(array *a, const char *listen_addr, void (*func)(int,short))
 
 
 /**
 /**
  * Initialize all listening sockets.
  * Initialize all listening sockets.
- * @return Number of created listening sockets
+ *
+ * @returns	Number of created listening sockets
  */
  */
 GLOBAL unsigned int
 GLOBAL unsigned int
 Conn_InitListeners( void )
 Conn_InitListeners( void )
@@ -509,15 +526,15 @@ Conn_InitListeners( void )
 } /* Conn_InitListeners */
 } /* Conn_InitListeners */
 
 
 
 
+/**
+ * Shut down all listening sockets.
+ */
 GLOBAL void
 GLOBAL void
 Conn_ExitListeners( void )
 Conn_ExitListeners( void )
 {
 {
 	/* Close down all listening sockets */
 	/* Close down all listening sockets */
 	int *fd;
 	int *fd;
 	size_t arraylen;
 	size_t arraylen;
-#ifdef ZEROCONF
-	Rendezvous_UnregisterListeners( );
-#endif
 
 
 	arraylen = array_length(&My_Listeners, sizeof (int));
 	arraylen = array_length(&My_Listeners, sizeof (int));
 	Log(LOG_INFO,
 	Log(LOG_INFO,
@@ -534,6 +551,14 @@ Conn_ExitListeners( void )
 } /* Conn_ExitListeners */
 } /* Conn_ExitListeners */
 
 
 
 
+/**
+ * Bind a socket to a specific (source) address.
+ *
+ * @param addr			Address structure.
+ * @param listen_addrstr	Source address as string.
+ * @param Port			Port number.
+ * @returns			true on success, false otherwise.
+ */
 static bool
 static bool
 InitSinaddrListenAddr(ng_ipaddr_t *addr, const char *listen_addrstr, UINT16 Port)
 InitSinaddrListenAddr(ng_ipaddr_t *addr, const char *listen_addrstr, UINT16 Port)
 {
 {
@@ -549,6 +574,14 @@ InitSinaddrListenAddr(ng_ipaddr_t *addr, const char *listen_addrstr, UINT16 Port
 }
 }
 
 
 
 
+/**
+ * Set a socket to "IPv6 only". If the given socket doesn't belong to the
+ * AF_INET6 family, or the operating system doesn't support this functionality,
+ * this function retruns silently.
+ *
+ * @param af	Address family of the socket.
+ * @param sock	Socket handle.
+ */
 static void
 static void
 set_v6_only(int af, int sock)
 set_v6_only(int af, int sock)
 {
 {
@@ -567,16 +600,20 @@ set_v6_only(int af, int sock)
 }
 }
 
 
 
 
-/* return new listening port file descriptor or -1 on failure */
+/**
+ * Initialize new listening port.
+ *
+ * @param listen_addr	Local address to bind the socet to (can be 0.0.0.0).
+ * @param Port		Port number on which the new socket should be listening.
+ * @returns		file descriptor of the socket or -1 on failure.
+ */
 static int
 static int
 NewListener(const char *listen_addr, UINT16 Port)
 NewListener(const char *listen_addr, UINT16 Port)
 {
 {
 	/* Create new listening socket on specified port */
 	/* Create new listening socket on specified port */
 	ng_ipaddr_t addr;
 	ng_ipaddr_t addr;
 	int sock, af;
 	int sock, af;
-#ifdef ZEROCONF
-	char name[CLIENT_ID_LEN], *info;
-#endif
+
 	if (!InitSinaddrListenAddr(&addr, listen_addr, Port))
 	if (!InitSinaddrListenAddr(&addr, listen_addr, Port))
 		return -1;
 		return -1;
 
 
@@ -612,44 +649,17 @@ NewListener(const char *listen_addr, UINT16 Port)
 		return -1;
 		return -1;
 	}
 	}
 
 
-	Log(LOG_INFO, "Now listening on [%s]:%d (socket %d).", ng_ipaddr_tostr(&addr), Port, sock);
-
-#ifdef ZEROCONF
-	/* Get best server description text */
-	if( ! Conf_ServerInfo[0] ) info = Conf_ServerName;
-	else
-	{
-		/* Use server info string */
-		info = NULL;
-		if( Conf_ServerInfo[0] == '[' )
-		{
-			/* Cut off leading hostname part in "[]" */
-			info = strchr( Conf_ServerInfo, ']' );
-			if( info )
-			{
-				info++;
-				while( *info == ' ' ) info++;
-			}
-		}
-		if( ! info ) info = Conf_ServerInfo;
-	}
-
-	/* Add port number to description if non-standard */
-	if (Port != 6667)
-		snprintf(name, sizeof name, "%s (port %u)", info,
-		 	 (unsigned int)Port);
-	else
-	 	strlcpy(name, info, sizeof name);
-
-	/* Register service */
-	Rendezvous_Register( name, MDNS_TYPE, Port );
-#endif
+	Log(LOG_INFO, "Now listening on [%s]:%d (socket %d).",
+	    ng_ipaddr_tostr(&addr), Port, sock);
 	return sock;
 	return sock;
 } /* NewListener */
 } /* NewListener */
 
 
 
 
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
-/*
+
+/**
+ * Check if SSL library needs to read SSL-protocol related data.
+ *
  * SSL/TLS connections require extra treatment:
  * SSL/TLS connections require extra treatment:
  * When either CONN_SSL_WANT_WRITE or CONN_SSL_WANT_READ is set, we
  * When either CONN_SSL_WANT_WRITE or CONN_SSL_WANT_READ is set, we
  * need to take care of that first, before checking read/write buffers.
  * need to take care of that first, before checking read/write buffers.
@@ -660,6 +670,9 @@ NewListener(const char *listen_addr, UINT16 Port)
  * If this function returns true, such a condition is met and we have
  * If this function returns true, such a condition is met and we have
  * to reverse the condition (check for read even if we've data to write,
  * to reverse the condition (check for read even if we've data to write,
  * do not check for read but writeability even if write-buffer is empty).
  * do not check for read but writeability even if write-buffer is empty).
+ *
+ * @param c	Connection to check.
+ * @returns	true if SSL-library has to read protocol data.
  */
  */
 static bool
 static bool
 SSL_WantRead(const CONNECTION *c)
 SSL_WantRead(const CONNECTION *c)
@@ -670,6 +683,15 @@ SSL_WantRead(const CONNECTION *c)
 	}
 	}
 	return false;
 	return false;
 }
 }
+
+/**
+ * Check if SSL library needs to write SSL-protocol related data.
+ *
+ * Please see description of SSL_WantRead() for full description!
+ *
+ * @param c	Connection to check.
+ * @returns	true if SSL-library has to write protocol data.
+ */
 static bool
 static bool
 SSL_WantWrite(const CONNECTION *c)
 SSL_WantWrite(const CONNECTION *c)
 {
 {
@@ -679,18 +701,23 @@ SSL_WantWrite(const CONNECTION *c)
 	}
 	}
 	return false;
 	return false;
 }
 }
+
 #else
 #else
+
 static inline bool
 static inline bool
 SSL_WantRead(UNUSED const CONNECTION *c)
 SSL_WantRead(UNUSED const CONNECTION *c)
 { return false; }
 { return false; }
+
 static inline bool
 static inline bool
 SSL_WantWrite(UNUSED const CONNECTION *c)
 SSL_WantWrite(UNUSED const CONNECTION *c)
 { return false; }
 { return false; }
+
 #endif
 #endif
 
 
 
 
 /**
 /**
  * "Main Loop": Loop until shutdown or restart is signalled.
  * "Main Loop": Loop until shutdown or restart is signalled.
+ *
  * This function loops until a shutdown or restart of ngIRCd is signalled and
  * This function loops until a shutdown or restart of ngIRCd is signalled and
  * calls io_dispatch() to check for readable and writable sockets every second.
  * calls io_dispatch() to check for readable and writable sockets every second.
  * It checks for status changes on pending connections (e. g. when a hostname
  * It checks for status changes on pending connections (e. g. when a hostname
@@ -708,10 +735,6 @@ Conn_Handler(void)
 	while (!NGIRCd_SignalQuit && !NGIRCd_SignalRestart) {
 	while (!NGIRCd_SignalQuit && !NGIRCd_SignalRestart) {
 		t = time(NULL);
 		t = time(NULL);
 
 
-#ifdef ZEROCONF
-		Rendezvous_Handler();
-#endif
-
 		/* Check configured servers and established links */
 		/* Check configured servers and established links */
 		Check_Servers();
 		Check_Servers();
 		Check_Connections();
 		Check_Connections();
@@ -814,12 +837,14 @@ Conn_Handler(void)
 
 
 /**
 /**
  * Write a text string into the socket of a connection.
  * Write a text string into the socket of a connection.
+ *
  * This function automatically appends CR+LF to the string and validates that
  * This function automatically appends CR+LF to the string and validates that
  * the result is a valid IRC message (oversized messages are shortened, for
  * the result is a valid IRC message (oversized messages are shortened, for
  * example). Then it calls the Conn_Write() function to do the actual sending.
  * example). Then it calls the Conn_Write() function to do the actual sending.
- * @param Idx Index fo the connection.
- * @param Format Format string, see printf().
- * @return true on success, false otherwise.
+ *
+ * @param Idx		Index fo the connection.
+ * @param Format	Format string, see printf().
+ * @returns		true on success, false otherwise.
  */
  */
 #ifdef PROTOTYPES
 #ifdef PROTOTYPES
 GLOBAL bool
 GLOBAL bool
@@ -889,16 +914,17 @@ va_dcl
 
 
 /**
 /**
  * Append Data to the outbound write buffer of a connection.
  * Append Data to the outbound write buffer of a connection.
- * @param Idx Index of the connection.
- * @param Data pointer to the data.
- * @param Len length of Data.
- * @return true on success, false otherwise.
+ *
+ * @param Idx	Index of the connection.
+ * @param Data	pointer to the data.
+ * @param Len	length of Data.
+ * @returns	true on success, false otherwise.
  */
  */
 static bool
 static bool
 Conn_Write( CONN_ID Idx, char *Data, size_t Len )
 Conn_Write( CONN_ID Idx, char *Data, size_t Len )
 {
 {
 	CLIENT *c;
 	CLIENT *c;
-	size_t writebuf_limit = WRITEBUFFER_LEN;
+	size_t writebuf_limit = WRITEBUFFER_MAX_LEN;
 	assert( Idx > NONE );
 	assert( Idx > NONE );
 	assert( Data != NULL );
 	assert( Data != NULL );
 	assert( Len > 0 );
 	assert( Len > 0 );
@@ -934,7 +960,7 @@ Conn_Write( CONN_ID Idx, char *Data, size_t Len )
 		/* Uncompressed link:
 		/* Uncompressed link:
 		 * Check if outbound buffer has enough space for the data. */
 		 * Check if outbound buffer has enough space for the data. */
 		if (array_bytes(&My_Connections[Idx].wbuf) + Len >=
 		if (array_bytes(&My_Connections[Idx].wbuf) + Len >=
-		    writebuf_limit) {
+		    WRITEBUFFER_FLUSH_LEN) {
 			/* Buffer is full, flush it. Handle_Write deals with
 			/* Buffer is full, flush it. Handle_Write deals with
 			 * low-level errors, if any. */
 			 * low-level errors, if any. */
 			if (!Handle_Write(Idx))
 			if (!Handle_Write(Idx))
@@ -946,10 +972,10 @@ Conn_Write( CONN_ID Idx, char *Data, size_t Len )
 		if (array_bytes(&My_Connections[Idx].wbuf) + Len >=
 		if (array_bytes(&My_Connections[Idx].wbuf) + Len >=
 		    writebuf_limit) {
 		    writebuf_limit) {
 			Log(LOG_NOTICE,
 			Log(LOG_NOTICE,
-			    "Write buffer overflow (connection %d, size %lu byte)!",
-			    Idx,
+			    "Write buffer space exhausted (connection %d, limit is %lu bytes, %lu bytes new, %lu bytes pending)",
+			    Idx, writebuf_limit, Len,
 			    (unsigned long)array_bytes(&My_Connections[Idx].wbuf));
 			    (unsigned long)array_bytes(&My_Connections[Idx].wbuf));
-			Conn_Close(Idx, "Write buffer overflow!", NULL, false);
+			Conn_Close(Idx, "Write buffer space exhausted", NULL, false);
 			return false;
 			return false;
 		}
 		}
 
 
@@ -967,6 +993,17 @@ Conn_Write( CONN_ID Idx, char *Data, size_t Len )
 } /* Conn_Write */
 } /* Conn_Write */
 
 
 
 
+/**
+ * Shut down a connection.
+ *
+ * @param Idx		Connection index.
+ * @param LogMsg	Message to write to the log or NULL. If no LogMsg
+ *			is given, the FwdMsg is logged.
+ * @param FwdMsg	Message to forward to remote servers.
+ * @param InformClient	If true, inform the client on the connection which is
+ *			to be shut down of the reason (FwdMsg) and send
+ *			connection statistics before disconnecting it.
+ */
 GLOBAL void
 GLOBAL void
 Conn_Close( CONN_ID Idx, const char *LogMsg, const char *FwdMsg, bool InformClient )
 Conn_Close( CONN_ID Idx, const char *LogMsg, const char *FwdMsg, bool InformClient )
 {
 {
@@ -1020,7 +1057,7 @@ Conn_Close( CONN_ID Idx, const char *LogMsg, const char *FwdMsg, bool InformClie
 		if (FwdMsg)
 		if (FwdMsg)
 			Conn_WriteStr(Idx, "ERROR :%s", FwdMsg);
 			Conn_WriteStr(Idx, "ERROR :%s", FwdMsg);
 		else
 		else
-			Conn_WriteStr(Idx, "ERROR :Closing connection.");
+			Conn_WriteStr(Idx, "ERROR :Closing connection");
 	}
 	}
 
 
 	/* Try to write out the write buffer. Note: Handle_Write() eventually
 	/* Try to write out the write buffer. Note: Handle_Write() eventually
@@ -1111,6 +1148,11 @@ Conn_Close( CONN_ID Idx, const char *LogMsg, const char *FwdMsg, bool InformClie
 } /* Conn_Close */
 } /* Conn_Close */
 
 
 
 
+/**
+ * Get current number of connections.
+ *
+ * @returns	Number of current connections.
+ */
 GLOBAL long
 GLOBAL long
 Conn_Count(void)
 Conn_Count(void)
 {
 {
@@ -1118,6 +1160,11 @@ Conn_Count(void)
 } /* Conn_Count */
 } /* Conn_Count */
 
 
 
 
+/**
+ * Get number of maximum simultaneous connections.
+ *
+ * @returns	Number of maximum simultaneous connections.
+ */
 GLOBAL long
 GLOBAL long
 Conn_CountMax(void)
 Conn_CountMax(void)
 {
 {
@@ -1125,6 +1172,11 @@ Conn_CountMax(void)
 } /* Conn_CountMax */
 } /* Conn_CountMax */
 
 
 
 
+/**
+ * Get number of connections accepted since the daemon startet.
+ *
+ * @returns	Number of connections accepted.
+ */
 GLOBAL long
 GLOBAL long
 Conn_CountAccepted(void)
 Conn_CountAccepted(void)
 {
 {
@@ -1166,6 +1218,9 @@ Conn_SyncServerStruct(void)
 
 
 /**
 /**
  * Send out data of write buffer; connect new sockets.
  * Send out data of write buffer; connect new sockets.
+ *
+ * @param Idx	Connection index.
+ * @returns	true on success, false otherwise.
  */
  */
 static bool
 static bool
 Handle_Write( CONN_ID Idx )
 Handle_Write( CONN_ID Idx )
@@ -1230,6 +1285,11 @@ Handle_Write( CONN_ID Idx )
 } /* Handle_Write */
 } /* Handle_Write */
 
 
 
 
+/**
+ * Count established connections to a specific IP address.
+ *
+ * @returns	Number of established connections.
+ */
 static int
 static int
 Count_Connections(ng_ipaddr_t *a)
 Count_Connections(ng_ipaddr_t *a)
 {
 {
@@ -1248,8 +1308,9 @@ Count_Connections(ng_ipaddr_t *a)
 
 
 /**
 /**
  * Initialize new client connection on a listening socket.
  * Initialize new client connection on a listening socket.
- * @param Sock Listening socket descriptor
- * @return Accepted socket descriptor or -1 on error
+ *
+ * @param Sock	Listening socket descriptor.
+ * @returns	Accepted socket descriptor or -1 on error.
  */
  */
 static int
 static int
 New_Connection(int Sock)
 New_Connection(int Sock)
@@ -1316,7 +1377,7 @@ New_Connection(int Sock)
 		    "Refused connection from %s: too may connections (%ld) from this IP address!",
 		    "Refused connection from %s: too may connections (%ld) from this IP address!",
 		    ip_str, cnt);
 		    ip_str, cnt);
 		Simple_Message(new_sock,
 		Simple_Message(new_sock,
-			       "ERROR :Connection refused, too many connections from your IP address!");
+			       "ERROR :Connection refused, too many connections from your IP address");
 		close(new_sock);
 		close(new_sock);
 		return -1;
 		return -1;
 	}
 	}
@@ -1380,18 +1441,32 @@ New_Connection(int Sock)
 
 
 	identsock = new_sock;
 	identsock = new_sock;
 #ifdef IDENTAUTH
 #ifdef IDENTAUTH
-	if (Conf_NoIdent)
+	if (!Conf_Ident)
 		identsock = -1;
 		identsock = -1;
 #endif
 #endif
-	if (!Conf_NoDNS)
+	if (Conf_DNS) {
+		if (Conf_NoticeAuth) {
+#ifdef IDENTAUTH
+			if (Conf_Ident)
+				(void)Conn_WriteStr(new_sock,
+					"NOTICE AUTH :*** Looking up your hostname and checking ident");
+			else
+#endif
+				(void)Conn_WriteStr(new_sock,
+					"NOTICE AUTH :*** Looking up your hostname");
+		}
 		Resolve_Addr(&My_Connections[new_sock].proc_stat, &new_addr,
 		Resolve_Addr(&My_Connections[new_sock].proc_stat, &new_addr,
 			     identsock, cb_Read_Resolver_Result);
 			     identsock, cb_Read_Resolver_Result);
+	}
 
 
 	Account_Connection();
 	Account_Connection();
 	return new_sock;
 	return new_sock;
 } /* New_Connection */
 } /* New_Connection */
 
 
 
 
+/**
+ * Update global connection counters.
+ */
 static void
 static void
 Account_Connection(void)
 Account_Connection(void)
 {
 {
@@ -1403,6 +1478,12 @@ Account_Connection(void)
 } /* Account_Connection */
 } /* Account_Connection */
 
 
 
 
+/**
+ * Translate socket handle into connection index.
+ *
+ * @param Sock	Socket handle.
+ * @returns	Connecion index or NONE, if no connection could be found.
+ */
 static CONN_ID
 static CONN_ID
 Socket2Index( int Sock )
 Socket2Index( int Sock )
 {
 {
@@ -1421,6 +1502,8 @@ Socket2Index( int Sock )
 /**
 /**
  * Read data from the network to the read buffer. If an error occures,
  * Read data from the network to the read buffer. If an error occures,
  * the socket of this connection will be shut down.
  * the socket of this connection will be shut down.
+ *
+ * @param Idx	Connection index.
  */
  */
 static void
 static void
 Read_Request( CONN_ID Idx )
 Read_Request( CONN_ID Idx )
@@ -1442,9 +1525,9 @@ Read_Request( CONN_ID Idx )
 	{
 	{
 		/* Read buffer is full */
 		/* Read buffer is full */
 		Log(LOG_ERR,
 		Log(LOG_ERR,
-		    "Receive buffer overflow (connection %d): %d bytes!",
+		    "Receive buffer space exhausted (connection %d): %d bytes",
 		    Idx, array_bytes(&My_Connections[Idx].rbuf));
 		    Idx, array_bytes(&My_Connections[Idx].rbuf));
-		Conn_Close( Idx, "Receive buffer overflow!", NULL, false );
+		Conn_Close(Idx, "Receive buffer space exhausted", NULL, false);
 		return;
 		return;
 	}
 	}
 
 
@@ -1480,7 +1563,7 @@ Read_Request( CONN_ID Idx )
 			Log(LOG_ERR,
 			Log(LOG_ERR,
 			    "Could not append recieved data to zip input buffer (connn %d): %d bytes!",
 			    "Could not append recieved data to zip input buffer (connn %d): %d bytes!",
 			    Idx, len);
 			    Idx, len);
-			Conn_Close(Idx, "Receive buffer overflow!", NULL,
+			Conn_Close(Idx, "Receive buffer space exhausted", NULL,
 				   false);
 				   false);
 			return;
 			return;
 		}
 		}
@@ -1489,22 +1572,27 @@ Read_Request( CONN_ID Idx )
 	{
 	{
 		if (!array_catb( &My_Connections[Idx].rbuf, readbuf, len)) {
 		if (!array_catb( &My_Connections[Idx].rbuf, readbuf, len)) {
 			Log( LOG_ERR, "Could not append recieved data to input buffer (connn %d): %d bytes!", Idx, len );
 			Log( LOG_ERR, "Could not append recieved data to input buffer (connn %d): %d bytes!", Idx, len );
-			Conn_Close( Idx, "Receive buffer overflow!", NULL, false );
+			Conn_Close(Idx, "Receive buffer space exhausted", NULL, false );
 		}
 		}
 	}
 	}
 
 
 	/* Update connection statistics */
 	/* Update connection statistics */
 	My_Connections[Idx].bytes_in += len;
 	My_Connections[Idx].bytes_in += len;
+	My_Connections[Idx].bps += Handle_Buffer(Idx);
+
+	/* Make sure that there is still a valid client registered */
+	c = Conn_GetClient(Idx);
+	if (!c)
+		return;
 
 
 	/* Update timestamp of last data received if this connection is
 	/* Update timestamp of last data received if this connection is
 	 * registered as a user, server or service connection. Don't update
 	 * registered as a user, server or service connection. Don't update
 	 * otherwise, so users have at least Conf_PongTimeout seconds time to
 	 * otherwise, so users have at least Conf_PongTimeout seconds time to
 	 * register with the IRC server -- see Check_Connections().
 	 * register with the IRC server -- see Check_Connections().
 	 * Update "lastping", too, if time shifted backwards ... */
 	 * Update "lastping", too, if time shifted backwards ... */
-	c = Conn_GetClient(Idx);
-	if (c && (Client_Type(c) == CLIENT_USER
-		  || Client_Type(c) == CLIENT_SERVER
-		  || Client_Type(c) == CLIENT_SERVICE)) {
+	if (Client_Type(c) == CLIENT_USER
+	    || Client_Type(c) == CLIENT_SERVER
+	    || Client_Type(c) == CLIENT_SERVICE) {
 		t = time(NULL);
 		t = time(NULL);
 		if (My_Connections[Idx].lastdata != t)
 		if (My_Connections[Idx].lastdata != t)
 			My_Connections[Idx].bps = 0;
 			My_Connections[Idx].bps = 0;
@@ -1515,8 +1603,9 @@ Read_Request( CONN_ID Idx )
 	}
 	}
 
 
 	/* Look at the data in the (read-) buffer of this connection */
 	/* Look at the data in the (read-) buffer of this connection */
-	My_Connections[Idx].bps += Handle_Buffer(Idx);
 	if (Client_Type(c) != CLIENT_SERVER
 	if (Client_Type(c) != CLIENT_SERVER
+	    && Client_Type(c) != CLIENT_UNKNOWNSERVER
+	    && Client_Type(c) != CLIENT_SERVICE
 	    && My_Connections[Idx].bps >= maxbps) {
 	    && My_Connections[Idx].bps >= maxbps) {
 		LogDebug("Throttling connection %d: BPS exceeded! (%u >= %u)",
 		LogDebug("Throttling connection %d: BPS exceeded! (%u >= %u)",
 			 Idx, My_Connections[Idx].bps, maxbps);
 			 Idx, My_Connections[Idx].bps, maxbps);
@@ -1527,11 +1616,13 @@ Read_Request( CONN_ID Idx )
 
 
 /**
 /**
  * Handle all data in the connection read-buffer.
  * Handle all data in the connection read-buffer.
+ *
  * Data is processed until no complete command is left in the read buffer,
  * Data is processed until no complete command is left in the read buffer,
- * or MAX_COMMANDS[_SERVER] commands were processed.
+ * or MAX_COMMANDS[_SERVER|_SERVICE] commands were processed.
  * When a fatal error occurs, the connection is shut down.
  * When a fatal error occurs, the connection is shut down.
- * @param Idx Index of the connection.
- * @return number of bytes processed.
+ *
+ * @param Idx	Index of the connection.
+ * @returns	Number of bytes processed.
  */
  */
 static unsigned int
 static unsigned int
 Handle_Buffer(CONN_ID Idx)
 Handle_Buffer(CONN_ID Idx)
@@ -1549,14 +1640,25 @@ Handle_Buffer(CONN_ID Idx)
 	CLIENT *c;
 	CLIENT *c;
 
 
 	c = Conn_GetClient(Idx);
 	c = Conn_GetClient(Idx);
-	assert( c != NULL);
+	starttime = time(NULL);
+
+	assert(c != NULL);
 
 
 	/* Servers do get special command limits, so they can process
 	/* Servers do get special command limits, so they can process
 	 * all the messages that are required while peering. */
 	 * all the messages that are required while peering. */
-	if (Client_Type(c) == CLIENT_SERVER)
-		maxcmd = MAX_COMMANDS_SERVER;
+	switch (Client_Type(c)) {
+	    case CLIENT_SERVER:
+		/* Allow servers to send more commands in the first 10 secods
+		 * to speed up server login and network synchronisation. */
+		if (starttime - Client_StartTime(c) < 10)
+			maxcmd = MAX_COMMANDS_SERVER * 5;
+		else
+			maxcmd = MAX_COMMANDS_SERVER;
+		break;
+	    case CLIENT_SERVICE:
+		maxcmd = MAX_COMMANDS_SERVICE; break;
+	}
 
 
-	starttime = time(NULL);
 	for (i=0; i < maxcmd; i++) {
 	for (i=0; i < maxcmd; i++) {
 		/* Check penalty */
 		/* Check penalty */
 		if (My_Connections[Idx].delaytime > starttime)
 		if (My_Connections[Idx].delaytime > starttime)
@@ -1786,6 +1888,12 @@ Check_Servers(void)
 } /* Check_Servers */
 } /* Check_Servers */
 
 
 
 
+/**
+ * Establish a new outgoing server connection.
+ *
+ * @param Server	Configuration index of the server.
+ * @param dest		Destination IP address to connect to.
+ */
 static void
 static void
 New_Server( int Server , ng_ipaddr_t *dest)
 New_Server( int Server , ng_ipaddr_t *dest)
 {
 {
@@ -1801,14 +1909,17 @@ New_Server( int Server , ng_ipaddr_t *dest)
 		return;
 		return;
 	}
 	}
 
 
-	Log(LOG_INFO, "Establishing connection for \"%s\" to \"%s\" (%s) port %d ... ",
-	    Conf_Server[Server].name, Conf_Server[Server].host, ip_str,
-	    Conf_Server[Server].port);
-
 	af_dest = ng_ipaddr_af(dest);
 	af_dest = ng_ipaddr_af(dest);
 	new_sock = socket(af_dest, SOCK_STREAM, 0);
 	new_sock = socket(af_dest, SOCK_STREAM, 0);
+
+	Log(LOG_INFO,
+	    "Establishing connection for \"%s\" to \"%s:%d\" (%s), socket %d ...",
+	    Conf_Server[Server].name, Conf_Server[Server].host,
+	    Conf_Server[Server].port, ip_str, new_sock);
+
 	if (new_sock < 0) {
 	if (new_sock < 0) {
-		Log( LOG_CRIT, "Can't create socket (af %d) : %s!", af_dest, strerror( errno ));
+		Log(LOG_CRIT, "Can't create socket (af %d): %s!",
+		    af_dest, strerror(errno));
 		return;
 		return;
 	}
 	}
 
 
@@ -1840,6 +1951,12 @@ New_Server( int Server , ng_ipaddr_t *dest)
 		return;
 		return;
 	}
 	}
 
 
+	if (!io_event_create( new_sock, IO_WANTWRITE, cb_connserver)) {
+		Log(LOG_ALERT, "io_event_create(): could not add fd %d", strerror(errno));
+		close(new_sock);
+		return;
+	}
+
 	My_Connections = array_start(&My_ConnArray);
 	My_Connections = array_start(&My_ConnArray);
 
 
 	assert(My_Connections[new_sock].sock <= 0);
 	assert(My_Connections[new_sock].sock <= 0);
@@ -1850,7 +1967,7 @@ New_Server( int Server , ng_ipaddr_t *dest)
 	c = Client_NewLocal(new_sock, ip_str, CLIENT_UNKNOWNSERVER, false);
 	c = Client_NewLocal(new_sock, ip_str, CLIENT_UNKNOWNSERVER, false);
 	if (!c) {
 	if (!c) {
 		Log( LOG_ALERT, "Can't establish connection: can't create client structure!" );
 		Log( LOG_ALERT, "Can't establish connection: can't create client structure!" );
-		close( new_sock );
+		io_close(new_sock);
 		return;
 		return;
 	}
 	}
 
 
@@ -1867,13 +1984,6 @@ New_Server( int Server , ng_ipaddr_t *dest)
 	strlcpy( My_Connections[new_sock].host, Conf_Server[Server].host,
 	strlcpy( My_Connections[new_sock].host, Conf_Server[Server].host,
 				sizeof(My_Connections[new_sock].host ));
 				sizeof(My_Connections[new_sock].host ));
 
 
-	/* Register new socket */
-	if (!io_event_create( new_sock, IO_WANTWRITE, cb_connserver)) {
-		Log( LOG_ALERT, "io_event_create(): could not add fd %d", strerror(errno));
-		Conn_Close( new_sock, "io_event_create() failed", NULL, false );
-		Init_Conn_Struct( new_sock );
-		Conf_Server[Server].conn_id = NONE;
-	}
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
 	if (Conf_Server[Server].SSLConnect && !ConnSSL_PrepareConnect( &My_Connections[new_sock],
 	if (Conf_Server[Server].SSLConnect && !ConnSSL_PrepareConnect( &My_Connections[new_sock],
 								&Conf_Server[Server] ))
 								&Conf_Server[Server] ))
@@ -1893,6 +2003,8 @@ New_Server( int Server , ng_ipaddr_t *dest)
 
 
 /**
 /**
  * Initialize connection structure.
  * Initialize connection structure.
+ *
+ * @param Idx	Connection index.
  */
  */
 static void
 static void
 Init_Conn_Struct(CONN_ID Idx)
 Init_Conn_Struct(CONN_ID Idx)
@@ -1908,11 +2020,18 @@ Init_Conn_Struct(CONN_ID Idx)
 } /* Init_Conn_Struct */
 } /* Init_Conn_Struct */
 
 
 
 
+/**
+ * Initialize options of a new socket.
+ *
+ * For example, we try to set socket options SO_REUSEADDR and IPTOS_LOWDELAY.
+ * The socket is automatically closed if a fatal error is encountered.
+ *
+ * @param Sock	Socket handle.
+ * @returns false if socket was closed due to fatal error.
+ */
 static bool
 static bool
 Init_Socket( int Sock )
 Init_Socket( int Sock )
 {
 {
-	/* Initialize socket (set options) */
-
 	int value;
 	int value;
 
 
 	if (!io_setnonblock(Sock)) {
 	if (!io_setnonblock(Sock)) {
@@ -1945,6 +2064,13 @@ Init_Socket( int Sock )
 } /* Init_Socket */
 } /* Init_Socket */
 
 
 
 
+/**
+ * Read results of a resolver sub-process and try to initiate a new server
+ * connection.
+ *
+ * @param fd		File descriptor of the pipe to the sub-process.
+ * @param events	(ignored IO specification)
+ */
 static void
 static void
 cb_Connect_to_Server(int fd, UNUSED short events)
 cb_Connect_to_Server(int fd, UNUSED short events)
 {
 {
@@ -1999,13 +2125,16 @@ cb_Connect_to_Server(int fd, UNUSED short events)
 } /* cb_Read_Forward_Lookup */
 } /* cb_Read_Forward_Lookup */
 
 
 
 
+/**
+ * Read results of a resolver sub-process from the pipe and update the
+ * apropriate connection/client structure(s): hostname and/or IDENT user name.
+ *
+ * @param r_fd		File descriptor of the pipe to the sub-process.
+ * @param events	(ignored IO specification)
+ */
 static void
 static void
 cb_Read_Resolver_Result( int r_fd, UNUSED short events )
 cb_Read_Resolver_Result( int r_fd, UNUSED short events )
 {
 {
-	/* Read result of resolver sub-process from pipe and update the
-	 * apropriate connection/client structure(s): hostname and/or
-	 * IDENT user name.*/
-
 	CLIENT *c;
 	CLIENT *c;
 	CONN_ID i;
 	CONN_ID i;
 	size_t len;
 	size_t len;
@@ -2057,13 +2186,22 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events )
 		strlcpy(My_Connections[i].host, readbuf,
 		strlcpy(My_Connections[i].host, readbuf,
 			sizeof(My_Connections[i].host));
 			sizeof(My_Connections[i].host));
 		Client_SetHostname(c, readbuf);
 		Client_SetHostname(c, readbuf);
+		if (Conf_NoticeAuth)
+			(void)Conn_WriteStr(i,
+					"NOTICE AUTH :*** Found your hostname");
 #ifdef IDENTAUTH
 #ifdef IDENTAUTH
 		++identptr;
 		++identptr;
 		if (*identptr) {
 		if (*identptr) {
 			Log(LOG_INFO, "IDENT lookup for connection %d: \"%s\".", i, identptr);
 			Log(LOG_INFO, "IDENT lookup for connection %d: \"%s\".", i, identptr);
 			Client_SetUser(c, identptr, true);
 			Client_SetUser(c, identptr, true);
+			if (Conf_NoticeAuth)
+				(void)Conn_WriteStr(i,
+					"NOTICE AUTH :*** Got ident response");
 		} else {
 		} else {
 			Log(LOG_INFO, "IDENT lookup for connection %d: no result.", i);
 			Log(LOG_INFO, "IDENT lookup for connection %d: no result.", i);
+			if (Conf_NoticeAuth && Conf_Ident)
+				(void)Conn_WriteStr(i,
+					"NOTICE AUTH :*** No ident response");
 		}
 		}
 #endif
 #endif
 	}
 	}
@@ -2075,9 +2213,14 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events )
 
 
 /**
 /**
  * Write a "simple" (error) message to a socket.
  * Write a "simple" (error) message to a socket.
+ *
  * The message is sent without using the connection write buffers, without
  * The message is sent without using the connection write buffers, without
  * compression/encryption, and even without any error reporting. It is
  * compression/encryption, and even without any error reporting. It is
- * designed for error messages of e.g. New_Connection(). */
+ * designed for error messages of e.g. New_Connection().
+ *
+ * @param Sock	Socket handle.
+ * @param Msg	Message string to send.
+ */
 static void
 static void
 Simple_Message(int Sock, const char *Msg)
 Simple_Message(int Sock, const char *Msg)
 {
 {
@@ -2106,8 +2249,9 @@ Simple_Message(int Sock, const char *Msg)
  * Get CLIENT structure that belongs to a local connection identified by its
  * Get CLIENT structure that belongs to a local connection identified by its
  * index number. Each connection belongs to a client by definition, so it is
  * index number. Each connection belongs to a client by definition, so it is
  * not required that the caller checks for NULL return values.
  * not required that the caller checks for NULL return values.
- * @param Idx Connection index number
- * @return Pointer to CLIENT structure
+ *
+ * @param Idx	Connection index number.
+ * @returns	Pointer to CLIENT structure.
  */
  */
 GLOBAL CLIENT *
 GLOBAL CLIENT *
 Conn_GetClient( CONN_ID Idx ) 
 Conn_GetClient( CONN_ID Idx ) 
@@ -2122,8 +2266,9 @@ Conn_GetClient( CONN_ID Idx )
 
 
 /**
 /**
  * Get PROC_STAT sub-process structure of a connection.
  * Get PROC_STAT sub-process structure of a connection.
- * @param Idx Connection index number
- * @return PROC_STAT structure
+ *
+ * @param Idx	Connection index number.
+ * @returns	PROC_STAT structure.
  */
  */
 GLOBAL PROC_STAT *
 GLOBAL PROC_STAT *
 Conn_GetProcStat(CONN_ID Idx)
 Conn_GetProcStat(CONN_ID Idx)
@@ -2139,8 +2284,9 @@ Conn_GetProcStat(CONN_ID Idx)
 
 
 /**
 /**
  * Get CONN_ID from file descriptor associated to a subprocess structure.
  * Get CONN_ID from file descriptor associated to a subprocess structure.
- * @param fd File descriptor
- * @return CONN_ID or NONE (-1)
+ *
+ * @param fd	File descriptor.
+ * @returns	CONN_ID or NONE (-1).
  */
  */
 GLOBAL CONN_ID
 GLOBAL CONN_ID
 Conn_GetFromProc(int fd)
 Conn_GetFromProc(int fd)
@@ -2157,14 +2303,34 @@ Conn_GetFromProc(int fd)
 } /* Conn_GetFromProc */
 } /* Conn_GetFromProc */
 
 
 
 
+#ifndef STRICT_RFC
+
+GLOBAL long
+Conn_GetAuthPing(CONN_ID Idx)
+{
+	assert (Idx != NONE);
+	return My_Connections[Idx].auth_ping;
+} /* Conn_GetAuthPing */
+
+GLOBAL void
+Conn_SetAuthPing(CONN_ID Idx, long ID)
+{
+	assert (Idx != NONE);
+	My_Connections[Idx].auth_ping = ID;
+} /* Conn_SetAuthPing */
+
+#endif
+
+
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
 
 
 /**
 /**
  * Get information about used SSL chiper.
  * Get information about used SSL chiper.
- * @param Idx Connection index number
- * @param buf Buffer for returned information text
- * @param len Size of return buffer "buf"
- * @return true on success, false otherwise
+ *
+ * @param Idx	Connection index number.
+ * @param buf	Buffer for returned information text.
+ * @param len	Size of return buffer "buf".
+ * @returns	true on success, false otherwise.
  */
  */
 GLOBAL bool
 GLOBAL bool
 Conn_GetCipherInfo(CONN_ID Idx, char *buf, size_t len)
 Conn_GetCipherInfo(CONN_ID Idx, char *buf, size_t len)
@@ -2178,8 +2344,9 @@ Conn_GetCipherInfo(CONN_ID Idx, char *buf, size_t len)
 
 
 /**
 /**
  * Check if a connection is SSL-enabled or not.
  * Check if a connection is SSL-enabled or not.
- * @param Idx Connection index number
- * @return true if connection is SSL-enabled, false otherwise.
+ *
+ * @param Idx	Connection index number.
+ * @return	true if connection is SSL-enabled, false otherwise.
  */
  */
 GLOBAL bool
 GLOBAL bool
 Conn_UsesSSL(CONN_ID Idx)
 Conn_UsesSSL(CONN_ID Idx)
@@ -2195,6 +2362,9 @@ Conn_UsesSSL(CONN_ID Idx)
 
 
 #ifdef DEBUG
 #ifdef DEBUG
 
 
+/**
+ * Dump internal state of the "connection module".
+ */
 GLOBAL void
 GLOBAL void
 Conn_DebugDump(void)
 Conn_DebugDump(void)
 {
 {

+ 12 - 4
src/ngircd/conn.h

@@ -7,14 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Connection management (header)
  */
  */
 
 
-
 #ifndef __conn_h__
 #ifndef __conn_h__
 #define __conn_h__
 #define __conn_h__
 
 
+/**
+ * @file
+ * Connection management (header)
+ */
 
 
 #include <time.h>			/* for time_t, see below */
 #include <time.h>			/* for time_t, see below */
 
 
@@ -90,6 +91,9 @@ typedef struct _Connection
 #ifdef SSL_SUPPORT
 #ifdef SSL_SUPPORT
 	struct ConnSSL_State ssl_state;	/* SSL/GNUTLS state information */
 	struct ConnSSL_State ssl_state;	/* SSL/GNUTLS state information */
 #endif
 #endif
+#ifndef STRICT_RFC
+	long auth_ping;			/** PING response expected on login */
+#endif
 } CONNECTION;
 } CONNECTION;
 
 
 GLOBAL CONNECTION *My_Connections;
 GLOBAL CONNECTION *My_Connections;
@@ -131,11 +135,15 @@ GLOBAL long Conn_Count PARAMS((void));
 GLOBAL long Conn_CountMax PARAMS((void));
 GLOBAL long Conn_CountMax PARAMS((void));
 GLOBAL long Conn_CountAccepted PARAMS((void));
 GLOBAL long Conn_CountAccepted PARAMS((void));
 
 
+#ifndef STRICT_RFC
+GLOBAL long Conn_GetAuthPing PARAMS((CONN_ID Idx));
+GLOBAL void Conn_SetAuthPing PARAMS((CONN_ID Idx, long ID));
+#endif
+
 #ifdef DEBUG
 #ifdef DEBUG
 GLOBAL void Conn_DebugDump PARAMS((void));
 GLOBAL void Conn_DebugDump PARAMS((void));
 #endif
 #endif
 
 
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 6 - 10
src/ngircd/defines.h

@@ -9,7 +9,6 @@
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
  */
  */
 
 
-
 #ifndef __defines_h__
 #ifndef __defines_h__
 #define __defines_h__
 #define __defines_h__
 
 
@@ -59,9 +58,12 @@
 
 
 #define READBUFFER_LEN 2048		/* Size of the read buffer of a
 #define READBUFFER_LEN 2048		/* Size of the read buffer of a
 					   connection in bytes. */
 					   connection in bytes. */
-#define WRITEBUFFER_LEN 4096		/* Size of the write buffer of a
+#define WRITEBUFFER_FLUSH_LEN 4096	/* Size of a write buffer that triggers
+					   buffer flushing if more space is
+					   needed for storing data. */
+#define WRITEBUFFER_MAX_LEN 32768	/* Maximum size of the write buffer of a
 					   connection in bytes. */
 					   connection in bytes. */
-#define WRITEBUFFER_SLINK_LEN 51200	/* Size of the write buffer of a
+#define WRITEBUFFER_SLINK_LEN 65536	/* Maximum size of the write buffer of a
 					   server link connection in bytes. */
 					   server link connection in bytes. */
 
 
 #define PROTOVER "0210"			/* Implemented IRC protocol version,
 #define PROTOVER "0210"			/* Implemented IRC protocol version,
@@ -81,7 +83,7 @@
 					   in seconds. */
 					   in seconds. */
 
 
 #define USERMODES "aciorswx"		/* Supported user modes. */
 #define USERMODES "aciorswx"		/* Supported user modes. */
-#define CHANMODES "biIklmnoPstvz"	/* Supported channel modes. */
+#define CHANMODES "biIklmnoOPstvz"	/* Supported channel modes. */
 
 
 #define CONNECTED true			/* Internal status codes. */
 #define CONNECTED true			/* Internal status codes. */
 #define DISCONNECTED false
 #define DISCONNECTED false
@@ -108,12 +110,6 @@
 #define CUT_TXTSUFFIX "[CUT]"		/* Suffix for oversized messages that
 #define CUT_TXTSUFFIX "[CUT]"		/* Suffix for oversized messages that
 					   have been shortened and cut off. */
 					   have been shortened and cut off. */
 
 
-#ifdef ZEROCONF
-#define MDNS_TYPE "_ircu._tcp."		/* Service type to register with mDNS */
 #endif
 #endif
 
 
-
-#endif
-
-
 /* -eof- */
 /* -eof- */

+ 54 - 49
src/ngircd/hash.c

@@ -1,20 +1,20 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2009 Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Hash calculation
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
-static char UNUSED id[] = "$Id: hash.c,v 1.13 2006/10/06 21:23:47 fw Exp $";
+/**
+ * @file
+ * Hash calculation
+ */
 
 
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
@@ -26,15 +26,17 @@ static char UNUSED id[] = "$Id: hash.c,v 1.13 2006/10/06 21:23:47 fw Exp $";
 #include "exp.h"
 #include "exp.h"
 #include "hash.h"
 #include "hash.h"
 
 
+static UINT32 jenkins_hash PARAMS((UINT8 *k, UINT32 length, UINT32 initval));
 
 
-static UINT32 jenkins_hash PARAMS(( register UINT8 *k, register UINT32 length, register UINT32 initval ));
-
-
+/**
+ * Calculate hash value for a given string.
+ *
+ * @param String Input string
+ * @return 32 bit hash value
+ */
 GLOBAL UINT32
 GLOBAL UINT32
 Hash( const char *String )
 Hash( const char *String )
 {
 {
-	/* Hash-Wert ueber String berechnen */
-
 	char buffer[LINE_LEN];
 	char buffer[LINE_LEN];
 
 
 	strlcpy(buffer, String, sizeof(buffer));
 	strlcpy(buffer, String, sizeof(buffer));
@@ -42,70 +44,75 @@ Hash( const char *String )
 			    (UINT32)strlen(buffer), 42);
 			    (UINT32)strlen(buffer), 42);
 } /* Hash */
 } /* Hash */
 
 
-
 /*
 /*
- * Die hier verwendete Hash-Funktion stammt aus lookup2.c von Bob Jenkins
- * (URL: <http://burtleburtle.net/bob/c/lookup2.c>). Aus dem Header:
+ * This hash function originates from lookup3.c of Bob Jenkins
+ * (URL: <http://burtleburtle.net/bob/c/lookup3.c>):
  * --------------------------------------------------------------------
  * --------------------------------------------------------------------
- * lookup2.c, by Bob Jenkins, December 1996, Public Domain.
- * hash(), hash2(), hash3, and mix() are externally useful functions.
- * Routines to test the hash are included if SELF_TEST is defined.
- * You can use this free for any purpose.  It has no warranty.
+ * lookup3.c, by Bob Jenkins, May 2006, Public Domain.
+ * These are functions for producing 32-bit hashes for hash table lookup.
+ * hashword(), hashlittle(), hashlittle2(), hashbig(), mix(), and final()
+ * are externally useful functions.  Routines to test the hash are included
+ * if SELF_TEST is defined.  You can use this free for any purpose.  It's in
+ * the public domain.  It has no warranty.
  * --------------------------------------------------------------------
  * --------------------------------------------------------------------
- * nicht alle seiner Funktionen werden hier genutzt.
+ * Not all of his functions are used here.
  */
  */
 
 
-
 #define hashsize(n) ((UINT32)1<<(n))
 #define hashsize(n) ((UINT32)1<<(n))
 #define hashmask(n) (hashsize(n)-1)
 #define hashmask(n) (hashsize(n)-1)
+#define rot(x,k) (((x)<<(k)) | ((x)>>(32-(k))))
 
 
 #define mix(a,b,c) \
 #define mix(a,b,c) \
 { \
 { \
-	a -= b; a -= c; a ^= (c>>13); \
-	b -= c; b -= a; b ^= (a<<8);  \
-	c -= a; c -= b; c ^= (b>>13); \
-	a -= b; a -= c; a ^= (c>>12); \
-	b -= c; b -= a; b ^= (a<<16); \
-	c -= a; c -= b; c ^= (b>>5);  \
-	a -= b; a -= c; a ^= (c>>3);  \
-	b -= c; b -= a; b ^= (a<<10); \
-	c -= a; c -= b; c ^= (b>>15); \
+	a -= c;  a ^= rot(c, 4);  c += b; \
+	b -= a;  b ^= rot(a, 6);  a += c; \
+	c -= b;  c ^= rot(b, 8);  b += a; \
+	a -= c;  a ^= rot(c,16);  c += b; \
+	b -= a;  b ^= rot(a,19);  a += c; \
+	c -= b;  c ^= rot(b, 4);  b += a; \
 } /* mix */
 } /* mix */
 
 
+#define final(a,b,c) \
+{ \
+	c ^= b; c -= rot(b,14); \
+	a ^= c; a -= rot(c,11); \
+	b ^= a; b -= rot(a,25); \
+	c ^= b; c -= rot(b,16); \
+	a ^= c; a -= rot(c,4);  \
+	b ^= a; b -= rot(a,14); \
+	c ^= b; c -= rot(b,24); \
+}
 
 
 static UINT32
 static UINT32
-jenkins_hash( register UINT8 *k, register UINT32 length, register UINT32 initval )
+jenkins_hash(UINT8 *k, UINT32 length, UINT32 initval)
 {
 {
 	/* k: the key
 	/* k: the key
 	 * length: length of the key
 	 * length: length of the key
 	 * initval: the previous hash, or an arbitrary value
 	 * initval: the previous hash, or an arbitrary value
 	 */
 	 */
-
-	register UINT32 a,b,c,len;
+	UINT32 a,b,c;
 
 
 	/* Set up the internal state */
 	/* Set up the internal state */
-	len = length;
-	a = b = 0x9e3779b9;	/* the golden ratio; an arbitrary value */
-	c = initval;		/* the previous hash value */
+	a = b = c = 0xdeadbeef + length + initval;
 
 
 	/* handle most of the key */
 	/* handle most of the key */
-	while (len >= 12)
-	{
+	while (length > 12) {
 		a += (k[0] +((UINT32)k[1]<<8) +((UINT32)k[2]<<16) +((UINT32)k[3]<<24));
 		a += (k[0] +((UINT32)k[1]<<8) +((UINT32)k[2]<<16) +((UINT32)k[3]<<24));
 		b += (k[4] +((UINT32)k[5]<<8) +((UINT32)k[6]<<16) +((UINT32)k[7]<<24));
 		b += (k[4] +((UINT32)k[5]<<8) +((UINT32)k[6]<<16) +((UINT32)k[7]<<24));
 		c += (k[8] +((UINT32)k[9]<<8) +((UINT32)k[10]<<16)+((UINT32)k[11]<<24));
 		c += (k[8] +((UINT32)k[9]<<8) +((UINT32)k[10]<<16)+((UINT32)k[11]<<24));
 		mix(a,b,c);
 		mix(a,b,c);
-		k += 12; len -= 12;
+		length -= 12;
+		k += 12;
 	}
 	}
 
 
-	/* handle the last 11 bytes */
-	c += length;
-	switch( (int)len )	/* all the case statements fall through */
+	/*-------------------------------- last block: affect all 32 bits of (c) */
+	switch(length)                   /* all the case statements fall through */
+
 	{
 	{
-		case 11: c+=((UINT32)k[10]<<24);
-		case 10: c+=((UINT32)k[9]<<16);
-		case 9 : c+=((UINT32)k[8]<<8);
-		/* the first byte of c is reserved for the length */
+		case 12: c+=((UINT32)k[11])<<24;
+		case 11: c+=((UINT32)k[10]<<16);
+		case 10: c+=((UINT32)k[9]<<8);
+		case 9 : c+=k[8];
 		case 8 : b+=((UINT32)k[7]<<24);
 		case 8 : b+=((UINT32)k[7]<<24);
 		case 7 : b+=((UINT32)k[6]<<16);
 		case 7 : b+=((UINT32)k[6]<<16);
 		case 6 : b+=((UINT32)k[5]<<8);
 		case 6 : b+=((UINT32)k[5]<<8);
@@ -114,13 +121,11 @@ jenkins_hash( register UINT8 *k, register UINT32 length, register UINT32 initval
 		case 3 : a+=((UINT32)k[2]<<16);
 		case 3 : a+=((UINT32)k[2]<<16);
 		case 2 : a+=((UINT32)k[1]<<8);
 		case 2 : a+=((UINT32)k[1]<<8);
 		case 1 : a+=k[0];
 		case 1 : a+=k[0];
-		/* case 0: nothing left to add */
+			 break;
+		case 0 : return c;
 	}
 	}
-	mix(a,b,c);
-
-	/* report the result */
+	final(a,b,c);
 	return c;
 	return c;
 } /* jenkins_hash */
 } /* jenkins_hash */
 
 
-
 /* -eof- */
 /* -eof- */

+ 5 - 7
src/ngircd/hash.h

@@ -7,20 +7,18 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: hash.h,v 1.6 2006/10/06 21:23:47 fw Exp $
- *
- * Hash calculation (header)
  */
  */
 
 
-
 #ifndef __hash_h__
 #ifndef __hash_h__
 #define __hash_h__
 #define __hash_h__
 
 
-GLOBAL UINT32 Hash PARAMS((const char *String ));
+/**
+ * @file
+ * Hash calculation (header)
+ */
 
 
+GLOBAL UINT32 Hash PARAMS((const char *String ));
 
 
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 4 - 3
src/ngircd/io.c

@@ -5,14 +5,15 @@
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
  *
  *
- * I/O abstraction interface.
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
  * Copyright (c) 2005 Florian Westphal (westphal@foo.fh-furtwangen.de)
- *
  */
  */
 
 
 #include "portab.h"
 #include "portab.h"
 
 
-static char UNUSED id[] = "$Id: io.c,v 1.31 2008/04/03 20:56:44 fw Exp $";
+/**
+ * @file
+ * I/O abstraction interface.
+ */
 
 
 #include <assert.h>
 #include <assert.h>
 #include <stdlib.h>
 #include <stdlib.h>

+ 5 - 4
src/ngircd/io.h

@@ -4,15 +4,16 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * I/O abstraction interface header
- *
- * $Id: io.h,v 1.4 2006/12/25 22:53:52 alex Exp $
  */
  */
 
 
 #ifndef io_H_included
 #ifndef io_H_included
 #define io_H_included
 #define io_H_included
 
 
+/**
+ * @file
+ * I/O abstraction interface (header)
+ */
+
 #include "portab.h"
 #include "portab.h"
 #include <sys/time.h>
 #include <sys/time.h>
 
 

+ 163 - 43
src/ngircd/irc-channel.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * IRC channel commands
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * IRC channel commands
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdlib.h>
 #include <stdlib.h>
@@ -37,13 +39,18 @@
 #include "irc-channel.h"
 #include "irc-channel.h"
 
 
 
 
-/*
+/**
+ * Part from all channels.
+ *
  * RFC 2812, (3.2.1 Join message Command):
  * RFC 2812, (3.2.1 Join message Command):
- *  Note that this message
- *  accepts a special argument ("0"), which is a special request to leave all
- *  channels the user is currently a member of. The server will process this
- *  message as if the user had sent a PART command (See Section 3.2.2) for
- *  each channel he is a member of.
+ *  Note that this message accepts a special argument ("0"), which is a
+ *  special request to leave all channels the user is currently a member of.
+ *  The server will process this message as if the user had sent a PART
+ *  command (See Section 3.2.2) for each channel he is a member of.
+ *
+ * @param client	Client that initiated the part request
+ * @param target	Client that should part all joined channels
+ * @returns		CONNECTED or DISCONNECTED
  */
  */
 static bool
 static bool
 part_from_all_channels(CLIENT* client, CLIENT *target)
 part_from_all_channels(CLIENT* client, CLIENT *target)
@@ -57,17 +64,18 @@ part_from_all_channels(CLIENT* client, CLIENT *target)
 		Channel_Part(target, client, Channel_Name(chan), Client_ID(target));
 		Channel_Part(target, client, Channel_Name(chan), Client_ID(target));
 	}
 	}
 	return CONNECTED;
 	return CONNECTED;
-}
+} /* part_from_all_channels */
 
 
 
 
 /**
 /**
  * Check weather a local client is allowed to join an already existing
  * Check weather a local client is allowed to join an already existing
  * channel or not.
  * channel or not.
- * @param Client Client that sent the JOIN command
- * @param chan Channel to check
- * @param channame Name of the channel
- * @param key Provided channel key (or NULL if none has been provided)
- * @return true if client is allowed to join channel, false otherwise
+ *
+ * @param Client	Client that sent the JOIN command
+ * @param chan		Channel to check
+ * @param channame	Name of the channel
+ * @param key		Provided channel key (or NULL)
+ * @returns		true if client is allowed to join, false otherwise
  */
  */
 static bool
 static bool
 join_allowed(CLIENT *Client, CHANNEL *chan, const char *channame,
 join_allowed(CLIENT *Client, CHANNEL *chan, const char *channame,
@@ -122,10 +130,24 @@ join_allowed(CLIENT *Client, CHANNEL *chan, const char *channame,
 		return false;
 		return false;
 	}
 	}
 
 
+	if (strchr(channel_modes, 'O') && !Client_OperByMe(Client)) {
+		/* Only IRC operators are allowed! */
+		IRC_WriteStrClient(Client, ERR_OPONLYCHANNEL_MSG,
+				   Client_ID(Client), channame);
+		return false;
+	}
+
 	return true;
 	return true;
-}
+} /* join_allowed */
 
 
 
 
+/**
+ * Set user channel modes.
+ *
+ * @param chan		Channel
+ * @param target	User to set modes for
+ * @param flags		Channel modes to add
+ */
 static void
 static void
 join_set_channelmodes(CHANNEL *chan, CLIENT *target, const char *flags)
 join_set_channelmodes(CHANNEL *chan, CLIENT *target, const char *flags)
 {
 {
@@ -139,9 +161,22 @@ join_set_channelmodes(CHANNEL *chan, CLIENT *target, const char *flags)
 	/* If channel persistent and client is ircop: make client chanop */
 	/* If channel persistent and client is ircop: make client chanop */
 	if (strchr(Channel_Modes(chan), 'P') && strchr(Client_Modes(target), 'o'))
 	if (strchr(Channel_Modes(chan), 'P') && strchr(Client_Modes(target), 'o'))
 		Channel_UserModeAdd(chan, target, 'o');
 		Channel_UserModeAdd(chan, target, 'o');
-}
+} /* join_set_channelmodes */
 
 
 
 
+/**
+ * Forward JOIN command to a specific server
+ *
+ * This function diffentiates between servers using RFC 2813 mode that
+ * support the JOIN command with appended ASCII 7 character and channel
+ * modes, and servers using RFC 1459 protocol which require separate JOIN
+ * and MODE commands.
+ *
+ * @param To		Forward JOIN (and MODE) command to this peer server
+ * @param Prefix	Client used to prefix the genrated commands
+ * @param Data		Parameters of JOIN command to forward, probably
+ *			containing channel modes separated by ASCII 7.
+ */
 static void
 static void
 cb_join_forward(CLIENT *To, CLIENT *Prefix, void *Data)
 cb_join_forward(CLIENT *To, CLIENT *Prefix, void *Data)
 {
 {
@@ -166,12 +201,25 @@ cb_join_forward(CLIENT *To, CLIENT *Prefix, void *Data)
 } /* cb_join_forward */
 } /* cb_join_forward */
 
 
 
 
+/**
+ * Forward JOIN command to all servers
+ *
+ * This function calls cb_join_forward(), which differentiates between
+ * protocol implementations (e.g. RFC 2812, RFC 1459).
+ *
+ * @param Client	Client used to prefix the genrated commands
+ * @param target	Forward JOIN (and MODE) command to this peer server
+ * @param chan		Channel structure
+ * @param channame	Channel name
+ */
 static void
 static void
 join_forward(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 join_forward(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 					const char *channame)
 					const char *channame)
 {
 {
 	char modes[CHANNEL_MODE_LEN], str[COMMAND_LEN];
 	char modes[CHANNEL_MODE_LEN], str[COMMAND_LEN];
 
 
+	/* RFC 2813, 4.2.1: channel modes are separated from the channel
+	 * name with ASCII 7, if any, and not spaces: */
 	strlcpy(&modes[1], Channel_UserModes(chan, target), sizeof(modes) - 1);
 	strlcpy(&modes[1], Channel_UserModes(chan, target), sizeof(modes) - 1);
 	if (modes[1])
 	if (modes[1])
 		modes[0] = 0x7;
 		modes[0] = 0x7;
@@ -198,6 +246,14 @@ join_forward(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 } /* join_forward */
 } /* join_forward */
 
 
 
 
+/**
+ * Aknowledge user JOIN request and send "channel info" numerics.
+ *
+ * @param Client	Client used to prefix the genrated commands
+ * @param target	Forward commands/numerics to this user
+ * @param chan		Channel structure
+ * @param channame	Channel name
+ */
 static bool
 static bool
 join_send_topic(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 join_send_topic(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 					const char *channame)
 					const char *channame)
@@ -228,10 +284,20 @@ join_send_topic(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 	/* send list of channel members to client */
 	/* send list of channel members to client */
 	if (!IRC_Send_NAMES(Client, chan))
 	if (!IRC_Send_NAMES(Client, chan))
 		return false;
 		return false;
-	return IRC_WriteStrClient(Client, RPL_ENDOFNAMES_MSG, Client_ID(Client), Channel_Name(chan));
-}
+	return IRC_WriteStrClient(Client, RPL_ENDOFNAMES_MSG, Client_ID(Client),
+				  Channel_Name(chan));
+} /* join_send_topic */
 
 
 
 
+/**
+ * Handler for the IRC "JOIN" command.
+ *
+ * See RFC 2812, 3.2.1 "Join message"; RFC 2813, 4.2.1 "Join message".
+ *
+ * @param Client	The client from which this command has been received
+ * @param Req		Request structure with prefix and all parameters
+ * @returns		CONNECTED or DISCONNECTED
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_JOIN( CLIENT *Client, REQUEST *Req )
 IRC_JOIN( CLIENT *Client, REQUEST *Req )
 {
 {
@@ -356,6 +422,12 @@ IRC_JOIN( CLIENT *Client, REQUEST *Req )
 
 
 /**
 /**
  * Handler for the IRC "PART" command.
  * Handler for the IRC "PART" command.
+ *
+ * See RFC 2812, 3.2.2: "Part message".
+ *
+ * @param Client	The client from which this command has been received
+ * @param Req		Request structure with prefix and all parameters
+ * @returns		CONNECTED or DISCONNECTED
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_PART(CLIENT * Client, REQUEST * Req)
 IRC_PART(CLIENT * Client, REQUEST * Req)
@@ -401,55 +473,81 @@ IRC_PART(CLIENT * Client, REQUEST * Req)
 } /* IRC_PART */
 } /* IRC_PART */
 
 
 
 
+/**
+ * Handler for the IRC "TOPIC" command.
+ *
+ * See RFC 2812, 3.2.4 "Topic message".
+ *
+ * @param Client	The client from which this command has been received
+ * @param Req		Request structure with prefix and all parameters
+ * @returns		CONNECTED or DISCONNECTED
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_TOPIC( CLIENT *Client, REQUEST *Req )
 IRC_TOPIC( CLIENT *Client, REQUEST *Req )
 {
 {
 	CHANNEL *chan;
 	CHANNEL *chan;
 	CLIENT *from;
 	CLIENT *from;
 	char *topic;
 	char *topic;
-	bool r;
+	bool onchannel, topicok, use_servermode, r;
 
 
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( Req != NULL );
 	assert( Req != NULL );
 
 
-	if ((Req->argc < 1) || (Req->argc > 2))
-		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG, Client_ID(Client), Req->command);
+	if (Req->argc < 1 || Req->argc > 2)
+		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
+					  Client_ID(Client), Req->command);
 
 
-	if( Client_Type( Client ) == CLIENT_SERVER ) from = Client_Search( Req->prefix );
-	else from = Client;
-	if( ! from ) return IRC_WriteStrClient( Client, ERR_NOSUCHNICK_MSG, Client_ID( Client ), Req->prefix );
+	if (Client_Type(Client) == CLIENT_SERVER)
+		from = Client_Search(Req->prefix);
+	else
+		from = Client;
 
 
-	/* Welcher Channel? */
-	chan = Channel_Search( Req->argv[0] );
-	if( ! chan ) return IRC_WriteStrClient( from, ERR_NOSUCHCHANNEL_MSG, Client_ID( from ), Req->argv[0] );
+	if (!from)
+		return IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
+					  Client_ID(Client), Req->prefix);
 
 
-	/* Ist der User Mitglied in dem Channel? */
-	if( ! Channel_IsMemberOf( chan, from )) return IRC_WriteStrClient( from, ERR_NOTONCHANNEL_MSG, Client_ID( from ), Req->argv[0] );
+	chan = Channel_Search(Req->argv[0]);
+	if (!chan)
+		return IRC_WriteStrClient(from, ERR_NOSUCHCHANNEL_MSG,
+					  Client_ID(from), Req->argv[0]);
 
 
-	if( Req->argc == 1 )
-	{
+	Channel_CheckAdminRights(chan, Client, from,
+				 &onchannel, &topicok, &use_servermode);
+
+	if (!onchannel && !topicok)
+		return IRC_WriteStrClient(from, ERR_NOTONCHANNEL_MSG,
+					  Client_ID(from), Req->argv[0]);
+
+	if (Req->argc == 1) {
 		/* Request actual topic */
 		/* Request actual topic */
 		topic = Channel_Topic(chan);
 		topic = Channel_Topic(chan);
 		if (*topic) {
 		if (*topic) {
 			r = IRC_WriteStrClient(from, RPL_TOPIC_MSG,
 			r = IRC_WriteStrClient(from, RPL_TOPIC_MSG,
-				Client_ID(Client), Channel_Name(chan), topic);
+					       Client_ID(Client),
+					       Channel_Name(chan), topic);
 #ifndef STRICT_RFC
 #ifndef STRICT_RFC
+			if (!r)
+				return r;
 			r = IRC_WriteStrClient(from, RPL_TOPICSETBY_MSG,
 			r = IRC_WriteStrClient(from, RPL_TOPICSETBY_MSG,
-				Client_ID(Client), Channel_Name(chan),
-				Channel_TopicWho(chan),
-				Channel_TopicTime(chan));
+					       Client_ID(Client),
+					       Channel_Name(chan),
+					       Channel_TopicWho(chan),
+					       Channel_TopicTime(chan));
 #endif
 #endif
 			return r;
 			return r;
 		}
 		}
 		else
 		else
-			 return IRC_WriteStrClient(from, RPL_NOTOPIC_MSG,
-					Client_ID(from), Channel_Name(chan));
+			return IRC_WriteStrClient(from, RPL_NOTOPIC_MSG,
+						  Client_ID(from),
+						  Channel_Name(chan));
 	}
 	}
 
 
-	if( strchr( Channel_Modes( chan ), 't' ))
-	{
-		/* Topic Lock. Ist der User ein Channel Operator? */
-		if( ! strchr( Channel_UserModes( chan, from ), 'o' )) return IRC_WriteStrClient( from, ERR_CHANOPRIVSNEEDED_MSG, Client_ID( from ), Channel_Name( chan ));
+	if (strchr(Channel_Modes(chan), 't')) {
+		/* Topic Lock. Is the user a channel or IRC operator? */
+		if (!topicok)
+			return IRC_WriteStrClient(from, ERR_CHANOPRIVSNEEDED_MSG,
+						  Client_ID(from),
+						  Channel_Name(chan));
 	}
 	}
 
 
 	/* Set new topic */
 	/* Set new topic */
@@ -458,6 +556,9 @@ IRC_TOPIC( CLIENT *Client, REQUEST *Req )
 		 Client_TypeText(from), Client_Mask(from), Channel_Name(chan),
 		 Client_TypeText(from), Client_Mask(from), Channel_Name(chan),
 		 Req->argv[1][0] ? Req->argv[1] : "<none>");
 		 Req->argv[1][0] ? Req->argv[1] : "<none>");
 
 
+	if (use_servermode)
+		from = Client_ThisServer();
+
 	/* Update channel and forward new topic to other servers */
 	/* Update channel and forward new topic to other servers */
 	if (!Channel_IsLocal(chan))
 	if (!Channel_IsLocal(chan))
 		IRC_WriteStrServersPrefix(Client, from, "TOPIC %s :%s",
 		IRC_WriteStrServersPrefix(Client, from, "TOPIC %s :%s",
@@ -475,8 +576,15 @@ IRC_TOPIC( CLIENT *Client, REQUEST *Req )
 
 
 /**
 /**
  * Handler for the IRC "LIST" command.
  * Handler for the IRC "LIST" command.
+ *
+ * See RFC 2812, 3.2.6 "List message".
+ *
  * This implementation handles the local case as well as the forwarding of the
  * This implementation handles the local case as well as the forwarding of the
  * LIST command to other servers in the IRC network.
  * LIST command to other servers in the IRC network.
+ *
+ * @param Client	The client from which this command has been received
+ * @param Req		Request structure with prefix and all parameters
+ * @returns		CONNECTED or DISCONNECTED
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_LIST( CLIENT *Client, REQUEST *Req )
 IRC_LIST( CLIENT *Client, REQUEST *Req )
@@ -560,6 +668,16 @@ IRC_LIST( CLIENT *Client, REQUEST *Req )
 } /* IRC_LIST */
 } /* IRC_LIST */
 
 
 
 
+/**
+ * Handler for the IRC+ command "CHANINFO".
+ *
+ * See doc/Protocol.txt, section II.3:
+ * "Exchange channel-modes, topics, and persistent channels".
+ *
+ * @param Client	The client from which this command has been received
+ * @param Req		Request structure with prefix and all parameters
+ * @returns		CONNECTED or DISCONNECTED
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_CHANINFO( CLIENT *Client, REQUEST *Req )
 IRC_CHANINFO( CLIENT *Client, REQUEST *Req )
 {
 {
@@ -572,7 +690,9 @@ IRC_CHANINFO( CLIENT *Client, REQUEST *Req )
 	assert( Req != NULL );
 	assert( Req != NULL );
 
 
 	/* Bad number of parameters? */
 	/* Bad number of parameters? */
-	if(( Req->argc < 2 ) || ( Req->argc == 4 ) || ( Req->argc > 5 )) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command );
+	if (Req->argc < 2 || Req->argc == 4 || Req->argc > 5)
+		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
+					  Client_ID(Client), Req->command);
 
 
 	/* Compatibility kludge */
 	/* Compatibility kludge */
 	if( Req->argc == 5 ) arg_topic = 4;
 	if( Req->argc == 5 ) arg_topic = 4;

+ 4 - 7
src/ngircd/irc-channel.h

@@ -7,16 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-channel.h,v 1.7 2005/03/19 18:43:48 fw Exp $
- *
- * IRC channel commands (header)
  */
  */
 
 
-
 #ifndef __irc_channel_h__
 #ifndef __irc_channel_h__
 #define __irc_channel_h__
 #define __irc_channel_h__
 
 
+/**
+ * @file
+ * IRC channel commands (header)
+ */
 
 
 GLOBAL bool IRC_JOIN PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_JOIN PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_PART PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_PART PARAMS((CLIENT *Client, REQUEST *Req ));
@@ -26,8 +25,6 @@ GLOBAL bool IRC_LIST PARAMS((CLIENT *Client, REQUEST *Req ));
 
 
 GLOBAL bool IRC_CHANINFO PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_CHANINFO PARAMS((CLIENT *Client, REQUEST *Req ));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 180 - 74
src/ngircd/irc-info.c

@@ -1,19 +1,21 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2010 Alexander Barton <alex@barton.de>
+ * Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * IRC info commands
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * IRC info commands
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <errno.h>
 #include <errno.h>
@@ -914,42 +916,21 @@ IRC_WHO( CLIENT *Client, REQUEST *Req )
 } /* IRC_WHO */
 } /* IRC_WHO */
 
 
 
 
-GLOBAL bool
-IRC_WHOIS( CLIENT *Client, REQUEST *Req )
+/**
+ * Generate WHOIS reply of one actual client.
+ *
+ * @param Client	The client from which this command has been received.
+ * @param from		The client requesting the information ("originator").
+ * @param c		The client of which information should be returned.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
+static bool
+IRC_WHOIS_SendReply(CLIENT *Client, CLIENT *from, CLIENT *c)
 {
 {
-	CLIENT *from, *target, *c;
 	char str[LINE_LEN + 1];
 	char str[LINE_LEN + 1];
 	CL2CHAN *cl2chan;
 	CL2CHAN *cl2chan;
 	CHANNEL *chan;
 	CHANNEL *chan;
 
 
-	assert( Client != NULL );
-	assert( Req != NULL );
-
-	/* Bad number of parameters? */
-	if(( Req->argc < 1 ) || ( Req->argc > 2 )) return IRC_WriteStrClient( Client, ERR_NEEDMOREPARAMS_MSG, Client_ID( Client ), Req->command );
-
-	/* Search client */
-	c = Client_Search( Req->argv[Req->argc - 1] );
-	if(( ! c ) || ( Client_Type( c ) != CLIENT_USER )) return IRC_WriteStrClient( Client, ERR_NOSUCHNICK_MSG, Client_ID( Client ), Req->argv[Req->argc - 1] );
-
-	/* Search sender of the WHOIS */
-	if( Client_Type( Client ) == CLIENT_SERVER ) from = Client_Search( Req->prefix );
-	else from = Client;
-	if( ! from ) return IRC_WriteStrClient( Client, ERR_NOSUCHNICK_MSG, Client_ID( Client ), Req->prefix );
-
-	/* Forward to other server? */
-	if( Req->argc > 1 )
-	{
-		/* Search target server (can be specified as nick of that server!) */
-		target = Client_Search( Req->argv[0] );
-		if( ! target ) return IRC_WriteStrClient( from, ERR_NOSUCHSERVER_MSG, Client_ID( from ), Req->argv[0] );
-	}
-	else target = Client_ThisServer( );
-
-	assert( target != NULL );
-
-	if(( Client_NextHop( target ) != Client_ThisServer( )) && ( Client_Type( Client_NextHop( target )) == CLIENT_SERVER )) return IRC_WriteStrClientPrefix( target, from, "WHOIS %s :%s", Req->argv[0], Req->argv[1] );
-
 	/* Nick, user, hostname and client info */
 	/* Nick, user, hostname and client info */
 	if (!IRC_WriteStrClient(from, RPL_WHOISUSER_MSG, Client_ID(from),
 	if (!IRC_WriteStrClient(from, RPL_WHOISUSER_MSG, Client_ID(from),
 				Client_ID(c), Client_User(c),
 				Client_ID(c), Client_User(c),
@@ -957,18 +938,21 @@ IRC_WHOIS( CLIENT *Client, REQUEST *Req )
 		return DISCONNECTED;
 		return DISCONNECTED;
 
 
 	/* Server */
 	/* Server */
-	if( ! IRC_WriteStrClient( from, RPL_WHOISSERVER_MSG, Client_ID( from ), Client_ID( c ), Client_ID( Client_Introducer( c )), Client_Info( Client_Introducer( c )))) return DISCONNECTED;
+	if (!IRC_WriteStrClient(from, RPL_WHOISSERVER_MSG, Client_ID(from),
+				Client_ID(c), Client_ID(Client_Introducer(c)),
+				Client_Info(Client_Introducer(c))))
+		return DISCONNECTED;
 
 
 	/* Channels */
 	/* Channels */
-	snprintf( str, sizeof( str ), RPL_WHOISCHANNELS_MSG, Client_ID( from ), Client_ID( c ));
-	cl2chan = Channel_FirstChannelOf( c );
-	while( cl2chan )
-	{
-		chan = Channel_GetChannel( cl2chan );
-		assert( chan != NULL );
+	snprintf(str, sizeof(str), RPL_WHOISCHANNELS_MSG,
+		 Client_ID(from), Client_ID(c));
+	cl2chan = Channel_FirstChannelOf(c);
+	while (cl2chan) {
+		chan = Channel_GetChannel(cl2chan);
+		assert(chan != NULL);
 
 
 		/* next */
 		/* next */
-		cl2chan = Channel_NextChannelOf( c, cl2chan );
+		cl2chan = Channel_NextChannelOf(c, cl2chan);
 
 
 		/* Secret channel? */
 		/* Secret channel? */
 		if (strchr(Channel_Modes(chan), 's')
 		if (strchr(Channel_Modes(chan), 's')
@@ -981,54 +965,168 @@ IRC_WHOIS( CLIENT *Client, REQUEST *Req )
 			continue;
 			continue;
 
 
 		/* Concatenate channel names */
 		/* Concatenate channel names */
-		if( str[strlen( str ) - 1] != ':' ) strlcat( str, " ", sizeof( str ));
-		if( strchr( Channel_UserModes( chan, c ), 'o' )) strlcat( str, "@", sizeof( str ));
-		else if( strchr( Channel_UserModes( chan, c ), 'v' )) strlcat( str, "+", sizeof( str ));
-		strlcat( str, Channel_Name( chan ), sizeof( str ));
+		if (str[strlen(str) - 1] != ':')
+			strlcat(str, " ", sizeof(str));
 
 
-		if( strlen( str ) > ( LINE_LEN - CHANNEL_NAME_LEN - 4 ))
-		{
+		strlcat(str, who_flags_qualifier(Channel_UserModes(chan, c)),
+						 sizeof(str));
+		strlcat(str, Channel_Name(chan), sizeof(str));
+
+		if (strlen(str) > (LINE_LEN - CHANNEL_NAME_LEN - 4)) {
 			/* Line becomes too long: send it! */
 			/* Line becomes too long: send it! */
-			if( ! IRC_WriteStrClient( Client, "%s", str )) return DISCONNECTED;
-			snprintf( str, sizeof( str ), RPL_WHOISCHANNELS_MSG, Client_ID( from ), Client_ID( c ));
+			if (!IRC_WriteStrClient(Client, "%s", str))
+				return DISCONNECTED;
+			snprintf(str, sizeof(str), RPL_WHOISCHANNELS_MSG,
+				 Client_ID(from), Client_ID(c));
 		}
 		}
 	}
 	}
-	if( str[strlen( str ) - 1] != ':')
-	{
+	if(str[strlen(str) - 1] != ':') {
 		/* There is data left to send: */
 		/* There is data left to send: */
-		if( ! IRC_WriteStrClient( Client, "%s", str )) return DISCONNECTED;
+		if (!IRC_WriteStrClient(Client, "%s", str))
+			return DISCONNECTED;
 	}
 	}
 
 
 	/* IRC-Operator? */
 	/* IRC-Operator? */
-	if( Client_HasMode( c, 'o' ))
-	{
-		if( ! IRC_WriteStrClient( from, RPL_WHOISOPERATOR_MSG, Client_ID( from ), Client_ID( c ))) return DISCONNECTED;
-	}
+	if (Client_HasMode(c, 'o') &&
+		!IRC_WriteStrClient(from, RPL_WHOISOPERATOR_MSG,
+				    Client_ID(from), Client_ID(c)))
+			return DISCONNECTED;
 
 
 	/* Connected using SSL? */
 	/* Connected using SSL? */
-	if (Conn_UsesSSL(Client_Conn(c))) {
-		if (!IRC_WriteStrClient
-		    (from, RPL_WHOISSSL_MSG, Client_ID(from), Client_ID(c)))
+	if (Conn_UsesSSL(Client_Conn(c)) &&
+		!IRC_WriteStrClient(from, RPL_WHOISSSL_MSG,
+				    Client_ID(from), Client_ID(c)))
 			return DISCONNECTED;
 			return DISCONNECTED;
-	}
 
 
 	/* Idle and signon time (local clients only!) */
 	/* Idle and signon time (local clients only!) */
-	if (Client_Conn(c) > NONE ) {
-		if (! IRC_WriteStrClient(from, RPL_WHOISIDLE_MSG,
-			Client_ID(from), Client_ID(c),
-			(unsigned long)Conn_GetIdle(Client_Conn(c)),
-			(unsigned long)Conn_GetSignon(Client_Conn(c))))
-				return DISCONNECTED;
-	}
+	if (!Conf_MorePrivacy && Client_Conn(c) > NONE &&
+		!IRC_WriteStrClient(from, RPL_WHOISIDLE_MSG,
+				    Client_ID(from), Client_ID(c),
+				    (unsigned long)Conn_GetIdle(Client_Conn(c)),
+				    (unsigned long)Conn_GetSignon(Client_Conn(c))))
+			return DISCONNECTED;
 
 
 	/* Away? */
 	/* Away? */
-	if( Client_HasMode( c, 'a' ))
-	{
-		if( ! IRC_WriteStrClient( from, RPL_AWAY_MSG, Client_ID( from ), Client_ID( c ), Client_Away( c ))) return DISCONNECTED;
+	if (Client_HasMode(c, 'a') &&
+		!IRC_WriteStrClient(from, RPL_AWAY_MSG,
+				    Client_ID(from), Client_ID(c),
+				    Client_Away(c)))
+			return DISCONNECTED;
+
+	return IRC_WriteStrClient(from, RPL_ENDOFWHOIS_MSG,
+				  Client_ID(from), Client_ID(c));
+} /* IRC_WHOIS_SendReply */
+
+
+/**
+ * Handler for the IRC "WHOIS" command.
+ *
+ * See RFC 2812, 3.6.2 "Whois query".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @return		CONNECTED or DISCONNECTED.
+ */
+GLOBAL bool
+IRC_WHOIS( CLIENT *Client, REQUEST *Req )
+{
+	CLIENT *from, *target, *c;
+	unsigned int match_count = 0, found = 0;
+	bool has_wildcards, is_remote;
+	bool got_wildcard = false;
+	const char *query;
+
+	assert( Client != NULL );
+	assert( Req != NULL );
+
+	/* Bad number of parameters? */
+	if (Req->argc < 1 || Req->argc > 2)
+		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
+					  Client_ID(Client), Req->command);
+
+	/* Search sender of the WHOIS */
+	if (Client_Type(Client) == CLIENT_SERVER) {
+		from = Client_Search(Req->prefix);
+	} else {
+		IRC_SetPenalty(Client, 1);
+		from = Client;
 	}
 	}
+	if (!from)
+		return IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
+					  Client_ID(Client), Req->prefix);
+
+	/* Get target server for this command */
+	if (Req->argc > 1) {
+		/* Search the target server, which can be specified as a
+		 * nick name on that server as well: */
+		target = Client_Search(Req->argv[0]);
+		if (!target)
+			return IRC_WriteStrClient(from, ERR_NOSUCHSERVER_MSG,
+						Client_ID(from), Req->argv[0]);
+	} else
+		target = Client_ThisServer();
+	assert(target != NULL);
+
+	/* Forward to other server? */
+	if (Client_NextHop(target) != Client_ThisServer() &&
+	    Client_Type(Client_NextHop(target)) == CLIENT_SERVER)
+		return IRC_WriteStrClientPrefix(target, from,
+						"WHOIS %s :%s",
+						Req->argv[0], Req->argv[1]);
+
+	is_remote = Client_Conn(from) < 0;
+	for (query = strtok(Req->argv[Req->argc - 1], ",");
+			query && found < 3;
+			query = strtok(NULL, ","), found++)
+	{
+		has_wildcards = query[strcspn(query, "*?")] != 0;
+		/*
+		 * follows ircd 2.10 implementation:
+		 *  - handle up to 3 targets
+		 *  - no wildcards for remote clients
+		 *  - only one wildcard target per local client
+		 *
+		 *  also, at most ten matches are returned.
+		 */
+		if (!has_wildcards || is_remote) {
+			c = Client_Search(query);
+			if (c) {
+				if (!IRC_WHOIS_SendReply(Client, from, c))
+					return DISCONNECTED;
+			} else {
+				if (!IRC_WriteStrClient(Client,
+							ERR_NOSUCHNICK_MSG,
+							Client_ID(Client),
+							query))
+					return DISCONNECTED;
+			}
+			continue;
+		}
+		if (got_wildcard) {
+			/* we already handled one wildcard query */
+			if (!IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
+			     Client_ID(Client), query))
+				return DISCONNECTED;
+			continue;
+		}
+		got_wildcard = true;
+		IRC_SetPenalty(Client, 3);
+
+		for (c = Client_First(); c && match_count < 10; c = Client_Next(c)) {
+			if (Client_Type(c) != CLIENT_USER)
+				continue;
+			if (!MatchCaseInsensitive(query, Client_ID(c)))
+				continue;
+			if (!IRC_WHOIS_SendReply(Client, from, c))
+				return DISCONNECTED;
+			match_count++;
+		}
 
 
-	/* End of Whois */
-	return IRC_WriteStrClient( from, RPL_ENDOFWHOIS_MSG, Client_ID( from ), Client_ID( c ));
+		if (match_count == 0)
+			return IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
+				Client_ID(Client), Req->argv[Req->argc - 1]);
+	}
+	return CONNECTED;
 } /* IRC_WHOIS */
 } /* IRC_WHOIS */
 
 
 
 
@@ -1065,6 +1163,10 @@ IRC_WHOWAS( CLIENT *Client, REQUEST *Req )
 	assert( Client != NULL );
 	assert( Client != NULL );
 	assert( Req != NULL );
 	assert( Req != NULL );
 
 
+	/* Do not reveal any info on disconnected users? */
+	if (Conf_MorePrivacy)
+		return CONNECTED;
+
 	/* Wrong number of parameters? */
 	/* Wrong number of parameters? */
 	if (Req->argc > 3)
 	if (Req->argc > 3)
 		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
 		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
@@ -1291,6 +1393,10 @@ IRC_Send_NAMES( CLIENT *Client, CHANNEL *Chan )
 	if( Channel_IsMemberOf( Chan, Client )) is_member = true;
 	if( Channel_IsMemberOf( Chan, Client )) is_member = true;
 	else is_member = false;
 	else is_member = false;
 
 
+	/* Do not print info on channel memberships to anyone that is not member? */
+	if (Conf_MorePrivacy && !is_member)
+		return CONNECTED;
+
 	/* Secret channel? */
 	/* Secret channel? */
 	if( ! is_member && strchr( Channel_Modes( Chan ), 's' )) return CONNECTED;
 	if( ! is_member && strchr( Channel_Modes( Chan ), 's' )) return CONNECTED;
 
 

+ 4 - 7
src/ngircd/irc-info.h

@@ -7,16 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-info.h,v 1.6 2008/02/17 13:26:42 alex Exp $
- *
- * IRC info commands (header)
  */
  */
 
 
-
 #ifndef __irc_info_h__
 #ifndef __irc_info_h__
 #define __irc_info_h__
 #define __irc_info_h__
 
 
+/**
+ * @file
+ * IRC info commands (header)
+ */
 
 
 GLOBAL bool IRC_ADMIN PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_ADMIN PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_INFO PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_INFO PARAMS(( CLIENT *Client, REQUEST *Req ));
@@ -41,8 +40,6 @@ GLOBAL bool IRC_Send_NAMES PARAMS(( CLIENT *Client, CHANNEL *Chan ));
 GLOBAL bool IRC_Show_MOTD PARAMS(( CLIENT *Client ));
 GLOBAL bool IRC_Show_MOTD PARAMS(( CLIENT *Client ));
 GLOBAL bool IRC_Send_ISUPPORT PARAMS(( CLIENT *Client ));
 GLOBAL bool IRC_Send_ISUPPORT PARAMS(( CLIENT *Client ));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 226 - 30
src/ngircd/irc-login.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Login and logout
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Login and logout
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdio.h>
 #include <stdio.h>
@@ -54,8 +56,13 @@ static void cb_Read_Auth_Result PARAMS((int r_fd, UNUSED short events));
 #endif
 #endif
 
 
 /**
 /**
- * Handler for the IRC command "PASS".
+ * Handler for the IRC "PASS" command.
+ *
  * See RFC 2813 section 4.1.1, and RFC 2812 section 3.1.1.
  * See RFC 2813 section 4.1.1, and RFC 2812 section 3.1.1.
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_PASS( CLIENT *Client, REQUEST *Req )
 IRC_PASS( CLIENT *Client, REQUEST *Req )
@@ -143,16 +150,17 @@ IRC_PASS( CLIENT *Client, REQUEST *Req )
 		if (type && strcmp(type, PROTOIRCPLUS) == 0) {
 		if (type && strcmp(type, PROTOIRCPLUS) == 0) {
 			/* The peer seems to be a server which supports the
 			/* The peer seems to be a server which supports the
 			 * IRC+ protocol (see doc/Protocol.txt). */
 			 * IRC+ protocol (see doc/Protocol.txt). */
-			serverver = ptr + 1;
-			flags = strchr(serverver, ':');
+			serverver = ptr ? ptr + 1 : "?";
+			flags = strchr(ptr ? serverver : impl, ':');
 			if (flags) {
 			if (flags) {
 				*flags = '\0';
 				*flags = '\0';
 				flags++;
 				flags++;
 			} else
 			} else
 				flags = "";
 				flags = "";
 			Log(LOG_INFO,
 			Log(LOG_INFO,
-			    "Peer announces itself as %s-%s using protocol %d.%d/IRC+ (flags: \"%s\").",
-			    impl, serverver, protohigh, protolow, flags);
+			    "Peer on conenction %d announces itself as %s-%s using protocol %d.%d/IRC+ (flags: \"%s\").",
+			    Client_Conn(Client), impl, serverver,
+			    protohigh, protolow, flags);
 		} else {
 		} else {
 			/* The peer seems to be a server supporting the
 			/* The peer seems to be a server supporting the
 			 * "original" IRC protocol (RFC 2813). */
 			 * "original" IRC protocol (RFC 2813). */
@@ -161,8 +169,9 @@ IRC_PASS( CLIENT *Client, REQUEST *Req )
 			else
 			else
 				flags = "";
 				flags = "";
 			Log(LOG_INFO,
 			Log(LOG_INFO,
-			    "Peer announces itself as \"%s\" using protocol %d.%d (flags: \"%s\").",
-			    impl, protohigh, protolow, flags);
+			    "Peer on connection %d announces itself as \"%s\" using protocol %d.%d (flags: \"%s\").",
+			    Client_Conn(Client), impl,
+			    protohigh, protolow, flags);
 		}
 		}
 		Client_SetFlags(Client, flags);
 		Client_SetFlags(Client, flags);
 	}
 	}
@@ -172,10 +181,17 @@ IRC_PASS( CLIENT *Client, REQUEST *Req )
 
 
 
 
 /**
 /**
- * IRC "NICK" command.
+ * Handler for the IRC "NICK" command.
+ *
+ * See RFC 2812, 3.1.2 "Nick message", and RFC 2813, 4.1.3 "Nick".
+ *
  * This function implements the IRC command "NICK" which is used to register
  * This function implements the IRC command "NICK" which is used to register
  * with the server, to change already registered nicknames and to introduce
  * with the server, to change already registered nicknames and to introduce
  * new users which are connected to other servers.
  * new users which are connected to other servers.
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_NICK( CLIENT *Client, REQUEST *Req )
 IRC_NICK( CLIENT *Client, REQUEST *Req )
@@ -255,6 +271,17 @@ IRC_NICK( CLIENT *Client, REQUEST *Req )
 			/* Register new nickname of this client */
 			/* Register new nickname of this client */
 			Client_SetID( target, Req->argv[0] );
 			Client_SetID( target, Req->argv[0] );
 
 
+#ifndef STRICT_RFC
+			if (Conf_AuthPing) {
+				Conn_SetAuthPing(Client_Conn(Client), rand());
+				IRC_WriteStrClient(Client, "PING :%ld",
+					Conn_GetAuthPing(Client_Conn(Client)));
+				LogDebug("Connection %d: sent AUTH PING %ld ...",
+					Client_Conn(Client),
+					Conn_GetAuthPing(Client_Conn(Client)));
+			}
+#endif
+
 			/* If we received a valid USER command already then
 			/* If we received a valid USER command already then
 			 * register the new client! */
 			 * register the new client! */
 			if( Client_Type( Client ) == CLIENT_GOTUSER )
 			if( Client_Type( Client ) == CLIENT_GOTUSER )
@@ -377,7 +404,13 @@ IRC_NICK( CLIENT *Client, REQUEST *Req )
 
 
 
 
 /**
 /**
- * Handler for the IRC command "USER".
+ * Handler for the IRC "USER" command.
+ *
+ * See RFC 2812, 3.1.3 "User message".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_USER(CLIENT * Client, REQUEST * Req)
 IRC_USER(CLIENT * Client, REQUEST * Req)
@@ -470,12 +503,18 @@ IRC_USER(CLIENT * Client, REQUEST * Req)
 
 
 
 
 /**
 /**
- * Handler for the IRC command "SERVICE".
+ * Handler for the IRC "SERVICE" command.
+ *
  * This function implements IRC Services registration using the SERVICE command
  * This function implements IRC Services registration using the SERVICE command
  * defined in RFC 2812 3.1.6 and RFC 2813 4.1.4.
  * defined in RFC 2812 3.1.6 and RFC 2813 4.1.4.
+ *
  * At the moment ngIRCd doesn't support directly linked services, so this
  * At the moment ngIRCd doesn't support directly linked services, so this
  * function returns ERR_ERRONEUSNICKNAME when the SERVICE command has not been
  * function returns ERR_ERRONEUSNICKNAME when the SERVICE command has not been
  * received from a peer server.
  * received from a peer server.
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED..
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_SERVICE(CLIENT *Client, REQUEST *Req)
 IRC_SERVICE(CLIENT *Client, REQUEST *Req)
@@ -568,8 +607,14 @@ IRC_SERVICE(CLIENT *Client, REQUEST *Req)
 
 
 
 
 /**
 /**
- * Handler for the IRC command "WEBIRC".
- * Syntax: WEBIRC <password> <username> <real-hostname> <real-IP-address>
+ * Handler for the IRC "WEBIRC" command.
+ *
+ * See doc/Protocol.txt, section II.4:
+ * "Update webchat/proxy client information".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
  */
  */
 GLOBAL bool
 GLOBAL bool
 IRC_WEBIRC(CLIENT *Client, REQUEST *Req)
 IRC_WEBIRC(CLIENT *Client, REQUEST *Req)
@@ -593,6 +638,15 @@ IRC_WEBIRC(CLIENT *Client, REQUEST *Req)
 } /* IRC_WEBIRC */
 } /* IRC_WEBIRC */
 
 
 
 
+/**
+ * Handler for the IRC "QUIT" command.
+ *
+ * See RFC 2812, 3.1.7 "Quit", and RFC 2813, 4.1.5 "Quit".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_QUIT( CLIENT *Client, REQUEST *Req )
 IRC_QUIT( CLIENT *Client, REQUEST *Req )
 {
 {
@@ -640,6 +694,38 @@ IRC_QUIT( CLIENT *Client, REQUEST *Req )
 } /* IRC_QUIT */
 } /* IRC_QUIT */
 
 
 
 
+#ifndef STRICT_RFC
+
+/**
+ * Handler for HTTP command, e.g. GET and POST
+ *
+ * We handle these commands here to avoid the quite long timeout when
+ * some user tries to access this IRC daemon using an web browser ...
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
+GLOBAL bool
+IRC_QUIT_HTTP( CLIENT *Client, REQUEST *Req )
+{
+	Req->argc = 1;
+	Req->argv[0] = "Oops, HTTP request received? This is IRC!";
+	return IRC_QUIT(Client, Req);
+} /* IRC_QUIT_HTTP */
+
+#endif
+
+
+/**
+ * Handler for the IRC "PING" command.
+ *
+ * See RFC 2812, 3.7.2 "Ping message".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_PING(CLIENT *Client, REQUEST *Req)
 IRC_PING(CLIENT *Client, REQUEST *Req)
 {
 {
@@ -709,22 +795,45 @@ IRC_PING(CLIENT *Client, REQUEST *Req)
 } /* IRC_PING */
 } /* IRC_PING */
 
 
 
 
+/**
+ * Handler for the IRC "PONG" command.
+ *
+ * See RFC 2812, 3.7.3 "Pong message".
+ *
+ * @param Client	The client from which this command has been received.
+ * @param Req		Request structure with prefix and all parameters.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
 GLOBAL bool
 GLOBAL bool
 IRC_PONG(CLIENT *Client, REQUEST *Req)
 IRC_PONG(CLIENT *Client, REQUEST *Req)
 {
 {
 	CLIENT *target, *from;
 	CLIENT *target, *from;
+	CONN_ID conn;
+#ifndef STRICT_RFC
+	long auth_ping;
+#endif
 	char *s;
 	char *s;
 
 
 	assert(Client != NULL);
 	assert(Client != NULL);
 	assert(Req != NULL);
 	assert(Req != NULL);
 
 
 	/* Wrong number of arguments? */
 	/* Wrong number of arguments? */
-	if (Req->argc < 1)
-		return IRC_WriteStrClient(Client, ERR_NOORIGIN_MSG,
-					  Client_ID(Client));
-	if (Req->argc > 2)
-		return IRC_WriteStrClient(Client, ERR_NEEDMOREPARAMS_MSG,
-					  Client_ID(Client), Req->command);
+	if (Req->argc < 1) {
+		if (Client_Type(Client) == CLIENT_USER)
+			return IRC_WriteStrClient(Client, ERR_NOORIGIN_MSG,
+						  Client_ID(Client));
+		else
+			return CONNECTED;
+	}
+	if (Req->argc > 2) {
+		if (Client_Type(Client) == CLIENT_USER)
+			return IRC_WriteStrClient(Client,
+						  ERR_NEEDMOREPARAMS_MSG,
+						  Client_ID(Client),
+						  Req->command);
+		else
+			return CONNECTED;
+	}
 
 
 	/* Forward? */
 	/* Forward? */
 	if (Req->argc == 2 && Client_Type(Client) == CLIENT_SERVER) {
 	if (Req->argc == 2 && Client_Type(Client) == CLIENT_SERVER) {
@@ -753,32 +862,76 @@ IRC_PONG(CLIENT *Client, REQUEST *Req)
 
 
 	/* The connection timestamp has already been updated when the data has
 	/* The connection timestamp has already been updated when the data has
 	 * been read from so socket, so we don't need to update it here. */
 	 * been read from so socket, so we don't need to update it here. */
+
+	conn = Client_Conn(Client);
+
+#ifndef STRICT_RFC
+	/* Check authentication PING-PONG ... */
+	auth_ping = Conn_GetAuthPing(conn);
+	if (auth_ping) {
+		LogDebug("AUTH PONG: waiting for token \"%ld\", got \"%s\" ...",
+			 auth_ping, Req->argv[0]);
+		if (auth_ping == atoi(Req->argv[0])) {
+			Conn_SetAuthPing(conn, 0);
+			if (Client_Type(Client) == CLIENT_WAITAUTHPING)
+				Hello_User(Client);
+		} else
+			if (!IRC_WriteStrClient(Client,
+					"To connect, type /QUOTE PONG %ld",
+					auth_ping))
+				return DISCONNECTED;
+	}
+#endif
+
 #ifdef DEBUG
 #ifdef DEBUG
-	if (Client_Conn(Client) > NONE)
+	if (conn > NONE)
 		Log(LOG_DEBUG,
 		Log(LOG_DEBUG,
-			"Connection %d: received PONG. Lag: %ld seconds.",
-			Client_Conn(Client),
+			"Connection %d: received PONG. Lag: %ld seconds.", conn,
 			time(NULL) - Conn_LastPing(Client_Conn(Client)));
 			time(NULL) - Conn_LastPing(Client_Conn(Client)));
 	else
 	else
 		 Log(LOG_DEBUG,
 		 Log(LOG_DEBUG,
-			"Connection %d: received PONG.", Client_Conn(Client));
+			"Connection %d: received PONG.", conn);
 #endif
 #endif
 	return CONNECTED;
 	return CONNECTED;
 } /* IRC_PONG */
 } /* IRC_PONG */
 
 
 
 
+/**
+ * Initiate client registration.
+ *
+ * This function is called after the daemon received the required NICK and
+ * USER commands of a new client. If the daemon is compiled with support for
+ * PAM, the authentication sub-processs is forked; otherwise the global server
+ * password is checked.
+ *
+ * @param Client	The client logging in.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
 static bool
 static bool
 Hello_User(CLIENT * Client)
 Hello_User(CLIENT * Client)
 {
 {
 #ifdef PAM
 #ifdef PAM
 	int pipefd[2], result;
 	int pipefd[2], result;
-	CONN_ID conn;
 	pid_t pid;
 	pid_t pid;
+#endif
+	CONN_ID conn;
 
 
 	assert(Client != NULL);
 	assert(Client != NULL);
 	conn = Client_Conn(Client);
 	conn = Client_Conn(Client);
 
 
-	if (Conf_NoPAM) {
+#ifndef STRICT_RFC
+	if (Conf_AuthPing) {
+		/* Did we receive the "auth PONG" already? */
+		if (Conn_GetAuthPing(conn)) {
+			Client_SetType(Client, CLIENT_WAITAUTHPING);
+			LogDebug("Connection %d: Waiting for AUTH PONG ...", conn);
+			return CONNECTED;
+		}
+	}
+#endif
+
+#ifdef PAM
+	if (!Conf_PAM) {
 		/* Don't do any PAM authentication at all, instead emulate
 		/* Don't do any PAM authentication at all, instead emulate
 		 * the beahiour of the daemon compiled without PAM support:
 		 * the beahiour of the daemon compiled without PAM support:
 		 * because there can't be any "server password", all
 		 * because there can't be any "server password", all
@@ -801,13 +954,13 @@ Hello_User(CLIENT * Client)
 		/* Sub process */
 		/* Sub process */
 		Log_Init_Subprocess("Auth");
 		Log_Init_Subprocess("Auth");
 		result = PAM_Authenticate(Client);
 		result = PAM_Authenticate(Client);
-		write(pipefd[1], &result, sizeof(result));
+		if (write(pipefd[1], &result, sizeof(result)) != sizeof(result))
+			Log_Subprocess(LOG_ERR,
+				       "Failed to pipe result to parent!");
 		Log_Exit_Subprocess("Auth");
 		Log_Exit_Subprocess("Auth");
 		exit(0);
 		exit(0);
 	}
 	}
 #else
 #else
-	assert(Client != NULL);
-
 	/* Check global server password ... */
 	/* Check global server password ... */
 	if (strcmp(Client_Password(Client), Conf_ServerPwd) != 0) {
 	if (strcmp(Client_Password(Client), Conf_ServerPwd) != 0) {
 		/* Bad password! */
 		/* Bad password! */
@@ -823,6 +976,9 @@ Hello_User(CLIENT * Client)
 
 
 /**
 /**
  * Read result of the authenticatior sub-process from pipe
  * Read result of the authenticatior sub-process from pipe
+ *
+ * @param r_fd		File descriptor of the pipe.
+ * @param events	(ignored IO specification)
  */
  */
 static void
 static void
 cb_Read_Auth_Result(int r_fd, UNUSED short events)
 cb_Read_Auth_Result(int r_fd, UNUSED short events)
@@ -866,6 +1022,14 @@ cb_Read_Auth_Result(int r_fd, UNUSED short events)
 #endif
 #endif
 
 
 
 
+/**
+ * Reject a client because of wrong password.
+ *
+ * This function is called either when the global server password or a password
+ * checked using PAM has been wrong.
+ *
+ * @param Client	The client to reject.
+ */
 static void
 static void
 Reject_Client(CLIENT *Client)
 Reject_Client(CLIENT *Client)
 {
 {
@@ -877,6 +1041,15 @@ Reject_Client(CLIENT *Client)
 }
 }
 
 
 
 
+/**
+ * Finish client registration.
+ *
+ * Introduce the new client to the network and send all "hello messages"
+ * to it after authentication has been succeeded.
+ *
+ * @param Client	The client logging in.
+ * @returns		CONNECTED or DISCONNECTED.
+ */
 static bool
 static bool
 Hello_User_PostAuth(CLIENT *Client)
 Hello_User_PostAuth(CLIENT *Client)
 {
 {
@@ -916,6 +1089,12 @@ Hello_User_PostAuth(CLIENT *Client)
 }
 }
 
 
 
 
+/**
+ * Kill all users with a specific nick name in the network.
+ *
+ * @param Nick		Nick name.
+ * @param Reason	Reason for the KILL.
+ */
 static void
 static void
 Kill_Nick( char *Nick, char *Reason )
 Kill_Nick( char *Nick, char *Reason )
 {
 {
@@ -934,6 +1113,13 @@ Kill_Nick( char *Nick, char *Reason )
 } /* Kill_Nick */
 } /* Kill_Nick */
 
 
 
 
+/**
+ * Introduce a new user or service client in the network.
+ *
+ * @param From		Remote server introducing the client or NULL (local).
+ * @param Client	New client.
+ * @param Type		Type of the client (CLIENT_USER or CLIENT_SERVICE).
+ */
 static void
 static void
 Introduce_Client(CLIENT *From, CLIENT *Client, int Type)
 Introduce_Client(CLIENT *From, CLIENT *Client, int Type)
 {
 {
@@ -967,6 +1153,16 @@ Introduce_Client(CLIENT *From, CLIENT *Client, int Type)
 } /* Introduce_Client */
 } /* Introduce_Client */
 
 
 
 
+/**
+ * Introduce a new user or service client to a remote server.
+ *
+ * This function differentiates between RFC1459 and RFC2813 server links and
+ * generates the appropriate commands to register the new user or service.
+ *
+ * @param To		The remote server to inform.
+ * @param Prefix	Prefix for the generated commands.
+ * @param data		CLIENT structure of the new client.
+ */
 static void
 static void
 cb_introduceClient(CLIENT *To, CLIENT *Prefix, void *data)
 cb_introduceClient(CLIENT *To, CLIENT *Prefix, void *data)
 {
 {

+ 6 - 4
src/ngircd/irc-login.h

@@ -7,14 +7,16 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Login and logout (header)
  */
  */
 
 
-
 #ifndef __irc_login_h__
 #ifndef __irc_login_h__
 #define __irc_login_h__
 #define __irc_login_h__
 
 
+/**
+ * @file
+ * Login and logout (header)
+ */
+
 GLOBAL bool IRC_PASS PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_PASS PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_NICK PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_NICK PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_USER PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_USER PARAMS((CLIENT *Client, REQUEST *Req));
@@ -23,8 +25,8 @@ GLOBAL bool IRC_WEBIRC PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_PING PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_PING PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_PONG PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_PONG PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_QUIT PARAMS((CLIENT *Client, REQUEST *Req));
 GLOBAL bool IRC_QUIT PARAMS((CLIENT *Client, REQUEST *Req));
+GLOBAL bool IRC_QUIT_HTTP PARAMS((CLIENT *Client, REQUEST *Req));
 
 
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 31 - 28
src/ngircd/irc-mode.c

@@ -1,19 +1,21 @@
 /*
 /*
  * ngIRCd -- The Next Generation IRC Daemon
  * ngIRCd -- The Next Generation IRC Daemon
- * Copyright (c)2001-2010 Alexander Barton (alex@barton.de)
+ * Copyright (c)2001-2011 Alexander Barton (alex@barton.de) and Contributors.
  *
  *
  * This program is free software; you can redistribute it and/or modify
  * 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
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * IRC commands for mode changes (MODE, AWAY, ...)
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * IRC commands for mode changes (like MODE, AWAY, etc.)
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdio.h>
 #include <stdio.h>
@@ -202,7 +204,7 @@ Client_Mode( CLIENT *Client, REQUEST *Req, CLIENT *Origin, CLIENT *Target )
 
 
 			case 'x': /* Cloak hostname */
 			case 'x': /* Cloak hostname */
 				if (Client_HasMode(Client, 'r'))
 				if (Client_HasMode(Client, 'r'))
-					IRC_WriteStrClient(Origin,
+					ok = IRC_WriteStrClient(Origin,
 							   ERR_RESTRICTED_MSG,
 							   ERR_RESTRICTED_MSG,
 							   Client_ID(Origin));
 							   Client_ID(Origin));
 				else
 				else
@@ -316,8 +318,7 @@ Channel_Mode(CLIENT *Client, REQUEST *Req, CLIENT *Origin, CHANNEL *Channel)
 {
 {
 	char the_modes[COMMAND_LEN], the_args[COMMAND_LEN], x[2],
 	char the_modes[COMMAND_LEN], the_args[COMMAND_LEN], x[2],
 	    argadd[CLIENT_PASS_LEN], *mode_ptr;
 	    argadd[CLIENT_PASS_LEN], *mode_ptr;
-	bool connected, set, skiponce, retval, onchannel;
-	bool modeok = true, use_servermode = false;
+	bool connected, set, skiponce, retval, onchannel, modeok, use_servermode;
 	int mode_arg, arg_arg;
 	int mode_arg, arg_arg;
 	CLIENT *client;
 	CLIENT *client;
 	long l;
 	long l;
@@ -331,28 +332,13 @@ Channel_Mode(CLIENT *Client, REQUEST *Req, CLIENT *Origin, CHANNEL *Channel)
 	if (Req->argc <= 1)
 	if (Req->argc <= 1)
 		return Channel_Mode_Answer_Request(Origin, Channel);
 		return Channel_Mode_Answer_Request(Origin, Channel);
 
 
-	/* Is the user allowed to change modes? */
-	if (Client_Type(Client) == CLIENT_USER) {
-		/* Is the originating user on that channel? */
-		onchannel = Channel_IsMemberOf(Channel, Origin);
-		modeok = false;
-		/* channel operator? */
-		if (onchannel &&
-		    strchr(Channel_UserModes(Channel, Origin), 'o')) {
-			modeok = true;
-		} else if (Conf_OperCanMode) {
-			/* IRC-Operators can use MODE as well */
-			if (Client_OperByMe(Origin)) {
-				modeok = true;
-				if (Conf_OperServerMode)
-					use_servermode = true; /* Change Origin to Server */
-			}
-		}
+	Channel_CheckAdminRights(Channel, Client, Origin,
+				 &onchannel, &modeok, &use_servermode);
 
 
-		if (!onchannel && !modeok)
-			return IRC_WriteStrClient(Origin, ERR_NOTONCHANNEL_MSG,
-				Client_ID(Origin), Channel_Name(Channel));
-	}
+	if (!onchannel && !modeok)
+		return IRC_WriteStrClient(Origin, ERR_NOTONCHANNEL_MSG,
+					  Client_ID(Origin),
+					  Channel_Name(Channel));
 
 
 	mode_arg = 1;
 	mode_arg = 1;
 	mode_ptr = Req->argv[mode_arg];
 	mode_ptr = Req->argv[mode_arg];
@@ -515,6 +501,23 @@ Channel_Mode(CLIENT *Client, REQUEST *Req, CLIENT *Origin, CHANNEL *Channel)
 				goto chan_exit;
 				goto chan_exit;
 			}
 			}
 			break;
 			break;
+		case 'O': /* IRC operators only */
+			if (modeok) {
+				/* Only IRC operators are allowed to
+				 * set the 'O' channel mode! */
+				if (set && !(Client_OperByMe(Client)
+				    || Client_Type(Client) == CLIENT_SERVER))
+					connected = IRC_WriteStrClient(Origin,
+						ERR_NOPRIVILEGES_MSG,
+						Client_ID(Origin));
+				else
+					x[0] = 'O';
+			} else
+				connected = IRC_WriteStrClient(Origin,
+						ERR_CHANOPRIVSNEEDED_MSG,
+						Client_ID(Origin),
+						Channel_Name(Channel));
+				break;
 		case 'P': /* Persistent channel */
 		case 'P': /* Persistent channel */
 			if (modeok) {
 			if (modeok) {
 				/* Only IRC operators are allowed to
 				/* Only IRC operators are allowed to

+ 4 - 7
src/ngircd/irc-mode.h

@@ -7,22 +7,19 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-mode.h,v 1.6 2005/03/19 18:43:48 fw Exp $
- *
- * IRC commands for mode changes (header)
  */
  */
 
 
-
 #ifndef __irc_mode_h__
 #ifndef __irc_mode_h__
 #define __irc_mode_h__
 #define __irc_mode_h__
 
 
+/**
+ * @file
+ * IRC commands for mode changes (header)
+ */
 
 
 GLOBAL bool IRC_MODE PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_MODE PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_AWAY PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_AWAY PARAMS((CLIENT *Client, REQUEST *Req ));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 5 - 3
src/ngircd/irc-op.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Channel operator commands
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Channel operator commands
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <string.h>
 #include <string.h>

+ 4 - 7
src/ngircd/irc-op.h

@@ -7,22 +7,19 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-op.h,v 1.4 2005/03/19 18:43:48 fw Exp $
- *
- * Channel operator commands (header)
  */
  */
 
 
-
 #ifndef __irc_op_h__
 #ifndef __irc_op_h__
 #define __irc_op_h__
 #define __irc_op_h__
 
 
+/**
+ * @file
+ * Channel operator commands (header)
+ */
 
 
 GLOBAL bool IRC_KICK PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_KICK PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_INVITE PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_INVITE PARAMS(( CLIENT *Client, REQUEST *Req ));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 5 - 3
src/ngircd/irc-oper.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * IRC operator commands
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * IRC operator commands
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdio.h>
 #include <stdio.h>

+ 4 - 7
src/ngircd/irc-oper.h

@@ -7,16 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-oper.h,v 1.12 2007/08/02 10:14:26 fw Exp $
- *
- * IRC operator commands (header)
  */
  */
 
 
-
 #ifndef __irc_oper_h__
 #ifndef __irc_oper_h__
 #define __irc_oper_h__
 #define __irc_oper_h__
 
 
+/**
+ * @file
+ * IRC operator commands (header)
+ */
 
 
 GLOBAL bool IRC_OPER PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_OPER PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_DIE PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_DIE PARAMS((CLIENT *Client, REQUEST *Req ));
@@ -26,8 +25,6 @@ GLOBAL bool IRC_CONNECT PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_DISCONNECT PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_DISCONNECT PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_WALLOPS PARAMS(( CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_WALLOPS PARAMS(( CLIENT *Client, REQUEST *Req ));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 11 - 4
src/ngircd/irc-server.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * IRC commands for server links
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * IRC commands for server links
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #include <stdio.h>
 #include <stdio.h>
@@ -275,6 +277,7 @@ IRC_SQUIT(CLIENT * Client, REQUEST * Req)
 	char msg[COMMAND_LEN], logmsg[COMMAND_LEN];
 	char msg[COMMAND_LEN], logmsg[COMMAND_LEN];
 	CLIENT *from, *target;
 	CLIENT *from, *target;
 	CONN_ID con;
 	CONN_ID con;
+	int loglevel;
 
 
 	assert(Client != NULL);
 	assert(Client != NULL);
 	assert(Req != NULL);
 	assert(Req != NULL);
@@ -299,7 +302,11 @@ IRC_SQUIT(CLIENT * Client, REQUEST * Req)
 		return IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
 		return IRC_WriteStrClient(Client, ERR_NOSUCHNICK_MSG,
 					  Client_ID(Client), Req->prefix);
 					  Client_ID(Client), Req->prefix);
 
 
-	Log(LOG_DEBUG, "Got SQUIT from %s for \"%s\": \"%s\" ...",
+	if (Client_Type(Client) == CLIENT_USER)
+		loglevel = LOG_NOTICE | LOG_snotice;
+	else
+		loglevel = LOG_DEBUG;
+	Log(loglevel, "Got SQUIT from %s for \"%s\": \"%s\" ...",
 	    Client_ID(from), Req->argv[0], Req->argv[1]);
 	    Client_ID(from), Req->argv[0], Req->argv[1]);
 
 
 	target = Client_Search(Req->argv[0]);
 	target = Client_Search(Req->argv[0]);

+ 4 - 7
src/ngircd/irc-server.h

@@ -7,16 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * $Id: irc-server.h,v 1.6 2007/11/21 12:16:36 alex Exp $
- *
- * IRC commands for server links (header)
  */
  */
 
 
-
 #ifndef __irc_server_h__
 #ifndef __irc_server_h__
 #define __irc_server_h__
 #define __irc_server_h__
 
 
+/**
+ * @file
+ * IRC commands for server links (header)
+ */
 
 
 GLOBAL bool IRC_SERVER PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_SERVER PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_NJOIN PARAMS((CLIENT *Client, REQUEST *Req ));
 GLOBAL bool IRC_NJOIN PARAMS((CLIENT *Client, REQUEST *Req ));
@@ -24,8 +23,6 @@ GLOBAL bool IRC_SQUIT PARAMS((CLIENT *Client, REQUEST *Req ));
 
 
 GLOBAL bool IRC_ENDOFMOTD_Server PARAMS((CLIENT *Client));
 GLOBAL bool IRC_ENDOFMOTD_Server PARAMS((CLIENT *Client));
 
 
-
 #endif
 #endif
 
 
-
 /* -eof- */
 /* -eof- */

+ 5 - 3
src/ngircd/irc-write.c

@@ -7,13 +7,15 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Sending IRC commands over the network
  */
  */
 
 
-
 #include "portab.h"
 #include "portab.h"
 
 
+/**
+ * @file
+ * Sending IRC commands over the network
+ */
+
 #include "imp.h"
 #include "imp.h"
 #include <assert.h>
 #include <assert.h>
 #ifdef PROTOTYPES
 #ifdef PROTOTYPES

+ 5 - 2
src/ngircd/irc-write.h

@@ -7,13 +7,16 @@
  * the Free Software Foundation; either version 2 of the License, or
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
  * (at your option) any later version.
  * Please read the file COPYING, README and AUTHORS for more information.
  * Please read the file COPYING, README and AUTHORS for more information.
- *
- * Sending IRC commands over the network (header)
  */
  */
 
 
 #ifndef __irc_write_h__
 #ifndef __irc_write_h__
 #define __irc_write_h__
 #define __irc_write_h__
 
 
+/**
+ * @file
+ * Sending IRC commands over the network (header)
+ */
+
 GLOBAL bool IRC_WriteStrClient PARAMS((CLIENT *Client, const char *Format, ...));
 GLOBAL bool IRC_WriteStrClient PARAMS((CLIENT *Client, const char *Format, ...));
 GLOBAL bool IRC_WriteStrClientPrefix PARAMS((CLIENT *Client, CLIENT *Prefix,
 GLOBAL bool IRC_WriteStrClientPrefix PARAMS((CLIENT *Client, CLIENT *Prefix,
 		const char *Format, ...));
 		const char *Format, ...));

+ 0 - 0
src/ngircd/irc.c


Some files were not shown because too many files changed in this diff