Skip to content
New issue

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

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

Already on GitHub? # to your account

Posting creates 8bit articles with no QP or MIME headers #19

Open
acli opened this issue Aug 7, 2020 · 3 comments
Open

Posting creates 8bit articles with no QP or MIME headers #19

acli opened this issue Aug 7, 2020 · 3 comments
Labels
bug Something isn't working

Comments

@acli
Copy link
Owner

acli commented Aug 7, 2020

So posting an article containing non-ASCII characters will produce posts that are technically invalid and will potentially cause problems with the patched trn itself (once non-UTF8 output is supported).

@acli acli added the bug Something isn't working label Aug 7, 2020
@acli
Copy link
Owner Author

acli commented Aug 7, 2020

This is going to be a challenge. trn posts articles using Pnews, but Pnews is written in sh; it’d be tricky to do QP in sh.

Note: I reread the test articles I posted on aioe.test. The post with diacritics was incorrectly read as Latin1, so this is indeed confusing the patched trn itself.

@acli
Copy link
Owner Author

acli commented Aug 7, 2020

Temporary hack to make it technically semi-valid: d653d28

@Eli-the-Bearded
Copy link
Contributor

I've fixed Pnews and Rnmail for myself. I've got a sample of how I fixed Rnmail here: https://github.com/Eli-the-Bearded/eli-mailx/blob/master/rnmail.d/Rnmail because I also use Rnmail with mailx.

My technique is a tad naive. I have a program (part of that mailx package) that tests bit patterns for UTF-8, US-ASCII, and ISO-8859-1 compliance, setting an exit code. Then I check for a charset in the header and use the appropriate test. If out of compliance it warns the user, the same way long lines warn.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants