diff options
author | Jeremy Allison <jra@samba.org> | 2016-01-05 11:33:48 -0800 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2016-02-24 11:38:53 +0100 |
commit | e1825c8138135226fbf9ca685edd4b44aac40220 (patch) | |
tree | 2e5d8ee2cda4c5c3da01d018473f945f31675893 /source3 | |
parent | 63a27a313a44ff8f3a37dcb695ad437fb847dfa0 (diff) | |
download | samba-e1825c8138135226fbf9ca685edd4b44aac40220.tar.gz |
CVE-2015-7560: s3: smbd: Refuse to set EA's on a symlink.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11648
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/trans2.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 04a13c48c24..103e601072e 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -658,6 +658,11 @@ NTSTATUS set_ea(connection_struct *conn, files_struct *fsp, return NT_STATUS_EAS_NOT_SUPPORTED; } + status = refuse_symlink(conn, fsp, smb_fname->base_name); + if (!NT_STATUS_IS_OK(status)) { + return status; + } + status = check_access(conn, fsp, smb_fname, FILE_WRITE_EA); if (!NT_STATUS_IS_OK(status)) { return status; |