[Bug 1592327] [NEW] force create mode not enforced on newly created files

Dariusz Gadomski 1592327 at bugs.launchpad.net
Tue Jun 14 09:31:07 UTC 2016


Public bug reported:

Samba version used:
4.3.9+dfsg-0ubuntu0.16.04.2

Steps to reproduce:
1. Configure a samba share with inherited permissions:
[share1]
  path = /srv/share1
  browseable = yes
  read only = no
  guest ok = no
  create mask = 0770
  force create mode = 0660
  directory mask = 2770
  force directory mode = 2770

2. Create a directory under the share:
cd /srv/share1; mkdir modes && chmod 2770 modes

3. Connect with a Windows client and create some files and directories in the new directory:
New text document.txt*
test.txt
New folder*
test

Entries marked with * have their default names (picked by Windows)
untouched.

What is expected?
All files and directories have permissions set according to share configuration.

What happens?
└── [drwxrws---] ./modes 
├── [-rwxr-----] ./modes/New text document.txt 
├── [drwxrws---] ./modes/New folder 
├── [drwxrws---] ./modes/test 
└── [-rwxrw----] ./modes/test.txt

Despite force create mode the "New text document.txt" does not have
group-write permission, while another file with custom name has the
permissions set as desired.

When I rename "New text document.txt" to anything else the permissions are fixed immediately:
└── [-rwxrw----] ./modes/test2.txt

This was not observable with Samba 4.1.6.

** Affects: samba
     Importance: Unknown
         Status: Unknown

** Affects: samba (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: regression-update sts

** Bug watch added: Samba Bugzilla #11967
   https://bugzilla.samba.org/show_bug.cgi?id=11967

** Also affects: samba via
   https://bugzilla.samba.org/show_bug.cgi?id=11967
   Importance: Unknown
       Status: Unknown

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to samba in Ubuntu.
https://bugs.launchpad.net/bugs/1592327

Title:
  force create mode not enforced on newly created files

Status in samba:
  Unknown
Status in samba package in Ubuntu:
  New

Bug description:
  Samba version used:
  4.3.9+dfsg-0ubuntu0.16.04.2

  Steps to reproduce:
  1. Configure a samba share with inherited permissions:
  [share1]
    path = /srv/share1
    browseable = yes
    read only = no
    guest ok = no
    create mask = 0770
    force create mode = 0660
    directory mask = 2770
    force directory mode = 2770

  2. Create a directory under the share:
  cd /srv/share1; mkdir modes && chmod 2770 modes

  3. Connect with a Windows client and create some files and directories in the new directory:
  New text document.txt*
  test.txt
  New folder*
  test

  Entries marked with * have their default names (picked by Windows)
  untouched.

  What is expected?
  All files and directories have permissions set according to share configuration.

  What happens?
  └── [drwxrws---] ./modes 
  ├── [-rwxr-----] ./modes/New text document.txt 
  ├── [drwxrws---] ./modes/New folder 
  ├── [drwxrws---] ./modes/test 
  └── [-rwxrw----] ./modes/test.txt

  Despite force create mode the "New text document.txt" does not have
  group-write permission, while another file with custom name has the
  permissions set as desired.

  When I rename "New text document.txt" to anything else the permissions are fixed immediately:
  └── [-rwxrw----] ./modes/test2.txt

  This was not observable with Samba 4.1.6.

To manage notifications about this bug go to:
https://bugs.launchpad.net/samba/+bug/1592327/+subscriptions



More information about the foundations-bugs mailing list