The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Jeffrey E Altman <jaltman@auristor.com>
To: Daniil Dulov <d.dulov@aladdin.ru>
Cc: linux-afs@lists.infradead.org,
	Marc Dionne <marc.dionne@auristor.com>,
	David Howells <dhowells@redhat.com>,
	linux-kernel@vger.kernel.org, lvc-project@linuxtesting.org
Subject: Re: [PATCH v2] afs: Increase buffer size in afs_update_volume_status()
Date: Mon, 12 Feb 2024 09:56:41 -0500	[thread overview]
Message-ID: <272e2048-85ca-4429-b3dc-b2434318dca4@auristor.com> (raw)
In-Reply-To: <20240212083347.10742-1-d.dulov@aladdin.ru>

On 2/12/2024 3:33 AM, Daniil Dulov wrote:
> The max length of volume->vid value is 20 characters.
> So increase idbuf[] size up to 20 to avoid overflow.
>
> Found by Linux Verification Center (linuxtesting.org) with SVACE.
>
> Fixes: d2ddc776a458 ("afs: Overhaul volume and server record caching and fileserver rotation")
> Signed-off-by: Daniil Dulov <d.dulov@aladdin.ru>
> ---
>   fs/afs/volume.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/afs/volume.c b/fs/afs/volume.c
> index 020ecd45e476..d4a379bfd54e 100644
> --- a/fs/afs/volume.c
> +++ b/fs/afs/volume.c
> @@ -353,7 +353,7 @@ static int afs_update_volume_status(struct afs_volume *volume, struct key *key)
>   {
>   	struct afs_server_list *new, *old, *discard;
>   	struct afs_vldb_entry *vldb;
> -	char idbuf[16];
> +	char idbuf[20];
>   	int ret, idsz;
>   
>   	_enter("");

Reviewed-by: Jeffrey Altman <jaltman@auristor.com>



  reply	other threads:[~2024-02-12 14:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-12  8:33 [PATCH v2] afs: Increase buffer size in afs_update_volume_status() Daniil Dulov
2024-02-12 14:56 ` Jeffrey E Altman [this message]
2024-02-19 10:28 ` David Howells
2024-02-19 10:33 ` David Howells
2024-02-19 15:07   ` Daniil Dulov
2024-02-19 16:01     ` David Howells

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=272e2048-85ca-4429-b3dc-b2434318dca4@auristor.com \
    --to=jaltman@auristor.com \
    --cc=d.dulov@aladdin.ru \
    --cc=dhowells@redhat.com \
    --cc=linux-afs@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=marc.dionne@auristor.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox