1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

531 Commits

Author SHA1 Message Date
Volker Lendecke
f9ad5cd133 s3: Convert cli_unix_extensions_version to async 2009-11-13 09:30:30 +01:00
Günther Deschner
f35a1b95aa s3-gencache: restore gencache_get behavior with NULL args (with torture test).
Without this, we panic in wins_srv_is_dead() and fail to start nmbd with
wins support.

Volker, please check.

Guenther
2009-11-02 13:04:26 +01:00
Jeremy Allison
49b23fe248 Fix comments on new test.
Jeremy
2009-10-20 17:41:27 -07:00
Jeremy Allison
e58f880381 Add local (or NFS) lock test to smbtorture. Checks that local locks
conflict with CIFS locks (see bug 6868).
Jeremy.
2009-10-20 17:37:43 -07:00
Volker Lendecke
94d5417d10 s3:torture: Add a notify-bench test
This is a test that creates and deletes files in a directory as fast as the
network allows it. At the same time, it opens a filechangenotify. This test is
done to just torture handling a single directory together with the notify
infrastructure.
2009-10-13 20:34:25 +02:00
Volker Lendecke
76d95b9a2d s3:gencache: Add a "was_expired" argument to gencache_get_data_blob
This is set to true if the routine returns failure due to an existing but
expired entry.
2009-09-23 18:50:33 +02:00
Matt Kraai
f6a29f7dd3 Port the Samba 3 shm_setup to QNX. 2009-09-13 12:55:26 +02:00
Volker Lendecke
a95955f285 s3:nsstest: Fix a very confusing behaviour in nsstest
Testing getgrent I thought I get the offset calculations wrong whereas
it was only nsstest printing stuff with spaces...
2009-08-29 19:43:33 +02:00
Volker Lendecke
1a22baa817 s3: Add talloc_dict.[ch] 2009-08-16 12:38:19 +02:00
Jeremy Allison
5d05d22999 Added prefer_ipv4 bool parameter to resolve_name().
W2K3 DC's can have IPv6 addresses but won't serve
krb5/ldap or cldap on those addresses. Make sure when
we're asking for DC's we prefer IPv4.
If you have an IPv6-only network this prioritizing code
will be a no-op. And if you have a mixed network then you
need to prioritize IPv4 due to W2K3 DC's.
Jeremy.
2009-07-28 11:51:58 -07:00
Volker Lendecke
be5cf23696 Fix the chain2 test 2009-07-24 17:17:08 +02:00
Tim Prouty
c9b8a01714 s3: Finish plumbing the fsp->fsp_name smb_fname conversion through the modules. 2009-07-20 17:26:57 -07:00
Jeremy Allison
1f5aec877f Make cli_unlock and cli_unlock64 async. Fix POSIX lock test.
Jeremy.
2009-07-15 11:49:33 -07:00
Volker Lendecke
3edcd55bf1 Remove gencache_init/shutdown
gencache_get/set/del/iterate call gencache_init() internally anyway. And we've
been very lazy calling gencache_shutdown, so this seems not really required.
2009-07-15 10:55:20 +02:00
Günther Deschner
9f15ef11bd s3-account_policy: add pdb_policy_type enum.
Guenther
2009-07-14 12:12:18 +02:00
Jeremy Allison
e67de63ba6 Make cli_posix_lock/unlock asynchronous.
Jeremy.
2009-07-13 18:43:10 -07:00
Volker Lendecke
3969f65aaa Fix&Run local-gencache 2009-07-10 18:16:46 +02:00
Volker Lendecke
0a0bff353e Fix our base64 implementation for blobs of length 4....
The additional length check bit us exactly at 4, removing it. The
torture test survives valgrind up to 2000 bytes :-)
2009-07-10 18:16:46 +02:00
Tim Prouty
161e182b65 s3: Remove is_ntfs_stream_name() and split_ntfs_stream_name()
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-08 21:36:04 -07:00
Tim Prouty
3cb0e521e1 s3: Plumb smb_filename through SMB_VFS_NTIMES 2009-07-06 15:38:42 -07:00
Tim Prouty
258952aa85 s3: Plumb smb_filename through SMB_VFS_UNLINK 2009-07-06 15:38:36 -07:00
Tim Prouty
5a09ba460c s3: Plumb smb_filename through SMB_VFS_RENAME 2009-07-06 15:38:29 -07:00
Volker Lendecke
520b6c0d50 Fix two pointless statics 2009-07-03 23:20:57 +02:00
Volker Lendecke
56ae65ad5c Test error codes on popular streams 2009-07-03 23:20:56 +02:00
Tim Prouty
e129384d7c s3: Plumb smb_filename through SMB_VFS_STAT and SMB_VFS_LSTAT
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-24 21:15:25 -07:00
Volker Lendecke
4aade2768b Add tldap paged searches, together with two helper routines 2009-06-20 18:54:07 +02:00
Volker Lendecke
756f83796f Add tiny tldap test 2009-06-19 14:28:22 +02:00
Tim Prouty
4e3656b8d1 s3: Change SMB_VFS_OPEN to take an smb_filename struct
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-17 20:11:53 -07:00
Jeremy Allison
dc5c7b7f98 Make ctemp async. Fix the test to pass against W2K3.
Jeremy.
2009-06-10 11:58:00 -07:00
Jeremy Allison
64a1f17aff Make cli_ftruncate async. Also add a simple test.
Jeremy.
2009-06-05 16:06:05 -07:00
Slava Semushin
ecd1fe2456 source3/torture/vfstest.c(process_file): fixed file descriptor leak.
Found by cppcheck:
[./source3/torture/vfstest.c:400]: (error) Resource leak: file
2009-06-05 10:17:09 +02:00
Stefan Metzmacher
c862018008 s3:smbd: move tcon specific globals to struct smbd_server_connection
metze
2009-06-03 17:54:38 +02:00
Kai Blin
bb9103d9c4 libwbclient: Store the winbind socket dir to use in the wb_context 2009-05-30 09:17:37 +02:00
Kai Blin
57ea909b32 libwbclient: Add async call framework. 2009-05-30 09:17:37 +02:00
Jeremy Allison
684d3dddd6 Make cli_nt_delete_on_close() async.
Jeremy.
2009-05-29 14:58:34 -07:00
Jeremy Allison
bccc7ee2c6 Add cli_posix_readlink() and a torture test for it.
Jeremy.
2009-05-27 21:51:15 -07:00
Jeremy Allison
f55c7614bd Add aync POSIX hardlink and symlink and torture test for them.
Missing call cli_readlink() is next.
Jeremy.
2009-05-27 17:28:23 -07:00
Volker Lendecke
49ca690b4b Introduce "struct stat_ex" as a replacement for SMB_STRUCT_STAT
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-05-26 17:48:23 +02:00
Slava Semushin
5d2cd81645 source{3,4}/torture/smbiconv.c(main): fixed file descriptor leak.
File descriptor leaks only when we use file instead of stdout.

Found by cppcheck:
[./source3/torture/smbiconv.c:219]: (error) Resource leak: out
[./source4/torture/smbiconv.c:211]: (error) Resource leak: out
2009-05-25 16:18:48 +02:00
Volker Lendecke
e744b0af68 use epoll for local-wbclient test 2009-05-24 13:51:32 +02:00
Jeremy Allison
e3851a9110 Test that POSIX open of a directory returns NT_STATUS_FILE_IS_A_DIRECTORY (ERRDOS, EISDIR).
Jeremy.
2009-05-22 15:21:55 -07:00
Tim Prouty
96ede10cfb s3 torture: Fix warning 2009-05-21 12:17:53 -07:00
Jeremy Allison
000da55dd9 Make cli_posix_open() and cli_posix_mkdir() async.
Jeremy.
2009-05-20 18:31:36 -07:00
Volker Lendecke
3fbc871f70 Demonstrate a bug we have when dealing with real os-level share modes
Another one of those where you stare at logfiles for hours, and when you found
it, it's absolutely obvious what is happening...
2009-05-20 14:58:37 +02:00
Volker Lendecke
ae386415b6 Make local-wbclient flexible in # of connections and ops 2009-05-19 23:09:26 +02:00
Jeremy Allison
f61959e87a Make error message clearer on fail.
Jeremy.
2009-05-14 16:30:11 -07:00
Jeremy Allison
41aa7d790a Add a test showing what ascii values cause an NTFS volume to
create a mangled name. We don't pass this yet, but it's not
run by default.
Jeremy.
2009-05-14 16:03:31 -07:00
Stefan Metzmacher
ca6ec5ecd7 s3:libsmb: let cli_smb_chain_send() also return NTSTATUS
metze
2009-05-13 18:27:50 +02:00
Jeremy Allison
b4c9cfb2af Fix a bunch of compiler warnings about wrong format types.
Should make Solaris 10 builds look cleaner.
Jeremy.
2009-05-11 21:56:57 -07:00
Volker Lendecke
efbc4315d2 Fix the mangle1 test 2009-05-09 14:09:42 +02:00