[Samba] State of chmod support for Samba 4.20.x

Erwin Hoffmann feh at fehcom.de
Wed Jul 17 12:22:09 UTC 2024


Hi Rowland,

thanks for the advice.


Am Mittwoch, dem 17.07.2024 um 13:01 +0100 schrieb Rowland Penny via
samba:
> On Wed, 17 Jul 2024 13:18:54 +0200
> Erwin Hoffmann via samba <samba at lists.samba.org> wrote:
> 
> > Hi together,
> > 
> > after the milestone release of Samba 4.20 supporting again Unix
> > Posix
> > semantics, I'm wondering 'what is the state of chmod support' here
> > (and planned for future releases).
> > 
> > Currently, the file permissions are not changeable by the user
> > having
> > mounted the share (ie. by mount_smb). I understand, that this also
> > depends on the capability of the cifs.ko on the Linux client (not
> > to
> > talk about gvfs -- different beast).
> 
> When you mount a share on Linux, the mount is carried out by root, so
> to change the permissions, you must do it as root or with sudo. This
> has nothing to do with Samba and everything to do with cifs.ko

Nope. Not working here. Client is Arch Linux (kernel 6.6), Samba server
is backported 4.20.2 (including Debian patches BFSG-6~BPO12+1). SMP
protocol is 3.1.1. Options 'posix' and 'unix' are given at mount.

chmod returns 0, but given ls -l permissions are not changed. 

Hm. 

> 
> Having said that, if the computer is domain joined, you can use
> 'sec=krb5' and 'multiuser', in this scenario, users can change
> permissions.
> 
Need to try this. Some background:

If you compile on a mounted SMB share, the compiler needs to chmod +x
the generated binary. This does not happen here, and the created file
is produced with the default file mask and left as is. Too bad.

I'll let you know after additional investigations.

Regards.
--eh. 


> Rowland
> 

-- 
Dr. Erwin Hoffmann | www.fehcom.de
PGP key-id: 20FD6E671A94DC1E
PGP key-fingerprint:  8C6B 155B 0FDA 64F1 BCCE A6B9 20FD 6E67 1A94 DC1E

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: This is a digitally signed message part
URL: <http://lists.samba.org/pipermail/samba/attachments/20240717/cd28e625/signature.sig>


More information about the samba mailing list