summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* smbd: brl_lock_cancel does not need "blr" anymoreVolker Lendecke2014-07-045-16/+8
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Remove unused blocking_lock_record* from VFS_BRL_CANCEL_WINDOWSVolker Lendecke2014-07-048-25/+17
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: do_lock does not need "blr" anymoreVolker Lendecke2014-07-046-18/+8
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: brl_lock does not need "blr" anymoreVolker Lendecke2014-07-045-12/+6
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Remove unused blocking_lock_record* from VFS_BRL_LOCK_WINDOWSVolker Lendecke2014-07-048-25/+17
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Remove two outdated commentsVolker Lendecke2014-07-041-5/+0
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Use brl_delete_lock_struct in brl_lock_cancel_defaultVolker Lendecke2014-07-041-6/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Factor out unlocking from smbd_do_lockingVolker Lendecke2014-07-043-49/+62
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Remove an outdated commentVolker Lendecke2014-07-041-4/+0
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s4-winbind: Use winbindd in the AD DC by defaultAndrew Bartlett2014-07-045-44/+22
| | | | | | | | | | | (Including changes to knownfail to match the new winbindd in use in each environment) Change-Id: I9e08086eba98e95e05a99afef28315e2857aae56 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Kamen Mazdrashki <kamenim@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Fri Jul 4 05:19:54 CEST 2014 on sn-devel-104
* winbindd: Use a remote RPC server when we are an RODC when neededAndrew Bartlett2014-07-047-35/+72
| | | | | | | | | | | | | This allows us to operate against the local cache where possible, but to forward some operations to the read-write DC. Andrew Bartlett Change-Id: Idc78ae379a402969381758919fcede17568f094e Pair-programmed-with: Garming Sam <garming@catalyst.net.nz> Signed-off-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* selftest: Use s4 RPC servers in the s4member environmentAndrew Bartlett2014-07-041-2/+15
| | | | | | Change-Id: I645669d551d7bb988c69da7b3805e3056ab1e8c8 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* s4-auth: Do not override the NT_STATUS_NOT_IMPLEMENTED error for winbinddAndrew Bartlett2014-07-044-6/+29
| | | | | | | | | This changes the auth code in winbindd to use this as a flag, and to therefore contact the RW DC. Change-Id: If4164d27b57b453b398642fdf7d46d03cd0e65f2 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* selftest: Make the wbinfo userinfo tests work properly with the qualified nameGarming Sam2014-07-042-3/+1
| | | | | | | | This eliminates a knownfail. Change-Id: I7331a4e62ef8c1f2a9999a78865023ae19beeaca Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* winbindd: Allow the AD-DC to call getdcnameGarming Sam2014-07-042-7/+16
| | | | | | | | This is particularly useful for RODC and eliminates a knownfail. Change-Id: Ia5089761dcabb1620eadd530dbc9b05580cddd1f Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* secrets: Ensure we store the secureChannelType when written to secrets.ldbAndrew Bartlett2014-07-043-7/+21
| | | | | | | | | This will allow winbindd to know when we are an RODC without needing to dig into sam.ldb. Change-Id: Ibdfa37fe6269305ccc5db42479f4a8db5eea53f3 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* torture4: Make raw.lock.multilock fail after 20 secondsVolker Lendecke2014-07-041-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Jul 4 00:04:10 CEST 2014 on sn-devel-104
* torture4: Adapt comment to codeVolker Lendecke2014-07-031-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s4: smbtorture: Add multi-lock test. Regression test for bug #10684.Jeremy Allison2014-07-031-0/+97
| | | | | | | | | Bug #10684 - SMB1 blocking locks can fail notification on unlock, causing client timeout. https://bugzilla.samba.org/show_bug.cgi?id=10684 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
* s3: smbd: Locking - re-add pending lock records if we fail to acquire a lock ↵Jeremy Allison2014-07-031-17/+80
| | | | | | | | | | | | | | | | | | (and the lock hasn't timed out). Keep the blocking lock record and the pending lock records consistent if we are dealing with multiple blocking lock requests in one SMB1 LockingX request. Ensure we re-add the records under the record lock, to avoid race conditions. Bug #10684 - SMB1 blocking locks can fail notification on unlock, causing client timeout. https://bugzilla.samba.org/show_bug.cgi?id=10684 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
* s3: smbd: Locking - treat lock timeout the same as any other error.Jeremy Allison2014-07-031-53/+38
| | | | | | | | | | | | Allows the special case in process_blocking_lock_queue() that talks back to the client to be removed. Bug #10684 - SMB1 blocking locks can fail notification on unlock, causing client timeout. https://bugzilla.samba.org/show_bug.cgi?id=10684 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
* s3: smbd: Locking - add and use utility function lock_timed_out().Jeremy Allison2014-07-031-3/+21
| | | | | | | | | Bug #10684 - SMB1 blocking locks can fail notification on unlock, causing client timeout. https://bugzilla.samba.org/show_bug.cgi?id=10684 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
* s3: smbd: Locking - convert to using utility macro used elsewhere.Jeremy Allison2014-07-031-2/+1
| | | | | | | | | Bug #10684 - SMB1 blocking locks can fail notification on unlock, causing client timeout. https://bugzilla.samba.org/show_bug.cgi?id=10684 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
* torture3: Fix bug 10687Volker Lendecke2014-07-031-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Jul 3 19:07:15 CEST 2014 on sn-devel-104
* ctdb-tests: Fix racy test for debugging hung scriptsMartin Schwenke2014-07-032-1/+10
| | | | | | | | | | | | | | | Debugging can still be running when a monitor event times out and scriptstatus output changes. When debugging a hung script to a log file, write to a temporary file and move the temporary file over the log file when done. The test then waits for the log file to appear. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com> Autobuild-User(master): Amitay Isaacs <amitay@samba.org> Autobuild-Date(master): Thu Jul 3 08:19:23 CEST 2014 on sn-devel-104
* ctdb-scripts: Always print footer when debugging hung scriptMartin Schwenke2014-07-031-8/+6
| | | | | | | | | | | There shouldn't be an early exit for the "init" event. Just make the "ctdb scriptstatus" call conditional. While here, move the comment about only running a single instance to be near locking code. The comment is more useful there. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
* s3-libnet: Improve error message.Andreas Schneider2014-07-021-1/+3
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Wed Jul 2 16:54:10 CEST 2014 on sn-devel-104
* s3: smbd: Locking, fix off-by one calculation in brl_pending_overlap().Jeremy Allison2014-07-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Consider: lock = start=110,size=10 pend_lock = 100, size=10 Do not overlap. However, (lock->start <= pend_lock->start + pend_lock->size) 110 100 10 is true, so it returns true (overlap). lock->start <= pend_lock->start + pend_lock->size should be: lock->start < pend_lock->start + pend_lock->size BUG: https://bugzilla.samba.org/show_bug.cgi?id=10685 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Michael Adam <obnox@samba.org> Autobuild-Date(master): Wed Jul 2 10:18:17 CEST 2014 on sn-devel-104
* make: Add gdbtestenv target.Andreas Schneider2014-07-021-0/+3
| | | | | | | | This starts the sever components in a xterm with gdb. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:winbindd - fix bad bugfix for bug #10280 - winbind panic if AD server is ↵Jeremy Allison2014-07-021-2/+2
| | | | | | | | | | | down. Previous bug fix reversed the sense of the test for out of memory. BUG: https://bugzilla.samba.org/show_bug.cgi?id=10280 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* smbd: Fix some typosVolker Lendecke2014-07-021-3/+3
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Wed Jul 2 02:25:47 CEST 2014 on sn-devel-104
* smbd: Remove an unused variableVolker Lendecke2014-07-021-1/+0
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Clarify smb2 lock checksVolker Lendecke2014-07-021-5/+18
| | | | | | | | | | When reading the code it was not immediately clear to me how one of the conditions in [MS-SMB2] 3.3.5.14.2 was satisfied. A separate loop to me is clearer and given that we don't expect thousands of locks in a single call also not significantly less efficient. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* torture: Add a check to verify MS-SMB2 3.3.5.14.2Volker Lendecke2014-07-022-0/+7
| | | | | | | | | If we have more than one lock and there is any blocking lock, we need to fail with NT_STATUS_INVALID_PARAMETER. At a quick glance I did not find this tested, so add it. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* libcli: Remove an unused variableVolker Lendecke2014-07-011-1/+0
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Jul 1 00:43:18 CEST 2014 on sn-devel-104
* smbd: validate_lock_entries does not need mem_ctx anymoreVolker Lendecke2014-06-301-4/+3
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Simplify validate_lock_entriesVolker Lendecke2014-06-301-36/+10
| | | | Signed-off-by: Volker Lendecke <vl@samba.org>
* smbd: Factor out brl_delete_lock_structVolker Lendecke2014-06-301-6/+12
| | | | | | | | memmove calculations are never nice, and this is going to be used in validate_lock_entries soon :-) Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbd: Simplify validate_lock_entriesVolker Lendecke2014-06-301-10/+11
| | | | | | | ... saves >100 bytes object code :-) Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* torture3: Add some brlock entries in cleanup2Volker Lendecke2014-06-301-2/+26
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbstatus: Fix an uninitialized variableVolker Lendecke2014-06-301-0/+1
| | | | | | | | | | We only print valid share mode entries, stale ones don't count. In traverse, let the callback decide about staleness. https://bugzilla.samba.org/show_bug.cgi?id=10680 Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* libcli: Make cli_smb2_close_fnum asyncVolker Lendecke2014-06-302-23/+92
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* lib: Align nt_time_to_unix_timespec with unix_timespec_to_nt_timeVolker Lendecke2014-06-305-11/+11
| | | | | | | Both take and return values now Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* lib: Align unix_timespec_to_nt_time with nt_time_to_unix_timespecVolker Lendecke2014-06-306-20/+17
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* libcli: Make smb2cli_create return blobsVolker Lendecke2014-06-305-23/+36
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs_snapper: use a talloc hierarchy for arraysDavid Disseldorp2014-06-301-27/+5
| | | | | | | | | | | Currently the config and snapshot array entries are freed individually. A talloc hierarchy can be used to avoid this behaviour. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Mon Jun 30 21:41:13 CEST 2014 on sn-devel-104
* vfs_snapper: don't redefine GMT_FORMAT macroDavid Disseldorp2014-06-301-2/+1
| | | | | | | Use existing header definition. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* doc: add vfs_snapper manpageDavid Disseldorp2014-06-302-0/+94
| | | | | | | | Document usage of the snapper VFS module, detailing permissions required to list and access snapshots. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs: add previous file version support for vfs_snapperDavid Disseldorp2014-06-301-0/+1215
| | | | | | | | | | | | | | Windows attempts to access previous file versions by first issuing an FSCTL_SRV_ENUMERATE_SNAPSHOTS request, and then using the corresponding snapshot timestamps in subsequent path based requests. This change sees vfs_snapper provide snapshot enumeration data via the get_shadow_copy_data VFS hook. Path based operations are also intercepted, with @GMT-$time components converted to snapper .snapshot/# paths. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfs: add vfs_snapper moduleDavid Disseldorp2014-06-303-0/+844
| | | | | | | | | Provides an interface for accessing snapshots exposed by Snapper. The module communicates with snapperd on the local machine using the D-Bus interface. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>