summaryrefslogtreecommitdiff
path: root/source3/modules/vfs_streams_xattr.c
AgeCommit message (Collapse)AuthorFilesLines
2012-08-09Check error returns from strupper_m() (in all reasonable places).Jeremy Allison1-1/+3
2012-04-06build: Remove SMB_OFF_T, replace with off_tAndrew Bartlett1-7/+7
Now that we always require a 64 bit off_t, we no longer need SMB_OFF_T. Andrew Bartlett Autobuild-User: Andrew Bartlett <abartlet@samba.org> Autobuild-Date: Fri Apr 6 01:47:43 CEST 2012 on sn-devel-104
2011-12-12vfs: Make function pointer names consistent. They all end in _fnRichard Sharpe1-11/+11
Autobuild-User: Richard Sharpe <sharpe@samba.org> Autobuild-Date: Mon Dec 12 04:58:40 CET 2011 on sn-devel-104
2011-10-14Add support for VFS op streaminfo chaining in all relevant VFS modules.Frank Lahm1-14/+4
Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Fri Oct 14 03:26:06 CEST 2011 on sn-devel-104
2011-06-09s3-talloc Change TALLOC_REALLOC_ARRAY() to talloc_realloc()Andrew Bartlett1-3/+3
Using the standard macro makes it easier to move code into common, as TALLOC_REALLOC_ARRAY isn't standard talloc. Andrew Bartlett
2011-05-18s3-lib Replace StrCaseCmp() with strcasecmp_m()Andrew Bartlett1-1/+1
strcasecmp_m() never needs to call to talloc, and via next_codepoint() still has an ASCII fast-path bypassing iconv() calls. Andrew Bartlett
2011-05-06More const fixes. Remove CONST_DISCARD.Jeremy Allison1-2/+2
2011-04-21s3-vfs: rename open function to open_fn.Günther Deschner1-1/+1
This should finally fix the AIX build and allow to remove AIX specific ifdefs. Guenther Signed-off-by: Jeremy Allison <jra@samba.org> Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Thu Apr 21 02:01:20 CEST 2011 on sn-devel-104
2011-03-30s3-vfs: include smbd/smbd.h in vfs modules.Günther Deschner1-0/+1
Guenther
2011-03-30s3-includes: only include system/filesys.h when needed.Günther Deschner1-0/+1
Guenther
2010-12-18Rename vfs operation posix_fallocate to just fallocate and add the ↵Jeremy Allison1-4/+5
vfs_fallocate_mode parameter. It turns out we need the fallocate operations to be able to both allocate and extend filesize, and to allocate and not extend filesize, and posix_fallocate can only do the former. So by defining the vfs op as posix_fallocate we lose the opportunity to use any underlying syscalls (like Linux fallocate) that can do the latter as well. We don't currently use the non-extending filesize call, but now I've changed the vfs op definition we can in the future. For the moment simply map the fallocate op onto posix_fallocate for the VFS_FALLOCATE_EXTEND_SIZE case and return ENOSYS for the VFS_FALLOCATE_KEEP_SIZE case. Jeremy. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Sat Dec 18 08:59:27 CET 2010 on sn-devel-104
2010-12-03posix_fallocate() returns an errno, not -1 on error.Jeremy Allison1-1/+1
2010-12-02Move posix_fallocate into the VFS where it belongs.Jeremy Allison1-0/+26
Jeremy.
2010-06-09s3: fix calculation of st_blocks in streams_xattrBjörn Jacke1-3/+3
Thanks to Joachim Schmitz for finding that miscalculation.
2010-05-18s3-crypto: only include crypto headers when crypto is done.Günther Deschner1-0/+1
Guenther
2009-10-16Add comment explaining about symlink following & posix.Jeremy Allison1-1/+6
Jeremy.
2009-09-16s3: Fix reading beyond the end of a named stream in xattr_streamsVolker Lendecke1-2/+1
This was found thanks to a test by Sivani from Microsoft against Samba at the SDC plugfest
2009-09-16s3: Add some debugs to streams_xattrVolker Lendecke1-0/+6
2009-08-24Second attempt at fix for bug 6529 - Offline files conflict with Vista and ↵Jeremy Allison1-2/+3
Office 2003. Confirmation from reporter that this fixes the issue in master on ext3/ext4. Back-ports to follow. Jeremy.
2009-07-24Make the smbd VFS typesafeVolker Lendecke1-27/+13
2009-07-20s3: Finish plumbing the fsp->fsp_name smb_fname conversion through the modules.Tim Prouty1-16/+9
2009-07-08s3: Remove is_ntfs_stream_name() and split_ntfs_stream_name()Tim Prouty1-9/+12
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.
2009-07-06s3: Update streaminfo implementations now that only base names are passed ↵Tim Prouty1-7/+9
through the vfs
2009-07-06s3: Plumb smb_filename through SMB_VFS_UNLINKTim Prouty1-19/+24
2009-07-06s3: Plumb smb_filename through SMB_VFS_RENAMETim Prouty1-58/+36
2009-06-24s3: Plumb smb_filename through SMB_VFS_STAT and SMB_VFS_LSTATTim Prouty1-62/+98
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-34/+83
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-05-26Introduce "struct stat_ex" as a replacement for SMB_STRUCT_STATVolker Lendecke1-27/+27
This patch introduces struct stat_ex { dev_t st_ex_dev; ino_t st_ex_ino; mode_t st_ex_mode; nlink_t st_ex_nlink; uid_t st_ex_uid; gid_t st_ex_gid; dev_t st_ex_rdev; off_t st_ex_size; struct timespec st_ex_atime; struct timespec st_ex_mtime; struct timespec st_ex_ctime; struct timespec st_ex_btime; /* birthtime */ blksize_t st_ex_blksize; blkcnt_t st_ex_blocks; }; typedef struct stat_ex SMB_STRUCT_STAT; It is really large because due to the friendly libc headers playing macro tricks with fields like st_ino, so I renamed them to st_ex_xxx. Why this change? To support birthtime, we already have quite a few #ifdef's at places where it does not really belong. With a stat struct that we control, we can consolidate the nanosecond timestamps and the birthtime deep in the VFS stat calls. At this moment it is triggered by a request to support the birthtime field for GPFS. GPFS does not extend the system level struct stat, but instead has a separate call that gets us the additional information beyond posix. Without being able to do that within the VFS stat calls, that support would have to be scattered around the main smbd code. It will very likely break all the onefs modules, but I think the changes will be reasonably easy to do.
2009-02-25Fix use of streams modules with CIFSFS client.Jeremy Allison1-2/+13
Jeremy.
2009-02-09s3 vfs: Add a destructor to the fsp extension data APITim Prouty1-1/+2
I'm not certain if the dummy pointer is needed in struct vfs_fsp_data, but I added it to be consistent with the comment below.
2009-01-29s3: Add a new SMB_VFS_GET_ALLOC_SIZE vfs operationTim Prouty1-2/+2
This allows module implementors to customize what allocation size is returned to the client.
2009-01-09s3: Remove rendundant op_tuple entry in xattr streamsTim Prouty1-2/+0
2009-01-04s3: Remove a few unnecessary checks from the streams xattr moduleTim Prouty1-11/+0
Handling of error codes when renaming a file to a stream and a stream to a file is now done in rename_internals_fsp. The NTRENAME stream path only passes in the stream name, so the new base can now be different from the old base.
2008-12-01s3:streams_xattr: fstat should do a stat on the base fileStefan Metzmacher1-1/+1
The behavior of stat and fstat should be the same. metze
2008-12-01s3:streams_xattr: recheck fsp->fsp_name after a renameStefan Metzmacher1-0/+65
metze
2008-12-01s3:streams_xattr: add support for renaming streamsStefan Metzmacher1-1/+142
metze
2008-11-21Rever 83ff6979f504d50caf725ee62549604630b69be7 - "Fix the logic bug that ↵Jeremy Allison1-34/+34
caused us to run into kernel oplocks on an open for a stream inside a file with stream_xattr module. On opening the base_fsp we must break existing oplocks." as it broke make test. Jeremy.
2008-11-21Fix the logic bug that caused us to run into kernel oplocks on an open for a ↵Jeremy Allison1-34/+34
stream inside a file with stream_xattr module. On opening the base_fsp we must break existing oplocks. Jeremy.
2008-11-21Use fxattr calls whenever possible (trying to work around the strange Linux ↵Jeremy Allison1-19/+51
kernel oplock bug). Jeremy.
2008-11-21Second part of the fix for bug #5903 - vfs_streams_xattr breaks contents of ↵Jeremy Allison1-1/+60
the file (also fix a bad merge of the previous patch from 3.3). Jeremy.
2008-04-21Remove redundant parameter fd from SMB_VFS_CLOSE().Michael Adam1-1/+1
Now all those redundant fd's have vanished from the VFS API. Michael (This used to be commit 14294535512a7f191c5008e622b6708e417854ae)
2008-01-22Hide streams from the EA APIVolker Lendecke1-8/+6
(This used to be commit e9bb3d5067b74a29beb778f85687829778e42b5b)
2008-01-21Add SMB_VFS_FS_CAPABILITIESVolker Lendecke1-10/+3
It turns out that this is a necessary operation, separate from statvfs. statvfs can fail during tcon, so conn->fs_capabilities would never see that we support streams on a particular share. James, can you check that I got the darwin variant right? Thanks! (This used to be commit 3ad798d803b3b023533bb48e6993885f22b96095)
2008-01-20Fix some "set but never used" warningsVolker Lendecke1-0/+4
(This used to be commit 4a6dadc5178f4861e9c032321939db3b639734b5)
2008-01-20Fix valgrind errorsVolker Lendecke1-2/+2
(This used to be commit d7e6ec2258350c564053371361c8f1d7d0f775b1)
2008-01-20Do not use an unfinished fsp in streams_xattr_openVolker Lendecke1-1/+1
(This used to be commit 023b313d0d4ed3beb8d77177bc8141cadeb86658)
2008-01-20In streams_xattr_pwrite, base_fsp does not have an fdVolker Lendecke1-1/+2
These bugs haven't shown up when I did my tests with real xattrs, not with the xattr_tdb backend. It worked because the stream fsp does has the base file as fd. (This used to be commit b7022f8f7bf83c9c5e73e98d1477b7da766e8c5f)
2008-01-20Add some DEBUGVolker Lendecke1-0/+12
(This used to be commit 8db25aba63b1dffb0dfbc74012c7ebd0ce4d5682)
2008-01-20For pread/pwrite we need to do the setxattr on base_fspVolker Lendecke1-4/+4
(This used to be commit d481dddc81699aba79e48bca79bfb10e586b5cbb)
2008-01-20Really remove the _NEXT_ from vfs_xattr_tdb.cVolker Lendecke1-15/+20
This must have been lost somewhere in my patch-mangling (This used to be commit c1794375d1fa27d72ec32946bb4bd7b9f96e59fc)