<feed xmlns='http://www.w3.org/2005/Atom'>
<title>archsetup/tests/cmail, branch main</title>
<subtitle>Builds a full dev workstation from a bare Arch Linux install.
</subtitle>
<id>https://git.cjennings.net/archsetup/atom?h=main</id>
<link rel='self' href='https://git.cjennings.net/archsetup/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/archsetup/'/>
<updated>2026-07-20T17:44:01+00:00</updated>
<entry>
<title>fix(security): decrypt the cmail password under a tight umask</title>
<updated>2026-07-20T17:44:01+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2026-07-20T17:44:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/archsetup/commit/?id=dffecf528cd20af2bd4437df567896ce03cabe2f'/>
<id>urn:sha1:dffecf528cd20af2bd4437df567896ce03cabe2f</id>
<content type='text'>
gpg writes its output at the process umask (often 0644), so the plaintext mail password was world-readable between the decrypt and the chmod. I extracted decrypt_to_secure, which runs the decrypt in a 0077 umask subshell so the file is 0600 from creation. A fake-gpg test pins that the write runs under the tight umask.
</content>
</entry>
</feed>
