Linux CIFS filesystem development
 help / color / mirror / Atom feed
From: David Disseldorp <ddiss@suse.de>
To: Volker Lendecke <Volker.Lendecke@sernet.de>
Cc: linux-cifs@vger.kernel.org, Steve French <smfrench@gmail.com>
Subject: Re: Fix posix 311 symlink creation mode
Date: Thu, 12 Jan 2023 14:25:17 +0100	[thread overview]
Message-ID: <20230112142517.7ea551e7@echidna.fritz.box> (raw)
In-Reply-To: <Y76gvH9ADxSgAxSw@sernet.de>

Hi Volker,

On Wed, 11 Jan 2023 12:42:52 +0100, Volker Lendecke wrote:

> If smb311 posix is enabled, we send the intended mode for file
> creation in the posix create context. Instead of using what's there on
> the stack, create the mfsymlink file with 0644.
> 
> Signed-off-by: Volker Lendecke <vl@samba.org>

Good catch. I think this deserves a Fixes tag as per
https://www.kernel.org/doc/html/latest/process/submitting-patches.html#using-reported-by-tested-by-reviewed-by-suggested-by-and-fixes
E.g.
Fixes: ce558b0e17f8a ("smb3: Add posix create context for smb3.11 posix mounts")
Preferably also with "Cc: stable@vger.kernel.org" for applicable
backports.

oparms.mode appears to be uninitialized in cifs_create_mf_symlink()
(#ifdef CONFIG_CIFS_ALLOW_INSECURE_LEGACY) and various other codepaths
but isn't currently used further down the call chain... This looks like
an accident waiting to happen.

Cheers, David

  parent reply	other threads:[~2023-01-12 13:24 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-11 11:42 Fix posix 311 symlink creation mode Volker Lendecke
2023-01-11 13:57 ` Paulo Alcantara
2023-01-11 16:21 ` Steve French
2023-01-11 16:51   ` Volker Lendecke
2023-01-11 17:04     ` Tom Talpey
2023-01-11 20:18     ` Steve French
2023-01-12 13:25 ` David Disseldorp [this message]
2023-01-12 15:59   ` Steve French

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=20230112142517.7ea551e7@echidna.fritz.box \
    --to=ddiss@suse.de \
    --cc=Volker.Lendecke@sernet.de \
    --cc=linux-cifs@vger.kernel.org \
    --cc=smfrench@gmail.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