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] [day] [month] [year] [list]
Message-ID: <aSxziiGia10e5Stm@horms.kernel.org>
Date: Sun, 30 Nov 2025 16:40:42 +0000
From: Simon Horman <horms@...nel.org>
To: Andre Carvalho <asantostc@...il.com>
Cc: Breno Leitao <leitao@...ian.org>, Andrew Lunn <andrew+netdev@...n.ch>,
	"David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	Shuah Khan <shuah@...nel.org>, netdev@...r.kernel.org,
	linux-kselftest@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next] selftests: netconsole: remove log noise due to
 socat exit

On Sat, Nov 29, 2025 at 12:24:19PM +0000, Andre Carvalho wrote:
> This removes some noise that can be distracting while looking at
> selftests by redirecting socat stderr to /dev/null.
> 
> Before this commit, netcons_basic would output:
> 
> Running with target mode: basic (ipv6)
> 2025/11/29 12:08:03 socat[259] W exiting on signal 15
> 2025/11/29 12:08:03 socat[271] W exiting on signal 15
> basic : ipv6 : Test passed
> Running with target mode: basic (ipv4)
> 2025/11/29 12:08:05 socat[329] W exiting on signal 15
> 2025/11/29 12:08:05 socat[322] W exiting on signal 15
> basic : ipv4 : Test passed
> Running with target mode: extended (ipv6)
> 2025/11/29 12:08:08 socat[386] W exiting on signal 15
> 2025/11/29 12:08:08 socat[386] W exiting on signal 15
> 2025/11/29 12:08:08 socat[380] W exiting on signal 15
> extended : ipv6 : Test passed
> Running with target mode: extended (ipv4)
> 2025/11/29 12:08:10 socat[440] W exiting on signal 15
> 2025/11/29 12:08:10 socat[435] W exiting on signal 15
> 2025/11/29 12:08:10 socat[435] W exiting on signal 15
> extended : ipv4 : Test passed
> 
> After these changes, output looks like:
> 
> Running with target mode: basic (ipv6)
> basic : ipv6 : Test passed
> Running with target mode: basic (ipv4)
> basic : ipv4 : Test passed
> Running with target mode: extended (ipv6)
> extended : ipv6 : Test passed
> Running with target mode: extended (ipv4)
> extended : ipv4 : Test passed
> 
> Signed-off-by: Andre Carvalho <asantostc@...il.com>
> ---
>  tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh b/tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh
> index 87f89fd92f8c..ae8abff4be40 100644
> --- a/tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh
> +++ b/tools/testing/selftests/drivers/net/lib/sh/lib_netcons.sh
> @@ -249,7 +249,7 @@ function listen_port_and_save_to() {
>  
>  	# Just wait for 2 seconds
>  	timeout 2 ip netns exec "${NAMESPACE}" \
> -		socat "${SOCAT_MODE}":"${PORT}",fork "${OUTPUT}"
> +		socat "${SOCAT_MODE}":"${PORT}",fork "${OUTPUT}" 2> /dev/null
>  }
>  
>  # Only validate that the message arrived properly

I'm always concerned that a blanket redirect might hide some corner
cases in the future. But I do agree that this addresses the issue
at hand. And probably I'm over-thinking things here.

Reviewed-by: Simon Horman <horms@...nel.org>


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ