summaryrefslogtreecommitdiffstats
path: root/source3/smbd/nttrans.c
Commit message (Collapse)AuthorAgeFilesLines
...
* Carefully label SMB1-specific locking calls.Jeremy Allison2010-04-291-1/+1
| | | | Jeremy.
* Connect set security descriptor into SMB2 code.Jeremy Allison2010-04-281-2/+2
| | | | Jeremy.
* Plumb in get_nt_acl into SMB2.Jeremy Allison2010-04-261-40/+91
| | | | Jeremy.
* Move to using 64-bit mid values in our internal open file database.Jeremy Allison2010-04-121-1/+2
| | | | | | | This will allow us to share logic much easier between SMB1 and SMB2 servers. Jeremy
* s3: add comment about what the FSCTL_QUERY_ALLOCATED_RANGES currently doesBjörn Jacke2010-04-071-0/+6
|
* Add FSCTL_QUERY_ALLOCATED_RANGES to the list of Windows ioctls we support.Jeremy Allison2010-04-051-0/+52
| | | | | | Based on a patch reported and tested by Ira Cooper <samba@ira.wakeful.net>. Jeremy.
* Second part of fix for bug #6494 - Incorrect FileStatus returned in ↵Jeremy Allison2010-03-301-1/+19
| | | | | | | | NT_CREATE_ANDX. Ensure we do this in nttrans create too. Jeremy.
* Fix for bug #7189 - Open txt files with notepad on samba shares creates problem.Jeremy Allison2010-03-051-0/+4
| | | | | | | | | | Ensure we don't use any of the create_options for Samba private use. Add a new parameter to the VFS_CREATE call (private_flags) which is only used internally. Renumber NTCREATEX_OPTIONS_PRIVATE_DENY_DOS and NTCREATEX_OPTIONS_PRIVATE_DENY_FCB to match the S4 code). Rev. the VFS interface to version 28. Jeremy.
* Remove all calls to reply_doserror - turn them intoJeremy Allison2009-12-211-42/+42
| | | | | | | correct reply_nterror calls. Next rename reply_doserror -> reply_force_doserror and plumb in when NT_STATUS_DOS is used. Jeremy.
* Vector correctly through reply_openerror() (which uses the same logic).Jeremy Allison2009-12-171-6/+1
| | | | Jeremy.
* Fix make test. Only do POSIX case conversion if FILE_FLAG_POSIX_SEMANTICS ↵Jeremy Allison2009-11-241-8/+12
| | | | | | set. Doh ! Jeremy.
* Restore NtCreateX case handling with FILE_FLAG_POSIX_SEMANTICS to the wayJeremy Allison2009-11-231-5/+68
| | | | | | | | it worked in 3.3.x and 3.2.x. UCF_POSIX_PATHNAMES may no longer be needed, as lp_posix_pathnames() being set isn't the same as case handling from NtCreateX (lp_posix_pathnames() changes the STAT calls to LSTAT, not the case semantics). Jeremy.
* Proper fix for #6898 - Samba duplicates file content on appending. Pointed ↵Jeremy Allison2009-11-231-12/+18
| | | | out by Volker.Restores the pathname handling for FILE_FLAG_POSIX_SEMANTICS but still prevents the O_APPEND problems. Jeremy.
* Fix bug #6898 - Samba duplicates file content on appendingJeremy Allison2009-11-231-0/+10
| | | | | | Clients using a Windows open call should not be able to set FILE_FLAG_POSIX_SEMANTICS in an open. Jeremy.
* Revert "s3: Move the global variable Protocol to struct smbd_server_connection"Volker Lendecke2009-11-231-1/+1
| | | | This reverts commit c85a4c9ba4a7de65a7850f6f9708df66bd24deea.
* s3: Move the global variable Protocol to struct smbd_server_connectionVolker Lendecke2009-11-211-1/+1
|
* Remove "store create time" code, cause create time to be storedJeremy Allison2009-11-171-8/+10
| | | | | | | | | | | | in the "user.DOSATTRIB" EA. From the docs: In Samba 3.5.0 and above the "user.DOSATTRIB" extended attribute has been extended to store the create time for a file as well as the DOS attributes. This is done in a backwards compatible way so files created by Samba 3.5.0 and above can still have the DOS attribute read from this extended attribute by earlier versions of Samba, but they will not be able to read the create time stored there. Storing the create time separately from the normal filesystem meta-data allows Samba to faithfully reproduce NTFS semantics on top of a POSIX filesystem. Passes make test but will need more testing. Jeremy.
* Got the logic simplification worked out so we still passJeremy Allison2009-11-051-1/+1
| | | | | BASE-DELAYWRITE and also RAW-CLOSE. Jeremy.
* Revert commit "0551284dc08eb93ef7b2b2227a45e5ec21d482fb" - simplifyJeremy Allison2009-11-051-1/+1
| | | | | the logic. This was incorrect (I'll revisit this tomorrow). Jeremy.
* Simplify the logic - remove extraneous argument and calls to ↵Jeremy Allison2009-11-051-1/+1
| | | | | | | | set_close_write_time(). We were treating a file time set on close as a sticky write time set, and I don't think it is. I will add a torture test later to RAW-CLOSE to confirm this. Jeremy.
* Get closer to an accurate model of Windows timestamp changes.Jeremy Allison2009-11-051-1/+1
| | | | | | | | "Normal" non truncate writes always cause the timestamp to be set on close. Once a close is done on a handle this can reset the sticky write time to current time also. Updated smbtorture4 confirms this. Jeremy.
* Remove "Protocol" as an extern, and add accessor functions.Jeremy Allison2009-11-041-2/+1
| | | | Jeremy.
* s3: Fix shadow copy display on Windows 7Volker Lendecke2009-10-081-1/+1
| | | | | Windows 7 is a bit more picky on our NT_STATUS_BUFFER_TOO_SMALL. Announce the right buffer size, the same amount we later check for.
* We now pass the Microsoft SMB2 fileio test with EA's and streams...Jeremy Allison2009-09-171-1/+1
| | | | Jeremy.
* Fix bug 6494 - Incorrect FileStatus returned in NT_CREATE_ANDX.Jeremy Allison2009-09-141-1/+19
| | | | | Lookup the EA and Stream status on CreateX. Jeremy.
* Second attempt at fix for bug 6529 - Offline files conflict with Vista and ↵Jeremy Allison2009-08-241-8/+8
| | | | | | | | Office 2003. Confirmation from reporter that this fixes the issue in master on ext3/ext4. Back-ports to follow. Jeremy.
* Add "store create time" parameter (docs to follow)Jeremy Allison2009-08-121-4/+4
| | | | | that stores the create time in the user.DosTimestamps EA. Jeremy.
* Refactor the use of create_time and change time to goJeremy Allison2009-08-101-10/+22
| | | | | through functions. Will aid in making us pass RAW-SETFILEINFO. Jeremy.
* s3: Convert a few callers of unix_convert() over to filename_convert()Tim Prouty2009-07-241-2/+2
| | | | | | This patch also changes the unix convert flags to make sure the correct semantics are preservered for allowing/disallowing wildcards in the last component of the path.
* s3: Simplify rename_internals() by passing in smb_filename structsTim Prouty2009-07-241-69/+52
|
* s3: Allow filename_convert() to pass through unix_convert_flags and let the ↵Tim Prouty2009-07-241-0/+8
| | | | | | caller know if the path has a wildcard This also eliminates the need for resolve_dfspath().
* s3: Remove the now unused fname parameter from filename_convert()Tim Prouty2009-07-211-8/+4
|
* s3: Fix RENAME_FLAG_RENAME path to stop calling unix_convert twiceTim Prouty2009-07-211-50/+75
|
* s3: Move is_ntfs_stream*() to filename.cTim Prouty2009-07-201-24/+0
|
* s3: Change fsp->fsp_name to be an smb_filename struct!Tim Prouty2009-07-201-9/+11
|
* s3: Remove is_ntfs_stream_name() and split_ntfs_stream_name()Tim Prouty2009-07-081-48/+1
| | | | | Actually I moved split_ntfs_stream_name into torture.c which is the one consumer of it. This could probably be changed at some point.
* s3: Plumb smb_filename through dos_mode() and related funtionsTim Prouty2009-07-081-12/+6
|
* Rename update_stat_ex_writetime() -> update_stat_ex_mtime()Jeremy Allison2009-07-081-2/+2
| | | | | to better describe what we're doing here. Jeremy
* The migration to struct stat_ex broke the calculation ofJeremy Allison2009-07-081-0/+18
| | | | | | | | | | | | | | | | create time from the existing timestamps (for systems that need to do this). Once the write time is changed via a sticky write, the create time might need to be recalculated. To do this I needed to add a bool into struct stat_ex to remember if the st_ex_btime field was calculated, or read from the OS. Also fixed the returning of modified write timestamps in the return from NTCreateX, SMBattr and SMBattrE (which weren't taking into account the modified timestamp stored in the open file table). Attempting to fix an issue with Excel 2003 and offline files. Volker and Metze, please review. Jeremy
* s3: Plumb smb_filename around SMB_VFS_CHFLAGSTim Prouty2009-07-061-11/+3
| | | | | | | | | | | SMB_VFS_CHFLAGS isn't actually getting the smb_filename struct for now since it only operates on the basefile. This is the strategy for all path-based operations that will never actually operate on a stream. By clarifying the meaning of path based operations that don't take an smb_filename struct, modules that implement streams such as vfs_onefs no longer need to implement SMB_VFS_CHFLAGS to ensure it's only called on the base_name.
* s3: Change some filename_convert to pass in NULL for char **fname argumentTim Prouty2009-07-061-2/+2
|
* s3:smbd: make change_notify_reply() more generic and hide send_nt_replies() ↵Stefan Metzmacher2009-07-021-2/+11
| | | | | | | | behind a callback This prepares change notify support for SMB2. metze
* s3:smbd: simplify the notify code a bit and always reply via ↵Stefan Metzmacher2009-07-021-1/+3
| | | | | | change_notify_reply() -> send_nt_replies() metze
* s3:smbd: push nttrans and trans2 responses with no data to the clientStefan Metzmacher2009-07-021-0/+8
| | | | | | | | | | For sync replies it's not a problem, as construct_reply() will send the response, but for async replies we would not send the reply to the client. Currently the notify code works arround this manually, so I assume we didn't have a bug here. But the next commits will simplify the notify code. metze
* s3:smbd: restore the 3.0.x bahavior of send_nt_replies()Stefan Metzmacher2009-07-021-0/+5
| | | | | | We should also set the error code, when we return no parameters or data. metze
* s3 file_access: Convert some more functions over to use smb_filneameTim Prouty2009-06-251-2/+2
|
* s3: simplify some redundant logic in is_ntfs_default_stream_smb_fname()Tim Prouty2009-06-251-5/+1
|
* Add some const to the stat struct in the dosmode calls.Jeremy Allison2009-06-181-34/+6
| | | | | | | | Fix a couple more unix_convert uses to filename_convert. Fix bug in acl_group_override() where an uninitialized struct could be used. Move unix_convert with wildcard use in SMBsearch reply to boilerplate code. Jeremy.
* Replace the boilerplate calls to :Jeremy Allison2009-06-181-18/+12
| | | | | | | | | | | | resolve_dfspath() -> unix_convert() -> get_full_smb_filename() -> check_name() with a new function filename_convert(). This restores the check_name() calls that had gone missing since the default create_file was changed. All "standard" pathname processing now goes through filename_convert(). I'll take a look at the non-standard pathname processing next. As a benefit, fixed a missing resolve_dfspath() in the trans2 mkdir call. Jeremy.
* s3: Change SMB_VFS_OPEN to take an smb_filename structTim Prouty2009-06-171-0/+16
| | | | | | | | | | | | This was a little messy because of all of the vfs modules I had to touch. Most of them were pretty straight forward, but the streams modules required a little attention to handle smb_filename. Since the use of smb_filename enables the vfs modules to access the raw, over-the-wire stream, a little bit of the handling that was being done by split_ntfs_stream_name has now been shifted into the individual stream modules. It may be a little more code, but overall it gives more flexibility to the streams modules, while also allowing correct stream handling.