Subject: + sh-fix-format-string-bug-in-stack-tracer.patch added to -mm tree
To: 
[email protected],[email protected],[email protected],[email protected]
From: [email protected]
Date: Tue, 11 Mar 2014 14:34:59 -0700


The patch titled
     Subject: sh: fix format string bug in stack tracer
has been added to the -mm tree.  Its filename is
     sh-fix-format-string-bug-in-stack-tracer.patch

This patch should soon appear at
    
http://ozlabs.org/~akpm/mmots/broken-out/sh-fix-format-string-bug-in-stack-tracer.patch
and later at
    
http://ozlabs.org/~akpm/mmotm/broken-out/sh-fix-format-string-bug-in-stack-tracer.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Matt Fleming <[email protected]>
Subject: sh: fix format string bug in stack tracer

Kees reported the following error,

   arch/sh/kernel/dumpstack.c: In function 'print_trace_address':
>> arch/sh/kernel/dumpstack.c:118:2: error: format not a string literal and no 
>> format arguments [-Werror=format-security]

Use the "%s" format so that it's impossible to interpret 'data' as a
format string.

Signed-off-by: Matt Fleming <[email protected]>
Reported-by: Kees Cook <[email protected]>
Acked-by: Kees Cook <[email protected]>
Cc: Paul Mundt <[email protected]>
Cc: <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
---

 arch/sh/kernel/dumpstack.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN arch/sh/kernel/dumpstack.c~sh-fix-format-string-bug-in-stack-tracer 
arch/sh/kernel/dumpstack.c
--- a/arch/sh/kernel/dumpstack.c~sh-fix-format-string-bug-in-stack-tracer
+++ a/arch/sh/kernel/dumpstack.c
@@ -115,7 +115,7 @@ static int print_trace_stack(void *data,
  */
 static void print_trace_address(void *data, unsigned long addr, int reliable)
 {
-       printk(data);
+       printk("%s", (char *)data);
        printk_address(addr, reliable);
 }
 
_

Patches currently in -mm which might be from [email protected] are

sh-fix-format-string-bug-in-stack-tracer.patch
linux-next.patch

--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to