🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #265973

Getting MIME headers right (was: I'm hacking on trn...want to join me?)

#265973
From: Richard
Date: Wed, 12 Apr 2023 15:36
38 lines
2970 bytes
[Please do not mail me a copy of your followup]

Michael =?ISO-8859-1?Q?B=E4uerle?= <michael.baeuerle@gmx.net> spake the secret code
<AABkNrMFcqkAAAFo.A3.flnews@WStation5.stz-e.de> thusly:

>I think such mistakes would not occur if trn would automatically convert
>the content to quote into the encoding used by the editor.
>The source encoding is declared in the MIME header of the article.

The source encoding *MAY* be declared in the MIME header of the article.
There's no guarantee that it actually is declared as such.  We've
already stated that malformed messages can be injected into news due
to user error (e.g. they didn't configure their editor to add
appropriate MIME headers).

>The target encoding should be the one the editor is using (manually
>configured, if trn cannot automatically detect it).

How can trn know anything about your editor?  It's entirely outside of
trn's control.

>The conversion itself can be done with iconv.

This is a unix-centric assumption.  It *could* be done with iconv.

>If the user has configured e.g. US-ASCII to quote an article written in
>Unicode, replacement characters should be inserted if the encoding
>conversion is not possible (instead of simply copying the bytes that are
>then interpreted wrong by the editor and the recipients).

All of this seems outside the control of trn and mostly a consequence
of how you edit the article.  The existing NEWSPOSTER environment variable
can be configured to a script that would do all that you propose.
-- 
"The Direct3D Graphics Pipeline" free book <http://tinyurl.com/d3d-pipeline>
            The Terminals Wiki <http://terminals-wiki.org>
     The Computer Graphics Museum <http://computergraphicsmuseum.org>
  Legalize Adulthood! (my blog) <http://legalizeadulthood.wordpress.com>
Technical Details
Message-ID: <u16j67$29qek$1@news.xmission.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
References: <u0ffth$1u1oi$1@news.xmission.com> <u141o0$28gtp$1@news.xmission.com> <u143j5$2m3va$4@dont-email.me> <AABkNrMFcqkAAAFo.A3.flnews@WStation5.stz-e.de>

Show Full Headers
Complete Article Headers
Message-ID: <u16j67$29qek$1@news.xmission.com>
Subject: Getting MIME headers right (was: I'm hacking on trn...want to join me?)
Date: Wed, 12 Apr 2023 15:36:39 +0000
From: legalize+jeeves@mail.xmission.com (Richard)
References: <u0ffth$1u1oi$1@news.xmission.com> <u141o0$28gtp$1@news.xmission.com> <u143j5$2m3va$4@dont-email.me> <AABkNrMFcqkAAAFo.A3.flnews@WStation5.stz-e.de>
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.readers
Organization: multi-cellular, biological
Sender: legalize+jeeves@mail.xmission.com
Reply-To: (Richard) legalize+jeeves@mail.xmission.com
Injection-Date: Wed, 12 Apr 2023 15:36:39 -0000 (UTC)
Injection-Info: news.xmission.com; posting-host="shell.xmission.com:2607:fa18:0:beef::4"; logging-data="2419156"; mail-complaints-to="abuse@xmission.com"
X-Reply-Etiquette: No copy by email, please
Mail-Copies-To: never
X-Newsreader: trn 4.0-test77 (Sep 1, 2010)
Originator: legalize@shell.xmission.com (Richard)