Volker Lendecke [Thu, 14 May 2009 13:39:52 +0000 (15:39 +0200)]
Remove two unused variables
Günther Deschner [Wed, 13 May 2009 14:38:26 +0000 (16:38 +0200)]
s3-netapi: implement NetShutdownInit_r and NetShutdownAbort_r.
Guenther
Günther Deschner [Wed, 13 May 2009 14:38:00 +0000 (16:38 +0200)]
s3-netapi: add example code for NetShutdownInit and NetShutdownAbort.
Guenther
Günther Deschner [Wed, 13 May 2009 14:35:45 +0000 (16:35 +0200)]
s3-netapi: add NetShutdownInit and NetShutdownAbort to public API.
Guenther
Günther Deschner [Wed, 13 May 2009 14:27:58 +0000 (16:27 +0200)]
s3-netapi: add NetShutdownInit and NetShutdownAbort skeletons.
Guenther
Günther Deschner [Wed, 13 May 2009 14:17:36 +0000 (16:17 +0200)]
s3-build: re-run make samba3-idl.
Guenther
Günther Deschner [Wed, 13 May 2009 14:16:33 +0000 (16:16 +0200)]
s3-netapi: add NetShutdownInit and NetShutdownAbort.
I know, they don't exist as such calls on windows but having them in
libnetapi.so would be very handy.
Guenther
Volker Lendecke [Thu, 14 May 2009 09:47:25 +0000 (11:47 +0200)]
Fix a type-punned warning
Volker Lendecke [Thu, 14 May 2009 09:47:09 +0000 (11:47 +0200)]
Add some const
Volker Lendecke [Thu, 14 May 2009 10:13:24 +0000 (12:13 +0200)]
Fix some nonempty blank lines
Andrew Bartlett [Wed, 13 May 2009 19:51:40 +0000 (05:51 +1000)]
s4:nbtd Use str_list_make_single() to turn iname->wins_server into a list
Andrew Bartlett [Wed, 13 May 2009 12:20:10 +0000 (22:20 +1000)]
s4:libnet Use str_list_make_single() in resolv code
Andrew Bartlett [Wed, 13 May 2009 07:13:57 +0000 (17:13 +1000)]
dsdb:schema Use str_list_make_empty() to create an empty list
Andrew Bartlett [Wed, 13 May 2009 06:54:44 +0000 (16:54 +1000)]
s4:torture Use str_list_make_single where appropriate
Andrew Bartlett [Wed, 13 May 2009 06:49:34 +0000 (16:49 +1000)]
Add new functions and tests: str_list_make_empty(), str_list_make_single()
Derrell Lipman [Wed, 13 May 2009 18:51:43 +0000 (14:51 -0400)]
What to do about debugging in a multi-threaded application?
- For now, punt. Any thread that requests debug to stderr will establish that
for all threads.
Derrell
Derrell Lipman [Wed, 13 May 2009 18:37:17 +0000 (14:37 -0400)]
Thread-safe protection: libsmbclient initialization
- Begin converting init functions to use SMB_THREAD_ONCE. libsmbclient
module-wide initialization is now moved into a separate function and called
via SMB_THREAD_ONCE.
- libsmbclient counts users (contexts) so that it can release global resources
when the last context is closed. That count of contexts is now protected by
a mutex.
Derrell
Derrell Lipman [Wed, 13 May 2009 18:33:21 +0000 (14:33 -0400)]
Take advantage of the easier-to-use thread macros
- Now that we initialize for the non-thread-safe case in the macro, there's no
need to do it here too.
Derrell
Derrell Lipman [Wed, 13 May 2009 18:31:40 +0000 (14:31 -0400)]
Make the thread functions a bit easier to use
- Create separate macros for lock and unlock so that it's easier to identify
which request is being made.
- Initialize *ponce in the SMB_THREAD_ONCE macro in the non-thread-safe case,
rather than requiring each init function to determine if it's in the
non-thread-safe case and manually initialize.
Derrell
Stefan Metzmacher [Wed, 13 May 2009 06:33:33 +0000 (08:33 +0200)]
s3:libsmb: move read_smb_send/recv() static in async_smb.c
metze
Stefan Metzmacher [Tue, 12 May 2009 12:47:02 +0000 (14:47 +0200)]
s3:libsmb: let cli_smb_chain_send() also return NTSTATUS
metze
Bo Yang [Tue, 12 May 2009 05:51:25 +0000 (13:51 +0800)]
s3:libsmb: return NT_STATUS_CONNECTION_INVALID if the fd is -1
This way we can destinguish between requests which failed
because the connection broke after they were triggered
and the requests which are started on an already broken
connection.
This also moves the check to cli_smb_req_iov_send()
where it really belongs.
metze
Bo Yang [Wed, 13 May 2009 14:00:05 +0000 (22:00 +0800)]
Revert "s3: checkin .po for pam_winbind" because of license issue.
This reverts commit
8611f03dbb0c45d8755725232508cff258b426d5.
Derrell Lipman [Wed, 13 May 2009 13:49:59 +0000 (09:49 -0400)]
Allow a parameter to smb_thread_once's initialization function
- This should make life easier for ourselves. We're no longer constrained to
the semantics of pthread_once, so let's allow passing a parameter to the
initialization function. Some of Samba's init functions return a
value. Although I haven't searched, I suspect that some of the init
functions require in input parameters. The parameter added here can be used
for input, output, or both, as necessary... or ignored, as is now done in
talloc_stackframe_init().
Derrell
Günther Deschner [Tue, 12 May 2009 12:15:01 +0000 (14:15 +0200)]
s3-printing: no need to define struct table_node 4 times.
Guenther
Günther Deschner [Wed, 13 May 2009 13:17:46 +0000 (15:17 +0200)]
s3-net: Fix bug 6340: don't segfault when cleartext trustdom pwd could not be retrieved.
Guenther
Günther Deschner [Wed, 13 May 2009 13:15:30 +0000 (15:15 +0200)]
s4-selftest: match new name of RPC-SAMR-ACCESSMASK.
Guenther
Günther Deschner [Wed, 13 May 2009 13:14:20 +0000 (15:14 +0200)]
s4-smbtorture: split RPC-SAMR-ACCESSMASK into several tests.
Guenther
Günther Deschner [Wed, 13 May 2009 01:18:07 +0000 (03:18 +0200)]
s4-smbtorture: cosmetic cleanup for RPC-SAMR-ACCESSMASK.
Guenther
Volker Lendecke [Wed, 13 May 2009 10:59:00 +0000 (12:59 +0200)]
Remove an unused struct definition
Bo Yang [Wed, 13 May 2009 10:59:55 +0000 (18:59 +0800)]
s3: checkin .po for pam_winbind
Signed-off-by: Bo Yang <boyang@samba.org>
Bo Yang [Thu, 14 May 2009 02:13:12 +0000 (10:13 +0800)]
s3: return proper error code in cli_smb_req_send
Signed-off-by: Bo Yang <boyang@samba.org>
Karolin Seeger [Wed, 13 May 2009 08:07:56 +0000 (10:07 +0200)]
s3/packaging: Fix build on RHEL when ccache is not available.
This fixes bug #5832.
Patch was provided by D.L. Meyer <dlmeyer [at] uiuc.edu>.
Thanks for reporting and providing the patch!
Karolin
Derrell Lipman [Wed, 13 May 2009 01:32:33 +0000 (21:32 -0400)]
Fix broken smb_thread_once function (again)
- It would help if smb_thread_once did, eventually, set the variable that
prevents the init function from being run again. Sigh. It must be getting
late.
Derrell
Derrell Lipman [Wed, 13 May 2009 01:22:23 +0000 (21:22 -0400)]
Fix broken smb_thread_once function
- We can't set *ponce=true before running the function because although other
threads wouldn't re-run the initialization function, they could potentially
proceed beyond the initialization point while the first thread was still
running the initialization function. If a second thread gets to an
SMB_THREAD_ONCE() call while one with the same ponce is running, we need to
ensure that it enters smb_thread_once() to await the mutex and then recheck
whether *ponce is set or not. My original comment about other "once"
functions possibly being called from within this "once" function is
irrelevant since those other ones would have their own unique ponce.
Derrell
Zack Kirsch [Mon, 11 May 2009 17:10:43 +0000 (17:10 +0000)]
s3 onefs: Self-contend level2 oplocks on BRL
Tim Prouty [Wed, 13 May 2009 00:38:10 +0000 (17:38 -0700)]
s3 onefs: Fix ignore sacl parameter
Tim Prouty [Tue, 12 May 2009 23:32:32 +0000 (16:32 -0700)]
s3: Fix strict locking with chained reads
Move the strict lock/unlock code down a level for reads to avoid
calling chain_reply before the unlock.
Aravind Srinivasan [Thu, 16 Apr 2009 20:42:40 +0000 (20:42 +0000)]
s3: Fallback to the legacy sid_to_(uid|gid) instead of returning NULL.
This is very similar to
be1dfff02d562e42a7847bd02fed8538630d3f41
Dan Sledz [Mon, 6 Apr 2009 01:12:10 +0000 (01:12 +0000)]
s3 auth: Make debug message louder and more useful
Timur I. Bakeyev [Tue, 12 May 2009 23:59:04 +0000 (01:59 +0200)]
Use PYTHON_VER rather than PYTHON_VERSION, as the first is already
commonly used (e.g. in the FreeBSD ports system).
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>
Günther Deschner [Tue, 12 May 2009 12:12:31 +0000 (14:12 +0200)]
s3-spoolss: move SPL_ARCH_X defines to IDL.
Guenther
Günther Deschner [Tue, 12 May 2009 12:11:03 +0000 (14:11 +0200)]
spoolss: add SPOOLSS_ARCHITECTURE_ALL to IDL.
Guenther
Günther Deschner [Tue, 12 May 2009 23:38:06 +0000 (01:38 +0200)]
s3-build: re-run make samba3-idl.
Guenther
Günther Deschner [Tue, 12 May 2009 23:37:30 +0000 (01:37 +0200)]
initshutdown: add shutdown reason codes.
Guenther
Günther Deschner [Tue, 12 May 2009 20:46:36 +0000 (22:46 +0200)]
s3-netdomjoin-gui: prepare to call out for NetRenameMachineInDomain() to rename computers
in domains.
Guenther
Jelmer Vernooij [Tue, 12 May 2009 22:34:57 +0000 (00:34 +0200)]
s4 config-summary: Fix printing of which libraries are external and
internal.
Günther Deschner [Tue, 12 May 2009 21:50:37 +0000 (23:50 +0200)]
error-codes: add some more WERRORs to table.
These tables really should be auto-generated at some point...
Guenther
Günther Deschner [Tue, 12 May 2009 21:47:21 +0000 (23:47 +0200)]
s3-netdomjoin-gui: Fix join prompt dialog test.
Guenther
Günther Deschner [Tue, 12 May 2009 20:15:04 +0000 (22:15 +0200)]
s3-netdomjoin-gui: use NetServerGetInfo() level 101 to get hostname.
Guenther
Günther Deschner [Tue, 12 May 2009 20:12:47 +0000 (22:12 +0200)]
s3-netdomjoin-gui: inspect the correct computername string before
enabling/disabling the change button.
Guenther
Jeremy Allison [Tue, 12 May 2009 18:45:37 +0000 (11:45 -0700)]
Clean up assignments to iov_base, ensure it's always cast to void *. This should quieten some warnings with picky compilers on the buildfarm.
Jeremy.
Jeremy Allison [Tue, 12 May 2009 17:38:00 +0000 (10:38 -0700)]
Fix the last few format arg missmatches I missed.
Jeremy.
Volker Lendecke [Tue, 12 May 2009 15:47:22 +0000 (17:47 +0200)]
Convert response.extra_data.data from malloc to talloc
Volker Lendecke [Thu, 12 Mar 2009 16:23:17 +0000 (17:23 +0100)]
Fix bug 6157
This patch picks the alphabetically smallest one of the multi-value attribute
"uid". This fixes a regression against 3.0 and also becomes deterministic.
Günther Deschner [Tue, 12 May 2009 09:41:14 +0000 (11:41 +0200)]
s3-printing: Fix vlp testprinter application.
Jeremy, we cannot just access cache_path() here without calling lp_load and
friends as well as parsing configfile from the commandline in order to make
"make test/selftest" find the correct conffile with path, etc.
I just changed it to pass the target tdbfilename as an argument, ok ?
Guenther
Michael Adam [Fri, 8 May 2009 22:10:51 +0000 (00:10 +0200)]
s3:build: extend the support fo Debian GNU/kFooBar to kOpenSolaris
As suggested by Robert Millan.
Michael
Michael Adam [Thu, 30 Apr 2009 19:59:07 +0000 (21:59 +0200)]
s3:build: support non-linux gnu ports
This is based on a patch by the debian package maintainers,
adapted for the merged branch.
Michael
Michael Adam [Wed, 6 May 2009 00:25:08 +0000 (02:25 +0200)]
s3:loadparm: free the file_list at the start of loadparm
This should reduce the waste of memory when using "config file"
or "config backend". It also reduces the risk of triggering
reloads due to some old unused files being checked.
Michael
Michael Adam [Wed, 6 May 2009 00:09:56 +0000 (02:09 +0200)]
s3:loadparm: refactor freeing of file_list out into free_file_lists()
Michael
Michael Adam [Mon, 11 May 2009 05:43:07 +0000 (07:43 +0200)]
s3:proto.h: remove old param/params.c prototype
Michael
Jeremy Allison [Tue, 12 May 2009 06:23:17 +0000 (23:23 -0700)]
Fix warning about unused label with no sendfile.
Jeremy.
Jeremy Allison [Tue, 12 May 2009 05:33:32 +0000 (22:33 -0700)]
Fix definition of smb_thread_once - must return int not void as
it's used in a ? : comparison macro.
Jeremy.
Jeremy Allison [Tue, 12 May 2009 04:56:57 +0000 (21:56 -0700)]
Fix a bunch of compiler warnings about wrong format types.
Should make Solaris 10 builds look cleaner.
Jeremy.
Jeremy Allison [Tue, 12 May 2009 00:29:48 +0000 (17:29 -0700)]
Hopefully fix the buildfarm. Add some debug level 10 messages
I used to track down the vlp problem, change the vlp test printer
not to use a static path of /tmp/vlp.tdb for the virtual print
database (as this will eventually fill up). Cause it to use
a virtual print database inside the cachepath.
Jeremy.
Jeremy Allison [Tue, 12 May 2009 00:29:16 +0000 (17:29 -0700)]
Ensure documentation matches the tdb_util function usage.
Jeremy.
Günther Deschner [Fri, 8 May 2009 09:25:56 +0000 (11:25 +0200)]
s3-samr: implement _samr_RidToSid().
Guenther
Günther Deschner [Mon, 11 May 2009 21:47:37 +0000 (23:47 +0200)]
s3-samr: Let _samr_TestPrivateFunctionsDomain() return NT_STATUS_NOT_SUPPORTED to make RPC-SAMR happy.
Guenther
Günther Deschner [Mon, 11 May 2009 22:19:56 +0000 (00:19 +0200)]
s4-smbtorture: skip SetMemberAttributesOfGroup in RPC-SAMR for s3 as well.
Guenther
Günther Deschner [Mon, 11 May 2009 21:46:45 +0000 (23:46 +0200)]
s4-smbtorture: Skip secdesc set calls for non-user objects in RPC-SAMR for Samba3.
Note that they are skipped for all objects while testing Samba4.
Guenther
Günther Deschner [Mon, 11 May 2009 21:46:11 +0000 (23:46 +0200)]
s4-smbtorture: Fix order of assert args in test_TestPrivateFunctionsDomain() in RPC-SAMR.
Guenther
Günther Deschner [Mon, 11 May 2009 21:13:26 +0000 (23:13 +0200)]
s4-smbtorture: switch to use torture_context in RPC-SAMR.
Guenther
Günther Deschner [Mon, 11 May 2009 20:44:58 +0000 (22:44 +0200)]
s4-smbtorture: remove trailing whitespace in RPC-SAMR.
Guenther
Volker Lendecke [Mon, 11 May 2009 21:07:24 +0000 (23:07 +0200)]
Fix some nonempty blank lines
Derrell Lipman [Mon, 11 May 2009 18:16:52 +0000 (14:16 -0400)]
Correct typos; semicolons instead of commas
Günther Deschner [Mon, 11 May 2009 16:45:46 +0000 (18:45 +0200)]
s3-samr: Fix Bug #5859, renaming of samr objects failed due to samr setuserinfo access checks.
Torture test to follow...
Guenther
Jeremy Allison [Mon, 11 May 2009 16:42:08 +0000 (09:42 -0700)]
Add checks for non_root mode to help buildfarm spoolss tests.
Reviewed by Guenther.
Jeremy.
Günther Deschner [Mon, 11 May 2009 16:27:40 +0000 (18:27 +0200)]
s3-lsa: Fix _lsa_LookupNames2() server implementation which always returned a NULL sid_array since 3.2.0.
Found by torture test.
This makes it possible to search for users while adding them to groups via
windows usermanager.
Guenther
Günther Deschner [Mon, 11 May 2009 14:29:39 +0000 (16:29 +0200)]
s3-selftest: enable RPC-LSA-LOOKUPNAMES against Samba 3.
Guenther
Günther Deschner [Mon, 11 May 2009 14:28:42 +0000 (16:28 +0200)]
s4-smbtorture: add very basic RPC-LSA-LOOKUPNAMES test.
Guenther
Günther Deschner [Mon, 11 May 2009 14:40:26 +0000 (16:40 +0200)]
s4-smbtorture: add optional very simple reply checks to lsa lookup name tests.
Guenther
Stefan Metzmacher [Mon, 11 May 2009 13:54:55 +0000 (15:54 +0200)]
s4:smb_server: return after we have processed an invalid smb2 request
metze
Volker Lendecke [Mon, 13 Apr 2009 20:26:46 +0000 (22:26 +0200)]
Move SMB2 constants to a separate file
Volker Lendecke [Sun, 12 Apr 2009 17:11:09 +0000 (19:11 +0200)]
Fix SMB2_CAP_DFS
Günther Deschner [Mon, 11 May 2009 12:54:04 +0000 (14:54 +0200)]
s4-smbtorture: remove trailing whitespace in RPC-LSA test.
Guenther
Günther Deschner [Mon, 11 May 2009 12:51:41 +0000 (14:51 +0200)]
s4-smbtorture: use struct torture_context in RPC-LSA.
Guenther
Günther Deschner [Mon, 11 May 2009 08:30:05 +0000 (10:30 +0200)]
s3-docs: document "net dom renamecomputer".
Guenther
Günther Deschner [Fri, 8 May 2009 19:56:17 +0000 (21:56 +0200)]
s3-net: add "net dom renamecomputer" to rename machines in a domain.
dmarkey, please test :)
Guenther
Derrell Lipman [Mon, 11 May 2009 03:04:00 +0000 (23:04 -0400)]
Use bool instead of int for a boolean variable
Derrell Lipman [Mon, 11 May 2009 02:58:12 +0000 (22:58 -0400)]
Optimize smb_thread_once usage by not calling it if known already called
- The macro SMB_THREAD_ONCE now tests whether the "once" variable is already
set, and if so avoids calling smb_thread_once().
Derrell
Derrell Lipman [Mon, 11 May 2009 02:40:20 +0000 (22:40 -0400)]
Panic upon mutex lock or unlock failure
- It's a serious error if we can't lock or unlock a mutex in
smb_thread_once(). Panic instead of just displaying a DEBUG message.
Derrell
Derrell Lipman [Mon, 11 May 2009 02:31:37 +0000 (22:31 -0400)]
Provide a libsmbclient interface for programs requiring threads
- This adds two functions: smbc_thread_posix() which provides access to the
internal threading implementation using pthread; and smbc_thread_impl()
where the user provides each of the functions required by Samba, to give
access to the thread implementation's native capabilities.
Derrell
Derrell Lipman [Mon, 11 May 2009 02:27:54 +0000 (22:27 -0400)]
Don't require external use of internal enum smb_thread_lock_type
- Internally, when locking or unlocking a mutex, we'll pass one of the
values of enum smb_thread_lock_type. That enum is not available to users
providing a thread implementation. Externally, we'll document the integer
values which will be passed to their lock_mutex function, but not require
them to access our internal header file.
Derrell
Derrell Lipman [Mon, 11 May 2009 01:55:23 +0000 (21:55 -0400)]
Replace external thread "once" with an internal implementation
Jeremy, please check...
- I'm in the process of providing an interface in libsmbclient to the
recently-added threading capabilities. In the process, I discovered that
different thread implementations have varying types for the variable passed
to the thread_impl_once() function. pthreads, for example, uses type
pthread_once_t. Since Samba needs to internally declare these variables, it
would need to know the exact type required by each thread implementation's
function. After considering multiple methods of obtaining an appropriately
sized variable, I decided that for the basic "once" functionality required
by Samba, it would be much simpler to just implement our own "once"
functionality. We don't require cancellation points et all. This commit adds
an smb_thread_once() function that is implemented using an internal
mutex. The mutex itself uses the implementation's create_mutex
function. This eliminates the need for the user to provide a smb_thread_once
function pointer and the entire issue of that function's first parameter.
Derrell
Volker Lendecke [Sun, 10 May 2009 05:42:55 +0000 (07:42 +0200)]
Fix an unitialized variable warning
Volker Lendecke [Sat, 9 May 2009 19:12:33 +0000 (21:12 +0200)]
wb_int_trans -> wb_simple_trans in wbclient.c
Volker Lendecke [Sat, 9 May 2009 19:01:09 +0000 (21:01 +0200)]
Add wb_simple_trans_send/recv
Simo Sorce [Sat, 9 May 2009 15:26:14 +0000 (11:26 -0400)]
Pass also sername to check password script
Volker Lendecke [Sat, 9 May 2009 11:46:08 +0000 (13:46 +0200)]
Fix the mangle1 test
Volker Lendecke [Sat, 9 May 2009 09:12:52 +0000 (11:12 +0200)]
Do not call SMB_VFS_GET_REAL_FILENAME if the name is mangled
The GPFS get_real_file name does not know about mangled names. Tim, if onefs
does not either, you need this bugfix :-)
In case onefs does 8.3 names, we need to pass the mangled flag down to
SMB_VFS_GET_REAL_FILENAME to give GPFS a chance say ENOTSUPP and do the
fallback.