Re: [PATCH] printk: add cpu id information to printk() output

2023-09-22 Thread Petr Mladek
On Fri 2023-09-22 15:34:44, Enlin Mu wrote: > John Ogness 于2023年9月15日周五 16:34写道: > > > > On 2023-09-15, Enlin Mu wrote: > > > Sometimes we want to print cpu id of printk() messages to consoles > > > > > > diff --git a/include/linux/threads.h b/include/linux/threads.h > > > index c34173e6c5f1..670

Re: [PATCH] printk: add cpu id information to printk() output

2023-09-22 Thread Petr Mladek
On Fri 2023-09-22 15:20:37, Enlin Mu wrote: > Petr Mladek 于2023年9月16日周六 00:34写道: > > > > On Fri 2023-09-15 11:53:13, Greg KH wrote: > > > On Fri, Sep 15, 2023 at 04:46:02PM +0800, Enlin Mu wrote: > > > > John Ogness 于2023年9月15日周五 16:34写道: > > >

Re: Suggestion for Capability Check Refinement in check_syslog_permissions()

2024-01-04 Thread Petr Mladek
On Wed 2024-01-03 07:59:18, Greg KH wrote: > On Wed, Jan 03, 2024 at 01:00:58PM +0800, 孟敬姿 wrote: > > Hi, we suggest revisiting the capability checks in > > check_syslog_permissions(). Currently CAP_SYSLOG is checked first, and > > if it’s not there but there is a CAP_SYS_ADMIN, it can also pass th

Re: [PATCH] cap_syslog: remove CAP_SYS_ADMIN when dmesg_restrict

2024-01-05 Thread Petr Mladek
On Fri 2024-01-05 09:49:44, Theodore Ts'o wrote: > On Fri, Jan 05, 2024 at 02:20:07PM +0800, Jingzi Meng wrote: > > CAP_SYSLOG was separated from CAP_SYS_ADMIN and introduced in Linux > > 2.6.37 (2010-11). For a long time, certain syslog actions required > > CAP_SYS_ADMIN or CAP_SYSLOG. Maybe it’s

Re: [PATCH 1/1] lib/vsprintf: Implement ssprintf() to catch truncated strings

2024-02-08 Thread Petr Mladek
On Tue 2024-01-30 15:53:36, Lee Jones wrote: > On Tue, 30 Jan 2024, Rasmus Villemoes wrote: > > On 30/01/2024 16.07, Lee Jones wrote: > > > On Mon, 29 Jan 2024, Lee Jones wrote: > > >> On Mon, 29 Jan 2024, David Laight wrote: > > snprintf() does this and has been proven to cause buffer-overflo

Re: [PATCH] printk: cleanup deprecated uses of strncpy/strcpy

2024-05-02 Thread Petr Mladek
est/process/deprecated.html#strncpy-on-nul-terminated-strings > [1] > Link: https://github.com/KSPP/linux/issues/90 [2] > Link: https://manpages.debian.org/testing/linux-manual-4.8/strscpy.9.en.html > [3] > Cc: linux-hardening@vger.kernel.org > Signed-off-by: Justin Stitt Nice improvements. Looks fine. Reviewed-by: Petr Mladek Best Regards, Petr

Re: [PATCH] printk: cleanup deprecated uses of strncpy/strcpy

2024-05-02 Thread Petr Mladek
On Thu 2024-05-02 07:06:21, Christophe JAILLET wrote: > Le 02/05/2024 à 01:18, Justin Stitt a écrit : > > On Wed, May 1, 2024 at 2:39 PM Christophe JAILLET > > wrote: > > > Hi, > > > > > > Nit: The { } around each branch can now also be removed. > > > > There was one line before and there's one

Re: [PATCH] printk: cleanup deprecated uses of strncpy/strcpy

2024-05-07 Thread Petr Mladek
On Mon 2024-04-29 23:06:54, Justin Stitt wrote: > Cleanup some deprecated uses of strncpy() and strcpy() [1]. > > There doesn't seem to be any bugs with the current code but the > readability of this code could benefit from a quick makeover while > removing some deprecated stuff as a benefit. > >

Re: [PATCH v2] printf: Remove unused 'bprintf'

2024-10-03 Thread Petr Mladek
unctions in that patch. > > Signed-off-by: Dr. David Alan Gilbert > Reviewed-by: Andy Shevchenko Looks good to me: Acked-by: Petr Mladek I assume that Sven is going to take it via the ftrace tree as he suggested at https://lore.kernel.org/r/20241002104807.42b4b...@gandalf.local.home Best Regards, Petr

Re: [DISCUSSION] vsprintf: the current state of restricted pointers (%pK)

2025-01-15 Thread Petr Mladek
On Tue 2025-01-14 16:35:57, Andy Shevchenko wrote: > On Mon, Jan 13, 2025 at 05:46:44PM +0100, Thomas Weißschuh wrote: > > Hi everybody, > > > > as you know, leaking raw kernel pointers to the user is problematic as > > they can be used to break KASLR. > > Therefore back in 2011 the %pK format spe