* [PATCH] arm64: compat_sys_sigsuspend: init local blocked mask not current process mask
@ 2013-02-25 12:40 Ryan Harkin
2013-02-25 12:58 ` Catalin Marinas
0 siblings, 1 reply; 2+ messages in thread
From: Ryan Harkin @ 2013-02-25 12:40 UTC (permalink / raw)
To: linux-arm-kernel
The original version changed the signal mask in the current process, and then passed an unitialized variable to sigsuspend, which in turn, besides the other work, sets current->blocked.
The value of mask, passed from a process, was effectively overwritten by some random value. If the random value was zero, all signals were blocked and pipes no longer work.
Signed-off-by: Ryan Harkin <ryan.harkin@linaro.org>
---
arch/arm64/kernel/signal32.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/kernel/signal32.c b/arch/arm64/kernel/signal32.c
index a4db3d2..0bc9461 100644
--- a/arch/arm64/kernel/signal32.c
+++ b/arch/arm64/kernel/signal32.c
@@ -347,7 +347,7 @@ asmlinkage int compat_sys_sigsuspend(int restart, compat_ulong_t oldmask,
{
sigset_t blocked;
- siginitset(¤t->blocked, mask);
+ siginitset(&blocked, mask);
return sigsuspend(&blocked);
}
--
1.7.9.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH] arm64: compat_sys_sigsuspend: init local blocked mask not current process mask
2013-02-25 12:40 [PATCH] arm64: compat_sys_sigsuspend: init local blocked mask not current process mask Ryan Harkin
@ 2013-02-25 12:58 ` Catalin Marinas
0 siblings, 0 replies; 2+ messages in thread
From: Catalin Marinas @ 2013-02-25 12:58 UTC (permalink / raw)
To: linux-arm-kernel
On Mon, Feb 25, 2013 at 12:40:07PM +0000, Ryan Harkin wrote:
> The original version changed the signal mask in the current process,
> and then passed an unitialized variable to sigsuspend, which in turn,
> besides the other work, sets current->blocked.
>
> The value of mask, passed from a process, was effectively overwritten
> by some random value. If the random value was zero, all signals were
> blocked and pipes no longer work.
>
> Signed-off-by: Ryan Harkin <ryan.harkin@linaro.org>
Thanks for the patch. It's a candidate for stable since mainline no
longer has this function, removed by commit 84b9e9b40 (arm64: switch
compat to generic old sigsuspend).
--
Catalin
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-02-25 12:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-25 12:40 [PATCH] arm64: compat_sys_sigsuspend: init local blocked mask not current process mask Ryan Harkin
2013-02-25 12:58 ` Catalin Marinas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox