summaryrefslogtreecommitdiffstats
path: root/source/smbd/file_access.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix bug #6297 - owner of sticky directory cannot delete files created by ↵Jeremy Allison2009-06-151-2/+13
| | | | | | others. The reason we couldn't delete was we were erroring out early if requestor was not the owner of the file we wanted to delete, instead of checking if the requestor owned the directory as well. If either of these is true, we must go on and check the ACL. Karolin, this is a must for 3.4.0 and also 3.3.next. I'll update the bug report with patches for 3.4.0 and 3.3.next and ask vl to review. Jeremy. (cherry picked from commit 966a51da8998cfd15875ba047b7f765c84b914dd)
* Fix bug #6154 - zfs does not honor admin users.Jeremy Allison2009-03-061-0/+5
| | | | | Jeremy. (cherry picked from commit a7efcb3666fe4df778df95449e98970a77369b79)
* Fix bug #6082 - smbd_gpfs_getacl failed: Windows client can´t rename or ↵Jeremy Allison2009-02-161-8/+3
| | | | | | | | | | delete file This fixes the generic rename/delete problem for 3.3.0 and above. Fixed slightly differently to discussions, user viewable modified ACLs are not a good idea :-). Jeremy. (cherry picked from commit c5462c8b43435763783185a03029903efe3b0c11)
* Unify se_access_check with the S4 code. Will makeJeremy Allison2008-11-181-4/+3
| | | | | | | calculation of SEC_FLAG_MAXIMUM_ALLOWED much easier for files. Jeremy. (cherry picked from commit 82a25d224b63148c4f9d38ae477328b12a5a03a6)
* Wrap the unix token info in a unix_user_token in auth_serversupplied_infoVolker Lendecke2008-06-191-4/+4
| | | | No functional change, this is a preparation for more current_user ref removal
* Fix checks in can_delete_file_in_directory()Volker Lendecke2008-06-191-6/+15
| | | | | | | | | With at least NFSv4 ACLs around the write permission for the owner is a bogus check if we can delete a file in a directory. Like in Windows, there are two ways which can grant us such: First, the DELETE permission on the file itself, or if that does not help, the DELETE_CHILD permission on the directory. It might be a bit more code that runs, but essentially we should end up with the same set of syscalls in the non-acl case.
* file_access: add a function header comment for can_access_file_acl().Michael Adam2008-06-181-0/+3
| | | | Michael
* file_access: remove unneeded stat buf parameter from can_access_file_acl().Michael Adam2008-06-171-3/+3
| | | | | | This is a security descriptor level function only. Michael
* Remove the reference to current_user from file_access.cVolker Lendecke2008-06-151-8/+6
| | | | conn holds the current user info
* Remove the "stat_open()" function, flag, and all associated code. It was onlyJeremy Allison2008-05-021-4/+4
| | | | | | | being (correctly) used in the can_read/can_write checks for hide unreadable/unwritable and this is more properly done using the functions in smbd/file_access.c. Preparing to do NT access checks on all file access. Jeremy.
* Move directory_has_default_acl() to file_access.c, belongsJeremy Allison2008-05-021-0/+27
| | | | | there as it no longer uses explicit POSIX ACL calls. Jeremy.
* Change the prototype of the vfs function get_nt_acl().Michael Adam2007-12-191-62/+5
| | | | | | | | | | | | | | Up to now, get_nt_acl() took a files_struct pointer (fsp) and a file name. All the underlying functions should need and now do need (after the previous preparatory work), is a connection_struct and a file name. The connection_struct is already there in the vfs_handle passed to the vfs functions. So the files_struct argument can be eliminated. This eliminates the need of calling open_file_stat in a couple of places to produce the fsp needed. Michael
* Fix potential orphaned open files.Michael Adam2007-11-131-2/+4
| | | | | | | Calling can_access_file could lead to orphaned open files when SMB_VFS_GET_NT_ACL returned ENOSYS (not implemented). Michael
* Make [f]get_nt_acl return NTSTATUSVolker Lendecke2007-11-131-8/+7
|
* Cosmetic fixVolker Lendecke2007-11-111-3/+5
| | | | Do directory vs file open before entering open_file_stat
* Move some access check functions that are not posix-acl specificMichael Adam2007-11-061-0/+239
to a new source file of their own. Michael