unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [bug?][notmuch-emacs] X11: renders Headers with face attributes
@ 2019-03-21  7:42 Gregor Zattler
  2019-03-25 12:54 ` David Bremner
  0 siblings, 1 reply; 2+ messages in thread
From: Gregor Zattler @ 2019-03-21  7:42 UTC (permalink / raw)
  To: notmuch

[-- Attachment #1: Type: text/plain, Size: 1248 bytes --]

Dear notmuch developers,

today I got a spam mail which's Subject: and From: header were
displayed as bold (with the exception of German umlauts) in
notmuch-emacs in a graphical frame (X11), they were displayed as
a string of hollow rectangles in a frame on a urxvt terminal (see
attached screen shots).  I see there are bold and italic
mathematical bold letters in Unicode.  The bold ones are used
here.

This are the headers in question:

Subject:=?UTF-8?B?IPCdl5jwnZe78J2YgfCdl7nwnZeu8J2YgPCdmIHwnZiC8J2Xu/Cdl7Qg8J2Xs8O88J2XvyDwnZeU8J2Xu/Cdl7TwnZey8J2XtcO28J2Xv/Cdl7bwnZe08J2XsiDwnZe28J2XuiDwnZen8J2Xv/Cdl67wnZiC8J2XsvCdl7/wnZez8J2XrvCdl7nwnZe5IA==?=
From:=?UTF-8?B?IPCdl6bwnZiB8J2XsvCdl7/wnZev8J2Xsi3wnZep8J2XvPCdl7/wnZiA8J2XvPCdl7/wnZe08J2XsiA=?=<2mH2r@0ytix511n5cb63oezbgj69wpm.com>

Is this a bug?  Should untrusted senders be allowed to influence
how headers are displayed?  I don't think so.  For me this case
should be handled as a homograph attack
(https://en.wikipedia.org/wiki/IDN_homograph_attack).

I do know there is character folding for searches but emacs would
need to use the reverse for displaying characters and only
characters which deviate in a way that is recognized as a font
attribute.

Thanks for your attention, Gregor

[-- Attachment #2: spam-in-urxvt.png --]
[-- Type: image/png, Size: 567 bytes --]

[-- Attachment #3: spam-graphical-frame-notmuch-show.png --]
[-- Type: image/png, Size: 14806 bytes --]

[-- Attachment #4: spam-graphical-frame-notmuch-search.png --]
[-- Type: image/png, Size: 4339 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [bug?][notmuch-emacs] X11: renders Headers with face attributes
  2019-03-21  7:42 [bug?][notmuch-emacs] X11: renders Headers with face attributes Gregor Zattler
@ 2019-03-25 12:54 ` David Bremner
  0 siblings, 0 replies; 2+ messages in thread
From: David Bremner @ 2019-03-25 12:54 UTC (permalink / raw)
  To: Gregor Zattler, notmuch

Gregor Zattler <telegraph@gmx.net> writes:

>
> Is this a bug?  Should untrusted senders be allowed to influence
> how headers are displayed?  I don't think so.  For me this case
> should be handled as a homograph attack
> (https://en.wikipedia.org/wiki/IDN_homograph_attack).

I'm not sure about the threat to the user here, but I agree that it
might make sense to normalize the subject at indexing time. 

>
> I do know there is character folding for searches but emacs would
> need to use the reverse for displaying characters and only
> characters which deviate in a way that is recognized as a font
> attribute.

I'm guessing this would be better handled at the notmuch CLI / library
level, where we have access to utf8 conversion facilities e.g. from
glib. It turns out that these kind of problems (related to locales) are
harder than one might expect.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-03-25 12:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-21  7:42 [bug?][notmuch-emacs] X11: renders Headers with face attributes Gregor Zattler
2019-03-25 12:54 ` David Bremner

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).