1
0
mirror of https://github.com/osmarks/ngircd.git synced 2024-10-27 20:36:18 +00:00
Commit Graph

3652 Commits

Author SHA1 Message Date
Alexander Barton
335ae4f0d0 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!
2023-08-03 10:57:27 +02:00
Alexander Barton
63ad3b9acd 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).
2023-07-18 11:45:01 +02:00
Alexander Barton
0035e0d778 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.
2023-07-18 11:42:07 +02:00
Alexander Barton
0f90a059b6 Enhance log messages for refused connections 2023-07-05 11:03:02 +02:00
Florian Weimer
0e678f766f 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.
2023-02-05 21:35:40 +01:00
Alexander Barton
50114cd017 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.
2023-01-02 23:51:15 +01:00
michi
c7de505c91 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.
2023-01-02 22:39:16 +01:00
Alexander Barton
8e9c789ae1 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!
2023-01-02 22:32:16 +01:00
Alexander Barton
3c9c54989e 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.
2023-01-02 21:48:42 +01:00
Alexander Barton
0ea1715d00 Refactor Channel_Mode(), get rid of some nesting
No functional changes.
2023-01-02 21:25:28 +01:00
michi
24f956abf7 Allow ircops to use WHO on any channel. 2023-01-02 21:17:29 +01:00
Alexander Barton
0652c99b39 Remove outdated macOS "Package Maker" configuration
The tool is unavailable for many macOS versions and many years, so
remove all related files.
2022-12-29 18:06:18 +01:00
Alexander Barton
a0576f4810 We no longer use Travis-CI, remove its configuration 2022-12-29 16:48:50 +01:00
Alexander Barton
1b186cf5a0
GitHub "ngIRCd CI" Action: Use sudo(8) when installing packages 2022-12-29 16:01:52 +01:00
Alexander Barton
b49bc98b83
Add "ngIRCd CI" GitHub Action 2022-12-29 15:58:19 +01:00
Alexander Barton
55744b1863 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.
2022-12-27 16:42:06 +01:00
ewired
5ef1a657f4 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.
2022-12-26 17:45:44 +01:00
Alexander Barton
3e23f7d2c3 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."
2022-12-26 17:32:59 +01:00
Alexander Barton
46081d619a Update Xcode project for latest Xcode version (14.2) 2022-12-25 15:54:59 +01:00
Alexander Barton
d605a0825a README.md: Update "status" section, remove "is being actively developed" ... 2022-12-25 15:20:00 +01:00
Alexander Barton
56ed5c90ad Spelling fixes, mostly in file comments 2022-12-25 15:16:31 +01:00
hello-smile6
7b30c352a1 Use "||" instead of "|" 2022-12-17 14:54:55 +01:00
9pfs
ea7ad914c8 Fix gline/kline with cloaked hostnames 2022-12-17 14:54:55 +01:00
Jules Maselbas
93e36555e3 Convert uses of Log(LOG_DEBUG, ...) to LogDebug() 2022-12-17 14:52:44 +01:00
Katherine Peeters
dc412a450e
Improve documentation for --syslog 2022-11-01 16:21:56 -07:00
salaaad2
b0caf5984e fix typo in conn.c 2022-11-01 17:38:38 +01:00
Katherine Peeters
8f6d04095b
Added command line flag to enable syslog
This allows -y / --syslog to be used to override -n / --nodaemon disabling it
2022-10-29 21:46:46 -07:00
Katherine Peeters
2debc2e833
Split NoSyslog from behaviour of NoDaemon
Allows syslog to be enabled/disabled seperately from daemonization
2022-10-29 21:33:18 -07:00
Alexander Barton
79ffa9132b 2022 =:)
Happy new year!
2022-01-01 16:05:09 +01:00
Alexander Barton
1db3447c90 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()!
2021-12-30 20:31:41 +01:00
Alexander Barton
3675c7567c Enhance documentation a bit, add doc/QuickStart.md
And this file could well be expanded!
2021-12-30 20:01:44 +01:00
Alexander Barton
97ffec3d64 doc/HowToRelease.txt: "dist-tarZ" and "dist-xz" make targets can't be combined 2021-10-31 13:41:20 +01:00
Alexander Barton
71ae2b7d7f ngIRCd Release 26.1 2021-01-02 14:32:48 +01:00
Alexander Barton
65558a46e5 Update AUTHORS file 2021-01-02 14:23:45 +01:00
Alexander Barton
afb17ff08e Update config.guess and config.sub to recent versions
- config.guess: 2020-12-22
- config.sub: 2020-12-22
2021-01-02 13:36:45 +01:00
Alexander Barton
cbd8e5b5d6 Update NEWS and ChangeLog files 2021-01-01 20:07:47 +01:00
Alexander Barton
dc832cd348 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>
2021-01-01 20:03:58 +01:00
Alexander Barton
2ff76d7f48 2021! :-)
Happy new year!
2021-01-01 15:38:26 +01:00
Alexander Barton
f3c89af845 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!
2020-12-29 21:45:09 +01:00
Alexander Barton
d777ce6600 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 3f807e1045).

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.
2020-12-29 21:12:43 +01:00
Alexander Barton
5ccdb26885 FAQ.txt: There is no "CVS" anymore, we use Git! 2020-11-28 21:22:34 +01:00
Rolf Eike Beer
c7781cf7ef Fix typo in comment: operaor -> operator 2020-11-02 12:13:02 +01:00
Alexander Barton
2056de82ae 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 4b7e8db418.

Closes #285.
2020-11-02 11:45:41 +01:00
Alexander Barton
5cf0eabd84 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.
2020-11-01 17:25:39 +01:00
Alexander Barton
6e382889a3 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!
2020-10-20 21:48:16 +02:00
Alexander Barton
e699325fd0 platformtest.sh: Try to mangle CLang name more intellligently 2020-10-20 21:47:10 +02:00
xnaas
0ae158a492 Fixed Atheme Links
.org and not .net
2020-08-04 13:44:58 +02:00
Alexander Barton
0f717bfd77 ngIRCd Release 26 2020-06-20 15:54:19 +02:00
Alexander Barton
ed9d8e7950 INSTALL.md: Add instructions for ArchLinux (pacman) 2020-06-20 15:54:02 +02:00
Alexander Barton
4bcf4613f9 ngIRCd Release 26~rc2 2020-06-11 17:22:08 +02:00