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

35026 Commits

Author SHA1 Message Date
Volker Lendecke
1b373d6044 s3: Fix a deadlock between smbd and ctdbd
Do the notification after we released the share mode lock. Inside notify_fname
we take out another tdb lock. With ctdb also accessing our databases, this can
lead to deadlocks. Putting this notify after the TALLOC_FREE(lck) above we
avoid locking two records simultaneously. Notifies are async and informational
only, so calling the notify_fname without holding the share mode lock should
not do any harm.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Fri Jan 21 12:29:21 CET 2011 on sn-devel-104
2011-01-21 12:29:21 +01:00
Günther Deschner
8db3258983 s3-spoolss: make it more obvious what winreg_create_printer() does.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Fri Jan 21 11:43:29 CET 2011 on sn-devel-104
2011-01-21 11:43:29 +01:00
Günther Deschner
621fb88e33 s3-rpcclient: rename duplicate enumkey command to winreg_enumkey.
Guenther
2011-01-21 10:58:20 +01:00
Günther Deschner
be884c1bfd s3-spoolss: as smbtorture testing proves: devmode size is the size of the devicemode minus the driverdata extra size.
Jeremy, please check.

Guenther
2011-01-21 10:58:20 +01:00
Günther Deschner
9b1878e538 s3-spoolss: disallow storing an invalid devmode size.
Guenther
2011-01-21 10:58:20 +01:00
Michael Adam
5780940092 s3:vfs:shadow_copy2: fix indentation in _SHADOW2_NEXT_SMB_FNAME
Autobuild-User: Michael Adam <obnox@samba.org>
Autobuild-Date: Fri Jan 21 10:57:45 CET 2011 on sn-devel-104
2011-01-21 10:57:45 +01:00
Volker Lendecke
1c1a842071 s3:vfs:shadow_copy2: Fix shadow-copy module for drag&drop from a snapshot
We have to return NT_STATUS_NOT_SAME_DEVICE to trigger the Windows client to
start a copy itself. Unbeknownst to us via the ACLs snapshots are read-only, so
a rename would trigger a EACCES. Unfortunately the MacOS/X finder does not do
the smart NOT_SAME_DEVICE fallback that Windows does.
2011-01-21 10:10:03 +01:00
Christian Ambach
d49d203279 s3:registry correct a debug level
this is not a level 0 message, move it to 10
2011-01-21 10:10:03 +01:00
Volker Lendecke
52c0fb359f s3:winbind: Protect against invalid winbindd_cache entries in lookuprids 2011-01-21 10:10:03 +01:00
Gregor Beck
64f8306e8e s3-net: add roundtrip tests for registry import/export 2011-01-21 10:10:03 +01:00
Volker Lendecke
46a3019d36 s3: Fix the code to immediately disconnect from a non-working ctdbd 2011-01-21 10:10:02 +01:00
Rusty Russell
385d925f7e s3:vfs:gpfs: fix logic when gpfs:winattr is false (the default!)
On my autocluster setup, it's not set.  Maybe it should be?  Otherwise
smbclient and some Windows client programs will get errors like:

        # smbclient //localhost/data -Uadministrator%XXX
        Domain=[VSOFS1] OS=[Unix] Server=[Samba 3.4.2-ctdb-10]
        smb: \> put /etc/resolv.conf resolv.conf
        NT_STATUS_ACCESS_DENIED closing remote file \resolv.conf
        smb: \>

Caused by attempting to update the time on close.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Michael Adam <obnox@samba.org>
2011-01-21 10:10:02 +01:00
Stefan Metzmacher
b7d6d3b840 s3:librpc: remove prototype of dcerpc_binding_handle_set_ref_alloc()
This function doesn't exist anymore.

metze
2011-01-21 07:21:10 +01:00
Jeremy Allison
78b931ce6c Remove all uses of "./" in pathnames - make canonical. This will become important when we need to guarantee canonical names for hashing.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Jan 21 02:59:56 CET 2011 on sn-devel-104
2011-01-21 02:59:56 +01:00
Jeremy Allison
de4b09ca01 Ensure we don't use "./" in findfirst pathnames. Use a directory open of "." instead. 2011-01-20 16:30:28 -08:00
Jeremy Allison
bb54f72b94 Make processing of incoming stream rename paths common between reply_mv and ntrename. Ensure we don't depend on "./" in the streams module. 2011-01-20 16:27:56 -08:00
Stefan Metzmacher
c3ad9bf157 s3:smbd: use anonymous_shared_free() for shared memory signing state
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Thu Jan 20 07:48:29 CET 2011 on sn-devel-104
2011-01-20 07:48:29 +01:00
Stefan Metzmacher
34ea909636 lib/util: s/allocate_anonymous_shared/anonymous_shared_allocate/
metze
2011-01-20 05:31:45 +01:00
Andreas Schneider
4744da8762 s3-param: Fixed code block in max_open_files().
When the HAVE_GETRLIMIT and RLIMIT_NOFILE macros are defined the block
isn't closed.

Autobuild-User: Andreas Schneider <asn@samba.org>
Autobuild-Date: Wed Jan 19 23:10:50 CET 2011 on sn-devel-104
2011-01-19 23:10:50 +01:00
Andreas Schneider
7a97518e12 s3-smbd: Fixed a possible null pointer dereference. 2011-01-19 22:27:48 +01:00
Volker Lendecke
7f87d58900 s3: Add wbinfo --dc-info
wbinfo --dc-info prints the current DC name and IP address. This helps
diagnosing problems that might happen when a later wbinfo --ping-dc fails.

This patch started out by using the SAF and NBT cache entires, but those are
relatively short-lived. So I decided to invent a new gencache entry with a very
long timeout. We need to go via the gencache because when for some reason a
winbind child process is stuck, we can't query it for the current DC it's
connected to. This must eventually go away again when we have a fully async
winbind.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Jan 19 08:40:28 CET 2011 on sn-devel-104
2011-01-19 08:40:28 +01:00
Jeremy Allison
1b43996022 Add DELETE-LN test to show bug #7863 - Unlink may unlink wrong file when hardlinks are involved
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Jan 19 03:06:32 CET 2011 on sn-devel-104
2011-01-19 03:06:32 +01:00
Olly Betts
f8f1711f61 Fix "net usersidlist" not to skip every other user
Remove double increment from for loop over users in get_user_tokens(),
left over from when this used to be a while loop.  Bug was introduced
in 1e39a619.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Jan 19 01:34:29 CET 2011 on sn-devel-104
2011-01-19 01:34:29 +01:00
Günther Deschner
49969e6aeb s3-winbind: no need to include ../librpc/gen_ndr/cli_lsa.h in
winbindd/winbindd_msrpc.c.

Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Wed Jan 19 00:37:46 CET 2011 on sn-devel-104
2011-01-19 00:37:46 +01:00
Günther Deschner
5efe6566a0 s3-rpc_client: no need to include ../librpc/gen_ndr/ndr_lsa_c.h anymore.
Guenther
2011-01-18 23:54:31 +01:00
Günther Deschner
6feed0c9d2 s3-netlogon: no need to include ../librpc/gen_ndr/ndr_lsa_c.h anymore.
Guenther
2011-01-18 23:54:31 +01:00
Günther Deschner
6ed4121d54 s3-netlogon: no need to include ../librpc/gen_ndr/cli_samr.h anymore.
Guenther
2011-01-18 23:54:31 +01:00
Günther Deschner
430664d769 s3-net: use correct spoolss header in net rpc.
Guenther
2011-01-18 23:54:31 +01:00
Günther Deschner
66bc2f9127 s3-net: use correct spoolss header in net_ads.c.
Guenther
2011-01-18 23:54:30 +01:00
Jeremy Allison
7754b75065 Fix error where Windows client spoolss returns WERR_INVALID_DATA W_ERROR(0x0000000D)
on opening a printer. We can't return zero for devmode->size. Guenther please check !

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Tue Jan 18 23:45:33 CET 2011 on sn-devel-104
2011-01-18 23:45:33 +01:00
Andreas Schneider
93da0aab97 s3-rpc_client: Fixed status check of dcerpc_lsa_lookup_sids_noalloc.
Autobuild-User: Andreas Schneider <asn@samba.org>
Autobuild-Date: Mon Jan 17 17:35:50 CET 2011 on sn-devel-104
2011-01-17 17:35:50 +01:00
Andreas Schneider
296a958c57 s3-rpc_client: Fixed return values of dcerpc_lsa_lookup_sids_generic. 2011-01-17 16:50:55 +01:00
Andreas Schneider
ad65605643 s3-auth: Fixed account lockout check. 2011-01-17 16:50:50 +01:00
Volker Lendecke
9b94f36605 s3: Make sure we call wbcAuthenticateUserEx correctly
There are cases where we fill in params.password.response.lm_data with non-NULL
where params.password.response.lm_length is 0. wbcAuthenticateUserEx does not
like that.

I haven't been able to reproduce this with smbclient yet, I've seen it with a
proprietary smb client implementation.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Jan 17 16:30:11 CET 2011 on sn-devel-104
2011-01-17 16:30:11 +01:00
Stefan Metzmacher
528bcedbc5 s3:build: don't use librpc/gen_ndr/cli_echo.[ch] anymore
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Mon Jan 17 09:34:12 CET 2011 on sn-devel-104
2011-01-17 09:34:12 +01:00
Stefan Metzmacher
494e57d913 s3:torture: use dcerpc_echo_X() functions
metze
2011-01-17 08:48:25 +01:00
Stefan Metzmacher
85db5c9f8f s3:rpcclient: use dcerpc_echo_X() functions
metze
2011-01-17 08:48:25 +01:00
Volker Lendecke
d3abc90401 s3: Avoid a few calls to cli_errstr
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Jan 17 08:47:25 CET 2011 on sn-devel-104
2011-01-17 08:47:25 +01:00
Volker Lendecke
c7a5933e4b s3: Remove some unused code 2011-01-17 08:03:43 +01:00
Volker Lendecke
6f3e11088c s3: Convert cli_lock64 to cli_smb 2011-01-17 08:03:43 +01:00
Volker Lendecke
dd2f234412 s3: Convert cli_lock to use cli_locktype 2011-01-17 08:03:43 +01:00
Volker Lendecke
0e2854f743 s3: Convert cli_locktype to cli_smb 2011-01-17 08:03:43 +01:00
Volker Lendecke
7b054ecaed s3: Make passing up "result_parent" from cli_smb optional 2011-01-17 08:03:43 +01:00
Volker Lendecke
b33f1147a6 s3: Remove unused cli_send_keepalive 2011-01-17 08:03:42 +01:00
Volker Lendecke
6e684c8460 s3: Remove unused cli_send/receive_trans 2011-01-17 08:03:42 +01:00
Volker Lendecke
cba5a26734 s3: Convert try_trans2 to cli_trans 2011-01-17 08:03:42 +01:00
Volker Lendecke
8ac68fc3cb s3: Convert cli_api to cli_trans 2011-01-17 08:03:42 +01:00
Volker Lendecke
cb412d22eb s3: Make cli_setpathinfo_basic use cli_setpathinfo 2011-01-17 08:03:42 +01:00
Volker Lendecke
21d5485e06 s3: Add cli_setpathinfo 2011-01-17 08:03:42 +01:00
Volker Lendecke
2068b96dce s3: Rename cli_setpathinfo->cli_setpathinfo_basic 2011-01-17 08:03:42 +01:00