Skip to content

config: Add DisallowIgateCall to drop packets by igate call or Q construct - #100

Merged
hessu merged 4 commits into
mainfrom
feature/disallow
Jul 5, 2026
Merged

config: Add DisallowIgateCall to drop packets by igate call or Q construct#100
hessu merged 4 commits into
mainfrom
feature/disallow

Conversation

@hessu

@hessu hessu commented Jul 4, 2026

Copy link
Copy Markdown
Owner

Add a DisallowIgateCall option (config.c/config.h), accepting a glob list
like DisallowSourceCall and DisallowLoginCall. incoming.c checks every
comma-delimited field from the Q construct (q_start) to path_end against
disallow_igate_glob after q_process, so a configured glob can drop based on
the igate/receiver callsigns or on the Q construct itself (e.g. qAY).

Add drop tests in tests/t/11misc-d

hessu added 4 commits July 5, 2026 00:28
…truct

Add a DisallowIgateCall option (config.c/config.h), accepting a glob list
like DisallowSourceCall and DisallowLoginCall. incoming.c checks every
comma-delimited field from the Q construct (q_start) to path_end against
disallow_igate_glob after q_process, so a configured glob can drop based on
the igate/receiver callsigns or on the Q construct itself (e.g. qAY).

Add drop tests in tests/t/11misc-drops.t with a DisallowIgateCall list in
tests/cfg-aprsc/basic.
The configure test for the one-argument (macOS) pthread_setname_np signature
included <pthread.h> without _GNU_SOURCE. On glibc the function is then not
declared, so the single-argument call compiled as an implicit declaration
(a warning, not an error, on older gcc) and HAVE_PTHREAD_SETNAME_NP_MACOS was
wrongly defined. hlog.c, which does define _GNU_SOURCE, then compiled the
one-argument branch against the real two-argument prototype and failed with
"too few arguments to function pthread_setname_np".

Define _GNU_SOURCE in the test (as hlog.c does) so glibc exposes the
two-argument prototype and the single-argument call becomes a hard error,
and compile the test with -Werror so an implicit declaration is fatal too.
Now the macOS signature is detected only where it actually applies.

Regenerate configure with autoreconf.
Commit fb006f9 rejects logins where the software name and version are not
separated by a space (the filter/udp keyword or nothing ends up as the
version number). Known-broken clients handled in quirks mode often send just
an application name with no version, so this rejected them before quirks mode
was ever established - breaking t/12quirks-mode.t, whose HR-IXPWINDi-123
client is on the quirks blacklist.

Determine the app name (and thus quirks-mode status) before applying the
check, and skip the rejection for quirks-mode clients. This also avoids a
latent out-of-bounds read of argv[i+2] when the version was missing.
@hessu
hessu merged commit 7ddd088 into main Jul 5, 2026
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant