~sircmpwn/sr.ht-discuss

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
5 4

Encrypted mail payloads have no encoding set => non-ASCII renders mangled?

Details
Message ID
<4uxbrlspm45s5i4bhhmqgmry374i22oqcxedtowda5zrzd7bpf2@5pyosds5owty>
DKIM signature
missing
Download raw message
Notifications from todo.sr.ht look like:

[-- The following data is PGP/MIME signed and encrypted --]

Ticket resolved: fixed

*?????? referenced this ticket in commit [91b3272].*

[91b3272]:
https://git.sr.ht/~nabijaczleweli/urlview-ng/commit/91b3272 "Beep on
unknown KEY_CODEs instead of passing them as chars"

--
View on the web: https://todo.sr.ht/~nabijaczleweli/urlview-ng/5#event-261404

[-- End of PGP/MIME signed and encrypted data --]

Which is Not Great.

Attaching the problematic mail raw,
and the problematic mail how neomutt attached it with attach-message
(decoded and reassembled as-if it hadn't been encrypted).

The raw decrypted body is
-- >8 --
$ gpg -d < raw
gpg: encrypted with 4096-bit RSA key, ID ED46733532B811FB, created 2015-08-23
      "наб <nabijaczleweli@nabijaczleweli.xyz>"
Mime-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain

Ticket resolved: fixed

*=D0=BD=D0=B0=D0=B1 referenced this ticket in commit [91b3272].*

[91b3272]:=20
https://git.sr.ht/~nabijaczleweli/urlview-ng/commit/91b3272 "Beep on=20
unknown KEY_CODEs instead of passing them as chars"

--=20
View on the web: https://todo.sr.ht/~nabijaczleweli/urlview-ng/5#event-2614=
04
gpg: Signature made Sun 01 Oct 2023 05:17:21 CEST
gpg:                using RSA key 447B69E4B34BE90BC829A0E9659704D1A38A93AE
gpg: Good signature from "sr.ht dispatch (Address for automated emails from dispatch.sr.ht) <dispatch@sr.ht>" [unknown]
gpg:                 aka "sr.ht <admin@sr.ht>" [unknown]
gpg:                 aka "sr.ht outgoing (General purpose outgoing sr.ht address) <outgoing@sr.ht>" [unknown]
gpg:                 aka "sr.ht todo (Address for automated emails from todo.sr.ht) <todo@sr.ht>" [unknown]
gpg:                 aka "sr.ht builds (Address for automated emails from builds.sr.ht) <builds@sr.ht>" [unknown]
gpg:                 aka "sr.ht git (Address for automated emails from git.sr.ht) <git@sr.ht>" [unknown]
gpg:                 aka "sr.ht meta (Address for automated emails from meta.sr.ht) <meta@sr.ht>" [unknown]
gpg: WARNING: This key is not certified with a trusted signature!
gpg:          There is no indication that the signature belongs to the owner.
Primary key fingerprint: 447B 69E4 B34B E90B C829  A0E9 6597 04D1 A38A 93AE
-- >8 --
which sure as hell doesn't look like it's got "utf-8" in there anywhere?

(Note how the message Subject (not encrypted) isn't RFC2047-encoded either:
   Subject: Re: ~nabijaczleweli/urlview-ng#5: Mousing around while editing URL inserts ƙ
 (so if I were using outlook I'd be hosed but I'm not so who cares).
 Still.

 Oddly, in the bounce mail I got from the first time I sent this with
 the attachments message/rfc822, the To: is fully-RFC2047-encoded.
 So idk.)

Best,
наб
Details
Message ID
<CVXSFTT0E0I0.38FDTX9FCZZTV@taiga>
In-Reply-To
<4uxbrlspm45s5i4bhhmqgmry374i22oqcxedtowda5zrzd7bpf2@5pyosds5owty> (view parent)
DKIM signature
missing
Download raw message
The mail code is all routed through one codepath in meta.sr.ht's GraphQL
API, should be relatively easy to narrow down and patch.

[PATCH core-go] email: EnqueueStd: set Content-Type with charset=UTF-8 instead of just text/plain

Details
Message ID
<puy5qcrndo7tevfn235xwiklgofhj3n66fcjqwswq6y62dg3bp@2ybhqj3backt>
In-Reply-To
<CVXSFTT0E0I0.38FDTX9FCZZTV@taiga> (view parent)
DKIM signature
missing
Download raw message
Patch: +1 -1
Mails are now
	--11d2cbf164a9ae0dfbb310faf818762607dcfd20aa74e07c7be0eec1458d
	Mime-Version: 1.0
	Content-Transfer-Encoding: quoted-printable
	Content-Type: text/plain; charset=UTF-8
	
	=D1=82=D1=80=D1=83=D0=BF=D0=B08
	
	--=20
	View on the web: http://192.168.1.101:5003/~nab2/trupa/8
	--11d2cbf164a9ae0dfbb310faf818762607dcfd20aa74e07c7be0eec1458d
	Content-Type: application/pgp-signature
	
	-----BEGIN PGP MESSAGE-----
	
	wnUEARYIACcFAmUavj0JkKdioLsBS5scFiEE+ts/9LaoXcZuSmrHp2KguwFLmxwA
	AIm9AP9KB4cZyiby7jiiRMRESDeJXrdb4kNqyA3D3nVOt14bKgD/UiDfUKE1MwiV
	pOqj/S0wiJdChKW52zRAkwuQ7PtKkgI=
	=AiY9
	-----END PGP MESSAGE-----
	--11d2cbf164a9ae0dfbb310faf818762607dcfd20aa74e07c7be0eec1458d--
which is correct, and decodes correctly in neomutt.

Fixes: https://lists.sr.ht/~sircmpwn/sr.ht-discuss/%3C4uxbrlspm45s5i4bhhmqgmry374i22oqcxedtowda5zrzd7bpf2%405pyosds5owty%3E
---
Subject is also
  Subject: =?utf-8?q?~nab2/trupa#8:_=D1=82=D1=80=D1=83=D0=BF=D0=B08?=
for that mail, so all appears to be fine.

 email/worker.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/email/worker.go b/email/worker.go
index 288b3e0..9e2a004 100644
--- a/email/worker.go
+++ b/email/worker.go
@@ -142,7 +142,7 @@ func EnqueueStd(ctx context.Context, header mail.Header,
	defer cleartext.Close()

	var inlineHeader mail.Header
	inlineHeader.SetContentType("text/plain", nil)
	inlineHeader.SetContentType("text/plain", map[string]string{"charset": "UTF-8"})
	body, err := mail.CreateSingleInlineWriter(cleartext, inlineHeader)
	if err != nil {
		panic(err)
-- 
2.39.2

[core-go/patches/alpine.yml] build failed

builds.sr.ht <builds@sr.ht>
Details
Message ID
<CVXZGEL56CPU.11TT2SEUB6GIQ@cirno2>
In-Reply-To
<puy5qcrndo7tevfn235xwiklgofhj3n66fcjqwswq6y62dg3bp@2ybhqj3backt> (view parent)
DKIM signature
missing
Download raw message
core-go/patches/alpine.yml: FAILED in 58s

[Encrypted mail payloads have no encoding set => non-ASCII renders mangled?][0] from [наб][1]

[0]: https://lists.sr.ht/~sircmpwn/sr.ht-discuss/patches/45286
[1]: nabijaczleweli@nabijaczleweli.xyz

✗ #1066950 FAILED core-go/patches/alpine.yml https://builds.sr.ht/~sircmpwn/job/1066950

Re: [PATCH core-go] email: EnqueueStd: set Content-Type with charset=UTF-8 instead of just text/plain

Details
Message ID
<CiOkjLFf0Atm0cxsxzIYTNqgoKPX2sW-yJoZT5LxvDt3NSG8KO2Xvb8Ldpdg1XWMwFKqJosaHF4n3H4TCAuat-w756XL-Djw3oAoGNs6R7w=@emersion.fr>
In-Reply-To
<puy5qcrndo7tevfn235xwiklgofhj3n66fcjqwswq6y62dg3bp@2ybhqj3backt> (view parent)
DKIM signature
missing
Download raw message
LGTM

Re: [PATCH core-go] email: EnqueueStd: set Content-Type with charset=UTF-8 instead of just text/plain

Details
Message ID
<CVZP8RG0ZUU0.KO8ENQAGLAZQ@taiga>
In-Reply-To
<puy5qcrndo7tevfn235xwiklgofhj3n66fcjqwswq6y62dg3bp@2ybhqj3backt> (view parent)
DKIM signature
missing
Download raw message
Thanks!

To git@git.sr.ht:~sircmpwn/core-go
   65b1657..bf4fe19  master -> master
Reply to thread Export thread (mbox)