Add getpid() to the seccomp2 sandbox.

We hadn't needed this before, because most getpid() callers on Linux
were looking at the vDSO version of getpid().  I don't know why at
least one version of OpenSSL seems to be ignoring the vDSO, but this
change should fix it.

Fixes bug 21943; bugfix on 0.2.5.1-alpha when the sandbox was
introduced.
This commit is contained in:
Nick Mathewson 2017-04-26 12:56:06 -04:00
parent 4a9f689430
commit 99e943998d

View file

@ -155,6 +155,7 @@ static int filter_nopar_gen[] = {
#ifdef __NR_getgid32 #ifdef __NR_getgid32
SCMP_SYS(getgid32), SCMP_SYS(getgid32),
#endif #endif
SCMP_SYS(getpid),
#ifdef __NR_getrlimit #ifdef __NR_getrlimit
SCMP_SYS(getrlimit), SCMP_SYS(getrlimit),
#endif #endif