providing imap_pass but not from ~/.muttrc

Ben Boeckel mathstuf at gmail.com
Thu Jun 13 19:19:26 UTC 2019


On Thu, Jun 13, 2019 at 20:56:33 +0200, Matthias Apitz wrote:
> I often use SSH to connect to my rented VM space of my ISP (which gets me to a
> Linux server) and I do use mutt from there to check my mails or even to
> answer, esp. when I do not have my FreeBSD netbook with full Internet and all
> mails up.
> 
> I do not want to set 'imap_pass=...' and such values in the ~/.muttrc on
> this VM. Is there any other way to provide such credentials without to
> key them in on start of mutt, for example based on an environment
> variable which I could route to the VM through the SSH session like:
> 
> $ ssh -At www.unixarea.de imap_pass=abc bash --login
> Thu Jun 13 20:44:51 CEST 2019
> ...
> sh4-5:~$ env | grep imap
> imap_pass=abc

I don't think there's any mechanism in mutt. You might be able to have
`mutt -F <(genmuttrc)` dump it out. It may also be worth just doing `set
imap_pass=...` inside mutt once it has started.

However, what's your threat model that having it in the file is not OK
but the environment is OK? `/proc/foo/environ` is just as readable on
Linux as muttrc is likely to be.

How are you getting your sendmail password over in order to send email?
Or is it trusted because it's coming from the ISP's VM?

--Ben


More information about the Mutt-users mailing list