Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] main from InterNetNews:main #62

Merged
merged 5 commits into from
Jul 23, 2024
Merged

Conversation

pull[bot]
Copy link

@pull pull bot commented Jul 23, 2024

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

A bug about stripping IP options not working for IPv6 connections was
mentioned in the innd manual page.

Stripping IP options for IPv4 was a vestige introduced in INN 1.6b1
and already removed in INN 2.6.0 in 2014 when modernizing the network
library.

Anyway, even the initial code from INN 1.6b1 was incomplete and did
not prevent INN from being vulnerable to IP spoofing attacks with
source-routed TCP connections.

Other software that also does IP-based restrictions never bothers with
this: xinetd, for example, or the rsync server.  That implies that this
is no longer considered a significant security issue, probably because
it's been fixed upstream in the kernel network stack.

close #183
(more information in the ticket)
The current code only removes the first component
of the domain, which is not enough in some cases like
"ec2-13-236-155-204.ap-southeast-2.compute.amazonaws.com" and
"ec2-18-184-57-186.eu-central-1.compute.amazonaws.com" which would end
up in several lines gathered by AWS datacenters whereas we would just
want a report of AWS connections from "*.compute.amazonaws.com".

To improve the report, just keep up to the last 3 components of the
hostname.  (Some country code top-level domains have 2 components, like
".co.uk" so we need a minimum of 3 components, which looks fine during
my testings.)

Also, add code to correctly report IPv6 addresses as unresolved instead
of unknown.

close #305
Also improve (a bit) the name of the sections.  Notably, the stats by
domain are for all the connections and not only readership connections
(that is to say which are not "curious" connections, reported
afterwards, without any NNTP command related to reading or posting).
Elapsed times, read articles and groups, etc. were wrong in totals.

When innreport tags a reader as a curious one (that is to say a
connection which does not send NNTP commands for reading nor posting)
or finds out that the client did not manage to authenticate, it was
removed from the readership statistics by client but is still counted
in the statistics per domain.  Now fixed.

Also remove some unused variables while refactoring the related code.

close #306
It shouldn't have been committed, sorry.
@pull pull bot added the ⤵️ pull label Jul 23, 2024
@pull pull bot merged commit 6ef2828 into tabulon-ext:main Jul 23, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant