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, 14 Feb 2017 00:29:34 +0000 (00:29 +0000)
commit3edbe9107219ed2fb2294d797b1363129a2986ce
treed50e508268d4dddd927c5981ea8962a933d43cbc
parent42f84a0e88104ceba3da7d7e01f4cdb377bb8d12
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