samba.git
14 years agopackaging(RHEL-CTDB): package the manpage of "sharesec"
Michael Adam [Mon, 3 Aug 2009 12:04:09 +0000 (14:04 +0200)]
packaging(RHEL-CTDB): package the manpage of "sharesec"

Michael
(cherry picked from commit 331b816a0bbe5c201edef20d2bb87ef97f9ee206)

14 years agopackaging(RHEL-CTDB): pam_winbindd man page has moved from section 7 to 8
Michael Adam [Mon, 3 Aug 2009 11:45:40 +0000 (13:45 +0200)]
packaging(RHEL-CTDB): pam_winbindd man page has moved from section 7 to 8

This due to updating the docs tarball to the 3.4 docs.

Michael
(cherry picked from commit d70f61aa50482dd3fbd8f4f754be92a864233eac)

14 years agopackaging(RHEL-CTDB): disable the merged build.
Michael Adam [Wed, 1 Jul 2009 09:06:34 +0000 (11:06 +0200)]
packaging(RHEL-CTDB): disable the merged build.

Michael
(cherry picked from commit 94bcef772d2a78711a345963aa1edc7037d7057d)

14 years agopackaging(RHEL-CTDB): also pack libwbcient in winbind-32bit package
Michael Adam [Thu, 19 Mar 2009 23:47:45 +0000 (00:47 +0100)]
packaging(RHEL-CTDB): also pack libwbcient in winbind-32bit package

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 34be433f948e32fec3a01fe138c526671310253d)

14 years agopackaging(RHEL-CTDB): add new pam_winbind.mo to the common package
Michael Adam [Thu, 19 Mar 2009 23:30:35 +0000 (00:30 +0100)]
packaging(RHEL-CTDB): add new pam_winbind.mo to the common package

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 0c4c24a074b7f3aebadbef93733e19312b0c4289)

14 years agopackaging(RHEL-CTDB): add new binary sharesec to the client package.
Michael Adam [Thu, 19 Mar 2009 23:28:36 +0000 (00:28 +0100)]
packaging(RHEL-CTDB): add new binary sharesec to the client package.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit f8772b9beda656bc7520a9d357a2407b08e70061)

14 years agopackaging(RHEL-CTDB): add new binary ldbrename to the common rpm
Michael Adam [Thu, 19 Mar 2009 23:26:11 +0000 (00:26 +0100)]
packaging(RHEL-CTDB): add new binary ldbrename to the common rpm

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit e364d9c522a2e2585ce8f74ffb5fad68639074f1)

14 years agopackaging(RHEL-CTDB): fix location of nsswitch/ directory for install
Michael Adam [Mon, 29 Jun 2009 15:07:14 +0000 (17:07 +0200)]
packaging(RHEL-CTDB): fix location of nsswitch/ directory for install

This has been moved to the top level directory in 3.4.

Michael
(cherry picked from commit 5bfcde9f41a87d20490d2d94342892becf90383a)

14 years agopackaging(RHEL-CTDB): don't pass CFLAGS to make.
Michael Adam [Mon, 29 Jun 2009 15:05:00 +0000 (17:05 +0200)]
packaging(RHEL-CTDB): don't pass CFLAGS to make.

This breaks the build since 3.3 since it overwrites the CFLAGS
set by configure.

Michael
(cherry picked from commit 58c72fa02ce943bb47287ca53bfb657b0b1e5b26)

14 years agopackaging(RHEL-CTDB): don't "make proto" any more.
Michael Adam [Mon, 29 Jun 2009 15:03:09 +0000 (17:03 +0200)]
packaging(RHEL-CTDB): don't "make proto" any more.

This has become unnecessary in 3.3

Michael
(cherry picked from commit c4d02edcbbea076e5ba87c52a27054c497dc6c9b)

14 years agopackaging(RHEL-CTDB):makerpms.sh: replace source/ by source3/
Michael Adam [Tue, 23 Jun 2009 21:09:09 +0000 (23:09 +0200)]
packaging(RHEL-CTDB):makerpms.sh: replace source/ by source3/

Michael
(cherry picked from commit c4af2b666b9310693820608b56114bad377d1236)

14 years agopackaging(RHEL-CTDB):makespec.sh: fix detection of version
Michael Adam [Tue, 23 Jun 2009 21:06:40 +0000 (23:06 +0200)]
packaging(RHEL-CTDB):makespec.sh: fix detection of version

Michael
(cherry picked from commit 1421aad532daf93d213e6c1b74ad00535832ece3)

14 years agopackaging(RHEL-CTDB): makeversion.sh: v3-4-test uses source3 instead of source
Michael Adam [Tue, 23 Jun 2009 20:41:51 +0000 (22:41 +0200)]
packaging(RHEL-CTDB): makeversion.sh: v3-4-test uses source3 instead of source

Michael
(cherry picked from commit 3a56367867c3578781b8c4ebaf3047c6d5fa3579)

14 years agopackaging(RHEL-CTDB): makerpms.sh: build winbind-32bit libs in the 64bit build
Michael Adam [Wed, 21 Jan 2009 08:49:12 +0000 (09:49 +0100)]
packaging(RHEL-CTDB): makerpms.sh: build winbind-32bit libs in the 64bit build

Michael
(cherry picked from commit a9a506b6640986548e2ae8540b7ae93960d6ece5)
(cherry picked from commit 63d465cdbf522409b6ba9e6507be908d15ac997a)

14 years agopackaging(RHEL-CTDB): Build winbind-32bit package in the 64bit build
Michael Adam [Tue, 20 Jan 2009 18:47:28 +0000 (19:47 +0100)]
packaging(RHEL-CTDB): Build winbind-32bit package in the 64bit build

Michael
(cherry picked from commit f5cd88a25f360e6609dc5abe24247fab78af6854)
(cherry picked from commit 0fa142fd45d09f7b700eb0a4bb984c16ca28a042)

14 years agopackaging(RHEL-CTDB): extend makespec.sh to extract VENDOR_PATCH from version.h
Michael Adam [Wed, 21 Jan 2009 10:03:34 +0000 (11:03 +0100)]
packaging(RHEL-CTDB): extend makespec.sh to extract VENDOR_PATCH from version.h

Michael
(cherry picked from commit fc122aa276bce379b492e5bdf52ab3e03bc3737f)
(cherry picked from commit fe585b56af225b3bc96eac6b0cd57de4cd305f07)

14 years agopackaging(RHEL-CTDB): The former release number has basically moved into VERSION
Michael Adam [Wed, 21 Jan 2009 09:24:31 +0000 (10:24 +0100)]
packaging(RHEL-CTDB): The former release number has basically moved into VERSION

Michael
(cherry picked from commit d39a1b4a09e86dd040158d545258507666b3cab1)

14 years agos3:smbd: also fill the memcache with sid<->id mappings in ldapsam_sid_to_id()
Michael Adam [Fri, 13 Nov 2009 15:16:50 +0000 (16:16 +0100)]
s3:smbd: also fill the memcache with sid<->id mappings in ldapsam_sid_to_id()

not only the persistent idmap cache.

Michael
(cherry picked from commit ee2565bd461ccfb916c5290c883e5ced3af72141)

14 years agos3:smbd: make idmap cache persistent for "ldapsam:trusted".
Michael Adam [Fri, 13 Nov 2009 14:51:33 +0000 (15:51 +0100)]
s3:smbd: make idmap cache persistent for "ldapsam:trusted".

This stores the mappings found in the idmap cache (which lives
inside gencache). This cache is already read in sid_to_Xid()
and Xid_to_sid() for ldapsam:trusted, this fills the opposite
direction, massively reducing the number of ldap roundtrips
across smbd restarts.

Michael
(cherry picked from commit d5537cbbf931f0bca519371bfd084fb0051acd57)

14 years agoFix large paged search
Volker Lendecke [Mon, 18 May 2009 14:04:04 +0000 (16:04 +0200)]
Fix large paged search

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit afb06a8af3c4e86ef9960c8beb19a22f5fd0f3c2)

14 years agofix bogus "out of memory" winbind msg
Volker Lendecke [Wed, 13 May 2009 08:12:26 +0000 (10:12 +0200)]
fix bogus "out of memory" winbind msg

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit a15ffba403cebd8b915f6fdd3de66114c0871219)

14 years agos3: Convert cli_unix_extensions_version to async
Volker Lendecke [Thu, 12 Nov 2009 22:07:21 +0000 (23:07 +0100)]
s3: Convert cli_unix_extensions_version to async
(cherry picked from commit d718908bbd261c6bad78a202cecd90a72f17c117)

14 years agoRevert "pidl: Fix selftest after s3 code changed"
Jeremy Allison [Fri, 13 Nov 2009 04:31:49 +0000 (20:31 -0800)]
Revert "pidl: Fix selftest after s3 code changed"

This reverts commit 439050fb40e5ce9c476924b01f2254b9aab35a3e.

Not needed in this branch (yet).
(cherry picked from commit a656083180683cf93bc4c1b9885d2749e5d238b2)

14 years agos3-kerberos: remove smb_krb5_get_tkt_from_creds().
Günther Deschner [Thu, 12 Nov 2009 14:42:03 +0000 (15:42 +0100)]
s3-kerberos: remove smb_krb5_get_tkt_from_creds().

Now that cli_krb5_get_ticket() already handles S4U2SELF impersonation, remove
smb_krb5_get_tkt_from_creds() which is not required anymore.

Guenther
(cherry picked from commit 61f0b247633501d6bf4103ca8345048e537c043d)
(cherry picked from commit a40c5eadf6da1d7e8b193f0bfbc2a15fb592b585)

14 years agos3-kerberos: avoid using ERROR_TABLE_BASE_krb5 without checking.
Günther Deschner [Thu, 12 Nov 2009 14:40:42 +0000 (15:40 +0100)]
s3-kerberos: avoid using ERROR_TABLE_BASE_krb5 without checking.

Guenther
(cherry picked from commit 0f8bf47d949fbdf47bdb388ad584652202ce185b)
(cherry picked from commit 07fd6cd68951f88d4c8e12156167a18ee6972be5)

14 years agolib/util Fix comments in rfc1738.c.
Andrew Bartlett [Mon, 2 Nov 2009 05:39:31 +0000 (16:39 +1100)]
lib/util Fix comments in rfc1738.c.

The Samba version does not use static buffers

Andrew Bartlett
(cherry picked from commit 5a8f21cb88e7579c12b3d97299f355bb64957a87)
(cherry picked from commit 0f4674c62cb5ed651221a06f05fe3985351e92db)

14 years agolib/util Use rfc1738.c from Squid for all our URL encode/decode needs.
Andrew Bartlett [Thu, 29 Oct 2009 21:58:34 +0000 (08:58 +1100)]
lib/util Use rfc1738.c from Squid for all our URL encode/decode needs.

Andrew Bartlett
(cherry picked from commit 7a290130bdeb411625f16451af3f2cfd25eeaf00)
(cherry picked from commit fa0f418baa628e63cf2b04e769c840eefa9aa61e)

14 years agolib/util Add rfc1738 escape/unescape code from Squid
Andrew Bartlett [Thu, 29 Oct 2009 06:09:49 +0000 (17:09 +1100)]
lib/util Add rfc1738 escape/unescape code from Squid

This is intended to replace our rfc1738_unescape(), and give us an
rfc1738_escape implementation (and hopefully is better tested and more
secure).

Andrew Bartlett
(cherry picked from commit 87195f55de771546ea74c0ab06d882f900588099)
(cherry picked from commit 4e4c75422f07447622d30192c93ffbd4a7874bc2)

14 years agopidl: Fix selftest after s3 code changed
Volker Lendecke [Mon, 9 Nov 2009 13:26:55 +0000 (14:26 +0100)]
pidl: Fix selftest after s3 code changed
(cherry picked from commit e6df4c2bc28b9204cf0637575b0289657e604830)
(cherry picked from commit 439050fb40e5ce9c476924b01f2254b9aab35a3e)

14 years agoRemove unused variable warning.
Jeremy Allison [Thu, 12 Nov 2009 22:09:25 +0000 (14:09 -0800)]
Remove unused variable warning.
Jeremy.
(cherry picked from commit d2a9f4a2729026da11780ae4b71e289982094bd7)
(cherry picked from commit 5c81851109021cc5e0733b3d153d3e2f18a16a41)

14 years agoRemove erroneous 'presult = NULL' changes. Now presult only gets set
Jeremy Allison [Thu, 12 Nov 2009 21:59:25 +0000 (13:59 -0800)]
Remove erroneous 'presult = NULL' changes. Now presult only gets set
if NTSTATUS == OK.
Jeremy.
(cherry picked from commit 03637130316099d4f3db4ce757af2f34ce46d881)
(cherry picked from commit 421ceb5070007924341b108e1a578b43b39fa058)

14 years agoRevert "Ensure every return path initializes presult as NULL."
Jeremy Allison [Thu, 12 Nov 2009 21:57:13 +0000 (13:57 -0800)]
Revert "Ensure every return path initializes presult as NULL."
Vl is correct, this is the wrong way to fix this.

This reverts commit 83c2c177a5e86d04da37384f1f04230c8274e1e6.
(cherry picked from commit 496d147dc4d50650ef1e88877aa28719458089b8)
(cherry picked from commit ca13c8cef238285c09ef5850a91ca1771a2a9685)

14 years agoEnsure all callers to the rpc_client/cli_pipe functions correctly
Jeremy Allison [Thu, 12 Nov 2009 21:56:33 +0000 (13:56 -0800)]
Ensure all callers to the rpc_client/cli_pipe functions correctly
initialize return variables.
Jeremy.
(cherry picked from commit 5363d6e62c2d4d3275e78d04c48835524c54f620)
(cherry picked from commit 3e0add7c118cff14c3ed8f619920f4938e4795c3)

14 years agoFix bug 6891 - using windows explorer to change ownership on a folder fails with...
Jeremy Allison [Thu, 12 Nov 2009 21:08:04 +0000 (13:08 -0800)]
Fix bug 6891 - using windows explorer to change ownership on a folder fails with Bad File Descriptor.
Jeremy.
(cherry picked from commit 6747a91ca0c350374c54bac5892cf96e5aed029f)
(cherry picked from commit 8702bdbeb552537d10b875b18ca814b9912058af)

14 years agoEnsure every return path initializes presult as NULL.
Jeremy Allison [Thu, 12 Nov 2009 19:49:54 +0000 (11:49 -0800)]
Ensure every return path initializes presult as NULL.
Ensures no crashes in calling code that forgets to
init return as null.
Jeremy.
(cherry picked from commit 83c2c177a5e86d04da37384f1f04230c8274e1e6)
(cherry picked from commit 01cb74f9c9a16d49c79dd5333f0a21790d747cc0)

14 years agos3: Fix debug messages in check_reduced_name
Volker Lendecke [Thu, 12 Nov 2009 10:07:15 +0000 (11:07 +0100)]
s3: Fix debug messages in check_reduced_name
(cherry picked from commit 8006e0e63419fbb8de7e1fadf1edc6a51da9d144)
(cherry picked from commit c2be4f267c6debe5cb1e97d766b681082402b847)

14 years agocifs.upcall: Fix Bug #6868: support building with Heimdal we well as with MIT.
Günther Deschner [Wed, 11 Nov 2009 23:52:38 +0000 (00:52 +0100)]
cifs.upcall: Fix Bug #6868: support building with Heimdal we well as with MIT.

Guenther
(cherry picked from commit b29eed492f1c056adb0b53510be10e738276ca11)
(cherry picked from commit 1230faabf8d836b900cdb9848de9fc12a79155f3)

14 years agos3-kerberos: add smb_krb5_principal_get_realm().
Günther Deschner [Wed, 11 Nov 2009 23:51:46 +0000 (00:51 +0100)]
s3-kerberos: add smb_krb5_principal_get_realm().

Guenther
(cherry picked from commit b4e40958b7f7406dc6cdd1bef4fa3f824b9cbe3a)
(cherry picked from commit 3571e726c09b323b4ddd17af517aef3cad94607f)

14 years agoSecond part of bugfix for 6865 - acl_xattr module: Has dependency that inherit acls...
Jeremy Allison [Thu, 12 Nov 2009 02:35:18 +0000 (18:35 -0800)]
Second part of bugfix for 6865 - acl_xattr module: Has dependency that inherit acls = yes or xattrs are removed.
We also need dos filemode = true set as well.
Jeremy.
(cherry picked from commit a8769e667514f83a45ee3e825d21a351987d0210)
(cherry picked from commit fbb22af1fa4fceab143de77700d388eb073e7452)

14 years agoFix bug 6878 - Cannot change ACL's inherit flag.
Jeremy Allison [Wed, 11 Nov 2009 20:17:47 +0000 (12:17 -0800)]
Fix bug 6878 - Cannot change ACL's inherit flag.
Based on a patch submitted by Tsukasa Hamano <hamano@osstech.co.jp>,
this is a change in the POSIX ACL mapping to deal with the lossy
mapping for directory ACE entries:

 We have a lossy mapping: directory ACE entries
 CREATOR_OWNER ------\
     (map to)         +---> SMB_ACL_USER_OBJ
 owning sid    ------/

 CREATOR_GROUP ------\
     (map to)         +---> SMB_ACL_GROUP_OBJ
 primary group sid --/

 on set. And on read of a directory ACL

 SMB_ACL_USER_OBJ ----> CREATOR_OWNER
 SMB_ACL_GROUP_OBJ ---> CREATOR_GROUP.

 Deal with this on set by duplicating
 owning sid and primary group sid ACE
 entries into the directory ACL.

Jeremy.
(cherry picked from commit 8995d3d813978a00b50f33943c60784ddfe308bf)
(cherry picked from commit cdcd4da33e2d2f125ac3af89afc234ca941c2ba9)

14 years agos3/docs: Document "enable spoolss".
Karolin Seeger [Wed, 11 Nov 2009 14:42:21 +0000 (15:42 +0100)]
s3/docs: Document "enable spoolss".

Karolin
(cherry picked from commit f3646ff392ab736ed82d2982490aa9d57e11ec6b)
(cherry picked from commit 2bef1fd0ef59bbb3d52c1fb475842ae3ca55308a)

14 years agos3:vfs_fs_capabilities: fix a debug message
Michael Adam [Tue, 10 Nov 2009 23:13:14 +0000 (00:13 +0100)]
s3:vfs_fs_capabilities: fix a debug message

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit d363850787da9217a4f26e3b8a9fb401e75b740e)

14 years agos3/configure: Disable the automatic merged build.
Karolin Seeger [Wed, 15 Apr 2009 07:52:23 +0000 (09:52 +0200)]
s3/configure: Disable the automatic merged build.

Karolin
(cherry picked from commit f78b83ce7f33251cb067d66738454df73422507b)

14 years agos3-rpc_client: make sure cli_rpc_pipe_open_schannel() does not always return NT_STATU...
Günther Deschner [Tue, 10 Nov 2009 12:10:12 +0000 (13:10 +0100)]
s3-rpc_client: make sure cli_rpc_pipe_open_schannel() does not always return NT_STATUS_OK.

Guenther
(cherry picked from commit d241b9ae4c9b520406aac98e24d078f2d4fd4ae5)
(cherry picked from commit bc0dc5a452f52df76d3f6bbd119acd8476afe9d5)

14 years agos3-netlogon: enable RPC-NETLOGON-ADMIN test against s3.
Günther Deschner [Mon, 9 Nov 2009 16:34:47 +0000 (17:34 +0100)]
s3-netlogon: enable RPC-NETLOGON-ADMIN test against s3.

Guenther
(cherry picked from commit d7ce873391f215f4f3785abcd13b9d120b87e744)
(cherry picked from commit f0e718833fa73560e06c844963fe78932a22dfb2)

14 years agos4-smbtorture: re-arrange netlogon LogonControl test.
Günther Deschner [Mon, 9 Nov 2009 16:32:31 +0000 (17:32 +0100)]
s4-smbtorture: re-arrange netlogon LogonControl test.

The LogonControl tests now are split out to a new RPC-NETLOGON-ADMIN test that
tests the behaviour of that call when called by user, dc or workstation.

Guenther
(cherry picked from commit e9c6984cb62ce8d7d899202c1275d241a605913c)
(cherry picked from commit 8b94ea1a55fa96078ce86dedb033b083143939ff)

14 years agos3:registry: add an extra check for dsize==0 to regdb_fetch_keys_internal()
Michael Adam [Mon, 2 Nov 2009 23:51:27 +0000 (00:51 +0100)]
s3:registry: add an extra check for dsize==0 to regdb_fetch_keys_internal()

Don't only rely on dptr == NULL.
I stumbled over this one when rewriting some of the dbwrap_ctdb code.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit b58c7d96528bf3aa781f76b76465699f97e8985c)

14 years agos3:registry: add safety check for return value of tdb_unpack to regdb_fetch_keys_inte...
Michael Adam [Mon, 2 Nov 2009 23:47:37 +0000 (00:47 +0100)]
s3:registry: add safety check for return value of tdb_unpack to regdb_fetch_keys_internal()

Prevents segfaults in some situations.

(For a non existent or empty record, we sometimes rely on the fetch operation
 to return dsize==0 and sometimes we rely on dptr==NULL.)

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 3fb7db84d76f15cc218554559c0f498cf00d1f7c)

14 years agos3:dbwrap_ctdb: add debug message to transaction_fetch_start()
Michael Adam [Sat, 31 Oct 2009 12:16:34 +0000 (13:16 +0100)]
s3:dbwrap_ctdb: add debug message to transaction_fetch_start()

for the case that another local process has started a transaction
bewteen releasing the transaction_lock record and starting the
transaction.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit bb939dff52c6a032719c1a2e1e4f6c056e9a0466)

14 years agos3:dbwrap_ctdb: split combined check in two and add descriptive debug
Michael Adam [Sat, 31 Oct 2009 12:13:04 +0000 (13:13 +0100)]
s3:dbwrap_ctdb: split combined check in two and add descriptive debug

in db_ctdb_transaction_fetch_start() for error conditions when re-fetching
the transaction_lock record inside the transaction

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 8b7189f4436ff9fc2bb91498ec76030cda730312)

14 years agos3:dbwrap_ctdb: fix race condition with concurrent transactions on the same node.
Michael Adam [Wed, 28 Oct 2009 23:01:45 +0000 (00:01 +0100)]
s3:dbwrap_ctdb: fix race condition with concurrent transactions on the same node.

In ctdb_transaction_commit(), when the trans2_commit control fails, there
is a race condition in the 1 second sleep between the local transaction_cancel
and the call to ctdb_replay_transaction(): The database is not locked, and
neither is the transaction_lock record. So another client can start and possibly
complete a new transaction in this gap, but only on the same node: The locking
of the transaction_lock record on a different node which involves migration of
the record to the other node has been disabled by introduction of the
transaction_active flag on the db which closes precisely this gap from the start
of the commit until the call to TRANS2_FINISH or TRANS2_ERROR.
But this mechanism does not cover the case where a process on the same node
tries to start a transaction: There is no obstacle to locking the transaction_lock
record because the record does not need to be migrated.

This commit closes this race condition in ctdb_transaction_fetch_start()
by using the new ctdb_ctrl_transaction_active() call to ask the local
ctdb daemon whether it has a transaction running on the database.
If so, the check is repeated until the running transaction is done.

This does introduce an additional call to the local ctdbd when starting
transactions, but it does close the (hopefully) last race condition.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 056c2376ccfdff724701edee6b319a7d6d97822e)

14 years agos3:configure: add a check for the new CTDB_CONTROL_TRANS2_ACTIVE
Michael Adam [Wed, 28 Oct 2009 22:56:59 +0000 (23:56 +0100)]
s3:configure: add a check for the new CTDB_CONTROL_TRANS2_ACTIVE

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 8296188b78c2246cd7fc2bd74fd271696aeceb6c)

14 years agos3:dbwrap_ctdb: add new db_ctdb_transaction_active() that calls CTDB_CONTROL_TRANS2_C...
Michael Adam [Wed, 28 Oct 2009 22:56:03 +0000 (23:56 +0100)]
s3:dbwrap_ctdb: add new db_ctdb_transaction_active() that calls CTDB_CONTROL_TRANS2_COMMIT

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit ef3ab7ba1c513860f1698143ae1f42859fb37e56)

14 years agos3:dbwrap_ctdb: fix a race in starting concurrent transactions on a single node
Michael Adam [Wed, 28 Oct 2009 00:54:04 +0000 (01:54 +0100)]
s3:dbwrap_ctdb: fix a race in starting concurrent transactions on a single node

There are two races in concurrent transactions on a single node.
One in starting a transaction and one with replay during commit.

This commit closes the first race by storing the client pid in the
transaction-lock record and comparing the stored pid against its own
pid after releasing the lock and refetching the record inside the
transaction.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 7b37b8a5dcc08817b21e12570da6632674cc7575)

14 years agos3:dbwrap_ctdb: use db_ctdb_ltdb_fetch() inside db_ctdb_transaction_fetch_start
Michael Adam [Wed, 28 Oct 2009 00:50:15 +0000 (01:50 +0100)]
s3:dbwrap_ctdb: use db_ctdb_ltdb_fetch() inside db_ctdb_transaction_fetch_start

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit f50ef43e69b1952ab182d2bb2e820680e5bb3643)

14 years agos3:dbwrap_ctdb: use db_ctdb_ltdb_fetch() inside db_ctdb_transaction_fetch()
Michael Adam [Wed, 28 Oct 2009 00:28:38 +0000 (01:28 +0100)]
s3:dbwrap_ctdb: use db_ctdb_ltdb_fetch() inside db_ctdb_transaction_fetch()

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 6f004b2e193208598d78599057b0d152d9aa6049)

14 years agos3:dbwrap_ctdb: add a function db_ctdb_ltdb_fetch()
Michael Adam [Mon, 2 Nov 2009 23:55:41 +0000 (00:55 +0100)]
s3:dbwrap_ctdb: add a function db_ctdb_ltdb_fetch()

This fetches a record from the db and splits out the ctdb header.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 72912511a14c3c727c24c0bae06f9cece859cdbb)

14 years agos3:dbrwap_ctdb: add a function db_ctdb_ltdb_store()
Michael Adam [Thu, 22 Oct 2009 14:27:45 +0000 (16:27 +0200)]
s3:dbrwap_ctdb: add a function db_ctdb_ltdb_store()

and use it in db_ctdb_store() and db_ctdb_transaction_store().

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 30e493a5fb411c50750d5f4263273425b9d6f14a)

14 years agos3:dbwrap_ctdb: reformat a comment slightly to enhance clearness.
Michael Adam [Thu, 22 Oct 2009 12:37:51 +0000 (14:37 +0200)]
s3:dbwrap_ctdb: reformat a comment slightly to enhance clearness.

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
(cherry picked from commit 6b5f30d420fdf867443ee3aeed999feb44f6eeda)

14 years agoREADME.Coding: Fix typos.
Matt Kraai [Mon, 10 Aug 2009 20:50:31 +0000 (13:50 -0700)]
README.Coding: Fix typos.
(cherry picked from commit 63e324dde5554db730be6f8a0f120c62f002d625)

14 years agoFix bug 6880 - cannot list workgroup servers
Jeremy Allison [Mon, 9 Nov 2009 20:44:47 +0000 (12:44 -0800)]
Fix bug 6880 - cannot list workgroup servers
reported by Alban Browaeys <prahal@yahoo.com> with fix.
Revert 2e989bab0764c298a2530a2d4c8690258eba210c
with extra comments - this broke workgroup enumeration.
Jeremy.
(cherry picked from commit 5d516181617419b9b078b4f375753afc3b785ced)
(cherry picked from commit 3d7e651e9fe18df79e7a47f19c66df7aaf810a20)

14 years agos3-param: fix set_inherit_acls().
Günther Deschner [Mon, 9 Nov 2009 15:02:24 +0000 (16:02 +0100)]
s3-param: fix set_inherit_acls().

Jeremy, please check.

Guenther
(cherry picked from commit 8eac3075b604d5d0938e2a087a154bb6546d78b1)
(cherry picked from commit fa13f626173fa8ae1eabe3461e354b75dc7d1d0e)

14 years agos3: Try to avoid dns searches with an empty site
Volker Lendecke [Mon, 9 Nov 2009 16:06:48 +0000 (17:06 +0100)]
s3: Try to avoid dns searches with an empty site
(cherry picked from commit 567dee6a70190795014d39f9557712b58cb64fca)

14 years agoWHATSNEW: Mention the new "ctdb timeout" parameter.
Karolin Seeger [Mon, 9 Nov 2009 08:44:35 +0000 (09:44 +0100)]
WHATSNEW: Mention the new "ctdb timeout" parameter.

Karolin
(cherry picked from commit 9ff12b4bbf12d41460464abe662ea48a20e0f6f3)

14 years agoRevert "s3: Do not directly reference the ndr_table_* in rpcclient"
Volker Lendecke [Sun, 8 Nov 2009 18:38:09 +0000 (19:38 +0100)]
Revert "s3: Do not directly reference the ndr_table_* in rpcclient"

This reverts commit 70c698fd547c4bc19cf77693608bbb34acac40b5.
(cherry picked from commit d88390e9931004fd3f33800f81246d8c16f1df06)

14 years agoRevert "s3: Do not reference ndr_table_<pipe> in the cli_ routines directly"
Volker Lendecke [Sun, 8 Nov 2009 18:38:01 +0000 (19:38 +0100)]
Revert "s3: Do not reference ndr_table_<pipe> in the cli_ routines directly"

This reverts commit daa964013bc5d036f4da571ce22c0052ef40943a.
(cherry picked from commit 28746a943b29dfdf2837bb17bf70fb4122f00220)

14 years agoRevert "s3: Consolidate getting the name out of a pipes_struct"
Volker Lendecke [Sun, 8 Nov 2009 18:37:53 +0000 (19:37 +0100)]
Revert "s3: Consolidate getting the name out of a pipes_struct"

This reverts commit 9621306351cdb469ef393a6d8cbeea456bc4bd9f.
(cherry picked from commit 579ad621b9bf6563be732e56d4690c0d046efac8)

14 years agoRevert "s3: Do not reference the ndr_tables in the server calls directly"
Volker Lendecke [Sun, 8 Nov 2009 18:37:42 +0000 (19:37 +0100)]
Revert "s3: Do not reference the ndr_tables in the server calls directly"

This reverts commit 98fb71782e05ae72cd6abeb38b6e0b96a50c1761.
(cherry picked from commit a4d214799f7909551251423b24dd149ffb8ce3d4)

14 years agoRevert "s3: Do not reference ndr_table when calling rpc_srv_register"
Volker Lendecke [Sun, 8 Nov 2009 18:37:33 +0000 (19:37 +0100)]
Revert "s3: Do not reference ndr_table when calling rpc_srv_register"

This reverts commit 494b2aff8826947e3bd556aecb175746163da485.
(cherry picked from commit c38006bc583cf0ff8b970d103f653fcd47cc2304)

14 years agoRevert "s3: Make run_rpc_command take strings instead of a ndr_interface_table"
Volker Lendecke [Sun, 8 Nov 2009 18:37:26 +0000 (19:37 +0100)]
Revert "s3: Make run_rpc_command take strings instead of a ndr_interface_table"

This reverts commit 53f2a1595e76db9fe1b42db65b51895b73365993.
(cherry picked from commit 2a04d2e34b6ab2858c5730b66977ef5a4f3c1678)

14 years agoRevert "s3: Make libnetapi_open_pipe take strings instead of a ndr_interface_table"
Volker Lendecke [Sun, 8 Nov 2009 18:37:13 +0000 (19:37 +0100)]
Revert "s3: Make libnetapi_open_pipe take strings instead of a ndr_interface_table"

This reverts commit 5fc9d93408effe75abcd231c45cbc14656692ebe.
(cherry picked from commit ea105fca3ea21d4bf669d351306aa925c9cdf75d)

14 years agos3: Make libnetapi_open_pipe take strings instead of a ndr_interface_table
Volker Lendecke [Sun, 8 Nov 2009 11:31:38 +0000 (12:31 +0100)]
s3: Make libnetapi_open_pipe take strings instead of a ndr_interface_table
(cherry picked from commit 753963ace9a9840ae7eb1ec8e3ab4a9b5f6f3e4b)

14 years agos3: Make run_rpc_command take strings instead of a ndr_interface_table
Volker Lendecke [Sun, 8 Nov 2009 11:24:06 +0000 (12:24 +0100)]
s3: Make run_rpc_command take strings instead of a ndr_interface_table
(cherry picked from commit a458f26d336d3859dcc848491df5ef6c6d627c82)

14 years agos3: Do not reference ndr_table when calling rpc_srv_register
Volker Lendecke [Sun, 8 Nov 2009 10:35:53 +0000 (11:35 +0100)]
s3: Do not reference ndr_table when calling rpc_srv_register
(cherry picked from commit 7b9e45e1170a1f1c8661bf52c1e9c3aa0e1d6599)

14 years agos3: Do not reference the ndr_tables in the server calls directly
Volker Lendecke [Sun, 8 Nov 2009 09:51:34 +0000 (10:51 +0100)]
s3: Do not reference the ndr_tables in the server calls directly

This involves storing the interface table in the pipes_struct
(cherry picked from commit a94a6c3c732b42cef6e461c3e9fdc7ef25a0aca3)

14 years agos3: Consolidate getting the name out of a pipes_struct
Volker Lendecke [Sun, 8 Nov 2009 09:43:34 +0000 (10:43 +0100)]
s3: Consolidate getting the name out of a pipes_struct
(cherry picked from commit 47fec3422ed002055609f6ee0e4df1c8bd625c27)

14 years agos3: Do not reference ndr_table_<pipe> in the cli_ routines directly
Volker Lendecke [Sun, 8 Nov 2009 08:53:08 +0000 (09:53 +0100)]
s3: Do not reference ndr_table_<pipe> in the cli_ routines directly
(cherry picked from commit f76d06c94c47413ef60891a0f44c69303ee129cf)

14 years agos3: Do not directly reference the ndr_table_* in rpcclient
Volker Lendecke [Sun, 1 Nov 2009 19:21:52 +0000 (20:21 +0100)]
s3: Do not directly reference the ndr_table_* in rpcclient
(cherry picked from commit 0af2b974c6899798c96798734a09f84a17a56566)

14 years agotdb: Fix a C++ warning
Volker Lendecke [Fri, 6 Nov 2009 13:04:49 +0000 (14:04 +0100)]
tdb: Fix a C++ warning
(cherry picked from commit 06b7a09c02aa5345d675c04449d54f6c0f8c13d0)

14 years agos3: Do the printing for DEBUGLEVEL>=10 centrally
Volker Lendecke [Sat, 7 Nov 2009 09:28:40 +0000 (10:28 +0100)]
s3: Do the printing for DEBUGLEVEL>=10 centrally

12 insertions(+), 10651 deletions(-)

I think that says it all :-)
(cherry picked from commit 8a438cc8b7d3ebf082427f175e58af8b74994b03)

14 years agos3: Register the ndr_interfaces dynamically
Volker Lendecke [Sun, 1 Nov 2009 11:05:14 +0000 (12:05 +0100)]
s3: Register the ndr_interfaces dynamically
(cherry picked from commit 657cbb225e9ad2a4903b6a9a5f8e7c4c31282848)

14 years agos3: Get rid of a NULL terminator
Volker Lendecke [Sun, 1 Nov 2009 10:33:59 +0000 (11:33 +0100)]
s3: Get rid of a NULL terminator
(cherry picked from commit 5791cd5df3bb8cf0b36b3ad606dad2b6b4e2b92c)

14 years agos3: Get rid of explicit pipe names
Volker Lendecke [Sat, 31 Oct 2009 19:04:54 +0000 (20:04 +0100)]
s3: Get rid of explicit pipe names
(cherry picked from commit 4bc7b833e721bb5eba09952169e5a410231a22cb)

14 years agos3: get_pipe_name_from_iface -> get_pipe_name_from_syntax
Volker Lendecke [Sat, 31 Oct 2009 18:28:16 +0000 (19:28 +0100)]
s3: get_pipe_name_from_iface -> get_pipe_name_from_syntax
(cherry picked from commit 1f26287bf36b164fe1f8e46d9c6d7c91bd4ff662)

14 years agoFix bug 6865 - acl_xattr module: Has dependency that inherit acls = yes or xattrs...
Jeremy Allison [Sat, 7 Nov 2009 05:53:07 +0000 (21:53 -0800)]
Fix bug 6865 - acl_xattr module: Has dependency that inherit acls = yes or xattrs are removed.
Jeremy.
(cherry picked from commit bd2ffb1c7a70ef9063b99a9318b3e185ddda84fe)
(cherry picked from commit 9991c4f65bfb093a3da01f3959bc4b4448e7db7b)

14 years agoFix bug 6841 - "map acl inherit = yes" not working.
Jeremy Allison [Sat, 7 Nov 2009 01:03:29 +0000 (17:03 -0800)]
Fix bug 6841 - "map acl inherit = yes" not working.
The code to read the new V2 SAMBA_PAI entries had
two errors.
Jeremy.
(cherry picked from commit afc592402068da2a928dd9975a38a6b1ccf3919f)
(cherry picked from commit bfb67ee75e74e144c3b1d3a195866a5d0b728b18)

14 years agos3-kerberos: let smb_krb5_get_tkt_from_creds() compile with older heimdal libs.
Günther Deschner [Fri, 6 Nov 2009 13:46:35 +0000 (14:46 +0100)]
s3-kerberos: let smb_krb5_get_tkt_from_creds() compile with older heimdal libs.

Guenther
(cherry picked from commit 11687e84e39291e9a0309d5df6dd088f71491593)
(cherry picked from commit ee7ce458a266e04cf83619b9437d377aa00ece87)

14 years agos3-netlogon: implement _netr_GetDcName and _netr_GetAnyDcName.
Günther Deschner [Wed, 30 Sep 2009 11:40:17 +0000 (13:40 +0200)]
s3-netlogon: implement _netr_GetDcName and _netr_GetAnyDcName.

Guenther
(cherry picked from commit 53d49bb7284a2d7281ad0ede20c37a6bd6d1794d)
(cherry picked from commit de7c7939b7f164ce5ac9d65babecb37bc7504635)

14 years agoRevert "s3-kerberos: add smb_krb5_parse_name_flags()."
Günther Deschner [Fri, 6 Nov 2009 12:48:23 +0000 (13:48 +0100)]
Revert "s3-kerberos: add smb_krb5_parse_name_flags()."

This reverts commit 17ef153b68795fec681f9ce17c198236aba2b1c2.
(cherry picked from commit 440db5a94e0ade69c9c258a54fa4d66b808d965c)
(cherry picked from commit c39cbefd0cce0b85aa6d67e2e6abf881e42689dc)

14 years agos3-kerberos: support S4U2SELF impersionation through cli_krb5_get_ticket().
Günther Deschner [Thu, 5 Nov 2009 18:10:55 +0000 (19:10 +0100)]
s3-kerberos: support S4U2SELF impersionation through cli_krb5_get_ticket().

Guenther
(cherry picked from commit 9e48dc2b78226bdacb8988509eaa93e5c9d92787)
(cherry picked from commit 95c05668213101755e719b10828a5e57a98b57d0)

14 years agos3-kerberos: use smb_krb5_get_credentials in ads_krb5_mk_req.
Günther Deschner [Thu, 5 Nov 2009 16:49:00 +0000 (17:49 +0100)]
s3-kerberos: use smb_krb5_get_credentials in ads_krb5_mk_req.

Guenther
(cherry picked from commit bb01aae1b9eb1bede98b7d9a9c4920082db128fe)
(cherry picked from commit 580b7b179818427d2cb1e245387cf1c7fa819314)

14 years agos3-kerberos: modify cli_krb5_get_ticket to take a new impersonate_princ_s arg.
Günther Deschner [Mon, 13 Oct 2008 15:29:22 +0000 (17:29 +0200)]
s3-kerberos: modify cli_krb5_get_ticket to take a new impersonate_princ_s arg.

Guenther
(cherry picked from commit 60bf0eb60788a5d4dc5de24997c5efda64f2bd73)
(cherry picked from commit ae4175e8a13e88fe7495af745d384b48f4f02784)

14 years agos3-net: better use memory credential cache in net_ads_kerberos_pac().
Günther Deschner [Fri, 6 Nov 2009 11:51:29 +0000 (12:51 +0100)]
s3-net: better use memory credential cache in net_ads_kerberos_pac().

Guenther
(cherry picked from commit 6ca8a40976f86f66713ba9a7b957f97a1c271016)
(cherry picked from commit a1d21fcfc5f7efed93b79155efe8d2a666da773e)

14 years agos3-net: allow to call "net ads kerberos pac <impersonation principal> -P".
Günther Deschner [Mon, 13 Oct 2008 15:28:39 +0000 (17:28 +0200)]
s3-net: allow to call "net ads kerberos pac <impersonation principal> -P".

Guenther
(cherry picked from commit 58184b5fd4e95bc7ad2179237808126411509eea)
(cherry picked from commit 05a8ecea99d2e056d20d31d8e15d016220a3d405)

14 years agos3-kerberos: add impersonate_principal for kerberos_return_pac_X calls.
Günther Deschner [Mon, 13 Oct 2008 15:27:21 +0000 (17:27 +0200)]
s3-kerberos: add impersonate_principal for kerberos_return_pac_X calls.

Guenther
(cherry picked from commit 5e266225108aa3335476cbe1214cc0f484c4fd02)
(cherry picked from commit 53680341f44babf0c1e87874feaa0cb2a0d6a615)

14 years agos3-kerberos: add smb_krb5_get_tkt_from_creds().
Günther Deschner [Mon, 13 Oct 2008 15:25:35 +0000 (17:25 +0200)]
s3-kerberos: add smb_krb5_get_tkt_from_creds().

Guenther
(cherry picked from commit 4ffbfc4475c92b9190811bd189802ff265aa6846)
(cherry picked from commit be4ad69eb9cd835ef9e97654793e60403c296b3a)

14 years agos3-kerberos: fix some build warnings when building against heimdal.
Günther Deschner [Fri, 6 Nov 2009 09:25:53 +0000 (10:25 +0100)]
s3-kerberos: fix some build warnings when building against heimdal.

Guenther
(cherry picked from commit bb75f713d628073c503b06a3d217195aa95d72b2)
(cherry picked from commit 99639fab2ae3da2edc4f51e8c6e8f3314bf4f31f)

14 years agos3-kerberos: add smb_krb5_get_{creds,credentials} incl. support for S4U2SELF imperson...
Günther Deschner [Mon, 13 Oct 2008 15:22:37 +0000 (17:22 +0200)]
s3-kerberos: add smb_krb5_get_{creds,credentials} incl. support for S4U2SELF impersonation.

Guenther
(cherry picked from commit 35dcc133c9c26d10186fe59ea096a2a5c87958e6)
(cherry picked from commit 16ba0e8649c441834da97f9584e5a64b670a083f)

14 years agos3-kerberos: remove duplicate prototype.
Günther Deschner [Mon, 13 Oct 2008 15:27:43 +0000 (17:27 +0200)]
s3-kerberos: remove duplicate prototype.

Guenther
(cherry picked from commit 0729df3661fefeffc5154c9b01ae027b3ede4b92)
(cherry picked from commit 33cc8575474b5de48c2cb65b1b0da07ba861277d)

14 years agos3-kerberos: add smb_krb5_parse_name_flags().
Günther Deschner [Thu, 5 Nov 2009 18:02:55 +0000 (19:02 +0100)]
s3-kerberos: add smb_krb5_parse_name_flags().

Guenther
(cherry picked from commit 17ef153b68795fec681f9ce17c198236aba2b1c2)
(cherry picked from commit 158d9e3c654e52e641d0485ccfaff2b7c0659576)