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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20221020043746.GB28729@pengutronix.de>
Date:   Thu, 20 Oct 2022 06:37:46 +0200
From:   Oleksij Rempel <o.rempel@...gutronix.de>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
        pabeni@...hat.com,
        syzbot+81c4b4bbba6eea2cfcae@...kaller.appspotmail.com,
        andrew@...n.ch, linux@...pel-privat.de, bagasdotme@...il.com,
        lkp@...el.com
Subject: Re: [PATCH net] ethtool: pse-pd: fix null-deref on genl_info in dump

On Wed, Oct 19, 2022 at 03:35:51PM -0700, Jakub Kicinski wrote:
> ethnl_default_dump_one() passes NULL as info.
> 
> It's correct not to set extack during dump, as we should just
> silently skip interfaces which can't provide the information.
> 
> Reported-by: syzbot+81c4b4bbba6eea2cfcae@...kaller.appspotmail.com
> Fixes: 18ff0bcda6d1 ("ethtool: add interface to interact with Ethernet Power Equipment")
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> ---
> CC: andrew@...n.ch
> CC: linux@...pel-privat.de
> CC: bagasdotme@...il.com
> CC: lkp@...el.com

Reviewed-by: Oleksij Rempel <o.rempel@...gutronix.de>

Thank you!

> ---
>  net/ethtool/pse-pd.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/ethtool/pse-pd.c b/net/ethtool/pse-pd.c
> index 5a471e115b66..e8683e485dc9 100644
> --- a/net/ethtool/pse-pd.c
> +++ b/net/ethtool/pse-pd.c
> @@ -64,7 +64,7 @@ static int pse_prepare_data(const struct ethnl_req_info *req_base,
>  	if (ret < 0)
>  		return ret;
>  
> -	ret = pse_get_pse_attributes(dev, info->extack, data);
> +	ret = pse_get_pse_attributes(dev, info ? info->extack : NULL, data);
>  
>  	ethnl_ops_complete(dev);
>  
> -- 
> 2.37.3
> 
> 

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ