summaryrefslogtreecommitdiff
path: root/source3/modules/vfs_full_audit.c
AgeCommit message (Collapse)AuthorFilesLines
2009-08-28s3: Add a new VFS op called SMB_VFS_TRANSLATE_NAMEAravind Srinivasan1-0/+15
This vop is designed to work in tandem with SMB_VFS_READDIR to allow vfs modules to make modifications to arbitrary filenames before they're consumed by callers. Subsequently the core directory enumeration code in smbd is now changed to free the memory that may be allocated in a module. This vop enables the new version of catia in the following patch. Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-08-26s3: Allow full_audit to play nice with smbd if it's using syslogtprouty1-1/+11
Explictly pass the facility from both smbd and full_audit to syslog. Really the only major change is to not call openlog() in full_audit if WITH_SYSLOG is defined, which implies that smbd is already using syslog. This allows full audit to piggy-back on the same ident as smbd, while still differentiating the logging via the facility.
2009-08-26s3 audit: Change create_file in full_audit to print whether a directory or ↵tprouty1-2/+28
file was requested full_audit will now print out whether the createfile was requested for a file or directory. The create disposition is also printed out.
2009-08-24Second attempt at fix for bug 6529 - Offline files conflict with Vista and ↵Jeremy Allison1-2/+2
Office 2003. Confirmation from reporter that this fixes the issue in master on ext3/ext4. Back-ports to follow. Jeremy.
2009-07-24Move the "enum _vfs_op_type" to full_auditVolker Lendecke1-0/+142
It's only used there now. Someone should now go in and simplify full_audit... :-)
2009-07-24Make the smbd VFS typesafeVolker Lendecke1-244/+112
2009-07-20s3: Finish plumbing the fsp->fsp_name smb_fname conversion through the modules.Tim Prouty1-39/+54
2009-07-19Fix a few type errors in VFS modulesVolker Lendecke1-2/+2
2009-07-06s3: Plumb smb_filename through SMB_VFS_NTIMESTim Prouty1-3/+5
2009-07-06s3: Plumb smb_filename through SMB_VFS_UNLINKTim Prouty1-3/+4
2009-07-06s3 audit: Remove some recently introduced memory leaks in the audit modulesTim Prouty1-9/+42
2009-07-06s3 audit: Remove the usesless static function declarations from the audit ↵Tim Prouty1-539/+248
modules
2009-07-06s3: Plumb smb_filename through SMB_VFS_RENAMETim Prouty1-4/+8
2009-06-24s3: Plumb smb_filename through SMB_VFS_STAT and SMB_VFS_LSTATTim Prouty1-8/+10
This patch introduces two new temporary helper functions vfs_stat_smb_fname and vfs_lstat_smb_fname. They basically allowed me to call the new smb_filename version of stat, while avoiding plumbing it through callers that are still too inconvenient. As the conversion moves along, I will be able to remove callers of this, with the goal being to remove all callers. There was also a bug in create_synthetic_smb_fname_split (also a temporary utility function) that caused it to incorrectly handle filenames with ':'s in them when in posix mode. This is now fixed.
2009-06-17s3: Change SMB_VFS_OPEN to take an smb_filename structTim Prouty1-4/+5
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.
2009-06-12s3: Plumb smb_filename through SMB_VFS_CREATE_FILETim Prouty1-13/+7
2009-06-02Add SMB_VFS_CONNECTPATH operationVolker Lendecke1-0/+18
This is required for the shadow_copy2 module and "wide links = no". The file system snapshots by nature are typically outside of share directory. So the REALPATH result fails the wide links = no test.
2009-03-13s3: Add strict lock/unlock calls to the vfs layer to replace is_lockedDave Richards1-0/+40
2009-02-19s3: Modify SMB_VFS_FILE_ID_CREATE to take a stat structTim Prouty1-3/+3
Since file_id_create_dev is incompatible with the concept of file_ids, it is now static and in the one file that needs it.
2009-02-13Add VFS ops for Windows BRL: Lock, Unlock and Cancel:Zack Kirsch1-0/+73
This patch adds 3 new VFS OPs for Windows byte range locking: BRL_LOCK_WINDOWS, BRL_UNLOCK_WINDOWS and BRL_CANCEL_WINDOWS. Specifically: * I renamed brl_lock_windows, brl_unlock_windows and brl_lock_cancel to *_default as the default implementations of the VFS ops. * The blocking_lock_record (BLR) is now passed into the brl_lock_windows and brl_cancel_windows paths. The Onefs implementation uses it - future implementations may find it useful too. * Created brl_lock_cancel to do what brl_lock/brl_unlock do: set up a lock_struct and call either the Posix or Windows lock function. These happen to be the same for the default implementation. * Added helper functions: increment_current_lock_count() and decrement_current_lock_count(). * Minor spelling correction in brl_timeout_fn: brl -> blr. * Changed blocking_lock_cancel() to return the BLR that it has cancelled. This allows us to assert its the lock that we wanted to cancel. If this assert ever fires, this path will need to take in the BLR to cancel, rather than choosing on its own. * Adds a small helper function: find_blocking_lock_record_by_id(). Used by the OneFS implementation, but could be useful for others.
2009-02-10S3: Add in missing full audit entries.todd stecher1-6/+34
2009-02-09s3: Added SMB_VFS_INIT_SEARCH_OP to initialize data at the beginning of SMB ↵Steven Danneman1-0/+14
search requests. By default this VFS call is a NOOP, but the onefs vfs module takes advantage of it to initialize direntry search caches at the beginning of each TRANS2_FIND_FIRST, TRANS2_FIND_NEXT, SMBffirst, SMBsearch, and SMBunique
2009-02-09Add an optional SMB_STRUCT_SMB parameter to VFS_OP_READDIRSteven Danneman1-3/+4
* this allows VFS implementations that prefetch stat information on readdir to return it through one VFS call * backwards compatibility is maintained by passing in NULL * if the system readdir doesn't return stat info, the stat struct is set to invalid
2009-01-29s3: Add a new SMB_VFS_GET_ALLOC_SIZE vfs operationTim Prouty1-0/+17
This allows module implementors to customize what allocation size is returned to the client.
2009-01-23Extend NTIMES to allow setting create_timetodd stecher1-3/+3
1) Add in smb_file_time struct to clarify code and make room for createtime. 2) Get and set create time from SMB messages. 3) Fixup existing VFS modules + examples Some OS'es allow for the setting of the birthtime through kernel interfaces. This value is generically used for Windows createtime, but is not settable in the code today.
2009-01-05Use talloc_tos in vfs_full_audit.c:do_logVolker Lendecke1-2/+2
2009-01-05Fix a bad memleak in vfs_full_auditVolker Lendecke1-1/+4
2009-01-05Add create_file to vfs_op_namesVolker Lendecke1-0/+1
2009-01-05Fix bug 6012: Add "get_real_filename" to full_auditVolker Lendecke1-0/+25
Thanks to Hodur <coil93@gmail.com> for testing! Volker
2008-12-03s3: Change SMB_VFS_CREATE_FILE to take a create_file_flags argumentTim Prouty1-3/+3
This replaces the is_dos_path bool with a more future-proof argument. The next step is to plumb INTERNAL_OPEN_ONLY through this flag instead of overridding the oplock_request.
2008-12-03s3: Add SMB_VFS_CREATE_FILE to vfs_full_audit moduleTim Prouty1-0/+64
2008-10-14Use {u,}int64_t instead of SMB_BIG_{U,}INT.Jelmer Vernooij1-7/+7
2008-10-07Update vfs version as I've added a const to the security_descriptor paramter ↵Jeremy Allison1-2/+2
in fset_nt_acl(). Need to watch the build farm to make sure I haven't broken the AIX or Solaris ACL modules. Jeremy.
2008-08-14Fix bug #5692 - Core dump in full_audit.so.Jeremy Allison1-3/+2
There were some function mismatches in the various GET_NT_ACL modules (some places the fsp parameter has not been removed). Jeremy. (This used to be commit 221cc5e21eb27cdad51f34ec6832467a7bd89213)
2008-07-04Add SMB_VFS_OP_RECVFILE to get it in sync with vfs.hLars Müller1-0/+1
Fix "vfs_full_audit.c: name table not in sync with vfs.h" panic reported by Franz Sirl. (This used to be commit 72b96b75a4a1b523540a24fb758b1965ad66009b)
2008-06-19Wrap the unix token info in a unix_user_token in auth_serversupplied_infoVolker Lendecke1-1/+1
No functional change, this is a preparation for more current_user ref removal (This used to be commit dcaedf345e62ab74ea87f0a3fa1e3199c75c5445)
2008-06-07Add STREAMINFO op to vfs_full_auditVolker Lendecke1-0/+27
Fix Coverity ID 552 and 553 (This used to be commit c46e10d2605b22d31675976e62e5ae61d73c8a0a)
2008-05-25Remove some references to get_current_username() and current_user_infoVolker Lendecke1-4/+2
(This used to be commit 344d69f95e217d16213eaa6b53141af6ab459708)
2008-05-10Remove "user" from connection_structVolker Lendecke1-1/+2
(This used to be commit 368454a27cb53a408ec416cbf37235b304592fb5)
2008-05-10Remove the unix token info from connection_structVolker Lendecke1-1/+2
(This used to be commit 2834dacc8d49f77fe55fb5d7e3eb2dda431d1d3d)
2008-05-08Yay ! Remove a VFS entry. Removed the set_nt_acl() call,Jeremy Allison1-20/+0
this can only be done via fset_nt_acl() using an open file/directory handle. I'd like to do the same with get_nt_acl() but am concerned about efficiency problems with "hide unreadable/hide unwritable" when doing a directory listing (this would mean opening every file in the dir on list). Moving closer to rationalizing the ACL model and maybe moving the POSIX calls into a posix_acl VFS module rather than having them as first class citizens of the VFS. Jeremy. (This used to be commit f487f742cb903a06fbf2be006ddc9ce9063339ed)
2008-04-21Remove redundant parameter fd from SMB_VFS_CLOSE().Michael Adam1-3/+3
Now all those redundant fd's have vanished from the VFS API. Michael (This used to be commit 14294535512a7f191c5008e622b6708e417854ae)
2008-03-23Fix Coverity ID 450Volker Lendecke1-1/+5
(This used to be commit 700cceb6940c95997cfef374cffd50729a35528a)
2008-03-21Fix Coverity IDs 553, 552Volker Lendecke1-0/+4
(This used to be commit 1a0aed566b7e4fc75bf894aac6828bfa4152c3dc)
2008-01-11Combine fsp and tofd to tofsp in SMB_VFS_RECVFILE().Michael Adam1-5/+4
Michael (This used to be commit 3958abffaf2866c69ad9e13ec345364fde5c78bb)
2008-01-11Combine fsp and fromfd to fromfsp in SMB_VFS_SENDFILE().Michael Adam1-5/+4
Michael (This used to be commit a52cfb7d777157c93c9dc26c67f457be592dd537)
2008-01-10Remove redundant parameter fd from SMB_VFS_WRITE().Michael Adam1-3/+3
Michael (This used to be commit c8ae7d095a2a6a7eac920a68ca7244e3a423e1b1)
2008-01-10Remove redundant parameter fd from SMB_VFS_READ().Michael Adam1-3/+3
Michael (This used to be commit a8fc2ddad8d5f7c6c00cb36c74a32a02d69d1d04)
2008-01-08Remove redundant parameter fd from SMB_VFS_AIO_CANCEL().Michael Adam1-3/+3
Michael (This used to be commit 3c997ae0002d4c50e8899600c17ddf74ac61f6f0)
2008-01-08Remove redundant parameter fd from SMB_VFS_FSETXATTR().Michael Adam1-4/+3
Michael (This used to be commit 0bd2643463a9160c8a1c7e1c2f8cca7b89060e09)