chiark / gitweb /
Avoid simple memory dumps via ptrace
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Wed, 12 Aug 2015 00:28:26 +0000 (20:28 -0400)
committerDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Tue, 3 Jan 2017 20:39:52 +0000 (20:39 +0000)
commit5c0ca5b715ab6b35b44df738153e05daa592d859
tree1c995fd6c2dc6d1414c9c3062a577fa74fa71046
parent3afe7539cae60c0a57902bff8a6892b6bf1aa7df
Avoid simple memory dumps via ptrace

This avoids needing to setgid gpg-agent.  It probably doesn't defend
against all possible attacks, but it defends against one specific (and
easy) one.  If there are other protections we should do them too.

This will make it slightly harder to debug the agent because the
normal user won't be able to attach gdb to it directly while it runs.

The remaining options for debugging are:

 * launch the agent from gdb directly
 * connect gdb to a running agent as the superuser

Upstream bug: https://bugs.gnupg.org/gnupg/issue1211

Gbp-Pq: Topic block-ptrace-on-agent
Gbp-Pq: Name 0002-Avoid-simple-memory-dumps-via-ptrace.patch
agent/gpg-agent.c
configure.ac