kai/samba.git
16 years agor23410: Merge the core of the cluster code.
Volker Lendecke [Sun, 10 Jun 2007 17:02:09 +0000 (17:02 +0000)]
r23410: Merge the core of the cluster code.

I'm 100% certain I've forgotten to merge something, but the main code
should be in. It's mainly in dbwrap_ctdb.c, ctdbd_conn.c and
messages_ctdbd.c.

There should be no changes to the non-cluster case, it does survive make
test on my laptop.

It survives some very basic tests with ctdbd enables, I did not do the
full test suite for clusters yet.

Phew...

Volker
(This used to be commit 15553d6327a3aecdd2b0b94a3656d04bf4106323)

16 years agor23408: Remove a bogus comment
Volker Lendecke [Sun, 10 Jun 2007 10:18:03 +0000 (10:18 +0000)]
r23408: Remove a bogus comment
(This used to be commit 0442e680eeacb56852e200fdf6f78e4972ecad68)

16 years agor23407: While verifying a bug I found out that for some reason
Simo Sorce [Sat, 9 Jun 2007 22:45:21 +0000 (22:45 +0000)]
r23407: While verifying a bug I found out that for some reason
the code to add a machine was different then the one used
to add a user, the old code led to the machine SID not being
built out correctly allocationg a new RID out of the passdb
but instead by using the old algorithmic method.
This may easily end up in creating duplicated SID when the
RID counter get close to the values built by the algorithmic method.

Simo.
(This used to be commit e077142aa39ad927a16e0d04874857bbc171ce07)

16 years agor23406: Evn if not strictly currently necessary do check for correct
Simo Sorce [Sat, 9 Jun 2007 19:29:35 +0000 (19:29 +0000)]
r23406: Evn if not strictly currently necessary do check for correct
init also in idmap_nss and idmap_passdb for coherency and to
prevent errors in future if we change the init functions to
actually do something and not just return NT_STATUS_OK
(This used to be commit 86f532c1b0cf7961b8331bb212c3ed2084fda3fc)

16 years agor23404: Fix wrong (and missing) action on error condition in ldap reply evaluation...
Simo Sorce [Sat, 9 Jun 2007 18:18:24 +0000 (18:18 +0000)]
r23404: Fix wrong (and missing) action on error condition in ldap reply evaluation loop
Fixes one of the segfaults in bug #4667
(This used to be commit 176e1c0b692b9509a29bbbb2b35ad821dfb0d5aa)

16 years agor23402: Got bitten by a talloc hierarchy. Make sure we alloc
Jeremy Allison [Sat, 9 Jun 2007 00:27:28 +0000 (00:27 +0000)]
r23402: Got bitten by a talloc hierarchy. Make sure we alloc
off the pipe ctx now ->names is part of the containing
struct.
Jeremy.
(This used to be commit 02fd43490212e9ff8f784ce4d33d64566d58fd82)

16 years agor23400: Fix lsa crash bug #4683. The "names" enum struct
Jeremy Allison [Sat, 9 Jun 2007 00:13:07 +0000 (00:13 +0000)]
r23400: Fix lsa crash bug #4683. The "names" enum struct
in a lookup_sidX reply isn't optional - like the
lookup_sidX query it needs to be defined in the
struct.
All this will go away with PIDL (thank goodness....).
Jerry - I think this is a showstopper to be merged
for 3.0.25b.
I'll be watching the build farm to see if anything broke.
Jeremy.
(This used to be commit 9300b92f7a51eb80fdc039d8dad23ea9ce82aa8f)

16 years agor23398: Support membership of >16 groups on Darwin by making sure we opt in to the
James Peach [Sat, 9 Jun 2007 00:10:26 +0000 (00:10 +0000)]
r23398: Support membership of >16 groups on Darwin by making sure we opt in to the
dynamic group resolution mechanism when switching UNIX credentials.
(This used to be commit b5cb21e951550fe836b0ef5febc037af9a7f51ec)

16 years agor23396: Make VFS callbacks static. Mark operations as OPAQUE because they
James Peach [Fri, 8 Jun 2007 23:08:41 +0000 (23:08 +0000)]
r23396: Make VFS callbacks static. Mark operations as OPAQUE because they
do not pass through.
(This used to be commit b9d6eee5d4d0894ded88455675a470cbf04d8f45)

16 years agor23393: Support BSD group semantics by making sure that the effective GID is always
James Peach [Fri, 8 Jun 2007 22:25:55 +0000 (22:25 +0000)]
r23393: Support BSD group semantics by making sure that the effective GID is always
passed as the first GID when calling setgroups(2).
(This used to be commit 6ebaf856c1d27f2fbfa0444a5c6c17c4331d2780)

16 years agor23391: Second part of the patch for Apple.
Jeremy Allison [Fri, 8 Jun 2007 19:58:32 +0000 (19:58 +0000)]
r23391: Second part of the patch for Apple.

Change the sequence :

gain_root();
sys_setgroups(ngroups, groups);
become_id(uid, gid);

to a function call :

set_unix_security_ctx(uid_t uid, gid_t gid, int ngroups, gid_t *groups)

James - should be safe for you to create a Darwin-specific
version of this function now.

Jeremy.
(This used to be commit 8ee982b3678be41ce8b4f4c1df428dcbf897ccbe)

16 years agor23390: First part of the patch to make Apple's life easier.
Jeremy Allison [Fri, 8 Jun 2007 19:52:18 +0000 (19:52 +0000)]
r23390: First part of the patch to make Apple's life easier.
Doing this in two stages to make it very easy to
review. Context switching must look like :

gain_root();
sys_setgroups(ngroups, groups);
become_id(uid, gid);

Re-arrange order so these three calls are always
seen together.

Next will be to turn these into a function.

Jeremy.
(This used to be commit eb537185ee4a3f460709267c843c9303a9bb61b5)

16 years agor23389: Disabling ACL support on Darwin/Mac OS X for now.
Michael Adam [Fri, 8 Jun 2007 14:37:29 +0000 (14:37 +0000)]
r23389: Disabling ACL support on Darwin/Mac OS X for now.

Current configure check detects posix ACL support
but compile of modules/vfs_posixacl.c fails due
to missing defines in sys/acl.h:
ACL_USER, ACL_USER_OBJ, ACL_GROUP, ACL_GROUP_OBJ, ACL_OTHER,
ACL_MASK, ACL_WRITE, ACL_READ

It has to be investigated, if this can be fixed within
the posixacl vfs module or if we need a darwinacl module.

Michael
(This used to be commit f275991c2fc92cf1e140e4cf8f8bc1a7fbcbbb0c)

16 years agor23387: 1. This unifies the POSIX ACL detection code:
Michael Adam [Fri, 8 Jun 2007 12:32:13 +0000 (12:32 +0000)]
r23387: 1. This unifies the POSIX ACL detection code:
Linux, FreeBSD and other (which?) ACL implementations
are now checked in the same block instead of in three
separate blocks. This was inspired by Timur Bakeyev
in Bug #4543. Since bugzilla is currently unavailable
this patch is probably slightly different from Timurs
original patch. This should finally fix Bug #4543.

2. The default of the --with-acl-support configure
option is changed to "auto" (which is actually the
same as "yes"). So configure tries to detect acl
support by default. This had been discussed with
Metze and others.

Michael
(This used to be commit 234b32c7bc18b3e450329dbee496d9f600a642ee)

16 years agor23380: netr_getdcname returns WERROR not NTSTATUS.
Günther Deschner [Fri, 8 Jun 2007 10:29:46 +0000 (10:29 +0000)]
r23380: netr_getdcname returns WERROR not NTSTATUS.

Guenther
(This used to be commit 5e75ea7f2b568d76c8ced5f43171741532cc97c2)

16 years agor23379: Whitespace cosmetics, to reduce irritating diffs...
Michael Adam [Fri, 8 Jun 2007 10:15:19 +0000 (10:15 +0000)]
r23379: Whitespace cosmetics, to reduce irritating diffs...

Michael
(This used to be commit df30f8d5c2999590aabe1e87f92fbdbafa7052aa)

16 years agor23377: Patch from Bjoern Jacke <bjoern@j3e.de> to deal
Gerald Carter [Thu, 7 Jun 2007 13:35:39 +0000 (13:35 +0000)]
r23377: Patch from Bjoern Jacke <bjoern@j3e.de> to deal
with non-GNU implementations of tr in autogen.sh
(This used to be commit ccc466c56a93906ef5dfa1079796b1a8a44b43c0)

16 years agor23376: More warnings
Volker Lendecke [Thu, 7 Jun 2007 07:53:33 +0000 (07:53 +0000)]
r23376: More warnings
(This used to be commit a8ec53f022ff66053231818d4a60568675079ede)

16 years agor23375: Fix a 64-bit warning
Volker Lendecke [Thu, 7 Jun 2007 07:49:43 +0000 (07:49 +0000)]
r23375: Fix a 64-bit warning
(This used to be commit c592b562fa793c9fb3bd0d84074d4ffaa8f63b64)

16 years agor23372: Remove restriction on string length for rpcclient commands.
Jeremy Allison [Thu, 7 Jun 2007 01:13:43 +0000 (01:13 +0000)]
r23372: Remove restriction on string length for rpcclient commands.
Jeremy.
(This used to be commit a2cf87f58a0a1dbc468a78347880a2f07443b1d8)

16 years agor23371: Fix the misleading comment I added - it really *should*
Jeremy Allison [Thu, 7 Jun 2007 00:14:06 +0000 (00:14 +0000)]
r23371: Fix the misleading comment I added - it really *should*
say "locks chain and returned record", not
"and returns record"
Jeremy.
(This used to be commit bf951e3d7f0310cc624abab11a7fb04c50770425)

16 years agor23370: Traverse in tdb wasn't consistently using the
Jeremy Allison [Thu, 7 Jun 2007 00:00:45 +0000 (00:00 +0000)]
r23370: Traverse in tdb wasn't consistently using the
travlocks.lock_rw for lock read/write types, it
was sometimes using it (tdb_next_lock) and
sometimes explicitly using F_WRLCK instead.
Change this to consistently use travlocks.lock_rw
only.
I'm pretty sure about this fix (else I woudn't
be checking this in :-) but tridge and Volker
please review.
Jeremy.
(This used to be commit d0b64567630ec02eb437aa713847bb23a8be8a60)

16 years agor23368: Make "winbind:rpc only" a full blown parameter. Thanks to Karolin for
Volker Lendecke [Wed, 6 Jun 2007 13:02:24 +0000 (13:02 +0000)]
r23368: Make "winbind:rpc only" a full blown parameter. Thanks to Karolin for
the patch :-)
(This used to be commit 07b71a02aef15b75d281cabeb7140db1bc0bb283)

16 years agor23367: check the "use mmap" option for ldb too
Andrew Tridgell [Wed, 6 Jun 2007 13:02:14 +0000 (13:02 +0000)]
r23367: check the "use mmap" option for ldb too
(This used to be commit 15345bbc73b28d07c069fde33d3d4c1f21f107d3)

16 years agor23363: Activate rep_pread and rep_pwrite in lib/replace/replace.h.
Michael Adam [Wed, 6 Jun 2007 09:27:43 +0000 (09:27 +0000)]
r23363: Activate rep_pread and rep_pwrite in lib/replace/replace.h.
This fixes the build on a SuSE 6.1. :-)
I guess this had been merely forgotten.

But beware: The implementations of rep_pread and rep_pwrite are
not thread safe.

Michael
(This used to be commit 5f5b93149216eb57872e4291336685b96948681e)

16 years agor23362: Respect "use mmap" in tdb_wrap_open(). Tridge, you might want to merge
Volker Lendecke [Wed, 6 Jun 2007 07:46:38 +0000 (07:46 +0000)]
r23362: Respect "use mmap" in tdb_wrap_open(). Tridge, you might want to merge
this in your tree.
(This used to be commit c0f40eb5846f617d9c421136b0e1ea593c8d8458)

16 years agor23359: Fix bug #4537, fix from jens.nissen@gmx.net.
Jeremy Allison [Wed, 6 Jun 2007 00:42:10 +0000 (00:42 +0000)]
r23359: Fix bug #4537, fix from jens.nissen@gmx.net.
Jeremy.
(This used to be commit 6ea7127f8e592f989a6263e360e809dcfdf98ef0)

16 years agor23358: Fix from Justin Maggard <jmaggard@infrant.com> - ensure we don't
Jeremy Allison [Tue, 5 Jun 2007 23:35:39 +0000 (23:35 +0000)]
r23358: Fix from Justin Maggard <jmaggard@infrant.com> - ensure we don't
expire a password if it's explicitly set as ACB_PWNOTREQ.
Jeremy.
(This used to be commit 2ea5a6bd334e31201aa6f93f5c51e42924d36ebd)

16 years agor23357: timespec_current() was returning the wrong ns time
Jeremy Allison [Tue, 5 Jun 2007 19:17:05 +0000 (19:17 +0000)]
r23357: timespec_current() was returning the wrong ns time
(multiplying tv_sec, not tv_usec).
Jeremy.
(This used to be commit bafd3b93f9ce74d7a8e2d6b36735f0977a22882c)

16 years agor23356: We missed to add the 'c' character to the list of valid ones for
Simo Sorce [Tue, 5 Jun 2007 12:58:18 +0000 (12:58 +0000)]
r23356: We missed to add the 'c' character to the list of valid ones for
shell escaping.

I hate this kind of bugs more than how Jeremy hates off by ones :(

Simo.
(This used to be commit 42d846ff870f93b7eaca316f04c12104330bbca8)

16 years agor23355: Fix some more build warnings.
Günther Deschner [Tue, 5 Jun 2007 10:49:05 +0000 (10:49 +0000)]
r23355: Fix some more build warnings.

Guenther
(This used to be commit 23e25bba8fafb31492b517d63f0a00c5ec07d5da)

16 years agor23354: Fix build warning.
Günther Deschner [Tue, 5 Jun 2007 10:23:56 +0000 (10:23 +0000)]
r23354: Fix build warning.

Guenther
(This used to be commit 4ad456e988f0b9b65890b4cf6a4f1b63ef1585b8)

16 years agor23352: Don't generate stamp-h. AFAICT it is never used.
James Peach [Tue, 5 Jun 2007 06:10:09 +0000 (06:10 +0000)]
r23352: Don't generate stamp-h. AFAICT it is never used.
(This used to be commit d47d1a44e74b3cd02cddf1cf2f22460987102b66)

16 years agor23349: Fix from Steve Langasek <vorlon@debian.org> to
Jeremy Allison [Tue, 5 Jun 2007 01:59:37 +0000 (01:59 +0000)]
r23349: Fix from Steve Langasek <vorlon@debian.org> to
allow SIGTERM to cause nmbd to exit on awaiting
an interface to come up. Debian bug #168079
Jeremy.
(This used to be commit 9ee310f3d68426da552f084ebcffef6b8ebbf612)

16 years agor23348: Fix connection reporting on SIGUSR2 (noticed by
Jeremy Allison [Mon, 4 Jun 2007 23:51:19 +0000 (23:51 +0000)]
r23348: Fix connection reporting on SIGUSR2 (noticed by
Herb).
Jeremy.
(This used to be commit dcb617e550c98de8a4bdcb9b1f7f78ba008fc138)

16 years agor23347: Fix Coverity 363. Dead code elimination.
Jeremy Allison [Mon, 4 Jun 2007 23:31:34 +0000 (23:31 +0000)]
r23347: Fix Coverity 363. Dead code elimination.
Jeremy.
(This used to be commit 4524ee2dbcd5c1c66085032de67c6d083f91cb8a)

16 years agor23346: Fix offline caching with XP/Vista. It was an off-by-one
Jeremy Allison [Mon, 4 Jun 2007 22:29:23 +0000 (22:29 +0000)]
r23346: Fix offline caching with XP/Vista. It was an off-by-one
in storing the access mask. I shouldn't have made this
mistake. Damn. Fixes bug #4673.
Jeremy
(This used to be commit 84801d4e83786b9de3d0875a317ca9ed8ff5b3e4)

16 years agor23345: Stop Coverity from getting confused.
Jeremy Allison [Mon, 4 Jun 2007 19:58:11 +0000 (19:58 +0000)]
r23345: Stop Coverity from getting confused.
Jeremy.
(This used to be commit 8e83e4267260201777c753c4e3849d65fd20ae8f)

16 years agor23344: Better error message
Volker Lendecke [Mon, 4 Jun 2007 19:50:30 +0000 (19:50 +0000)]
r23344: Better error message
(This used to be commit 4042d2cdd2797e2f675ddeb0d288327ca55d9f5b)

16 years agor23343: Fix error return
Volker Lendecke [Mon, 4 Jun 2007 19:45:41 +0000 (19:45 +0000)]
r23343: Fix error return
(This used to be commit 0014ee44b87a4a109c897ffec5f9c38eea442571)

16 years agor23342: Stop Coverity from getting confused.
Jeremy Allison [Mon, 4 Jun 2007 19:29:40 +0000 (19:29 +0000)]
r23342: Stop Coverity from getting confused.
Jeremy.
(This used to be commit 34144c63ad0d776c0b01f6bd3ce378921f2d31cd)

16 years agor23341: pdb interfaces should be versioned. As SAMBA_3_0 and SAMBA_3_0_26
Jeremy Allison [Mon, 4 Jun 2007 19:03:33 +0000 (19:03 +0000)]
r23341: pdb interfaces should be versioned. As SAMBA_3_0 and SAMBA_3_0_26
are now identical, use the same version number (16) for both.
Jeremy.
(This used to be commit f2ac311ed408e1f17f468945b34289d4c6b915cc)

16 years agor23340: Fix typo in debug ouput. Found by Karolin Seeger <ks@sernet.de>.
Michael Adam [Mon, 4 Jun 2007 14:48:26 +0000 (14:48 +0000)]
r23340: Fix typo in debug ouput. Found by Karolin Seeger <ks@sernet.de>.
Michael
(This used to be commit 81c7d152b2cb8fafa3d510c3d35fb86bae1e0856)

16 years agor23337: fix a crash bug...I wonder why only HP-UX 11.00 ans 11.11 noticed
Stefan Metzmacher [Mon, 4 Jun 2007 14:25:52 +0000 (14:25 +0000)]
r23337: fix a crash bug...I wonder why only HP-UX 11.00 ans 11.11 noticed
it via a SIGBUS...

I missed to remove the samba3 specifc code path to tdb_open_ex()
when I synced lib/tdb/ with samba4. The explicit cast in on tdb_open_ex()
dropped the compiler warning :-(

metze
(This used to be commit 815d2101715d6646fc15ac9f2853cf727cf7fcd8)

16 years agor23335: as not all source files include replace.h/config.h
Stefan Metzmacher [Mon, 4 Jun 2007 09:57:59 +0000 (09:57 +0000)]
r23335: as not all source files include replace.h/config.h
before unistd.h we need to pass -D_FILE_OFFSET_BITS=64
together with -Dpread=pread64 -Dpwrite=pwrite64

metze
(This used to be commit 1716613cc7ab8dec739adadeadbf18937682cd5c)

16 years agor23330: always include "winbind_client.h" as first header
Stefan Metzmacher [Mon, 4 Jun 2007 08:03:46 +0000 (08:03 +0000)]
r23330: always include "winbind_client.h" as first header
as it brings in "replace.h" this will bring in "config.h"

metze
(This used to be commit d0b7b77fc437288d2e14099209bfd435bd7f1da4)

16 years agor23328: don't typedef ber_tag_t when it's already done by openldap
Stefan Metzmacher [Mon, 4 Jun 2007 08:01:48 +0000 (08:01 +0000)]
r23328: don't typedef ber_tag_t when it's already done by openldap
headers on HP-UX (lber_types.h defines _LBER_TYPES_H).

metze
(This used to be commit bd1b28dd3e47c2f244baba4a239b0d6dca57f2d2)

16 years agor23323: merged ldb changes from 3.0.26
Andrew Tridgell [Mon, 4 Jun 2007 01:51:18 +0000 (01:51 +0000)]
r23323: merged ldb changes from 3.0.26
(This used to be commit 7c9a5c2a3f012a06e9550dc0de7df460c2fd943b)

16 years agor23321: remove unused variable (due to mad merge from Centeris patches)
Gerald Carter [Mon, 4 Jun 2007 01:33:00 +0000 (01:33 +0000)]
r23321: remove unused variable (due to mad merge from Centeris patches)
(This used to be commit 1b68302e344df1e35becd26c1959ab0f94d8b3bc)

16 years agor23317: Fix the build: r23315 was a little overeager in removing the
Michael Adam [Sun, 3 Jun 2007 20:24:25 +0000 (20:24 +0000)]
r23317: Fix the build: r23315 was a little overeager in removing the
INIPARSER_OBJ from the bin/net target altogether. I re-add it
in the guise of @BUILD_INIPARSER@ (to NET_OBJ). This also
eliminates the need to have @BUILD_INIPARSER@ in the deps for
the bin/net target.
Same procedure for the pam_winbindd module.

Michael
(This used to be commit 114a80dd2e1ddc577ae6ab336878f48317ce3e98)

16 years agor23316: Ouch... This would not have run in production without cluster code
Volker Lendecke [Sun, 3 Jun 2007 19:56:41 +0000 (19:56 +0000)]
r23316: Ouch... This would not have run in production without cluster code
anyway.
(This used to be commit ca1d0ff03d038372d5886ff1aa409494721142f4)

16 years agor23315: - don't use the builtin and -liniparser together in bin/net
Stefan Metzmacher [Sun, 3 Jun 2007 16:21:40 +0000 (16:21 +0000)]
r23315: - don't use the builtin and -liniparser together in bin/net
- unify handling on @BUILD_INIPARSER@

btw: nsswitch/pam_winbind.c doesn't compile anymore on SuSE 10.2!
     I think we should build pam modules by default to notice things
     like this in the build-farm...

metze
(This used to be commit 1f30ac2905989cb27daffcf864cf931c1cf76b67)

16 years agor23314: For some systems it's needed to inject replace.h into
Stefan Metzmacher [Sun, 3 Jun 2007 15:51:09 +0000 (15:51 +0000)]
r23314: For some systems it's needed to inject replace.h into
the iniparser source code, I do it in a way we can still have
a unmodified copy of iniparser in source/iniparser/
and have the wrapper stuff in source/iniparser_build/.

If the build-farm is happy with this I'll merge it to 3_0_26
tomorrow...

metze
(This used to be commit 43d390d1863e7d8c1cb7c47f2272ee78661c352a)

16 years agor23313: Janitor for tridge:
Volker Lendecke [Sun, 3 Jun 2007 06:54:51 +0000 (06:54 +0000)]
r23313: Janitor for tridge:

we need to use tdb_wrap_open in both these backends to allow for
multiple opens.  This is done for notify.tdb. Otherwise we die when a
2nd share with notify is setup
(This used to be commit 40dcccfcf91737ba658fd9e733a431001649d255)

16 years agor23312: As per Volker, rename the "windbind:ads" parameter "winbind:rpc only".
James Peach [Sat, 2 Jun 2007 21:12:47 +0000 (21:12 +0000)]
r23312: As per Volker, rename the "windbind:ads" parameter "winbind:rpc only".
(This used to be commit cbd083efb9a00db68be24cde10b96da06390d970)

16 years agor23309: sync lib/replace with SAMBA_4_0
Stefan Metzmacher [Sat, 2 Jun 2007 09:10:08 +0000 (09:10 +0000)]
r23309: sync lib/replace with SAMBA_4_0

metze
(This used to be commit 20965d800fcac0c55853fb12cdd36b5836fc7e56)

16 years agor23307: move readahead stuff out of libreplace and make it samba3 specific
Stefan Metzmacher [Sat, 2 Jun 2007 08:30:42 +0000 (08:30 +0000)]
r23307: move readahead stuff out of libreplace and make it samba3 specific
as we can't replace this function in libreplace and we do
the some stuff for other function in the same way.

metze
(This used to be commit 5e9b84326b4c65799e6fa6550de870d9a7ebba85)

16 years agor23305: merge from samba4:
Stefan Metzmacher [Sat, 2 Jun 2007 08:14:27 +0000 (08:14 +0000)]
r23305: merge from samba4:

fix large file support on HP-UX 11.00 and 11.11

metze
(This used to be commit 85a07e24f0c9ea7062b7f8d02279e994bc1b5dc5)

16 years agor23302: Refactor vfs_gpfs module, fix problems with chmod Tridge has found during...
Alexander Bokovoy [Sat, 2 Jun 2007 06:28:38 +0000 (06:28 +0000)]
r23302: Refactor vfs_gpfs module, fix problems with chmod Tridge has found during ctdb tests
(This used to be commit e150e42ac59494a1da12bb5c9da8c9c935780924)

16 years agor23300: AFAICT these are not needed. Jerry, can you please review and revert
James Peach [Fri, 1 Jun 2007 19:42:23 +0000 (19:42 +0000)]
r23300: AFAICT these are not needed. Jerry, can you please review and revert
if this is not correct.
(This used to be commit 7aa40efd28edcd4d6a5a3a2d790df0af1f5f3fea)

16 years agor23299: Fix the build for !WITH_SENDFILE.
James Peach [Fri, 1 Jun 2007 19:34:08 +0000 (19:34 +0000)]
r23299: Fix the build for !WITH_SENDFILE.
(This used to be commit 87b92e7ebda018f1d6a588748e282dc1a2c50613)

16 years agor23297: This introduces the winbind:ads parameter which defaults to True. Setting it
Volker Lendecke [Fri, 1 Jun 2007 18:39:50 +0000 (18:39 +0000)]
r23297: This introduces the winbind:ads parameter which defaults to True. Setting it
to False makes winbind use RPC and not LDAP methods to connect to the DCs,
even when it figured out they are AD.
(This used to be commit 1c1f710e3e2e222c9d91a5650844c1db5ebd5a3a)

16 years agor23295: Apply proto_exists and bin/.dummy dependencies consistently for all
James Peach [Fri, 1 Jun 2007 16:06:40 +0000 (16:06 +0000)]
r23295: Apply proto_exists and bin/.dummy dependencies consistently for all
binaries.  Fix vfs_zfsacl build rule in SAMBA_3_0.
(This used to be commit 07fa76c6c7f54a95889415e27ce6d7c199a6a12c)

16 years agor23291: Undo the somewhat naive change of r23279:
Michael Adam [Fri, 1 Jun 2007 12:24:57 +0000 (12:24 +0000)]
r23291: Undo the somewhat naive change of r23279:
The clear text presentaion of the sid in the ldap expression
does work with w2k3 but not with w2k....

Thanks to Guenther for advising me of this issue.

Michael
(This used to be commit 7e6b0c19f816b52cca257c2837680e70f1af8594)

16 years agor23290: Fix another small and stupid but severe typo.
Michael Adam [Fri, 1 Jun 2007 12:18:16 +0000 (12:18 +0000)]
r23290: Fix another small and stupid but severe typo.
Hopfully, I have finally got this right... :-)

Michael
(This used to be commit 2190d838e49692fcba8f3a393dd30db937899fed)

16 years agor23287: Use talloc_move instead of talloc_steal as this is what I really
Michael Adam [Fri, 1 Jun 2007 10:10:57 +0000 (10:10 +0000)]
r23287: Use talloc_move instead of talloc_steal as this is what I really
wanted to do.

Michael
(This used to be commit f2adae8fc197be1e40769dbda27ee5b1085c3c64)

16 years agor23284: Oh what a nasty typo! This gave me some headache,
Michael Adam [Thu, 31 May 2007 23:58:56 +0000 (23:58 +0000)]
r23284: Oh what a nasty typo! This gave me some headache,
with talloc randomly failing.

Hey, shouldn't TALLOC_ARRAY _not_ return NULL when
requested to allocate an array with zero entries? :-)

Michael
(This used to be commit 7170d2e9f5381b405e0ea902d2b2463e5ca804e6)

16 years agor23283: Use a temporary talloc context in ads:lookup_groupmem.
Michael Adam [Thu, 31 May 2007 23:55:37 +0000 (23:55 +0000)]
r23283: Use a temporary talloc context in ads:lookup_groupmem.
And clean up unused stuff at the end.
Daringly, I use talloc_steal at some point, where it
appears natural to me.

Michael
(This used to be commit f2a29643bdb08bf026eaf974424f4eadfc920ca0)

16 years agor23279: Replace occurrence of sid_binstring inside lookup_groupmem
Michael Adam [Thu, 31 May 2007 22:02:49 +0000 (22:02 +0000)]
r23279: Replace occurrence of sid_binstring inside lookup_groupmem
by sid_string_static.
(This used to be commit ba3026dce02d554313647c3d6825bfe0d30d6ffc)

16 years agor23274: merge CloseEventlog() pidl conversion from 3.0.26 && fix a few init call...
Gerald Carter [Thu, 31 May 2007 17:59:04 +0000 (17:59 +0000)]
r23274: merge CloseEventlog() pidl conversion from 3.0.26 && fix a few init call renames for svcctl in the previous commit
(This used to be commit ebcae48ec10fefa74efcc3563cff50e3b9c2388c)

16 years agor23272: Fix main event loop - reviewed by Volker.
Jeremy Allison [Thu, 31 May 2007 17:26:30 +0000 (17:26 +0000)]
r23272: Fix main event loop - reviewed by Volker.
Jeremy.
(This used to be commit dfb4cb5d2bd6c50ad2ecfa729d76daccfc43925a)

16 years agor23271: merge service control pidl change for CloseServiceHandle() from SAMBA_3_0_26
Gerald Carter [Thu, 31 May 2007 17:24:30 +0000 (17:24 +0000)]
r23271: merge service control pidl change for CloseServiceHandle() from SAMBA_3_0_26
(This used to be commit 0b1bc3521fac52f3164b6cc9e053abc3ceabf5e7)

16 years agor23269: Regenerate svcctl files after IDL fixes
Gerald Carter [Thu, 31 May 2007 15:46:01 +0000 (15:46 +0000)]
r23269: Regenerate svcctl files after IDL fixes
(This used to be commit 92c505bf7f15a79c6e32a38b2d218f65b0283507)

16 years agor23268: Rename some variables in the svcctl.idl to prevent
Gerald Carter [Thu, 31 May 2007 15:43:40 +0000 (15:43 +0000)]
r23268: Rename some variables in the svcctl.idl to prevent
redeclaration compile failures in the generated client
code.
(This used to be commit 87b37de8ad4e91e75530996dde0900b6e1fed622)

16 years agor23263: Remove an unused variable -- Fix Coverity ID 358
Volker Lendecke [Thu, 31 May 2007 09:23:51 +0000 (09:23 +0000)]
r23263: Remove an unused variable -- Fix Coverity ID 358
(This used to be commit c5929aa82b20e8a3877e6196c17bc9118cb399b0)

16 years agor23253: Add some debugging output.
Michael Adam [Wed, 30 May 2007 22:40:26 +0000 (22:40 +0000)]
r23253: Add some debugging output.
(This used to be commit bd90573fbb3ff243f343fcfc61b6228aa70b13e3)

16 years agor23252: Complete the reworking of the ads lookup_groupmem function
Michael Adam [Wed, 30 May 2007 22:04:42 +0000 (22:04 +0000)]
r23252: Complete the reworking of the ads lookup_groupmem function
started in r23070, r23072, r23073, r23078, r23081 and r23082:

After retrieving the list of sids with the extended dn
ldap query, instead of passing all sids to the lsa_lookup_sids
call, now while extracting the sids from the extended dn member
entries, we first try to lookup the sid from cache and only pass
the sids that were not in cache to the lsa_lookup_sids call.

Michael
(This used to be commit 5520c7d8557fe48957c2a85eaba8c3a0e9d8b9e2)

16 years agor23251: whoops! Fix compile error
Gerald Carter [Wed, 30 May 2007 21:55:49 +0000 (21:55 +0000)]
r23251: whoops!  Fix compile error
(This used to be commit 22a3ea40ac69fa3722abf28db845ab284a65ad97)

16 years agor23249: another sync from 3.0.26 for the echo work to rpcclient
Gerald Carter [Wed, 30 May 2007 21:46:03 +0000 (21:46 +0000)]
r23249: another sync from 3.0.26 for the echo work to rpcclient
(This used to be commit 7aa1f89eb369805e3c3e36b4d62dddbea9dfab2f)

16 years agor23248: Merge echo pipe implementation chanegs from SAMBA_3_0_26
Gerald Carter [Wed, 30 May 2007 21:43:48 +0000 (21:43 +0000)]
r23248: Merge echo pipe implementation chanegs from SAMBA_3_0_26
just to stay in sink.  This was more or less just for me
to play with.
(This used to be commit 6c4b85cce0f947771fd9aa93451c53adb1795e3f)

16 years agor23244: Fix loop with nscd and NSS recusive calls.
Gerald Carter [Wed, 30 May 2007 19:47:35 +0000 (19:47 +0000)]
r23244: Fix loop with nscd and NSS recusive calls.

> Here's the problem I hit:
>
> getgrnam("foo") -> nscd -> NSS -> winbindd ->
>   winbindd_passdb.c:nam_to_sid() -> lookup_global_sam_name() ->
>   getgrnam("foo") -> nscd -> ....
>
> This is in the SAMBA_3_0 specifically but in theory could happen
> SAMBA_3_0_25 (or 26) for an unknown group.
>
> The attached patch passes down enough state for the
> name_to_sid() call to be able to determine the originating
> winbindd cmd that came into the parent.  So we can avoid
> making more NSS calls if the original call came in trough NSS
> so we don't deadlock ?  But you should still service
> lookupname() calls which are needed for example when
> doing the token access checks for a "valid groups" from
> smb.conf.
>
> I've got this in testing now.  The problem has shown up with the
> DsProvider on OS X and with nscd on SOlaris and Linux.
(This used to be commit bcc8a3290aaa0d2620e9d391ffbbf65541f6d742)

16 years agor23242: BUG 4671: Fix Makefile syntax error when SMBMOUNT_PROGS is not defined
Gerald Carter [Wed, 30 May 2007 14:53:10 +0000 (14:53 +0000)]
r23242: BUG 4671: Fix Makefile syntax error when SMBMOUNT_PROGS is not defined
(This used to be commit 592e73dc31672c993aad5afde73b1c43dd31eed2)

16 years agor23241: In preparation for the cluster messaging import the parent smbd needs to
Volker Lendecke [Wed, 30 May 2007 13:41:38 +0000 (13:41 +0000)]
r23241: In preparation for the cluster messaging import the parent smbd needs to
respond to events.c style events.
(This used to be commit 476080df3ff19c3c4742928ff50293935e171f99)

16 years agor23236: Another bad merge: Correctly free and unlock the session record in
Volker Lendecke [Wed, 30 May 2007 07:02:40 +0000 (07:02 +0000)]
r23236: Another bad merge: Correctly free and unlock the session record in
session_claim. Jerry, this fixes the hanging smbstatus.

Sorry for that,

Volker
(This used to be commit 86ff82a5df998045185682cf09b2db3d37f01004)

16 years agor23228: Merge cleanup to the gpfs module from Tridge. Also potentially disable
Volker Lendecke [Tue, 29 May 2007 19:54:26 +0000 (19:54 +0000)]
r23228: Merge cleanup to the gpfs module from Tridge. Also potentially disable
gpfs share modes in special situations. This might be split up in
several modules later.
(This used to be commit 553fe9245165ce4a14902daa722935c94ff32d61)

16 years agor23226: Make the "debug prefix timestamp" output a bit more readable by making
Volker Lendecke [Tue, 29 May 2007 19:36:13 +0000 (19:36 +0000)]
r23226: Make the "debug prefix timestamp" output a bit more readable by making
the debug level alway at least 2 digits
(This used to be commit 94d2fd919c268efa3df2661d2ccb32e492c52f53)

16 years agor23225: Attached find a patch that makes use of NetSamLogonEx in
Volker Lendecke [Tue, 29 May 2007 19:31:57 +0000 (19:31 +0000)]
r23225: Attached find a patch that makes use of NetSamLogonEx in
winbind. With this and W2k3 DCs around it is possible to use
more than one winbind on the same machine account, because
NetSamLogonEx does not use the credentials chain.

I added the flag domain->can_do_samlogon_ex because this
only works against W2k3 and with schannel. The theory is to
try if we're AD and have schannel, and fall back to
NetSamLogon if this fails. can_do_samlogon_ex is thus a
protection against multiple failures.

Only checking into 3_0, this needs more review before going
into a production release.

Feel free to comment :-)
(This used to be commit f5d525399b0b03a3d0b223fe72ef0a8a631fc599)

16 years agor23224: Move map_nt_error_from_unix to lib/errmap_unix.c. This function is
Volker Lendecke [Tue, 29 May 2007 19:09:38 +0000 (19:09 +0000)]
r23224: Move map_nt_error_from_unix to lib/errmap_unix.c. This function is
useful even in binaries that don't link in libsmb
(This used to be commit 52545d119277b42a46d13b5b031c85f47d96b84c)

16 years agor23223: Convert a leftover direct tdb access to sessionid.tdb
Volker Lendecke [Tue, 29 May 2007 18:41:16 +0000 (18:41 +0000)]
r23223: Convert a leftover direct tdb access to sessionid.tdb
(This used to be commit 201c8952a812fe0c9be95a71fbc55c12ba8daa55)

16 years agor23222: share_mode_forall() is only for counting and status display stuff, so
Volker Lendecke [Tue, 29 May 2007 18:32:49 +0000 (18:32 +0000)]
r23222: share_mode_forall() is only for counting and status display stuff, so
traverse_read is enough here
(This used to be commit 40991badef046233326815e50097aa7f493790e8)

16 years agor23221: Fix a bad merge, avoid a memory leak and tdb lock problem
Volker Lendecke [Tue, 29 May 2007 18:14:54 +0000 (18:14 +0000)]
r23221: Fix a bad merge, avoid a memory leak and tdb lock problem
(This used to be commit 2e2415655d352708b9799ae5ff4d9276c49cfb3b)

16 years agor23220: Add traverse_read to dbwrap
Volker Lendecke [Tue, 29 May 2007 18:04:38 +0000 (18:04 +0000)]
r23220: Add traverse_read to dbwrap
(This used to be commit b38dc5ffdfe9fdc2879c57dc181815f06b4747fe)

16 years agor23219: Two warnings
Volker Lendecke [Tue, 29 May 2007 17:57:52 +0000 (17:57 +0000)]
r23219: Two warnings
(This used to be commit eccd50abdaed3e4e06cc5da5473ca1beeb3fc49a)

16 years agor23210: Very funny, we thought to use netr_GetDcName (e.g. in winbind) but were using
Günther Deschner [Tue, 29 May 2007 15:27:13 +0000 (15:27 +0000)]
r23210: Very funny, we thought to use netr_GetDcName (e.g. in winbind) but were using
netr_GetDcAnyName all the time (which is the correct thing to do).

Fix the naming and opcode mixup in all branches.

Guenther
(This used to be commit def6464c872a5939f0028837254f2c019d2d71c8)

16 years agor23207: merge net help test fix from SAMBA_3_0_26
Gerald Carter [Tue, 29 May 2007 14:53:46 +0000 (14:53 +0000)]
r23207: merge net help test fix from SAMBA_3_0_26
(This used to be commit dbee1088bb06a4ccb440d372102eb5c105cc4294)

16 years agor23206: remove unreachable code
Gerald Carter [Tue, 29 May 2007 14:53:13 +0000 (14:53 +0000)]
r23206: remove unreachable code
(This used to be commit 6e2bb4836fab5e548429613dea431007af3a7995)

16 years agor23204: Add MSG_SMB_BRL_VALIDATE. Tridge, this is a bit different from your bzr
Volker Lendecke [Tue, 29 May 2007 14:49:19 +0000 (14:49 +0000)]
r23204: Add MSG_SMB_BRL_VALIDATE. Tridge, this is a bit different from your bzr
branch, please check if it fulfils your needs.

Two changes: The validation is not done inside the brlock.c traverse_fn,
it's done as a separate routine.

Secondly, this patch does not call the checker routines in smbcontrol
directly but depends on a running smbd.
(This used to be commit 7e39d77c1f90d9025cab08918385d140e20ca25b)

16 years agor23195: Add void *private_data to brl_forall
Volker Lendecke [Tue, 29 May 2007 13:26:44 +0000 (13:26 +0000)]
r23195: Add void *private_data to brl_forall
(This used to be commit c91b2bdc160d76bf0b0770fe7f92cbc7124d6c3c)

16 years agor23194: cherry pick two fixes from SAMBA_3_0_26
Gerald Carter [Tue, 29 May 2007 13:20:40 +0000 (13:20 +0000)]
r23194: cherry pick two fixes from SAMBA_3_0_26

* strptime() failure check
* make legcacy sid/uid/gid calls static
(This used to be commit 3c9fb1c6f3263c0ce6edbf2a8824c153317a84a3)

16 years agor23192: Remove fallback to looking up group mappings by the
Gerald Carter [Tue, 29 May 2007 13:18:57 +0000 (13:18 +0000)]
r23192: Remove fallback to looking up group mappings by the
Unix name after discussion with Simo.
(This used to be commit 6af4c1a73cdb523e5a81c15128c706a16f76c84d)