gd/samba/.git
15 years agobuild: move libtdb target further down following common schema like with libtalloc
Michael Adam [Sun, 6 Jul 2008 18:39:45 +0000 (20:39 +0200)]
build: move libtdb target further down following common schema like with libtalloc

Michael
(cherry picked from commit f94b07f0c56928f890ffb1e2aca2c8bfcc954dd5)
(cherry picked from commit ed8622ea9d58620bd5319e5cd5c32ebf7838d6fb)

15 years agobuild: fix uninstalllibnetapi target - handle symlink libnetapi.so
Michael Adam [Sun, 6 Jul 2008 18:38:03 +0000 (20:38 +0200)]
build: fix uninstalllibnetapi target - handle symlink libnetapi.so

and use the defined variables instead of hardcoded bits.
Also move the target into the libnetapi section (forgotten last time).

Michael
(cherry picked from commit 21b6164795344cea45161bc01828ec1127b5b6ab)
(cherry picked from commit f471bcda42f4d504830989f9c69382075c701b39)

15 years agobuild: fix installlibnetapi target - install symlink libnetapi.so (if appropriate)
Michael Adam [Sun, 6 Jul 2008 18:35:13 +0000 (20:35 +0200)]
build: fix installlibnetapi target - install symlink libnetapi.so (if appropriate)

Michael
(cherry picked from commit 59e7827e557c5096fb363051a4cf1835b2a53223)
(cherry picked from commit e4a7abb5f978475493c8c1d10dd078b778a857bf)

15 years agobuild: add a cleanlibnetapi target and use it in make clean
Michael Adam [Sun, 6 Jul 2008 18:28:43 +0000 (20:28 +0200)]
build: add a cleanlibnetapi target and use it in make clean

Michael

(cherry picked from commit ff62887a94a7dd6f09995c820db7d825828bacad)

resolved conflicts
(cherry picked from commit cf7c21409bce6fc39cf62ced54191e7a78ea470b)

15 years agobuild: fix creation of the libnetapi shared lib: create soname library
Michael Adam [Sun, 6 Jul 2008 18:25:16 +0000 (20:25 +0200)]
build: fix creation of the libnetapi shared lib: create soname library

and add the .so file as symlink

Michael
(cherry picked from commit d9af2f7ab6b839e8074a69ce5d1fe66548c08e52)
(cherry picked from commit e278895d41780ba7022a085229d2b0482be5f0ea)

15 years agobuild: move libnetapi related definitions and targets together into the libnetapi...
Michael Adam [Sun, 6 Jul 2008 18:11:50 +0000 (20:11 +0200)]
build: move libnetapi related definitions and targets together into the libnetapi section.

in Makefile.in

Michael

(cherry picked from commit da29e1ce44d4f99b876259fbad892691e2c7d7e0)

resolved conflicts
(cherry picked from commit d3c483ffac09498fc0ebe23b7c9b890586849597)

15 years agobuild: add an uninstalllibtdb target.
Michael Adam [Sun, 6 Jul 2008 12:43:12 +0000 (14:43 +0200)]
build: add an uninstalllibtdb target.

Michael
(cherry picked from commit c50c847f4b9772261f8011f32eec97d8244dccdd)
(cherry picked from commit 25852c3df675cdbbac07d919cb5c088b7146d1ef)

15 years agobuild: fix the installlibtdb target to install the soname file of libtdb.
Michael Adam [Sun, 6 Jul 2008 12:42:30 +0000 (14:42 +0200)]
build: fix the installlibtdb target to install the soname file of libtdb.

and create the .so file as a symlink (if appropriate)

Michael
(cherry picked from commit 5c090762f769b645c411333aef2085362bb2e6cb)
(cherry picked from commit 1fc6b24ac85aee70802d88a9f8280776a0beb3ca)

15 years agobuild: create a cleanlibtdb target and use it in target clean.
Michael Adam [Sun, 6 Jul 2008 12:37:29 +0000 (14:37 +0200)]
build: create a cleanlibtdb target and use it in target clean.

Michael

(cherry picked from commit ebfe13b79b24791bd9c854ac2f239f02796da6bb)

resolved conflicts
(cherry picked from commit 2ae7ab1640b8f8da8c74be5e88480bd3293a4dbf)

15 years agobuild: fix creation of the libtdb shared library.
Michael Adam [Sun, 6 Jul 2008 12:32:36 +0000 (14:32 +0200)]
build: fix creation of the libtdb shared library.

Create the libtdb.so.1 file and create the .so file as the symlink.
Not vice versa.

Michael
(cherry picked from commit 662d666b41b11ae70daf7422b1ced5f86209e608)
(cherry picked from commit dfd2262ca469e7e409e0061ed62c14ac72d5440a)

15 years agobuild: move libtdb related definitions and targets to libtdb section in Makefile.in
Michael Adam [Sun, 6 Jul 2008 11:07:54 +0000 (13:07 +0200)]
build: move libtdb related definitions and targets to libtdb section in Makefile.in

Michael
(cherry picked from commit a4de301af48f4e5b4898751e8836bdb434d047a6)
(cherry picked from commit d0fa43966e5486512e04bd28cf84f24896d035d1)

15 years agobuild: move all libtalloc related definitions into the libtalloc section in Makefile.in
Michael Adam [Sun, 6 Jul 2008 11:02:40 +0000 (13:02 +0200)]
build: move all libtalloc related definitions into the libtalloc section in Makefile.in

Michael
(cherry picked from commit b330892f4b2f9f50fd192e37720217d15fedf1f0)
(cherry picked from commit 8a2c96bd92e2090a7542709819b2f478247da6da)

15 years agobuild: move top level targets for the libs into the corresponding sections in Makefile.in
Michael Adam [Sun, 6 Jul 2008 10:53:21 +0000 (12:53 +0200)]
build: move top level targets for the libs into the corresponding sections in Makefile.in

Michael
(cherry picked from commit 4092059ff0bbb638c937c3f2b977ad431d868331)
(cherry picked from commit ddf6b352fe79e3118e20b50e0f0a981dc44634a9)

15 years agobuild: add more structuring comments to Makefile.in
Michael Adam [Sun, 6 Jul 2008 10:51:04 +0000 (12:51 +0200)]
build: add more structuring comments to Makefile.in

for several shared libs and shared modules section

Michael
(cherry picked from commit 53cc6a3225c0c7baea4d8ea04eefc61283650434)
(cherry picked from commit e5b3718913f52afe7df3b0e017451d9ece330191)

15 years agobuild: add a "make shlibs" target to build all the shared libraries.
Michael Adam [Fri, 23 May 2008 11:42:40 +0000 (13:42 +0200)]
build: add a "make shlibs" target to build all the shared libraries.

Michael
(cherry picked from commit 5a99f59d7514edadbab081dc0c5c28a6ea26972a)
(cherry picked from commit 387707e4e48ebcaf1951d440362c301495903946)

15 years agobuild: add structuring comments for libraries and libtalloc section.
Michael Adam [Sun, 6 Jul 2008 10:39:24 +0000 (12:39 +0200)]
build: add structuring comments for libraries and libtalloc section.

Michael
(cherry picked from commit 3de000890447dd15962fbd6a9b1b3504b9bd1175)
(cherry picked from commit b5ccce5db2f034dbeade68d97f55d973db241321)

15 years agobuild: fix installlibtalloc to not install symlink if the library is not there
Michael Adam [Mon, 7 Jul 2008 14:16:28 +0000 (16:16 +0200)]
build: fix installlibtalloc to not install symlink if the library is not there

Michael
(cherry picked from commit 52ccb52c8e42e748fcc05337849945ddc30d5efa)
(cherry picked from commit 512cf07187c33f17e1724d345fffb4f813fa8768)

15 years agobuild: move libtalloc related targets together.
Michael Adam [Sun, 6 Jul 2008 00:52:09 +0000 (02:52 +0200)]
build: move libtalloc related targets together.

Michael
(cherry picked from commit 01b1e642d72ecccac5277b5f071aab8f6df04c0d)
(cherry picked from commit 9509bfbbb0581d71d15110aa8192c00ef3a89c40)

15 years agobuild: add a cleanlibtalloc target.
Michael Adam [Sun, 6 Jul 2008 00:48:39 +0000 (02:48 +0200)]
build: add a cleanlibtalloc target.

Michael

(cherry picked from commit 5d3c6c3c1c08747c521292ef09648ad528c2dca9)

resolved conflicts
(cherry picked from commit 76cfd3116a0d30301bdb1e728debe615e6caddc3)

15 years agobuild: add an uninstalllibtalloc target
Michael Adam [Sun, 6 Jul 2008 00:40:19 +0000 (02:40 +0200)]
build: add an uninstalllibtalloc target

Michael
(cherry picked from commit 4b6ef6202cd9b6e1e8949c43d0c45c04d4b97438)
(cherry picked from commit 22e28489a7ae01bb7adc994008e6b062b2d74a66)

15 years agobuild: fix creation of link libtalloc.so on some systems.
Michael Adam [Sun, 6 Jul 2008 00:32:09 +0000 (02:32 +0200)]
build: fix creation of link libtalloc.so on some systems.

ln -s -f seem to be unknown on some solaris versions (e.g.).
so if there is an old libtalloc.so around, this will fail.
use rm -f prior to creating the link to circumvent this.

Michael
(cherry picked from commit d913b1e7316e84c1430f9d577f49d3c3e4e7719b)
(cherry picked from commit 1cf4d4aaa4bcec2dcc7b99288f4818b0535fdfad)

15 years agobuild: fix the installlibtalloc target to install SONAME and \.so versions of shared...
Michael Adam [Sun, 6 Jul 2008 00:30:38 +0000 (02:30 +0200)]
build: fix the installlibtalloc target to install SONAME and \.so versions of shared lib.

Michael
(cherry picked from commit 49919889892f258cc669b08417e7569e8f5efaf4)
(cherry picked from commit 03f8b71417188e363d04eacff0904b693a06b339)

15 years agobuild: fix creation of talloc shared lib.
Michael Adam [Sun, 6 Jul 2008 00:29:02 +0000 (02:29 +0200)]
build: fix creation of talloc shared lib.

link the libtalloc.so.1 file and create libtalloc.so as a link

Michael
(cherry picked from commit 946537e6bec904d4a7937eeb6085dfac19c3e2b5)
(cherry picked from commit f75a3ff33255ba3cc12535f1c0405c0a0b2ca410)

15 years agobuild: add ability to use library files of the form NAME.so.VERSION to create version...
Michael Adam [Sun, 6 Jul 2008 00:26:57 +0000 (02:26 +0200)]
build: add ability to use library files of the form NAME.so.VERSION to create version script name.

Michael
(cherry picked from commit b8d13f8773f61863b71bfc9df468f0018b0db0d1)
(cherry picked from commit 3b221c60cc92dfaa7ca7c45b1ee3d8efa0e15197)

15 years agoAdd double-colon where it makes sense.
Jelmer Vernooij [Sun, 18 May 2008 16:39:48 +0000 (18:39 +0200)]
Add double-colon where it makes sense.

(cherry picked from commit 256200e951476ff31c95a7d5621a50ba297ea6e4)

Conflicts resolved (obnox)
(cherry picked from commit df52ff62eb890fd645b1c955d72f4bec90851929)

15 years agoRevert "build: fix bug #5608: link creation for libtalloc.so.1 (and friends) on solar...
Michael Adam [Thu, 14 Aug 2008 09:48:23 +0000 (11:48 +0200)]
Revert "build: fix bug #5608: link creation for libtalloc.so.1 (and friends) on solaris 8"

This reverts commit f4d26db5dfccb962f5ca2cc03e9012a9883e16d8.

In preparation of the library cration / installation changes.

Michael
(cherry picked from commit 8fd80452ec71b621adb48b735229f6214dfca85e)

15 years agoWHATSNEW: Add release date, add hint on printing timeouts.
Karolin Seeger [Fri, 15 Aug 2008 07:45:31 +0000 (09:45 +0200)]
WHATSNEW: Add release date, add hint on printing timeouts.

Karolin
(cherry picked from commit c01f10709b50f26a9513f9a83975c187d9958ecb)

15 years agoWHATSNEW: Update changes since 3.2.1.
Karolin Seeger [Fri, 15 Aug 2008 07:13:32 +0000 (09:13 +0200)]
WHATSNEW: Update changes since 3.2.1.

Karolin
(cherry picked from commit 4f958f09a75f5215044e680cc86edb3eca1c51be)

15 years agoFix show-stopper for 3.2. Smbd depends on group SID
Jeremy Allison [Fri, 15 Aug 2008 04:53:55 +0000 (21:53 -0700)]
Fix show-stopper for 3.2. Smbd depends on group SID
position zero being the primary group sid. Authenicating
via winbindd call returned a non-sorted sid list. This
fixes is for both a winbindd call and a pac list from
an info3 struct. Without this we mess up the
primary group associated with created files. Found by
Herb.
Jeremy.
(cherry picked from commit 5cfa78d6e45477cb952d3b12cc914635842d6251)

15 years agoFix bug #5692 - Core dump in full_audit.so.
Jeremy Allison [Thu, 14 Aug 2008 18:00:47 +0000 (11:00 -0700)]
Fix bug #5692 - Core dump in full_audit.so.
There were some function mismatches in the various GET_NT_ACL modules (some places the fsp parameter has not been removed).
Jeremy.
(cherry picked from commit 12b4ed7c3c10a6a29d108f6a83d961bf19751ca7)

15 years agosmbspool: Fix printing on port 139.
Karolin Seeger [Wed, 13 Aug 2008 19:27:55 +0000 (21:27 +0200)]
smbspool: Fix printing on port 139.

This one was introduced with 8eff35bc.
Thanks to Noèl Köthe for tracking that down!

Karolin
(cherry picked from commit 250f5a40d6e80305220d7cdc6a8f8459d8d0de74)
(cherry picked from commit d7a50f1b22f5ccc5d027f8c2eeb73fa335d49f81)
(cherry picked from commit 50d6d617e5b76c3566b719dffe0058c5a0599dd0)
(cherry picked from commit 8e4f9b935f57f73c0f1a653ac02b59677c1192d1)

15 years agoWHATSNEW: Update changes since 3.2.1.
Karolin Seeger [Thu, 14 Aug 2008 06:52:36 +0000 (08:52 +0200)]
WHATSNEW: Update changes since 3.2.1.

Karolin
(cherry picked from commit 77c25837addde31086151ce174dcbf463b2569f0)

15 years agoFix coverity CID: 594. Resource leak on error path.
Jeremy Allison [Wed, 13 Aug 2008 23:53:28 +0000 (16:53 -0700)]
Fix coverity CID: 594. Resource leak on error path.
Jeremy.
(cherry picked from commit dcd28df09538922369cb613ac95c147365e02c42)

15 years agoFix for bug #5688 from SATOH Fumiyasu <fumiyas@osstech.co.jp>. LPQ process is orphane...
Jeremy Allison [Wed, 13 Aug 2008 23:46:49 +0000 (16:46 -0700)]
Fix for bug #5688 from SATOH Fumiyasu <fumiyas@osstech.co.jp>. LPQ process is orphaned if socket address parameter is invalid.
If the "socket address" parameter is a null string that is an invalid value for Samba 3.2 but valid for Samba 3.0.
Jeremy.
(cherry picked from commit a46dc151f692e6b4bd14d3881f90bca5fe5b9474)

15 years agoFix for bug #5617, reported and patched by Bartosz Antosik antosik@gmail.com.
Jeremy Allison [Wed, 13 Aug 2008 22:48:26 +0000 (15:48 -0700)]
Fix for bug #5617, reported and patched by Bartosz Antosik antosik@gmail.com.
xp/2003 explorer freezes browsing shares on samba ipv6 hosts. Caused by missing
reply packet to SMB printclose packet.
Jeremy
(cherry picked from commit 93c977e80594e20ebd562b1eb8a03d57b9299461)

15 years agoPrevent NT_STATUS 0xF1000000 errors from appearing when
Jim McDonough [Wed, 13 Aug 2008 22:03:51 +0000 (18:03 -0400)]
Prevent NT_STATUS 0xF1000000 errors from appearing when
dos errors are used and there is no error.  It should
be mapped directly to NT_STATUS_OK.  smbclient to older
servers didn't work.
(cherry picked from commit 43054b199cb2a5f12c8e0c2bb14cf2328a945152)

15 years agoWHATSNEW: Update changes since 3.2.1.
Karolin Seeger [Wed, 13 Aug 2008 14:38:18 +0000 (16:38 +0200)]
WHATSNEW: Update changes since 3.2.1.

Karolin
(cherry picked from commit f03ffcb78e4ea8a8bd4a5fa0d26642544314a5e4)

15 years agonetapi: add c++ guard.
Günther Deschner [Tue, 12 Aug 2008 17:38:22 +0000 (19:38 +0200)]
netapi: add c++ guard.

Guenther
(cherry picked from commit 5ea69915a75447d9f66b651ef5601c0a7ac6cfbb)

15 years agoAttempt to fix bug 5684
Volker Lendecke [Tue, 12 Aug 2008 20:31:52 +0000 (22:31 +0200)]
Attempt to fix bug 5684

With the ctdb checkin dde9f3f006 tdb optimized out write lock checks for
write-enabled transaction. Sadly, this also removed the possibility to ever
remove dead records left over from tdb_delete calls within a transaction.

Tridge, please check this! Did dde9f3f006 have any reason beyond performance
optimizations?

Thanks,

Volker
(cherry picked from commit 96d683d3ec1e95cddf9ec96326ebaf8e9cc2079c)

15 years agoI found lots of places where we assume error will be set when calling
Andrew Tridgell [Sun, 10 Aug 2008 00:43:36 +0000 (10:43 +1000)]
I found lots of places where we assume error will be set when calling
one of our virtualised functions, such as db_open(), but error is only
set when a system call fails, and it is not uncommon for us to fail a
function internally without ever making a system call. That led to us
passing back success when a function had in fact failed.

I found two places where we relied on map_nt_error_from_unix()
returning success when errno==0, but lots and lots of places where we
relied on the reverse, so I fixed those two places.

map_nt_error_from_unix() will now always return an error, returning
NT_STATUS_UNSUCCESSFUL if errno is 0
(cherry picked from commit 69d40ca4c1af925d4b0e59ddc69ef8c26e6501d1)
(cherry picked from commit 8c66020a82d9b92fb10d14359b1381d58ad4972b)

15 years agoFix unix_convert() for "*" after changing map_nt_error_from_unix().
Michael Adam [Tue, 12 Aug 2008 12:59:59 +0000 (14:59 +0200)]
Fix unix_convert() for "*" after changing map_nt_error_from_unix().

map_nt_error_from_unix() now assumes that it is called in
an error path and returns an error even for a given errno == 0.
The original behaviour of unix_convert() used the mapping
of errno == 0 ==> NT_STATUS_OK to return success through
an error path.

I think this must have been an oversight, and unix_convert() worked
only by coincidence (or because explicitly using the knowledge
of the conceptually wrong working of map_nt_error_from_unix().

This patch puts this straight by not interpreting errno == 0
as an error condition and proceeding in that case.

Jeremy - please check!

Michael
(cherry picked from commit 736bdf15d934028b579a02dc411aed6c14a437f3)

15 years agoMake sure to always set errno on error path in OpenDir (and hence scan_directory).
Michael Adam [Tue, 12 Aug 2008 13:19:17 +0000 (15:19 +0200)]
Make sure to always set errno on error path in OpenDir (and hence scan_directory).

Michael
(cherry picked from commit 06304f3c5f538c75bfc63c7abc1457d2b4dc0f0b)

15 years agoprint correct test status
Herb Lewis [Tue, 12 Aug 2008 20:38:51 +0000 (13:38 -0700)]
print correct test status
(cherry picked from commit ccd413b8b10c99f18b6369717116765c3397edfb)

15 years agoFix bug 5686 - libsmbclient segfaults with more than one SMBCCTX.
Jeremy Allison [Tue, 12 Aug 2008 20:34:00 +0000 (13:34 -0700)]
Fix bug 5686 - libsmbclient segfaults with more than one SMBCCTX.
Here is a patch to allow many subsystems to be re-initialized. The only
functional change I made was to remove the null context tracking, as the memory
allocated here is designed to be left for the complete lifetime of the program.
Freeing this early (when all smb contexts are destroyed) could crash other
users of talloc.
Jeremy.
(cherry picked from commit 4779f1efccc8364fd8b3ba446aa96ba0bddec689)

15 years agofix build warning.
Günther Deschner [Mon, 11 Aug 2008 09:20:38 +0000 (11:20 +0200)]
fix build warning.

Guenther
(cherry picked from commit eb7c3dc2ca92ef7885eef8f89e4397b5df486b65)

15 years agoWHATSNEW: Update changes since 3.2.1.
Karolin Seeger [Mon, 11 Aug 2008 14:46:15 +0000 (16:46 +0200)]
WHATSNEW: Update changes since 3.2.1.

Karolin
(cherry picked from commit 0099cb0741c159db7f389bcca52a3cc6a3762771)

15 years agofix smb_len calculation for chained requests
Volker Lendecke [Sun, 10 Aug 2008 15:53:35 +0000 (17:53 +0200)]
fix smb_len calculation for chained requests

I think chain_reply() is one of the most tricky parts of Samba. This recursion
needs to go away, we need to sequentially walk the chain list.
(cherry picked from commit 34b56cb54e06f9b38d2bb0a626ec7b04030fc4fa)

15 years agoFix andx offset calculation for more than 2 chained requests
Volker Lendecke [Sun, 10 Aug 2008 15:37:08 +0000 (17:37 +0200)]
Fix andx offset calculation for more than 2 chained requests

Untested code is broken code.... Test follows later, it's quite an intrusive
change to libsmb/
(cherry picked from commit 2abeea64e15f0e8e8c413744de9194bdcedd6f16)

15 years agoOne more build fix. Ensure we have KRB5_AUTH_CONTEXT_USE_SUBKEY defined before we...
Jeremy Allison [Fri, 8 Aug 2008 23:08:36 +0000 (16:08 -0700)]
One more build fix. Ensure we have KRB5_AUTH_CONTEXT_USE_SUBKEY defined before we compile the new code.
Jeremy.
(cherry picked from commit fc309e41a45079d58c03dc6fb0c35ceb4517f0ae)

15 years agoTry and fix the build for systems that don't have krb5_auth_con_set_req_cksumtype().
Jeremy Allison [Fri, 8 Aug 2008 22:16:04 +0000 (15:16 -0700)]
Try and fix the build for systems that don't have krb5_auth_con_set_req_cksumtype().
Jeremy.
(cherry picked from commit 02862653724355b32e0c6e38e0ebcbb1a9954759)

15 years agoAdd Derrick Schommer's <dschommer@F5.com> kerberos delegation patch. Some
Jeremy Allison [Fri, 8 Aug 2008 21:33:00 +0000 (14:33 -0700)]
Add Derrick Schommer's <dschommer@F5.com> kerberos delegation patch. Some
work by me and advice by Love.
Jeremy.
(cherry picked from commit 5f419135ba1acae6bc37692fa77ae1162b62e0e3)

15 years agousing NGROUPS_MAX instead of 32 for the max group value in rep_initgroups() subroutin...
Yannick Bergeron [Fri, 8 Aug 2008 17:32:15 +0000 (13:32 -0400)]
using NGROUPS_MAX instead of 32 for the max group value in rep_initgroups() subroutine in lib/replace/replace.c
(cherry picked from commit 6d6b205e444154e1bd2993d964eff4cf532bacd8)

15 years agoFix bug #5675 with a varient of Tim Waugh's patch,
Jeremy Allison [Fri, 8 Aug 2008 00:56:50 +0000 (17:56 -0700)]
Fix bug #5675 with a varient of Tim Waugh's patch,
as proposed by James Peach.
Jeremy.
(cherry picked from commit 1ee1e8306f3578c19fe015145eb8da1013f7b820)

15 years agoSolve an IBM XL C/C++ compiler error encountered in get_exit_code() auth_errors array...
Yannick Bergeron [Wed, 6 Aug 2008 17:23:00 +0000 (13:23 -0400)]
Solve an IBM XL C/C++ compiler error encountered in get_exit_code() auth_errors array initialization in client/smbspool.c
(cherry picked from commit f6ffc95a363d3ed8aa480ac25e440d2472551891)

15 years agofixed permissions on ctdb databases
Andrew Tridgell [Wed, 6 Aug 2008 06:35:43 +0000 (16:35 +1000)]
fixed permissions on ctdb databases
(cherry picked from commit 123fc3980a83d956bffaa689f3af81bbf81ce1c1)
(cherry picked from commit 61274204b63cf077a826671a9e0d807bd17dfec3)

15 years agofixed a fd leak when trying to regain contact to a domain controller
Andrew Tridgell [Wed, 6 Aug 2008 04:02:45 +0000 (14:02 +1000)]
fixed a fd leak when trying to regain contact to a domain controller
in winbind

When a w2k3 DC is rebooted the 139/445 ports come up before the
udp/389 cldap port. During this brief period, winbind manages to
connect to 139/445 but not to udp 389. It then enters a tight loop
where it leaks one fd each time. In a couple of seconds it runs out of
file descriptors, and leaves winbind crippled after the DC does
finally come up
(cherry picked from commit 57187cafbcc053e75bb54750494df9feabe3a738)
(cherry picked from commit 892e41d60469e1e8adccd2b1ff860210db58dcb0)

15 years agodbwrap: add comment describing behaviour of dbwrap_change_int32_atomic().
Michael Adam [Tue, 5 Aug 2008 21:38:56 +0000 (23:38 +0200)]
dbwrap: add comment describing behaviour of dbwrap_change_int32_atomic().

Michael
(cherry picked from commit f8f21c8e3922806230e240cb54205fc2db7a3619)
(cherry picked from commit 0bdab793c1da9b56790d37ac7d064b67ec51e3a4)

15 years agosecrets: fix replacemend random seed generator (security issue).
Michael Adam [Tue, 5 Aug 2008 21:14:05 +0000 (23:14 +0200)]
secrets: fix replacemend random seed generator (security issue).

This is a regression introduced by the change to dbwrap.
The replacement dbwrap_change_int32_atomic() does not
correctly mimic the behaviour of tdb_change_int32_atomic():
The intended behaviour is to use *oldval  as an initial
value when the entry does not yet exist in the db and to
return the old value in *oldval.

The effect was that:
1. get_rand_seed() always returns sys_getpid() in *new_seed
   instead of the incremented seed from the secrets.tdb.
2. the seed stored in the tdb is always starting at 0 instead
   of sys_getpid() + 1 and incremented in subsequent calls.

In principle this is a security issue, but i think the danger is
low, since this is only used as a fallback when there is no useable
/dev/urandom, and this is at most called on startup or via
reinit_after_fork.

Michael
(cherry picked from commit bfc5d34a196f667276ce1e173821db478d01258b)
(cherry picked from commit c0e764d3878120e9612bbd847e581c6fd6c79532)

15 years agodbwrap: add comment describing behaviour of dbwrap_change_uint32_atomic().
Michael Adam [Tue, 5 Aug 2008 21:13:06 +0000 (23:13 +0200)]
dbwrap: add comment describing behaviour of dbwrap_change_uint32_atomic().

Michael
(cherry picked from commit 7edfb54c865ddcfd5cdcc8c2184b96aaac2d2ec0)
(cherry picked from commit c601ad0d1c5b7f3568fef7592e501b8f6be9c469)

15 years agoidmap_tdb2: fix a race condition in idmap_tdb2_allocate_id().
Michael Adam [Tue, 5 Aug 2008 20:38:44 +0000 (22:38 +0200)]
idmap_tdb2: fix a race condition in idmap_tdb2_allocate_id().

The race is a regression introduced by the change to dbwrap.
It might have led to two concurrent processes returning the same id.

This fix is achieved by changing dbwrap_change_uint32_atomic() to
match the original behaviour of tdb_change_uint32_atomic(), which
is the following: *oldval is used as initial value when
the value does not yet exist and that the old value should be
returned in *oldval.

dbwrap_change_uint32_atomic() is used (only) in idmap_tdb2.c,
to get new ids.

Michael
(cherry picked from commit 72bd83fea7572a6202027b200d192c05023aa633)
(cherry picked from commit f3cdf9e646180837a470e90f8a17d933f07b60c3)

15 years agoWithout stdlib.h we don't get a prototype for free().
Andrew Bartlett [Tue, 17 Jun 2008 12:45:29 +0000 (22:45 +1000)]
Without stdlib.h we don't get a prototype for free().

This test fails if GCC emits any warnings (presumably to detect the
function propertly), but unless we include this message then free()
fail.  Why we need to call free in a configure test is probably
something to blame on valgrind...

Andrew Bartlett
(cherry picked from commit d013f6fadc3e80fabb4a1784207dabc84f9b7dc2)
(cherry picked from commit 91c17ecfd7b07ff948874c3eb7013eb79c5b66ab)

15 years agoWHATSNEW: Start WHATSNEW for 3.2.2.
Karolin Seeger [Tue, 5 Aug 2008 13:14:51 +0000 (15:14 +0200)]
WHATSNEW: Start WHATSNEW for 3.2.2.

Karolin
(cherry picked from commit c06ee7cd99c44f10fd7cf9926fe1511664f53ac3)

15 years agoVERSION: Raise version number up to 3.2.2.
Karolin Seeger [Tue, 5 Aug 2008 13:13:13 +0000 (15:13 +0200)]
VERSION: Raise version number up to 3.2.2.

Karolin
(cherry picked from commit c6d2845fddb6eefc78435356f2d004e4dc95d803)

15 years agoman pages: Improve description of boolean values in smb.conf.5.
Karolin Seeger [Tue, 5 Aug 2008 12:20:32 +0000 (14:20 +0200)]
man pages: Improve description of boolean values in smb.conf.5.

This fixes bug #5378.
Thanks Morton K. Poulsen <morten+bugzilla.samba.org [at] afdelingp.dk>
for reporting!

Karolin
(cherry picked from commit 8195ca2132cbdba396dc35e9d04d4bdc3a8a666c)
(cherry picked from commit 6cb22c3722df8cce64d923034ffb32eb12e23572)

15 years agoman pages: Add documentation about smbclient command "rename".
Karolin Seeger [Tue, 5 Aug 2008 12:10:11 +0000 (14:10 +0200)]
man pages: Add documentation about smbclient command "rename".

This fixes bug #5268.
Thanks to Alexander Franz <a.franz [at] gmx.net> for reporting!

Karolin
(cherry picked from commit 0a93fd2dedfa7fed1ad0b8a5e079bf7be72a4bd5)
(cherry picked from commit 29de36037d9fc4c8eb58059a9c4caccfb2b4d069)

15 years agoWHATSNEW: Update changes since 3.2.0. release-3-2-1
Karolin Seeger [Tue, 5 Aug 2008 06:21:13 +0000 (08:21 +0200)]
WHATSNEW: Update changes since 3.2.0.

Karolin
(cherry picked from commit bdbc8f821063df8f612b83ce6c903270fa985cbf)

15 years agoCompile error on AIX 6.1
Yannick Bergeron [Mon, 4 Aug 2008 17:21:02 +0000 (13:21 -0400)]
Compile error on AIX 6.1
(cherry picked from commit afe139e3272b324df2dec2d4066b351b03792dc8)

15 years agoSamba3 HowTo: Fix duplicate chapter id.
Karolin Seeger [Fri, 1 Aug 2008 12:10:28 +0000 (14:10 +0200)]
Samba3 HowTo: Fix duplicate chapter id.

Karolin
(cherry picked from commit f67b6fd97e177a527e896861f337c2e70541f697)
(cherry picked from commit 7359f89ded09a0916a42d696a217d3100aab25d2)

15 years agoWHATSNEW: Update changes since 3.2.0.
Karolin Seeger [Thu, 31 Jul 2008 07:39:58 +0000 (09:39 +0200)]
WHATSNEW: Update changes since 3.2.0.

Karolin
(cherry picked from commit b562b97872f51abe1bd2fb4d61d91c464d1d0840)

15 years agoFix uninitialized variable.
Jeremy Allison [Wed, 30 Jul 2008 23:22:16 +0000 (16:22 -0700)]
Fix uninitialized variable.
Jeremy.
(cherry picked from commit 5fb17b866642a9f971cce6d9f228b4d52618e42b)

15 years agorpc_client: Bug 5616 - fix session keys also in rpccli_netr_LogonSamLogonEx wrapper.
Günther Deschner [Wed, 30 Jul 2008 17:03:13 +0000 (19:03 +0200)]
rpc_client: Bug 5616 - fix session keys also in rpccli_netr_LogonSamLogonEx wrapper.

Guenther
(cherry picked from commit fef58091408cce0d7870c86f28f78cf9400cf2b6)
(cherry picked from commit 4f62fa50c7d542db4a2b8976d85da590194203f0)

15 years agowinbindd: handle trusted domains without sid.
Günther Deschner [Tue, 29 Jul 2008 10:08:47 +0000 (12:08 +0200)]
winbindd: handle trusted domains without sid.

Guenther
(cherry picked from commit 0c1efc6c89b1a51a94d10971bf0fc515416709b3)
(cherry picked from commit 4f5255d1e5025c4c9ebb0b1f22d800e26bcdfb7f)

15 years agolibwbclient: let wbcStringToSid handle the global NULL sid.
Günther Deschner [Wed, 30 Jul 2008 14:59:11 +0000 (16:59 +0200)]
libwbclient: let wbcStringToSid handle the global NULL sid.

Guenther
(cherry picked from commit 09fed085bea9dae5bb8aacd986deed3d458e3574)
(cherry picked from commit fba8506112938bf714c06da08e0e0725a7eecf3a)

15 years agoman pages: Fix typos in man smbclient.
Karolin Seeger [Tue, 29 Jul 2008 10:03:08 +0000 (12:03 +0200)]
man pages: Fix typos in man smbclient.

Karolin
(cherry picked from commit db843d2faafb3487e3c7df4a3a52d6c71f369e1d)
(cherry picked from commit 3a3640a85daa1a85415c949f9c2b804b4f067dd7)

15 years agoAttempt to fix bug 5616
Volker Lendecke [Mon, 28 Jul 2008 15:52:35 +0000 (17:52 +0200)]
Attempt to fix bug 5616

We were calculating the session key but did not return it to the caller...
(cherry picked from commit 8ab79b1d009d53e414b90e4a0ab8fc7a4889b6df)

15 years agoWHATSNEW: Update changes since 3.2.0.
Karolin Seeger [Mon, 28 Jul 2008 13:26:19 +0000 (15:26 +0200)]
WHATSNEW: Update changes since 3.2.0.

Karolin
(cherry picked from commit 0d4a3c2dfb07663dc9fded298e6b7b6c67029f71)

15 years agoFix an incompatible pointer warning
Volker Lendecke [Fri, 25 Jul 2008 21:30:53 +0000 (23:30 +0200)]
Fix an incompatible pointer warning
(cherry picked from commit 3282f7289b7b33beeaa1ca649651cca6537a69af)

15 years agoFix bug creating files using DOS clients with mixed
Jeremy Allison [Fri, 25 Jul 2008 20:14:57 +0000 (13:14 -0700)]
Fix bug creating files using DOS clients with mixed
case files. Reported by Daniel Johnson <Progman2000@usa.net>.
The smb_set_file_time() call to set the filetimes is failing
because it's using the unmodified name passed in by the
client, not the modified name (matching case on the
disk) that comes out from create_file().
Jeremy.
(cherry picked from commit d54fe83b16c187847a975df373e73d56111d7f21)

15 years agoWHATSNEW: Update changes since 3.2.0.
Karolin Seeger [Fri, 25 Jul 2008 14:31:27 +0000 (16:31 +0200)]
WHATSNEW: Update changes since 3.2.0.

Karolin
(cherry picked from commit a1d0fb1f00432f3bc4d7175dbff1354724ea2b67)

15 years agoFix a race condition in winbind leading to a crash
Volker Lendecke [Fri, 25 Jul 2008 10:08:03 +0000 (12:08 +0200)]
Fix a race condition in winbind leading to a crash

When SIGCHLD handling is delayed for some reason, sending a request to a child
can fail early because the child has died already. In this case
async_main_request_sent() directly called the continuation function without
properly removing the malfunctioning child process and the requests in the
queue. The next request would then crash in the DLIST_ADD_END() in
async_request() because the request pending for the child had been
talloc_free()'ed and yet still was referenced in the list.

This one is *old*...

Volker
(cherry picked from commit 8691709626b0d461de91b8fc9d10c730d1f183dd)

15 years agotalloc_string_sub2: Don't return NULL if src is empty.
Karolin Seeger [Wed, 23 Jul 2008 15:07:56 +0000 (17:07 +0200)]
talloc_string_sub2: Don't return NULL if src is empty.

This fixes BUG #5635.

Finished print jobs were not removed from the $PRINTER.tdb file if
"printing=cups".

In print_queue_update, talloc_string_sub2 is used to assemble the
"lprm command". In the case of using "printing=cups", the default
"lprm command" is an empty string. talloc_string_sub2 is called with
this empty string and returns NULL which leads to exiting
print_queue_update without doing the actual print queue update.

Signed-off by Michael Adam <obnox@samba.org>
(cherry picked from commit 03d66554d1bbd9d6c72a3dd5203e5305343c76b8)
(cherry picked from commit c6ca0f7d462c51122ccb1068306410ccdbee7b00)

15 years agoIf we're not allowing streams on this conn ptr,
Jeremy Allison [Fri, 25 Jul 2008 01:13:20 +0000 (18:13 -0700)]
If we're not allowing streams on this conn ptr,
then don't allow create_file() to call down to
create_file_unixpath() with a stream name.
Jeremy.
(cherry picked from commit 7f749a10eff0bb469e6eb50b02cb60fd65c23f9e)

15 years agoRemove trailing withespace from wbinfo -m which breaks gdm auth.
Andreas Schneider [Mon, 21 Jul 2008 09:52:10 +0000 (11:52 +0200)]
Remove trailing withespace from wbinfo -m which breaks gdm auth.

Signed-off-by: Andreas Schneider <anschneider@suse.de>
(cherry picked from commit cdf10e6ee9faff42693bb39ede535cc6611a8fc9)

15 years agoRemove test changes added in error.
Jeremy Allison [Thu, 24 Jul 2008 19:00:01 +0000 (12:00 -0700)]
Remove test changes added in error.
Jeremy.
(cherry picked from commit 218ffbe3876dbd58f56e107819dec2e74f5d2f1a)

15 years agoUse sys_getgrnam not getgrnam. Pointed out by Herb.
Jeremy Allison [Thu, 24 Jul 2008 18:56:20 +0000 (11:56 -0700)]
Use sys_getgrnam not getgrnam. Pointed out by Herb.
Jeremy.
(cherry picked from commit 2518197d7f3833b5d85fe42b05b51d89fa69eb75)

15 years agoget rid of unused variable warnings when HAVE_IPV6 not defined
Herb Lewis [Wed, 23 Jul 2008 00:50:33 +0000 (17:50 -0700)]
get rid of unused variable warnings when HAVE_IPV6 not defined
(cherry picked from commit 2b5425efddfccb1010d082e6133cfdd79d72729e)

15 years agopdb_ldap: Raise level for debug message to avoid log file flooding.
John H Terpstra [Thu, 24 Jul 2008 07:45:02 +0000 (09:45 +0200)]
pdb_ldap: Raise level for debug message to avoid log file flooding.
(cherry picked from commit 9b863a10da8762f715c16f147d6cd1e79422d248)
(cherry picked from commit 1c3187fd250e5219197206cb7c7345ea9d649e74)

15 years agoUpdate Roadmap
Volker Lendecke [Mon, 21 Jul 2008 14:12:22 +0000 (16:12 +0200)]
Update Roadmap
(cherry picked from commit d1c3b57085b493b47398daf71ce18f16ece57da0)

15 years agoman pages: "printcap name" is a global parameter, not a share specific one.
Karolin Seeger [Tue, 22 Jul 2008 09:27:16 +0000 (11:27 +0200)]
man pages: "printcap name" is a global parameter, not a share specific one.

Karolin
(cherry picked from commit 9cde2525560536e16e2dbf991dbeb446260dd0df)
(cherry picked from commit 76061eee93fd67b96916a088c64a038e47a48814)

15 years agotestsuite: fix expr error on Tru64, triggered by uninitialized failed variable.
Michael Adam [Mon, 21 Jul 2008 09:23:55 +0000 (11:23 +0200)]
testsuite: fix expr error on Tru64, triggered by uninitialized failed variable.

Michael
(cherry picked from commit 25cd227aaecf91dfa3114ae0fd2b47c783434aad)
(cherry picked from commit 90f33570e45159193d9336c742bf53d51573849b)

15 years agotestsuite: fix another expr syntax error. in tests_all.sh.
Michael Adam [Mon, 21 Jul 2008 09:17:36 +0000 (11:17 +0200)]
testsuite: fix another expr syntax error. in tests_all.sh.

Michael
(cherry picked from commit 486b1bc5b5021565ec443fd463c8287c02c686b3)
(cherry picked from commit 4038363b72eb852d462234a1ec85c3cc68765f0d)

15 years agotestsuite: fix expr syntax error in net registry test.
Michael Adam [Sun, 20 Jul 2008 21:49:40 +0000 (23:49 +0200)]
testsuite: fix expr syntax error in net registry test.

Pointed out by Björn Jacke <bj@sernet.de>.

Michael
(cherry picked from commit 63e7d9adb7a51b3790eb431615cb6e450391a894)
(cherry picked from commit 0dbb8def6b9647bb01f4544361cb87bafdfb3fc8)

15 years agoFix link to Using Samba
Alexander Bokovoy [Sun, 20 Jul 2008 06:36:05 +0000 (10:36 +0400)]
Fix link to Using Samba
(cherry picked from commit 04cce8c620108ba00921bd1630a8692abdc2e0dc)

15 years agoFix the build of vfs_zfsacl.c
Volker Lendecke [Fri, 18 Jul 2008 08:01:39 +0000 (10:01 +0200)]
Fix the build of vfs_zfsacl.c
(cherry picked from commit b83beeda44e1c8d485c2ad6bb8ee539cdcbe8bda)

15 years agoWHATSNEW: Update changes since 3.2.0.
Karolin Seeger [Fri, 18 Jul 2008 14:13:04 +0000 (16:13 +0200)]
WHATSNEW: Update changes since 3.2.0.

Karolin
(cherry picked from commit 2a874d07648a6b0303249ac8a6cdbf266668afe1)

15 years agoDocument the streams modules
Volker Lendecke [Fri, 18 Jul 2008 09:18:04 +0000 (11:18 +0200)]
Document the streams modules
(cherry picked from commit e7e6800b3df4e6c9c4429204c5a4162a1e1118d6)

15 years agoChange the directory parameter in streams_depot to become consistent
Volker Lendecke [Fri, 18 Jul 2008 09:17:33 +0000 (11:17 +0200)]
Change the directory parameter in streams_depot to become consistent

This is not built by default and not documented in 3.2.0, so I doubt this will
break any setups :-)
(cherry picked from commit ca2dfb372cfd9096407fca67a6b65bceda6f72b6)

15 years agoFrom Jim McDonough
Jeremy Allison [Fri, 18 Jul 2008 03:01:13 +0000 (20:01 -0700)]
From Jim McDonough

In reloading the smb.conf, if a "log file" is specified in smb.conf,
winbind children will overwrite the logfile name to be the same as the
parent.

Jeremy.
(cherry picked from commit 147dc45cfb0da3677e381bec3873b9645b320f60)

15 years agogitignore: ignore the generated library symbol files
Michael Adam [Thu, 17 Jul 2008 19:05:11 +0000 (21:05 +0200)]
gitignore: ignore the generated library symbol files

Michael
(cherry picked from commit 1006173f98ea8a19c4891c543373124dc2f65282)

15 years agoallow SID with 0 in subauthority to be converted properly
Herb Lewis [Thu, 17 Jul 2008 16:23:30 +0000 (09:23 -0700)]
allow SID with 0 in subauthority to be converted properly
from string representation.
(cherry picked from commit eaee722ca74af274e628cbd868753800bddc3e97)