Volker Lendecke [Mon, 18 May 2009 05:08:34 +0000 (07:08 +0200)]
Fix broken pipe handling
Metze is right: If we have *any* error at the socket level, we just can
not continue.
Also, apply some defensive programming: With this async stuff someone else
might already have closed the socket.
Volker Lendecke [Mon, 18 May 2009 05:08:28 +0000 (07:08 +0200)]
Fix a type-punned warning
Bo Yang [Mon, 18 May 2009 17:13:36 +0000 (01:13 +0800)]
s3: tevent_req_poll() loops forever when pipe is broken
Signed-off-by: Bo Yang <boyang@samba.org>
Michael Adam [Sun, 17 May 2009 20:15:02 +0000 (22:15 +0200)]
s3:fix bug #6371, unsuccessful net conf setparm leaves empty share
Wrap creation of share and setting of parameter into a transaction.
Michael
Volker Lendecke [Sun, 17 May 2009 09:43:54 +0000 (11:43 +0200)]
s3-events: Not only timed, also immediate events generate a timeout return
Simo Sorce [Sat, 16 May 2009 17:04:06 +0000 (13:04 -0400)]
Move smb_create_user() in samsync
It is not used anywhere else, so make it also static and remove
it from proto.h
Jelmer Vernooij [Sat, 16 May 2009 18:31:59 +0000 (20:31 +0200)]
tevent: Define TALLOC_FREE() if it's not defined yet, to allow building
with released versions of talloc.
Volker Lendecke [Sat, 16 May 2009 16:20:02 +0000 (18:20 +0200)]
Fix static linking of vfs_notify_fam
Volker Lendecke [Sat, 16 May 2009 14:05:37 +0000 (16:05 +0200)]
Fix a typo
Volker Lendecke [Sat, 16 May 2009 13:42:53 +0000 (15:42 +0200)]
s3-events: If immediate requests are pending, the timeout is 0
Volker Lendecke [Sat, 16 May 2009 17:03:37 +0000 (19:03 +0200)]
Fix the merged build -- thanks jelmer for the hint!
Jelmer Vernooij [Sat, 16 May 2009 12:56:37 +0000 (14:56 +0200)]
tevent: Remove python module.
This module didn't have any functionality that we actually used yet, and
it was quite small.
Tevent is quite low level and perhaps doesn't make much sense to expose
directly as a Python module. It was also causing build problems when used with a
system-tevent. We can always back later if necessary.
Jelmer Vernooij [Sat, 16 May 2009 02:14:21 +0000 (04:14 +0200)]
tevent: Install tevent_internal.h in the standalone build.
This is not ideal, but at least it fixes the build of samba-gtk for now.
I've also added a warning about API guarantees at the top of the header.
Samuel Thibault [Sat, 16 May 2009 02:05:53 +0000 (04:05 +0200)]
Fix linker flags on non-Linux GNU platforms.
(e.g. Debian GNU/kFreeBSD)
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
Jelmer Vernooij [Sat, 16 May 2009 02:03:12 +0000 (04:03 +0200)]
Update copies of config.guess and config.sub.
Jelmer Vernooij [Fri, 15 May 2009 23:54:10 +0000 (01:54 +0200)]
tevent: Don't install headers, since we don't install a shared lib
either (from Samba).
Günther Deschner [Fri, 15 May 2009 23:22:28 +0000 (01:22 +0200)]
s3-privileges: add privilege_delete_account().
Guenther
Günther Deschner [Fri, 15 May 2009 23:21:08 +0000 (01:21 +0200)]
s3-privileges: remove trailing whitespace from privileges codes.
Guenther
Jeremy Allison [Fri, 15 May 2009 23:16:47 +0000 (16:16 -0700)]
Oops. Forgot to delete now unused local from the previous patch.
Jeremy.
Ole Hansen [Fri, 15 May 2009 23:13:59 +0000 (16:13 -0700)]
Fix bug #6359 - smbclient -L does not list workgroup for hosts with both IPv4 and IPv6 addresses
Michael Adam [Fri, 15 May 2009 21:35:55 +0000 (23:35 +0200)]
s3:build: fix linking with --disable-shared-libs
Michael
Jeremy Allison [Fri, 15 May 2009 21:20:00 +0000 (14:20 -0700)]
Ensure users with SeAddUser privs get full access to
groups/aliases when opening.
Jeremy.
Jeremy Allison [Fri, 15 May 2009 20:36:43 +0000 (13:36 -0700)]
Add extra abilities for a user with SeAddUsers, so they
can manipulate groups and aliases.
Jeremy.
Jeremy Allison [Fri, 15 May 2009 20:13:01 +0000 (13:13 -0700)]
DeleteUser doesn't need the priv checks, this is done at OpenUser time.
Jeremy.
Günther Deschner [Fri, 15 May 2009 18:05:30 +0000 (20:05 +0200)]
s3-samr: Fix samr access checks in _samr_RemoveMemberFromForeignDomain().
Guenther
Volker Lendecke [Fri, 15 May 2009 19:02:08 +0000 (21:02 +0200)]
Fix bug 6361: Make --rcfile work in smbget
Thanks to j scott <gl@arlut.utexas.edu> for reporting!
Jeff Layton [Fri, 15 May 2009 18:31:28 +0000 (14:31 -0400)]
mount.cifs: directly include sys/stat.h in mtab.c
This file is mysteriously getting included when built via the makefile,
but when you try to build mtab.o by hand it fails to build. Directly
include it to remove any ambiguity.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Günther Deschner [Fri, 15 May 2009 17:43:19 +0000 (19:43 +0200)]
s3-netdomjoin-gui: allow to switch between workgroups/domains with the same name.
Guenther
Günther Deschner [Fri, 15 May 2009 17:42:05 +0000 (19:42 +0200)]
s3-netdomjoin-gui: cosmetic fix for empty hostnames.
Guenther
Günther Deschner [Fri, 15 May 2009 15:06:54 +0000 (17:06 +0200)]
s3-netdomjoin-gui: only gray out labels when not root and not connecting to
remote machines.
Guenther
Michael Adam [Fri, 15 May 2009 16:00:59 +0000 (18:00 +0200)]
s3:swat: hide "config backend" from swat
Michael
Michael Adam [Thu, 14 May 2009 23:46:09 +0000 (01:46 +0200)]
s3:param: prevent includes from being dumped in dump_*() functions.
This fixes bug #4271: testparm should not print includes.
Michael
Michael Adam [Fri, 15 May 2009 13:41:41 +0000 (15:41 +0200)]
s3:build: add install-dbwrap_tool target
Michael
Michael Adam [Fri, 15 May 2009 13:41:26 +0000 (15:41 +0200)]
s3:build dbwrap_tool with make everything
Michael
Jelmer Vernooij [Fri, 15 May 2009 14:02:33 +0000 (16:02 +0200)]
errormap: Remove wbc -> NTSTATUS error map for now. It is not used.
This was breaking the Samba 4 installation since it added dependencies
on header files we weren't installing.
Confirmed with Kai.
Günther Deschner [Fri, 15 May 2009 11:04:01 +0000 (13:04 +0200)]
s3-samr: Fix samr access checks in _samr_SetUserInfo().
Guenther
Günther Deschner [Fri, 15 May 2009 01:10:02 +0000 (03:10 +0200)]
s3-samr: Fix samr access checks in _samr_QueryUserInfo().
Guenther
Günther Deschner [Fri, 15 May 2009 12:34:50 +0000 (14:34 +0200)]
s3-samr: in _samr_QueryUserInfo() make sure to not return any info in error case.
Guenther
Günther Deschner [Thu, 14 May 2009 22:56:54 +0000 (00:56 +0200)]
s3-samr: Fix samr access checks in _samr_SetDomainInfo().
Guenther
Günther Deschner [Thu, 14 May 2009 22:40:14 +0000 (00:40 +0200)]
s3-samr: Fix samr access checks in _samr_QueryDomainInfo().
Guenther
Günther Deschner [Thu, 14 May 2009 22:31:16 +0000 (00:31 +0200)]
s3-samr: use normal integer in r->in.level switch statements.
Guenther
Michael Adam [Fri, 15 May 2009 09:58:17 +0000 (11:58 +0200)]
s3:build: rename OBJ collection for dbwrap_tool consistently
Michael
Michael Adam [Thu, 14 May 2009 23:48:55 +0000 (01:48 +0200)]
s3:first cut at dbwrap_tool - a tdb tool that is CTDB-aware.
This tool (in contrast to tdbtool) reads Samba's configuration
and if clustering = yes, it talks to CTDB instead of accessing
the TDB data bases directly. This is done by simply using
the dbwrap mechanim, just like the Samba daemons.
This first version can read and write int32 and uint32 values
and delete records from a (c)tdb database.
More operations will follow.
This tool can already be useful in CTDB environments, e.g. when
"net idmap restore" fails to set the USER and GROUP HWM keys,
because the methods are deliberately not implemented in
idmap_tdb2.c. You can manually set the high water marks
with
"dbwrap_tool store idmap_tdb2.tdb 'USER HWM' int32 12345"
and
"dbwrap_tool store idmap_tdb2.tdb 'GROUP HWM' int32 67890"
Michael
Jeremy Allison [Thu, 14 May 2009 23:49:34 +0000 (16:49 -0700)]
Turn on SHORTNAME-TEST in torture.
Jeremy.
Jeremy Allison [Thu, 14 May 2009 23:49:18 +0000 (16:49 -0700)]
Make us pass SHORTNAME-TEST.
Jeremy
Jeremy Allison [Thu, 14 May 2009 23:30:11 +0000 (16:30 -0700)]
Make error message clearer on fail.
Jeremy.
Jeremy Allison [Thu, 14 May 2009 23:03:31 +0000 (16:03 -0700)]
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.
Jeremy Allison [Thu, 14 May 2009 23:03:18 +0000 (16:03 -0700)]
Remove one use of mangle_is_8_3(), not needed.
Jeremy.
Jeremy Allison [Thu, 14 May 2009 22:11:50 +0000 (15:11 -0700)]
Fix the core of the SAMR access functions. This passes make test, but
usrmgr fails against it. The core of this patch is to move all the
access mask setup into the _samr_OpenXXX functions, and then have
each specific function check the attached access_mask against the
required bits. We can then go through the MS-SAMR doc and match
things up. Signed off by Guenther, and writespace cleanup removal
by Volker.
Jeremy.
Steve French [Thu, 14 May 2009 20:04:27 +0000 (15:04 -0500)]
Maximum password length check too short in mount.cifs
Windows allows up to 127 byte passwords, and we using a 64 byte limit
in most places and a 16 byte limit when using the "pass=" mount option
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
Andrew Bartlett [Thu, 14 May 2009 15:47:39 +0000 (01:47 +1000)]
Add extensive tests for str_list function behaviour
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