]> arthur.barton.de Git - ngircd-alex.git/log
ngircd-alex.git
3 months agoUpdate included Debian package configuration
Alexander Barton [Fri, 19 Jan 2024 21:07:38 +0000 (22:07 +0100)]
Update included Debian package configuration

- Rewrite using current dh_make.
- Standards-Version: 4.6.2.
- No longer build 3 different packages; only build "ngircd" which now
  includes support for IDENT, PAM (disabled in the ngircd.conf installed
  by the package), SSL (OpenSSL), ZLib and IPv6.
- Update package description accordingly.
- No longer install a SysV init file, only install ngircd.service unit.

3 months agoRemove outdated and obsolete targets from the toplevel Makefile
Alexander Barton [Fri, 19 Jan 2024 21:14:47 +0000 (22:14 +0100)]
Remove outdated and obsolete targets from the toplevel Makefile

This affects targets for Apple Xcode and Package Maker, which both are
no longer supported/included in the ngIRCd distribution.

See commits 0652c99b and 07219281, this is a leftover ...

3 months agoUse -Werror when testing for -Wno-format-truncation
Alexander Barton [Fri, 19 Jan 2024 15:55:23 +0000 (16:55 +0100)]
Use -Werror when testing for -Wno-format-truncation

Clang does not know the -Wno-format-truncation option of (current) GCC,
but accepts unknown -W... options (exit core 0) but issues a warning
message on every invocation. So for example on macOS, where Clang is
used as "gcc", a new warning message was shown for every file to
compile, since we enabled -Wno-format-truncation in commit 1d527eaf:

  warning: unknown warning option '-Wno-format-truncation' [-Wunknown-warning-option]

Clang no longer acceps unknown -W... options by enabling -Werror, which
this patch adds to the CFLAGS while testing for -Wno-format-truncation,
which fixes this issue.

This fixes commit 1d527eaf.

3 months agoAnnotate "fall through" cases to silence warnings
Alexander Barton [Thu, 18 Jan 2024 21:41:39 +0000 (22:41 +0100)]
Annotate "fall through" cases to silence warnings

Add a "/* fall through */" annotation to "case" statements which
actually should "fall through" to silences GCC warning like this:

  hash.c: In function ‘jenkins_hash’:
  hash.c:110:27: warning: this statement may fall through
                 [-Wimplicit-fallthrough=]
    110 |                 case 12: c+=((UINT32)k[11])<<24;
        |                          ~^~~~~~~~~~~~~~~~~~~~~

3 months agoDisable GCC -Wformat-truncation when suported
Alexander Barton [Thu, 18 Jan 2024 21:39:10 +0000 (22:39 +0100)]
Disable GCC -Wformat-truncation when suported

Pass -Wno-format-truncation when this is supported by GCC so silence
warnings like this:

  conf.c: In function ‘Read_Config’:
  conf.c:985:60: warning: ‘snprintf’ output may be truncated before
                 the last format character [-Wformat-truncation=]
    985 |                         snprintf(file, sizeof(file), "%s/%s",
        |                                                            ^
  conf.c:985:25: note: ‘snprintf’ output 2 or more bytes (assuming 257)
                 into a destination of size 256
    985 |                         snprintf(file, sizeof(file), "%s/%s",
        |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    986 |                                  Conf_IncludeDir, entry->d_name);
        |                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The warning is correct, but this is basically why we use snprintf() in
the first place.

3 months agoSpelling fixes, mostly in file comments
Alexander Barton [Fri, 30 Dec 2022 14:37:35 +0000 (15:37 +0100)]
Spelling fixes, mostly in file comments

3 months agoautogen.sh: Prefere automake 1.11 over other releases
Alexander Barton [Tue, 16 Jan 2024 16:33:54 +0000 (17:33 +0100)]
autogen.sh: Prefere automake 1.11 over other releases

GNU automake 1.11 is the last release supporting "de-ANSI-fication"
using the included ansi2knr tool. And becuase we _want_ to support old
K&R platforms, we try hard to use this release of automake when
available to generate our build system.

3 months agoAutodetect support for IPv6 by default
Alexander Barton [Mon, 15 Jan 2024 21:14:15 +0000 (22:14 +0100)]
Autodetect support for IPv6 by default

Until now, IPv6 support was disabled by default, which seems a bit
outdated in 2024. Note: You still can pass "--enable-ipv6" or
"--disable-ipv6" to the ./configure script to forcefully activate or
deactivate IPv6 support.

3 months agoDo IDENT requests even when DNS lookups are disabled
Alexander Barton [Mon, 15 Jan 2024 20:12:10 +0000 (21:12 +0100)]
Do IDENT requests even when DNS lookups are disabled

Without this patch, disabling DNS in the configuration disabled IDENT
lookups as well (for no good reason).

This patch allows enabling/disabling DNS lookups and IDENT requests
completely separately and enhances the messages sent to the client when
"NoticeBeforeRegistration" is enabled, too.

Thanks for reporting this, Miniontoby!

Closes #291.

3 months agoStart preparing the ChangeLog for the next release ...
Alexander Barton [Thu, 11 Jan 2024 13:56:03 +0000 (14:56 +0100)]
Start preparing the ChangeLog for the next release ...

3 months agoUpdate config.guess and config.sub to recent versions
Alexander Barton [Thu, 11 Jan 2024 13:51:27 +0000 (14:51 +0100)]
Update config.guess and config.sub to recent versions

- config.guess: 2023-08-22
- config.sub: 2023-09-19

3 months agoChannel Admins are not allowed to set Channel Owner status!
Alexander Barton [Tue, 9 Jan 2024 15:36:10 +0000 (16:36 +0100)]
Channel Admins are not allowed to set Channel Owner status!

This was reported back in April 2021, thanks Sarah!

    Subject: NGIRCD bug report
    Date: April 28 2021, 14:30:08 MESZ
    To: alex@barton.de

    Hello,

    I am writing to you to report a bug in ngircd.
    In any give channel, if an user is with mode +a (admin), he/she can
    sets mode +/-q(owner) to any other user. This is not inline with the
    documentation.

    I've looked into the code irc-mode.c, apparently an if block is
    missing. Below are the code snippets that I believe fixes the bug.

This patch is what Sarah sent in. Thanks a lot!

3 months agoConvert the FAQ to Markdown and enhance it!
Alexander Barton [Tue, 9 Jan 2024 14:52:34 +0000 (15:52 +0100)]
Convert the FAQ to Markdown and enhance it!

3 months agoTest suite: Update for OpenSSL 3.x
Alexander Barton [Mon, 8 Jan 2024 22:11:33 +0000 (23:11 +0100)]
Test suite: Update for OpenSSL 3.x

3 months agoAllow SSL client-only configurations without keys/certificates
Alexander Barton [Sat, 6 Jan 2024 18:53:33 +0000 (19:53 +0100)]
Allow SSL client-only configurations without keys/certificates

You don't need to configure certificates/keys as long as you don't
configure SSL-enabled listening ports.

This can make sense when you want to only link your local daemon to an
uplink server using SSL and only have clients on your local host or in
you fully trusted network, where SSL is not required.

3 months agoRemove unmaintained contrib/MacOSX/ folder
Alexander Barton [Mon, 8 Jan 2024 21:16:52 +0000 (22:16 +0100)]
Remove unmaintained contrib/MacOSX/ folder

This includes removing the Xcode project.

The sample launchd(8) configuration properties list file was moved to
"contrib/de.barton.ngircd.plist" and kept.

3 months agoQuickStart.md: Update title and fix Markdown syntax
Alexander Barton [Mon, 8 Jan 2024 20:08:18 +0000 (21:08 +0100)]
QuickStart.md: Update title and fix Markdown syntax

3 months agoUpdate the project description, enhance & fix the README.md
Alexander Barton [Mon, 8 Jan 2024 20:07:33 +0000 (21:07 +0100)]
Update the project description, enhance & fix the README.md

3 months ago2024 =:)
Alexander Barton [Mon, 8 Jan 2024 15:38:45 +0000 (16:38 +0100)]
2024 =:)

4 months agoFix showing the "Ident" option in --configtest output
Alexander Barton [Sat, 6 Jan 2024 14:50:33 +0000 (15:50 +0100)]
Fix showing the "Ident" option in --configtest output

We tested for the wrong #define ... ooops!

4 months agoChange GnuTLS "slot handling" messages to debug level
Alexander Barton [Fri, 5 Jan 2024 21:22:20 +0000 (22:22 +0100)]
Change GnuTLS "slot handling" messages to debug level

Those messages are about an internal implementation detail, not relevant
for an administrator of ngIRCd.

4 months agoEnlarge buffer for log messages
Alexander Barton [Fri, 5 Jan 2024 21:18:17 +0000 (22:18 +0100)]
Enlarge buffer for log messages

For example, SSL/TLS certificate information can easily get longer than
256 characters. So enlarge the log buffer to 1 KB.

4 months agoRespect "SSLConnect" option for incoming connections
Alexander Barton [Mon, 1 Jan 2024 17:20:26 +0000 (18:20 +0100)]
Respect "SSLConnect" option for incoming connections

Don't accept incoming plain-text ("non SSL") server connections for
servers configured with "SSLConnect" enabled.

If "SSLConnect" is not set for an incoming connection the server still
accepts both plain-text and encrypted connections.

This change prevents an authenticated client-server being able to force
the server-server to send its password on a plain-text connection when
SSL/TLS was intended.

4 months agoAlways initiate closing a connection on errors.
Alexander Barton [Fri, 24 Nov 2023 17:16:36 +0000 (18:16 +0100)]
Always initiate closing a connection on errors.

Always try to close a connection with errors immediately, but try hard
to avoid too much recursion.

Without this patch, an outgoing server connection could get stuck in an
"endless" state trying to write out data over and over again.

This tries to fix 04de1423eb26.

6 months agoAdd "hopm.service" to "Wants" and "Before" dependencies in systemd unit file
Alexander Barton [Tue, 17 Oct 2023 14:15:38 +0000 (16:15 +0200)]
Add "hopm.service" to "Wants" and "Before" dependencies in systemd unit file

7 months agoUpdate Debian package configuration
Alexander Barton [Sun, 17 Sep 2023 21:42:08 +0000 (23:42 +0200)]
Update Debian package configuration

This not only bumps the "compat" version, but updates the package
dependencies and build rules accordingly.

Closes #299.

7 months agoUpdate config.guess and config.sub to recent versions
Alexander Barton [Sun, 17 Sep 2023 21:39:05 +0000 (23:39 +0200)]
Update config.guess and config.sub to recent versions

- config.guess: 2022-01-09
- config.sub: 2022-01-03

7 months agoReturn ERR_NOTEXTTOSEND on empty PRIVMSG content
Valentin Lorentz [Sun, 3 Sep 2023 08:05:54 +0000 (10:05 +0200)]
Return ERR_NOTEXTTOSEND on empty PRIVMSG content

They are dropped further down the line anyway; and sending ERR_NOTEXTTOSEND
early matches other servers' behavior.

7 months agoUpdate and enhance the manual pages a bit
Alexander Barton [Sun, 17 Sep 2023 20:03:12 +0000 (22:03 +0200)]
Update and enhance the manual pages a bit

7 months agoMerge branch 'katp32/master'
Alexander Barton [Sun, 17 Sep 2023 19:37:45 +0000 (21:37 +0200)]
Merge branch 'katp32/master'

Thanks Katherine Peeters for the patch and pull request!

Closes #294.

* katp32/master:
  Improve documentation for --syslog
  Added command line flag to enable syslog
  Split NoSyslog from behaviour of NoDaemon

7 months agoConf_Test(): Use yesno_to_str() instead of individual tests and output
Alexander Barton [Sun, 17 Sep 2023 18:28:52 +0000 (20:28 +0200)]
Conf_Test(): Use yesno_to_str() instead of individual tests and output

7 months agoChannel autojoin: Add missing variable in --configtest output
Alexander Barton [Sun, 17 Sep 2023 18:27:14 +0000 (20:27 +0200)]
Channel autojoin: Add missing variable in --configtest output

7 months agoSilence compiler warning in Init_New_Client()
Alexander Barton [Sun, 17 Sep 2023 18:16:35 +0000 (20:16 +0200)]
Silence compiler warning in Init_New_Client()

Use strdup() instead of pointless strndup() to fix the following
compiler warning:

client.c: In function ‘Init_New_Client’:
client.c:216:32: warning: ‘strndup’ specified bound 127 exceeds source size 5 [-Wstringop-overread]
  216 |                 client->away = strndup(DEFAULT_AWAY_MSG, CLIENT_AWAY_LEN - 1);
      |                                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

7 months agoVarious fixes and enhancements for the "Autojoin" patch
Alexander Barton [Sun, 17 Sep 2023 17:38:53 +0000 (19:38 +0200)]
Various fixes and enhancements for the "Autojoin" patch

- Bring sample-ngircd.conf and ngircd.conf.5 description in line.
- Fix configuration parsing, it always showed the 'Unknown variable
  "Autojoin"' error message, even when everything was perfectly fine.
- And fix a build error (at least on macOS with Apple Clang 14):
    login.c:234:3: error: call to undeclared function 'IRC_JOIN'; ISO
    C99 and later do not support implicit function declarations
    [-Wimplicit-function-declaration]
       IRC_JOIN(Client, &Req);
       ^
  The #include for the "irc.channel.h" header was missing!
- Remove a unused variable that caused a compiler warning:
    login.c:222:12: warning: unused variable 'n' [-Wunused-variable]
       size_t i, n, channel_count = array_length(&Conf_Channels, sizeof(*conf_chan));
                 ^
- Add a explicit cast to fix a compiler warning:
    login.c:235:15: warning: assigning to 'char *' from 'const char[51]'
    discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
       Req.argv[0] = conf_chan->name;
                   ^ ~~~~~~~~~~~~~~~

7 months agoChannel autojoin functionality
Ivan Agarkov [Sun, 13 Dec 2020 18:57:41 +0000 (21:57 +0300)]
Channel autojoin functionality

9 months ago2023!
Alexander Barton [Thu, 3 Aug 2023 12:22:53 +0000 (14:22 +0200)]
2023!

9 months agoHide +i users on "WHOIS <pattern>"
Alexander Barton [Thu, 3 Aug 2023 08:57:27 +0000 (10:57 +0200)]
Hide +i users on "WHOIS <pattern>"

Let's behave like most(?) other IRC daemons (at least ircd2.11) and hide
all +i users when WHOIS is used with a pattern. Otherwise privacy of
this users is not guaranteed and the +i mode a bit useless ...

Reported by Cahata on #ngircd, thanks!

9 months agoUpdate the final "closing connection" message
Alexander Barton [Tue, 18 Jul 2023 09:45:01 +0000 (11:45 +0200)]
Update the final "closing connection" message

Add some more information (nick name, user name, host name) and bring it
in line with some other implementations (at least ircd2.11 and Hybrid).

9 months agoFix RPL_INVITING message: It must originate from the server
Alexander Barton [Tue, 18 Jul 2023 09:42:07 +0000 (11:42 +0200)]
Fix RPL_INVITING message: It must originate from the server

All numeric replies must originate from an IRC server, never from a
client. So fix the RPL_INVITING message!

Thanks tommyrot for reporting this!

Closes #307.

10 months agoEnhance log messages for refused connections
Alexander Barton [Wed, 5 Jul 2023 09:03:02 +0000 (11:03 +0200)]
Enhance log messages for refused connections

15 months agoconfigure.ng: Include <string.h> for memset in WORKING_GETADDRINFO probe
Florian Weimer [Thu, 2 Feb 2023 08:56:42 +0000 (09:56 +0100)]
configure.ng: Include <string.h> for memset in WORKING_GETADDRINFO probe

Otherwise, the probe always fails with compilers which do not
support implicit function declarations.

16 months agoAdd "+DEBUG" to the version string only when configured with --enable-debug
Alexander Barton [Mon, 2 Jan 2023 22:51:15 +0000 (23:51 +0100)]
Add "+DEBUG" to the version string only when configured with --enable-debug

The debug log messages are always available and a runtime option (since
commit c7de505c), but the assert()'s are only active when ngIRCd was
configured with the "--enable-debug" option.

So only add "+DEBUG" to the version string when the latter is the case.

16 months agoMake the debug loglevel always available
michi [Sun, 1 Jan 2023 12:12:54 +0000 (13:12 +0100)]
Make the debug loglevel always available

This basically means to unifdef DEBUG in (almost) all places.
We keep it in src/portab/portab.h so DEBUG stays available to
enable assert(). Also add a comment about this.

16 months agoBetter validate MODE +k & +l parameters and return errors
Alexander Barton [Mon, 2 Jan 2023 21:32:16 +0000 (22:32 +0100)]
Better validate MODE +k & +l parameters and return errors

Implement new numeric ERR_INVALIDMODEPARAM_MSG(696) and:

- Reject channel keys with spaces and return ERR_INVALIDMODEPARAM_MSG;
  This was possible until now and resulted in garbled IRC commands later.
- Reject empty channel keys and return ERR_INVALIDMODEPARAM_MSG;
  This was possible until now and resulted in garbled IRC commands later.
- Return ERR_INVALIDMODEPARAM_MSG when user limit is out of bounds;
  This was silently ignored until now.

Closes #290. Thanks Val Lorentz for reporting it!

16 months agoChannel modes +k & +l: Always report an error when a parameter is missing
Alexander Barton [Mon, 2 Jan 2023 20:42:04 +0000 (21:42 +0100)]
Channel modes +k & +l: Always report an error when a parameter is missing

This relates to #290 and considerations which errors to show when: and I
think it is the better approach to give feedback instead of silently
failing.

Note that this code path is also used when handling modes of channels
defined in "[Channel]" blocks in configuration files: in this case the
client is the local server and we can't send messages to it, because it
has no socket connection! Therefore we need those "is_machine" checks
and log an error im this case.

16 months agoRefactor Channel_Mode(), get rid of some nesting
Alexander Barton [Mon, 2 Jan 2023 20:25:28 +0000 (21:25 +0100)]
Refactor Channel_Mode(), get rid of some nesting

No functional changes.

16 months agoAllow ircops to use WHO on any channel.
michi [Tue, 23 Mar 2021 09:08:58 +0000 (10:08 +0100)]
Allow ircops to use WHO on any channel.

16 months agoRemove outdated macOS "Package Maker" configuration
Alexander Barton [Thu, 29 Dec 2022 17:03:10 +0000 (18:03 +0100)]
Remove outdated macOS "Package Maker" configuration

The tool is unavailable for many macOS versions and many years, so
remove all related files.

16 months agoWe no longer use Travis-CI, remove its configuration
Alexander Barton [Thu, 29 Dec 2022 15:48:50 +0000 (16:48 +0100)]
We no longer use Travis-CI, remove its configuration

16 months agoGitHub "ngIRCd CI" Action: Use sudo(8) when installing packages
Alexander Barton [Thu, 29 Dec 2022 15:01:52 +0000 (16:01 +0100)]
GitHub "ngIRCd CI" Action: Use sudo(8) when installing packages

16 months agoAdd "ngIRCd CI" GitHub Action
Alexander Barton [Thu, 29 Dec 2022 14:58:19 +0000 (15:58 +0100)]
Add "ngIRCd CI" GitHub Action

16 months agoRefactor join_send_topic() into IRC_Send_Channel_Info() and use it for JOIN and NJOIN... bug288-Send-NAMES-TOPIC-to-NJOINed-users
Alexander Barton [Mon, 26 Dec 2022 16:38:10 +0000 (17:38 +0100)]
Refactor join_send_topic() into IRC_Send_Channel_Info() and use it for JOIN and NJOIN handlers

This reduces code duplication and brings the order of messages on JOIN
and NJOIN in line.

Fixes #288.

16 months agoSend NAMES list and channel topic to NJOIN'ed users
ewired [Fri, 16 Apr 2021 18:28:00 +0000 (13:28 -0500)]
Send NAMES list and channel topic to NJOIN'ed users

Send the NAMES list and channel topic to users "forcefully" joined to a
channel using NJOIN, like they joined on their own using JOIN.

Closes #288.

16 months agoChannel mode setting: The local server is allowed to work on local channels
Alexander Barton [Mon, 26 Dec 2022 16:32:59 +0000 (17:32 +0100)]
Channel mode setting: The local server is allowed to work on local channels

Don't forbid the local server to change modes on local channels: this
happens when overriding modes on local (&) channels in the server
configuration file, for example, and is perfectly fine.

Without this patch, the server worked as expected but showed critical
error messages for each local channel in its configuration file:

  "Got remote MODE command for local channel!? Ignored."

16 months agoUpdate Xcode project for latest Xcode version (14.2)
Alexander Barton [Sun, 25 Dec 2022 14:53:36 +0000 (15:53 +0100)]
Update Xcode project for latest Xcode version (14.2)

16 months agoREADME.md: Update "status" section, remove "is being actively developed" ...
Alexander Barton [Sun, 25 Dec 2022 14:20:00 +0000 (15:20 +0100)]
README.md: Update "status" section, remove "is being actively developed" ...

16 months agoSpelling fixes, mostly in file comments
Alexander Barton [Sun, 25 Dec 2022 14:16:31 +0000 (15:16 +0100)]
Spelling fixes, mostly in file comments

16 months agoUse "||" instead of "|"
hello-smile6 [Wed, 14 Dec 2022 20:33:03 +0000 (12:33 -0800)]
Use "||" instead of "|"

16 months agoFix gline/kline with cloaked hostnames
9pfs [Tue, 13 Dec 2022 00:47:53 +0000 (00:47 +0000)]
Fix gline/kline with cloaked hostnames

16 months agoConvert uses of Log(LOG_DEBUG, ...) to LogDebug()
Jules Maselbas [Tue, 26 Apr 2022 13:41:28 +0000 (15:41 +0200)]
Convert uses of Log(LOG_DEBUG, ...) to LogDebug()

18 months agoImprove documentation for --syslog
Katherine Peeters [Tue, 1 Nov 2022 23:21:56 +0000 (16:21 -0700)]
Improve documentation for --syslog

18 months agofix typo in conn.c
salaaad2 [Thu, 27 May 2021 16:19:30 +0000 (18:19 +0200)]
fix typo in conn.c

18 months agoAdded command line flag to enable syslog
Katherine Peeters [Sun, 30 Oct 2022 04:46:46 +0000 (21:46 -0700)]
Added command line flag to enable syslog

This allows -y / --syslog to be used to override -n / --nodaemon disabling it

18 months agoSplit NoSyslog from behaviour of NoDaemon
Katherine Peeters [Sun, 30 Oct 2022 04:33:18 +0000 (21:33 -0700)]
Split NoSyslog from behaviour of NoDaemon

Allows syslog to be enabled/disabled seperately from daemonization

2 years ago2022 =:)
Alexander Barton [Sat, 1 Jan 2022 15:05:09 +0000 (16:05 +0100)]
2022 =:)

Happy new year!

2 years agoFix a possible race condition in Client_Introduce()
Alexander Barton [Thu, 30 Dec 2021 19:31:41 +0000 (20:31 +0100)]
Fix a possible race condition in Client_Introduce()

Conf_GetServer() can return NULL when the server introducing the client
had a write error for example, and is being disconnected.

So make sure that we have a valid server before calling Conf_NickIsService()!

2 years agoEnhance documentation a bit, add doc/QuickStart.md
Alexander Barton [Thu, 30 Dec 2021 19:01:44 +0000 (20:01 +0100)]
Enhance documentation a bit, add doc/QuickStart.md

And this file could well be expanded!

2 years agodoc/HowToRelease.txt: "dist-tarZ" and "dist-xz" make targets can't be combined
Alexander Barton [Sun, 31 Oct 2021 12:41:20 +0000 (13:41 +0100)]
doc/HowToRelease.txt: "dist-tarZ" and "dist-xz" make targets can't be combined

3 years agongIRCd Release 26.1 rel-26.1
Alexander Barton [Sat, 2 Jan 2021 13:32:48 +0000 (14:32 +0100)]
ngIRCd Release 26.1

3 years agoUpdate AUTHORS file
Alexander Barton [Sat, 2 Jan 2021 13:23:45 +0000 (14:23 +0100)]
Update AUTHORS file

3 years agoUpdate config.guess and config.sub to recent versions
Alexander Barton [Sat, 2 Jan 2021 12:36:45 +0000 (13:36 +0100)]
Update config.guess and config.sub to recent versions

- config.guess: 2020-12-22
- config.sub: 2020-12-22

3 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Fri, 1 Jan 2021 19:07:47 +0000 (20:07 +0100)]
Update NEWS and ChangeLog files

3 years agoUpdate Platforms.txt
Alexander Barton [Fri, 1 Jan 2021 15:12:46 +0000 (16:12 +0100)]
Update Platforms.txt

- Add aarch64/apple/darwin (Apple CLang 12.0.0)
- Add x86_64/unknown/openbsd6.7 (gcc 4.2.1)

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

3 years ago2021! :-)
Alexander Barton [Fri, 1 Jan 2021 14:38:26 +0000 (15:38 +0100)]
2021! :-)

Happy new year!

3 years agoExplicitely cast Conf_MaxPenaltyTime (time_t) to "long"
Alexander Barton [Tue, 29 Dec 2020 20:45:09 +0000 (21:45 +0100)]
Explicitely cast Conf_MaxPenaltyTime (time_t) to "long"

This fixes the following compiler warning, for example on OpenBSD:

  conf.c: In function 'Conf_Test':
  conf.c:391: warning: format '%ld' expects type 'long int', but argument
                       2 has type 'time_t'

Thanks to Götz Hoffart for reporting this!

3 years agoDon't set AI_ADDRCONFIG, even when it exists
Alexander Barton [Tue, 29 Dec 2020 20:12:43 +0000 (21:12 +0100)]
Don't set AI_ADDRCONFIG, even when it exists

Basically, the issue described in #281 is that the test suite uses the
IPv4 address 127.0.0.1 on an IPv6-only host. But this is the "safest"
thing to do in (almost) all other setups: relaying on DNS host names
makes things even more complex, as different systems map 127.0.0.1
differently (including the reverse lookup; that's why we switched to
127.0.0.1 back in 2014, see commit 3f807e10457).

But with AI_ADDRCONFIG set, on an IPv6-only host, we prevent 127.0.0.1
to get translated properly, even when the loopback interface has this
address configured! So don't set it any more.

The drawback is that the resolver possibly returns more addresses now,
even of an unsupported/not connected address family; but this shouldn't
do much harm in practice, as ngIRCd iterates over all returned addresses
while trying to establish an outgoing connection.

Closes #281.

3 years agoFAQ.txt: There is no "CVS" anymore, we use Git!
Alexander Barton [Sat, 28 Nov 2020 20:21:47 +0000 (21:21 +0100)]
FAQ.txt: There is no "CVS" anymore, we use Git!

3 years agoFix typo in comment: operaor -> operator
Rolf Eike Beer [Sun, 1 Nov 2020 17:00:22 +0000 (18:00 +0100)]
Fix typo in comment: operaor -> operator

3 years agoRevert "Show allowed channel types in ISUPPORT(005) numeric only"
Alexander Barton [Mon, 2 Nov 2020 10:45:41 +0000 (11:45 +0100)]
Revert "Show allowed channel types in ISUPPORT(005) numeric only"

The ISUPPORT(005) numeric lists only channel prefixes which are listed
in the "AllowedChannelTypes" configuration option. And if this is the
empty string ("") for example, this now results in IRC clients assuming
"oh, no channel prefix characters at all, so no channels at all, so no
PRIVMSG can go to any channel" -- which is not the case when there are
pre-defined channel set up or other servers still having channels!

So "allowed channel types" != "supported channel types", and we always
have to list all supported ones in the ISUPPORT(005) numeric!

This reverts commit 4b7e8db418340576c95f1edad8470b66d6fe886d.

Closes #285.

3 years agoTest suite: Wait 2 seconds after reloading the daemon
Alexander Barton [Sun, 1 Nov 2020 16:25:39 +0000 (17:25 +0100)]
Test suite: Wait 2 seconds after reloading the daemon

On reload, all listening ports are closed, configuration updated, and
then opened again. Which leads to subsequent tests running while the
daemon isn't listening on any ports, and that's why the tests fail.

The "proper" way whould be to loop and check for open ports, but waiting
is what the start-server.sh script does right now, so stick with this in
reload-server.sh for now as well.

This fixes the issue, at least on my RaspberryPi ...

Closes #280.

3 years agoUpdate Platforms.txt
Alexander Barton [Tue, 20 Oct 2020 19:48:16 +0000 (21:48 +0200)]
Update Platforms.txt

- Update powerpc/apple/darwin8.11.0 (gcc 4.0.1)
- Add x86_64/apple/darwin19.6.0 (Apple clang 12.0.0)
- Add x86_64/unknown/freebsd12.1 (FreeBSD clang 8.0.1)
- Update x86_64/pc/linux-gnu (gcc 8.3.0)
- Add x86_64/unknown/netbsd9.0 (gcc 7.4.0)
- Add x86_64/unknown/openbsd6.6 (gcc 4.2.1)
- Add x86_64/unknown/openbsd6.6 (OpenBSD clang 8.0.1)

Thanks to Götz Hoffart <goetz@hoffart.de> for the PowerPC test!

3 years agoplatformtest.sh: Try to mangle CLang name more intellligently
Alexander Barton [Tue, 20 Oct 2020 19:47:10 +0000 (21:47 +0200)]
platformtest.sh: Try to mangle CLang name more intellligently

3 years agoFixed Atheme Links
xnaas [Tue, 4 Aug 2020 03:17:04 +0000 (22:17 -0500)]
Fixed Atheme Links

.org and not .net

3 years agongIRCd Release 26 rel-26
Alexander Barton [Sat, 20 Jun 2020 13:54:19 +0000 (15:54 +0200)]
ngIRCd Release 26

3 years agoINSTALL.md: Add instructions for ArchLinux (pacman)
Alexander Barton [Sat, 20 Jun 2020 13:54:02 +0000 (15:54 +0200)]
INSTALL.md: Add instructions for ArchLinux (pacman)

3 years agongIRCd Release 26~rc2 rel-26-rc2
Alexander Barton [Thu, 11 Jun 2020 15:22:08 +0000 (17:22 +0200)]
ngIRCd Release 26~rc2

3 years agoUpdate NEWS, ChangeLog and doc/Platforms.txt files
Alexander Barton [Thu, 11 Jun 2020 15:13:06 +0000 (17:13 +0200)]
Update NEWS, ChangeLog and doc/Platforms.txt files

3 years agoAdd AppStream metadata file: contrib/de.barton.ngircd.metainfo.xml
Alexander Barton [Thu, 11 Jun 2020 15:11:15 +0000 (17:11 +0200)]
Add AppStream metadata file: contrib/de.barton.ngircd.metainfo.xml

3 years agoDon't send invalid CHANINFO commands when no key is set
Alexander Barton [Thu, 11 Jun 2020 14:45:30 +0000 (16:45 +0200)]
Don't send invalid CHANINFO commands when no key is set

It can happen that a channel is +k, but no key is set: for example by
misconfiguring a pre-defined channel. In this case, ngIRCd sent an
invalud CHANINFO command ("CHANINFO #test +Pk  0 :'", note the unset
key represented by the two spaces) to its peers.

Fix this and enhance the CHANINFO documentation.

3 years agoUpdate NEWS and ChangeLog files
Alexander Barton [Sun, 31 May 2020 17:38:59 +0000 (19:38 +0200)]
Update NEWS and ChangeLog files

3 years agoUpdate description text in manual page, too!
Alexander Barton [Tue, 26 May 2020 21:00:25 +0000 (23:00 +0200)]
Update description text in manual page, too!

3 years agongircd.spec: Fix name of README.md and INSTALL.md
Alexander Barton [Tue, 26 May 2020 17:55:01 +0000 (19:55 +0200)]
ngircd.spec: Fix name of README.md and INSTALL.md

3 years agoUpdate description texts
Alexander Barton [Tue, 26 May 2020 17:43:11 +0000 (19:43 +0200)]
Update description texts

Bring them in line with the updated texts on the homepage.

3 years agoIRC_SQUIT(): Fix use-after-free when unregistering the sending client
Alexander Barton [Mon, 25 May 2020 22:05:22 +0000 (00:05 +0200)]
IRC_SQUIT(): Fix use-after-free when unregistering the sending client

3 years agoIRC_SERVER: Make sure that the client sent a prefix
Alexander Barton [Mon, 25 May 2020 21:43:29 +0000 (23:43 +0200)]
IRC_SERVER: Make sure that the client sent a prefix

The SERVER command is only valid with a prefix when received from other
servers, so make sure that there is one and disconnect the peer if not
(instead of crashing ...).

This obsoletes PR #275.

Thanks Hilko Bengen (hillu) for finding & reporting this as well for the
patch & pull request! But I think this is the "more correct" fix.

3 years agoEnhance debug logging for PONG commands
Alexander Barton [Mon, 25 May 2020 21:30:07 +0000 (23:30 +0200)]
Enhance debug logging for PONG commands

Distinguish between expected and unexpected PONG commands.

3 years agoFix PING-PONG handling when processing backlog in read buffers
Alexander Barton [Mon, 25 May 2020 17:02:16 +0000 (19:02 +0200)]
Fix PING-PONG handling when processing backlog in read buffers

Prior to this commit, the PONG wasn't registered correctly, becauuse the
"last ping" time was set to time(NULL), which could be bigger than the
"last data" time stamp, for example when handling the read buffer took
more than 1 second -- and this resulted in the PONG time out kicking in
effectively disconnecting a newly linked server for example, because
ngIRCd thought it was still waiting for a PONG: last data < last ping.

Now the "last ping" value has three possible values:

    0: new connection, no PING, no PONG so far.
    1: got a PONG, no longer waiting for a PONG.
  <t>: time stamp of last sent out PING command.

3 years agoRevert "Set the "last data" time to "last ping" time when updating the latter"
Alexander Barton [Sun, 24 May 2020 21:24:51 +0000 (23:24 +0200)]
Revert "Set the "last data" time to "last ping" time when updating the latter"

This patch completely broke the PING-PONG logic: now ngIRCd never
disconnects any stale peers but keeps sending out PINGs over and over
again ...

The real issue (server disconnects right after connect) will be fixed in
the next commit, but let's revert to the somewhat "half-broken but
'known' state" first ...

This reverts commit 79a917f954bef8089967786bd3597a6e5ff5c336.

3 years agotestsuite: Add missing files to EXTRA_DIST
Hilko Bengen [Fri, 22 May 2020 10:29:09 +0000 (12:29 +0200)]
testsuite: Add missing files to EXTRA_DIST

26~rc1 as extracted from tarball cannot be built/tested with SSL
support because of a missing script and certificates.

3 years agongIRCd Release 26~rc1 rel-26-rc1
Alexander Barton [Sun, 10 May 2020 15:13:51 +0000 (17:13 +0200)]
ngIRCd Release 26~rc1