diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-05-10 18:39:54 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-05-10 18:39:54 +0000 |
commit | 869ce5a1007a9d00bbac5121d825c80be70f9dde (patch) | |
tree | 26cd16954837176d7032fd1841853c34c5b32f99 /sys/arch/powerpc/include | |
parent | 24ed245ec22671d3d288d52c91f39a81a24637bf (diff) |
SROP mitigation. sendsig() stores a (per-process ^ &sigcontext) cookie
inside the sigcontext. sigreturn(2) checks syscall entry was from the
exact PC addr in the (per-process ASLR) sigtramp, verifies the cookie,
and clears it to prevent sigcontext reuse.
not yet tested on landisk, sparc, *88k, socppc.
ok kettenis
Diffstat (limited to 'sys/arch/powerpc/include')
-rw-r--r-- | sys/arch/powerpc/include/signal.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/powerpc/include/signal.h b/sys/arch/powerpc/include/signal.h index 7258c5a90df..67e82644ff7 100644 --- a/sys/arch/powerpc/include/signal.h +++ b/sys/arch/powerpc/include/signal.h @@ -1,4 +1,4 @@ -/* $OpenBSD: signal.h,v 1.8 2012/12/02 07:03:31 guenther Exp $ */ +/* $OpenBSD: signal.h,v 1.9 2016/05/10 18:39:47 deraadt Exp $ */ /* $NetBSD: signal.h,v 1.1 1996/09/30 16:34:34 ws Exp $ */ /* @@ -64,7 +64,7 @@ struct trapframe { }; struct sigcontext { - int __sc_unused; + long sc_cookie; int sc_mask; /* saved signal mask */ struct trapframe sc_frame; /* saved registers */ }; |