summaryrefslogtreecommitdiff
path: root/source4/ntvfs/posix/pvfs_open.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r14256: - rename smb_file -> smb_handleStefan Metzmacher1-6/+6
- move it into the in/out substructs again - allow file.path only on smb_fileinfo/smb_setfileinfo metze (This used to be commit be6d5298a2cdb7e7c61d70471bad445645af5963)
2007-10-10r14173: change smb interface structures to always useStefan Metzmacher1-5/+5
a union smb_file, to abtract - const char *path fot qpathinfo and setpathinfo - uint16_t fnum for SMB - smb2_handle handle for SMB2 the idea is to later add a struct ntvfs_handle *ntvfs so that the ntvfs subsystem don't need to know the difference between SMB and SMB2 metze (This used to be commit 2ef3f5970901b5accdb50f0d0115b5d46b0c788f)
2007-10-10r14157: - pass a struct ntvfs_request to the ntvfs layerStefan Metzmacher1-18/+18
(for now we just do #define ntvfs_request smbsrv_request, but it's the first step...) - rename ntvfs_openfile() -> ntvfs_open() - fix the talloc hierachie in some places in the ntvfs_map_*() code metze (This used to be commit ed9ed1f48f602354810937c0b0de850b44322191)
2007-10-10r13745: remove some code I was experimenting with and forgot was there when IAndrew Tridgell1-349/+0
committed that will teach me to run svn diff before committing .... (This used to be commit ef6e30c72cf610728584dfab1755b47bfc53f01c)
2007-10-10r13739: a fairly major overhaul of the opendb code to allow the BASE-DELETEAndrew Tridgell1-70/+615
test to pass. To try to make the code a bit more understandable, I moved to using an IDL description of the opendb tdb record format. One of the larger changes was to make directory opens and creates go via the opendb code, so directory operations now obey all the share mode restrictions, as well as delete on close semantics. I also changed the period over which the opendb locks are held, to try to minimise races due to two open operations happening at the same time. (This used to be commit cd2602d05725e1734b0862131dd91601c6b6d51a)
2007-10-10r12694: Move some headers to the directory of the subsystem they belong to.Jelmer Vernooij1-1/+1
(This used to be commit c722f665c90103f3ed57621c460e32ad33e7a8a3)
2007-10-10r9792: Rename StrCaseCmp -> strcasecmp_m. All these years I was thinkingJelmer Vernooij1-1/+1
StrCaseCmp was sys_strcasecmp, while it is in fact strcasecmp_m! (This used to be commit 200a8f6652cb2de7a8037a7a4c2a204b50aee2b1)
2007-10-10r9054: removed incorrect paranoia check on opening streams (this caused ↵Andrew Tridgell1-3/+0
RAW-STREAMS to fail) (This used to be commit c164ee5b19f6880b7b5df8d8fb96704350432862)
2007-10-10r9009: directory not empty is not an error on failure to delete directory in ↵Andrew Tridgell1-1/+1
delete on close (This used to be commit dada509f5e374872cded9035611c9d4fd9f4c4c7)
2007-10-10r9007: fixed error code for setting delete on close on a non-empty directoryAndrew Tridgell1-0/+3
(This used to be commit 320ab3c93b05a79b77dbbb85e9b038bb07848ba5)
2007-10-10r8258: Release the opendb lock in pvfs_change_create_options.Volker Lendecke1-0/+2
Volker (This used to be commit 2c4fd3ff99a4ade613030b3eb47d0ed527a95be3)
2007-10-10r8122: more fixes from testing dos error code handling against w2k3Andrew Tridgell1-1/+1
(This used to be commit b71fbcf5e2c627d918aef555b8cc8dd4591d8fe7)
2007-10-10r8059: fixed handling of delete on close fir directoriesAndrew Tridgell1-0/+5
(This used to be commit 14f51a99bccffac0ca284d1315ab6d4b10f3711f)
2007-10-10r7850: Support mkdir() with just one parameter. Patch fromJelmer Vernooij1-0/+1
Steven Edwards <steven_ed4153@yahoo.com>. I've moved the Win32-specific tests to win32.m4 so it does not make any of the POSIX configure stuff more complicated. (This used to be commit bf85fdd01552f75b745fdf3159a7a87cd6521ed2)
2007-10-10r6580: fixed the bug that caused the truncation of the main file on a streamAndrew Tridgell1-6/+20
open with openx and the 'truncate if exists' flag (This used to be commit aa82b105d5871b3ca693a0757bb48cc589d88824)
2007-10-10r5298: - got rid of pstring.h from includes.h. This at least makes it a bitAndrew Tridgell1-1/+0
less likely that anyone will use pstring for new code - got rid of winbind_client.h from includes.h. This one triggered a huge change, as winbind_client.h was including system/filesys.h and defining the old uint32 and uint16 types, as well as its own pstring and fstring. (This used to be commit 9db6c79e902ec538108d6b7d3324039aabe1704f)
2007-10-10r5037: got rid of all of the TALLOC_DEPRECATED stuff. My apologies for theAndrew Tridgell1-7/+7
large commit. I thought this was worthwhile to get done for consistency. (This used to be commit ec32b22ed5ec224f6324f5e069d15e92e38e15c0)
2007-10-10r4584: fix pvfs backend to pass the new enhanced RAW-ACLS test. Easy once I ↵Andrew Tridgell1-11/+4
really the strange behaviour I saw was a w2k3 bug :-) (This used to be commit e729061bcde25d0565a72222e4720ca8074ef23f)
2007-10-10r4448: - fixed access_mask checking on acl setAndrew Tridgell1-2/+5
- honor the change ownership requests of acl set, changing the underlying unix owner/group - fix the access mask on file create with SEC_FLAG_MAXIMUM_ALLOWED (This used to be commit 5761fa35ab727b51ef1b52459911bafbdd788755)
2007-10-10r4408: added the remaining access check hooks into pvfs. All calls should ↵Andrew Tridgell1-4/+14
now have acl checking, and obey the various inheritance rules. (This used to be commit 5fe51807d6b97e68b65f152c0f405e5c5a025d21)
2007-10-10r4403: - added ACL inheritance in the pvfs backend. ACLs are now inherited onAndrew Tridgell1-43/+73
file and directory creation via ntcreatex. pvfs now passes the inheritance test in RAW-ACLS - cleaned up the error handling a bit in pvfs_open() (This used to be commit f4dfb63d5395a365961a21388639809fcd3112d0)
2007-10-10r4314: added ACL checking on unlinkAndrew Tridgell1-1/+7
(This used to be commit f25c469693517ed993e0379d8b07cd7eb235a669)
2007-10-10r4247: two more places that need the unlink hookAndrew Tridgell1-0/+5
(This used to be commit 795897b64f3c63baaf53a36eb1611293c2fd8974)
2007-10-10r4243: a sniff from kukks showed that the ea_set interface in trans2 ↵Andrew Tridgell1-9/+12
setfileinfo allows for multiple EAs to be set at once. This fixes all the ea code to allow for that. (This used to be commit b26828bef5d55e5eef0e34a164e76292df45e207)
2007-10-10r4242: added support for storing xattrs in a tdb. This allows all advanced NTAndrew Tridgell1-0/+6
attributes (streams, EAs, NT ACLs, timestamps etc) to be used on filesystems that don't support xattrs. It also allows for large streams, although they are very inefficient. I won't enable this by default, as I really wrote it as a way of testing large stream support while still using ext3, but perhaps with a bit more work this could be generally usable. To enable this use: posix:eadb = /home/test/myeas.tdb (This used to be commit 0c927d912cb65754351189d3a0442004a14aa5c6)
2007-10-10r4173: - new t2open code, that can cope with "create with EAs". Many thanksAndrew Tridgell1-36/+0
to kukks on #samba-technical for the sniffs that allowed me to work this out - much simpler ntvfs open generic mapping code - added t2open create with EA torture test to RAW-OPEN test (This used to be commit a56d95ad89b4f32a05974c4fe9a816d67aa369e3)
2007-10-10r4062: the RAW-ACLS test now passes. The SEC_STD_DELETE bit is rather strangeAndrew Tridgell1-0/+10
though - I expect we'll need to tweak that some more. (This used to be commit e3500811b90b8423ee7694609340f394957d1160)
2007-10-10r4026: added NT ACL checking on pvfs_open() for existing files. I need toAndrew Tridgell1-14/+12
work out some way to do a decent test suite for this. (This used to be commit 9a9a0d0e791e4b64f0a35c921729e623b977af47)
2007-10-10r4011: get rid of rpc_secdes.h and replace it with a single sane set ofAndrew Tridgell1-12/+12
definitions for security access masks, in security.idl The previous definitions were inconsistently named, and contained many duplicate and misleading entries. I kept finding myself tripping up while using them. (This used to be commit 01c0fa722f80ceeb3f81f01987de95f365a2ed3d)
2007-10-10r3939: - added "posix:fakeoplocks" option for testing with oplocks forced onAndrew Tridgell1-14/+42
- added support for sticky write times after a setfileinfo, by using a write_time field in the DosAttrib xattr structure. (This used to be commit 4a52fae82d8305e999f94f1947daa21dab54cdfd)
2007-10-10r3835: - added testing of setting an initial ACL on a file using NTTRANS createAndrew Tridgell1-0/+16
- added support for initial ACLs in pvfs backend (This used to be commit 05ee9179f74d243aa22fa00be7873c5db76a8ad1)
2007-10-10r3806: added support to smb_server and pvfs for the NTTRANS Create call. ThisAndrew Tridgell1-1/+16
call has an optional sec_desc and ea_list. (This used to be commit 8379ad14e3d51a848a99865d9ce8d56a301e8a3c)
2007-10-10r3800: - fixed delete-on-close behaviour for streamsAndrew Tridgell1-1/+12
- added a delete-on-close test to RAW-STREAMS - don't allow rename of streams at the moment (I need to work out if its supposed to be allowed first) (This used to be commit f4b2b1311da6e37ac0947a3419d89c77ebbd6b63)
2007-10-10r3798: added support for alternate data streams in xattrs into pvfs.Andrew Tridgell1-29/+97
The trickiest part about this was getting the sharing and locking rules right, as alternate streams are separate locking spaces from the main file for the purposes of byte range locking, and separate for most share violation rules. I suspect there are still problems with delete on close with alternate data streams. I'll look at that next. (This used to be commit b6452c4a2068cf7e837778559da002ae191b508a)
2007-10-10r3747: - added some of the infrastructure needed for streams support in pvfsAndrew Tridgell1-8/+9
(the IDL, and the load/save meta-data logic) - changed pvfs_resolve_name() to default to non-wildcard, needing PVFS_RESOLVE_WILDCARD to enable wildcards. Most callers don't want wildcards, so defaulting this way makes more sense. - fixed deletion of EAs (This used to be commit e7afd4403cc1b7e0928776929f8988aa6f15640b)
2007-10-10r3741: FILE_ATTRIBUTE_DIRECTORY is illegal in open of a fileAndrew Tridgell1-0/+4
(This used to be commit ad7815fababe5783df5e8fb4a490921a5af693d6)
2007-10-10r3718: added support for the ntrename level in pvfs_rename().Andrew Tridgell1-2/+1
(This used to be commit 3d50982f5419b9a5c53f2b82a2313669cdeaaa21)
2007-10-10r3717: - expanded the RAW-RENAME test a littleAndrew Tridgell1-1/+1
- added support for wildcard rename in pvfs - made more consistent use of pvfs_map_errno() (This used to be commit e255d1c3a811c480a850452aaf636d9fa36f69fe)
2007-10-10r3631: a couple of tweaks to the talloc hierarchy for async requests inAndrew Tridgell1-0/+2
pvfs. This prevents a possible crash due to free ordering on unexpected disconnect. (This used to be commit bfca9eb7cb7a2caf3a232d538808ff2ade8e1ca9)
2007-10-10r3618: - this adds the special case for DENY_DOS semantics, as shown by the ↵Andrew Tridgell1-35/+119
BASE-DENYDOS test. - pvfs now passes BASE-DENY1 and BASE-DENYDOS. (This used to be commit aa09df22ee729c02552638859236d9068e9748ae)
2007-10-10r3615: split out struct pvfs_file_handle from struct pvfs_file. This is inAndrew Tridgell1-111/+151
preparation for adding code to pass the BASE-DENY1 and BASE-DENYDOS tests, which require a shared filesystem handle for some specific combinations of two DENY_DOS opens on the same connection. (This used to be commit 6e4fdf01d19051e3923d7703dbf990fc1722b09a)
2007-10-10r3595: - fixed a talloc_free ordering problem on cleanup with pending requestsAndrew Tridgell1-0/+10
- added initial support for MODE_INFORMATION in setfileinfo (I have no idea what "mode information" on a file is - it takes a value of 0, 2, 4 or 6. What could it be?) (This used to be commit e53ec2f6b68e1d19149c36ea8fcd25a204db38fb)
2007-10-10r3580: - on file overwrite in ntcreatex we need to replace the file permissions.Andrew Tridgell1-0/+16
- pvfs now passes BASE-OPENATTR - pvfs also passes the BASE-DEFER_OPEN test, but it is not a well formed test for regular running so I am removing it from the list of tests to run in test_posix.sh (the test is covered better by RAW-MUX anyway) (This used to be commit cb76bd218ed4194ea151264d495aa902ddf03b3c)
2007-10-10r3574: the RAW-OPEN test changes broke a couple of the other tests. ThisAndrew Tridgell1-1/+26
fixes most of them, although RAW-SEARCH still fails (due to an interaction with the new xattr code) (This used to be commit 09b4652b40c4cfca027765178bd5a0adbaa666c2)
2007-10-10r3573: added trans2open support to smbd and pvfs, and fine-tuned the ↵Andrew Tridgell1-0/+37
open->generic ntvfs mapping code. (This used to be commit ed844192d7f7ed487290f719df65f256a5b0b9bc)
2007-10-10r3550: fixed initial attribute on file create (inlusion of ↵Andrew Tridgell1-2/+4
FILE_ATTRIBUTE_ARCHIVE) (This used to be commit b07feaafd16e42e84ba51004a6a9d4a3cb8f9a37)
2007-10-10r3549: added support for DOS extended attribute lists (name/value pairs)Andrew Tridgell1-5/+5
stored in posix xattrs (This used to be commit bad6a88371264cffce2bf5d6ce904b7b357081de)
2007-10-10r3545: initial support for using extended attributes to hold extended dos ↵Andrew Tridgell1-1/+13
attributes of files. I decided to use IDL/NDR to encode the attribute, as it gives us a simple way to describe and extend the saved attributes. The xattr code needs to hook into quite a few more places in the pvfs code, but this at least gets the basics done. I will start encoding alternate data streams streams, DOS EAs etc soon using the same basic mechanism. I'll probably stick to "version 1" for the xattr.idl for quite a while even though it will be changing, as I don't expect anyone to be deploying this in production just yet. Once we have production users we will need to keep compatibility by supporting all the old version numbers in xattr.idl. (This used to be commit c54253ed1b7dce1d14f43e747da61089aea87094)
2007-10-10r3540: added testing of SMBntcancel in the open/open/close muxAndrew Tridgell1-2/+8
testing. Interestingly, w2k3 does not allow the cancel of an outstanding async open request, whereas it does allow the cancel of an outstanding async lock request. To support this I have changed the pvfs_wait interface to provide a enum on why the event is happening, so the callback can decide what to do. (This used to be commit f23d6a28008a13588cde24b5012ec21e488ac47a)
2007-10-10r3539: much nicer async open delay code.Andrew Tridgell1-95/+83
The previous code didn't handle the case where the file got renamed or deleted while waiting for the sharing violation delay. To handle this we need to make the 2nd open a full open call, including the name resolve call etc. Luckily this simplifies the logic. I also expanded the RAW-MUX test to include the case where we do open/open/open/close/close, with the 3rd open async, and that open gets retried after both the first close and the 2nd close, with the first retry failing and the 2nd retry working. The tests the "async reply after a async reply" logic in pvfs_open(). (This used to be commit eded2ad9c91f5ba587ef4f7f5f5a6dceb4b51ff3)