unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Austin Clements <aclements@csail.mit.edu>
To: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
Cc: notmuch mailing list <notmuch@notmuchmail.org>
Subject: Re: privacy problem: text/html parts pull in network resources
Date: Wed, 21 Jan 2015 17:39:09 -0500	[thread overview]
Message-ID: <20150121223909.GL22599@csail.mit.edu> (raw)
In-Reply-To: <87k30fq0hx.fsf@alice.fifthhorseman.net>

Quoth Daniel Kahn Gillmor on Jan 21 at  4:36 pm:
> On Wed 2015-01-21 16:14:07 -0500, Austin Clements wrote:
> > I have a fix for this on shr buried deep in an old patch series that I
> > never got back to: id:1398105468-14317-12-git-send-email-amdragon@mit.edu
> >
> > For shr, the key is to set shr-blocked-images to ".".
> 
> I've just done this, but it doesn't seem to help.
> 
> > However, IIRC, in the current notmuch message rendering pipeline, mm
> > overrides this variable with something computed from
> > gnus-blocked-images.  That said, I'm not sure why gnus-blocked-images
> > isn't *already* taking care of this, but that's probably the place to
> > start digging.
> 
> gnus-blocked-images is set for me to the function
> gnus-block-private-groups, but i don't know what that is (the function
> is undocumented afaict).  Setting gnus-blocked-images to a regexp of "."
> seems to work for me, though.

In notmuch, mm will wind up calling (gnus-block-private-groups nil).
Unfortunately, gnus apparently considers nil to be a news group rather
than a "private group" (gnus speak for email, I think), so
gnus-block-private-groups returns nil (meaning *don't* block images)
rather than ".".

Probably notmuch should override the gnus-blocked-images variable,
since the default value is simply wrong for notmuch.  Maybe something
along the lines of the following should go around our text/html
handler?

  (let ((gnus-blocked-images
         (if (eq gnus-blocked-images 'gnus-block-private-groups)
             ;; mm uses gnus-blocked-images to control image loading.
             ;; However, the default value of gnus-blocked-images
             ;; doesn't work for notmuch because
             ;; gnus-block-private-groups depends on gnus variables we
             ;; don't set.  Override it to disallow network image
             ;; loading.
             "."
           ;; Use the user's customized value.
           gnus-blocked-images)))
    ...)

Long live abstraction!

  reply	other threads:[~2015-01-21 22:39 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-21 21:00 privacy problem: text/html parts pull in network resources Daniel Kahn Gillmor
2015-01-21 21:14 ` Austin Clements
2015-01-21 21:36   ` Daniel Kahn Gillmor
2015-01-21 22:39     ` Austin Clements [this message]
2015-01-21 21:46   ` David Bremner
2015-01-22  7:25 ` Tomi Ollila
2015-01-25 17:51 ` David Bremner
2015-01-28  3:47   ` Daniel Kahn Gillmor
2015-01-28  4:44     ` Jinwoo Lee
2015-01-28 23:57       ` Jinwoo Lee
2015-01-29 18:03         ` Daniel Kahn Gillmor
2015-01-29 18:14           ` Jinwoo Lee
2015-01-30 12:12           ` David Edmondson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150121223909.GL22599@csail.mit.edu \
    --to=aclements@csail.mit.edu \
    --cc=dkg@fifthhorseman.net \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).