LFCS · Question #622
What does the entry valid users = @smbusers in the smb.conf file mean when used in a share section?
The correct answer is C. Only users in the unix group called smbusers can access this share. The valid users = @groupname entry in a Samba share configuration restricts access exclusively to members of the specified Unix group.
Question
Options
- AOnly users connecting from the machine called smbusers can use this share.
- BFiles saved in the specified share will be owned by the group smbusers.
- COnly users in the unix group called smbusers can access this share.
- DOnly the user account smbusers can access this share.
How the community answered
(24 responses)- C96% (23)
- D4% (1)
Why each option
The `valid users = @groupname` entry in a Samba share configuration restricts access exclusively to members of the specified Unix group.
The `valid users` parameter controls user authentication based on identity, not the originating machine; host-based access is managed by `hosts allow` or `hosts deny` parameters.
File ownership within a share is typically managed by `force user`, `force group`, or the user who creates the file, not by the `valid users` parameter.
The `@` symbol preceding a group name, such as `@smbusers`, in the `valid users` parameter within `smb.conf` signifies that only authenticated users who are members of the corresponding Unix group `smbusers` are permitted to access that particular Samba share. This is a standard method for enforcing group-based access control for Samba resources.
Without the `@` prefix, `valid users = smbusers` would specify a single user account named 'smbusers', but the `@` specifically denotes a Unix group.
Concept tested: Samba share user group access control
Source: https://www.samba.org/samba/docs/current/manpages/smb.conf.5.html
Topics
Community Discussion
No community discussion yet for this question.