Article View: news.software.nntp
Article #90199Re: Seeking help modifying Diablo source to prevent miscategorization of articles containing PGP
From: Russ Allbery
Date: Tue, 21 Mar 2023 01:05
Date: Tue, 21 Mar 2023 01:05
29 lines
2351 bytes
2351 bytes
Jesse Rehmer <jesse.rehmer@blueworldhosting.com> writes:
> linetype = classifyLineAsTypes(ptr, len);
> if (*ptr == '-' &&
> strncmp(ptr, "-----BEGIN PGP ", 15) == 0)
> Type |= ARTTYPE_PGPMESSAGE;
> return(Type);
Just FYI, by doing it this way you are allowing people to send you
arbitrarily large binaries (up to your article size limit) by just adding
a line starting with "-----BEGIN PGP " before the encoded binary. This is
likely why the code didn't short-circuit analysis of the rest of the
article in that case and still flagged messages as binary if there were
more than 8 lines of encoded text. (No PGP *signature* should be that
long.)
Back in the day, if any change like this were used on a bunch of servers,
the people trading binaries that for legal reasons you really do not want
on your server would probably quickly start doing that. You're only
making this change on one server, and hopefully there isn't as much abuse
of binaries on Usenet these days, but you may still want to keep that in
mind.
--
Russ Allbery (eagle@eyrie.org) <https://www.eyrie.org/~eagle/>
Please post questions rather than mailing me directly.
<https://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Technical Details
Message-ID:
<87cz5252x5.fsf@hope.eyrie.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mailReferences:
<tv8ale$2t9m$1@nnrp.usenet.blueworldhosting.com> <tv9cuv$3ti$1@freeq.furie.org.uk> <tv9qce$dtq$1@nnrp.usenet.blueworldhosting.com> <tva24q$dcm$1@freeq.furie.org.uk> <tva4p3$2b2p$1@nnrp.usenet.blueworldhosting.com> <tvapdi$2ade$1@nnrp.usenet.blueworldhosting.com>Show Full Headers
Complete Article Headers
Message-ID: <87cz5252x5.fsf@hope.eyrie.org> Subject: Re: Seeking help modifying Diablo source to prevent miscategorization of articles containing PGP Date: Mon, 20 Mar 2023 18:05:58 -0700 From: Russ Allbery <eagle@eyrie.org> References: <tv8ale$2t9m$1@nnrp.usenet.blueworldhosting.com> <tv9cuv$3ti$1@freeq.furie.org.uk> <tv9qce$dtq$1@nnrp.usenet.blueworldhosting.com> <tva24q$dcm$1@freeq.furie.org.uk> <tva4p3$2b2p$1@nnrp.usenet.blueworldhosting.com> <tvapdi$2ade$1@nnrp.usenet.blueworldhosting.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail Newsgroups: news.software.nntp Organization: The Eyrie Mime-Version: 1.0 Content-Type: text/plain Injection-Info: hope.eyrie.org; logging-data="22737"; mail-complaints-to="news@eyrie.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) Cancel-Lock: sha1:0mrQHotuzljou4klz2incq5zKd0=