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]
Message-id: <172299818573.6062.18188541572825124295@noble.neil.brown.name>
Date: Wed, 07 Aug 2024 12:36:25 +1000
From: "NeilBrown" <neilb@...e.de>
To: "Mark Grimes" <mark.grimes@...ystems.com>
Cc: "Chuck Lever" <chuck.lever@...cle.com>, "Jeff Layton" <jlayton@...nel.org>,
 "Olga Kornievskaia" <kolga@...app.com>, "Dai Ngo" <Dai.Ngo@...cle.com>,
 "Tom Talpey" <tom@...pey.com>, linux-nfs@...r.kernel.org,
 linux-kernel@...r.kernel.org, "Mark Grimes" <mark.grimes@...ystems.com>
Subject: Re: [PATCH] nfsd: Add quotes to client info 'callback address'

On Wed, 07 Aug 2024, Mark Grimes wrote:
> The 'callback address' in client_info_show is output without quotes
> causing yaml parsers to fail on processing IPv6 addresses.
> Adding quotes to 'callback address' also matches that used by
> the 'address' field.

Reviewed-by: NeilBrown <neilb@...e.de>

It is conceivable that existing code already handles the existing format
and could break, but it seems unlikely.  nfs-utils has code to parse
this file but it ignores "callback address" and doesn't care about the
content of "address" just including it in logs.

Consistency with "address" is a strong argument - strong enough to risk
the unlikely breakage.

Thanks,
NeilBrown


> 
> Signed-off-by: Mark Grimes <mark.grimes@...ystems.com>
> ---
>  fs/nfsd/nfs4state.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
> index a20c2c9d7d45..0061ae253f4d 100644
> --- a/fs/nfsd/nfs4state.c
> +++ b/fs/nfsd/nfs4state.c
> @@ -2692,7 +2692,7 @@ static int client_info_show(struct seq_file *m, void *v)
>  			clp->cl_nii_time.tv_sec, clp->cl_nii_time.tv_nsec);
>  	}
>  	seq_printf(m, "callback state: %s\n", cb_state2str(clp->cl_cb_state));
> -	seq_printf(m, "callback address: %pISpc\n", &clp->cl_cb_conn.cb_addr);
> +	seq_printf(m, "callback address: \"%pISpc\"\n", &clp->cl_cb_conn.cb_addr);
>  	seq_printf(m, "admin-revoked states: %d\n",
>  		   atomic_read(&clp->cl_admin_revoked));
>  	drop_client(clp);
> -- 
> 2.39.2
> 
> 


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ