lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 20 Jul 2016 14:15:20 +0200
From:	Steffen Klassert <steffen.klassert@...unet.com>
To:	Vegard Nossum <vegard.nossum@...cle.com>
CC:	Stephen Hemminger <stephen@...workplumber.org>,
	<netdev@...r.kernel.org>
Subject: Re: [PATCH] xfrm: use printk instead of WARN for bad policy reporting

On Wed, Jul 20, 2016 at 10:32:35AM +0200, Vegard Nossum wrote:
> AFAICT this message is just printed whenever input validation fails.
> This is a normal failure and we shouldn't be dumping the stack over it.
> 
> Looks like it was originally a printk that was maybe incorrectly
> upgraded to a WARN:
> 
> commit 62db5cfd70b1ef53aa21f144a806fe3b78c84fab
> Author: stephen hemminger <shemminger@...tta.com>
> Date:   Wed May 12 06:37:06 2010 +0000
> 
>     xfrm: add severity to printk
> 
> Cc: Stephen Hemminger <stephen@...workplumber.org>
> Signed-off-by: Vegard Nossum <vegard.nossum@...cle.com>
> ---
>  net/xfrm/xfrm_user.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c
> index 4fb04ce..0b81bfc 100644
> --- a/net/xfrm/xfrm_user.c
> +++ b/net/xfrm/xfrm_user.c
> @@ -2150,7 +2150,7 @@ static int xfrm_add_acquire(struct sk_buff *skb, struct nlmsghdr *nlh,
>  	return 0;
>  
>  bad_policy:
> -	WARN(1, "BAD policy passed\n");
> +	printk(KERN_WARNING "xfrm_user: bad policy passed\n");

Why should we print here anything at all? If it is a normal
configuration error, we should remove the printing.

Powered by blists - more mailing lists