samba.git
14 years agos3-kerberos: Fix Bug #6929: build with recent heimdal.
Günther Deschner [Fri, 27 Nov 2009 00:06:36 +0000 (01:06 +0100)]
s3-kerberos: Fix Bug #6929: build with recent heimdal.

Heimdal changed the KRB5_DEPRECATED define (which now may not take an identifier
for activation) in new releases (like 1.3.1).

Guenther
(cherry picked from commit 1a8f8382740e352a83133b8c49aaedd4716210cd)
(cherry picked from commit 83ee139ddde91bffc7b5921eb5e6a4364a408d38)

14 years agos3-kerberos: next step to resolve Bug #6929: build with recent heimdal.
Günther Deschner [Thu, 26 Nov 2009 09:15:45 +0000 (10:15 +0100)]
s3-kerberos: next step to resolve Bug #6929: build with recent heimdal.

Based on patch from Allan <allan@archlinux.org>.

Also should fix the FreeBSD build on the buildfarm.

Guenther
(cherry picked from commit 5b3a32be97a37c119e837bdee8f049684565458c)
(cherry picked from commit 9ea9c2089ed0835f4cf8f5fb6fecf4f156b19520)

14 years agos3-kerberos: add check for prerequisite krb5/krb5.h header while checking for krb5...
Günther Deschner [Wed, 25 Nov 2009 20:33:48 +0000 (21:33 +0100)]
s3-kerberos: add check for prerequisite krb5/krb5.h header while checking for krb5/locate_plugin.h.

(Needed for new Heimdal versions).

Guenther
(cherry picked from commit c438b2b3923db66672ec82e795eef543de5fcb8a)
(cherry picked from commit 124c695872a6630cc6670a0547e1c3e6507be748)

14 years agonsswitch: fix compile of winbind_krb5_locator with recent Heimdal versions.
Günther Deschner [Wed, 25 Nov 2009 14:21:54 +0000 (15:21 +0100)]
nsswitch: fix compile of winbind_krb5_locator with recent Heimdal versions.

Guenther
(cherry picked from commit 51864219cc12ceb66c281355f3e1191d5e32842d)
(cherry picked from commit 0d19596e123d63343d31ca1783cc1f56d4f21684)

14 years agocifs.upcall: 2nd part of fix for Bug #6868: support building with Heimdal we well...
Günther Deschner [Wed, 25 Nov 2009 14:06:19 +0000 (15:06 +0100)]
cifs.upcall: 2nd part of fix for Bug #6868: support building with Heimdal we well as with MIT.

Guenther
(cherry picked from commit 660ee2e74523194e5f6b2b6428d76628beb74717)
(cherry picked from commit e3a06f282d5e5c06bd006497dd8736a531e6cb3b)

14 years agos3-build: really fix build of winbind_krb5_locator.
Günther Deschner [Thu, 19 Nov 2009 12:44:33 +0000 (13:44 +0100)]
s3-build: really fix build of winbind_krb5_locator.

Guenther
(cherry picked from commit fc9f199f2619635f73e8ee7f3b5359521d63f325)
(cherry picked from commit 15832c25f0d252646045b292530556239805e737)

14 years agonsswitch: fix the build of the winbind krb5 locator plugin.
Günther Deschner [Wed, 21 Oct 2009 00:44:44 +0000 (02:44 +0200)]
nsswitch: fix the build of the winbind krb5 locator plugin.

Guenther
(cherry picked from commit b9d9353b548d9b2ab684aa171f511174e6414762)
(cherry picked from commit 8900c0a1c8dd16cd98bfd219232d3bc57acb033a)

14 years agos3:docs: Fix typo in man mount.cifs.
Karolin Seeger [Mon, 30 Nov 2009 13:53:23 +0000 (14:53 +0100)]
s3:docs: Fix typo in man mount.cifs.

Fix bug #6844 (wrong credential file format in mount.cifs manpage).
Thanks to the Debian Samba package maintainers for reporting!

Karolin
(cherry picked from commit 3b7f8a759f57f32a8c1bc2db85236e88f616ffd9)
(cherry picked from commit 54e2e0ae51e2e126696570104ed64d0458beb4ce)
(cherry picked from commit dbe41dce7491df93a26bb0f4bd2a33b53fe90188)

14 years agos3: re-run make samba3-idl.
Günther Deschner [Fri, 27 Nov 2009 15:49:48 +0000 (16:49 +0100)]
s3: re-run make samba3-idl.

Guenther

Fix bug #6934.
(cherry picked from commit b89d902b6ab0ab14c95cf7b7bbe37b3884fefea5)

14 years agopidl: fix handling of output arguments in s3 client stubs.
Günther Deschner [Fri, 27 Nov 2009 15:44:39 +0000 (16:44 +0100)]
pidl: fix handling of output arguments in s3 client stubs.

a20e095 used (uint8_t) instead of (uint8_t *).

Guenther
(cherry picked from commit 11f5df11cc6998688cadc034b3e1e249d98bf3e1)

14 years agopidl:Samba3/ClientNDR: $size can be 'foo / 2' so we need to add '(' and ')'
Günther Deschner [Fri, 27 Nov 2009 10:37:01 +0000 (11:37 +0100)]
pidl:Samba3/ClientNDR: $size can be 'foo / 2' so we need to add '(' and ')'

foo / 5 * sizeof(bar)' isn't the same as
'(foo / 2) * sizeof(bar)'.

metze
(cherry picked from commit 4f14da8ddb1c903b75917cefaaea3e9b405a633a)

14 years agopidl:NDR/Parser: $size can be 'foo / 2' so we need to add '(' and ')'
Stefan Metzmacher [Wed, 25 Nov 2009 13:21:32 +0000 (14:21 +0100)]
pidl:NDR/Parser: $size can be 'foo / 2' so we need to add '(' and ')'

foo / 5 * sizeof(bar)' isn't the same as
'(foo / 2) * sizeof(bar)'.

metze
(cherry picked from commit ab1c92950f3cfdc8c52b772ecef23a5477f48f9d)
(cherry picked from commit d0d77d830072fbb5bda1c45f9df0722718f89096)

14 years agos3:docs: Document "aio write behind".
Karolin Seeger [Mon, 30 Nov 2009 12:34:34 +0000 (13:34 +0100)]
s3:docs: Document "aio write behind".

Part of a fix for bug #6890 (Some smb.conf parameters are undocumented).

Karolin
(cherry picked from commit fde7c2ab19bc7442d8ee9d85ab2fe54e0cfb4782)
(cherry picked from commit 267ebc03b43dd8c11f5aebf341620b0d94d95135)
(cherry picked from commit 93bbbd3cc776e4aa69239cb086067ec953fc8c8e)

14 years agos3:docs: Document "ldap page size".
Karolin Seeger [Mon, 30 Nov 2009 11:29:27 +0000 (12:29 +0100)]
s3:docs: Document "ldap page size".

Part of a fix for bug #6890 (Some smb.conf parameters are undocumented).

Karolin
(cherry picked from commit 9478ec35b5349f50a61bbe2aa88af88577918e91)
(cherry picked from commit 940121d666b9e0645584c93db178b763ac5c8c04)
(cherry picked from commit a1d8a6127448fbdc25d1d87a2541a2ea8e430e17)

14 years agos3:docs: Document "enable core files".
Karolin Seeger [Mon, 30 Nov 2009 10:40:06 +0000 (11:40 +0100)]
s3:docs: Document "enable core files".

Part of a fix for bug #6890 (Some smb.conf parameters are undocumented).

Karolin
(cherry picked from commit b03ad70848e6ea889f382c0cb9f21057370f1ab6)
(cherry picked from commit 15f7b70b0e6b6bd2604255cff1c351bb0425e9f3)
(cherry picked from commit 5832bc1c5896b391131952a06013154cbdafe3f9)

14 years agos3:docs: Document "cache directory" and "state directory".
Karolin Seeger [Mon, 30 Nov 2009 10:04:50 +0000 (11:04 +0100)]
s3:docs: Document "cache directory" and "state directory".

Part of a fix for bug #6890 (Some smb.conf parameters are undocumented).

Karolin
(cherry picked from commit 0003b5fad1dee687bc15dfad9f71b6dfc40556d7)
(cherry picked from commit d677cea90f0b28d65ddba551acaed9157ea30c2e)
(cherry picked from commit 7e9537792a8c5b8aad27a14ca5968aa8327a89bd)

14 years agocreate-tarball: Make it more comfortable to use the --copy-docs option.
Karolin Seeger [Thu, 26 Nov 2009 10:18:39 +0000 (11:18 +0100)]
create-tarball: Make it more comfortable to use the --copy-docs option.

Now you can directly specify the 'make release' output dir without any
modifications.

Karolin
(cherry picked from commit 77e2d2f1d29b69699f4539abfce7b2f32db843e4)
(cherry picked from commit 62df932f9dc333f69bf901fe88bfac6fc4e59bcd)
(cherry picked from commit f35a774cd0a6837e5440acf51ef1fc032d434007)

14 years agos3: Fix bug 6338 -- net rpc trustdom list always display "none"
Volker Lendecke [Sun, 22 Nov 2009 21:38:45 +0000 (22:38 +0100)]
s3: Fix bug 6338 -- net rpc trustdom list always display "none"
(cherry picked from commit e3dc0f527700a8be5e239dacedb880ca88c47312)

14 years agodocs: Fix Bug 6922: Add Registry patchfile for Win7 domain join.
Günther Deschner [Tue, 24 Nov 2009 10:36:14 +0000 (11:36 +0100)]
docs: Fix Bug 6922: Add Registry patchfile for Win7 domain join.

Patchfile from SATOH Fumiyasu <fumiyas@osstech.co.jp>.

Thanks!

Guenther
(cherry picked from commit 95d0f0aab01fdd751841d57cebe6150cd6fdf80c)
(cherry picked from commit 12dcd59dd9cf412bc45f4943f96ec9e1ab9efcf8)

14 years agoclikrb5: Prefer krb5_free_keytab_entry_contents to krb5_kt_free_entry.
Jelmer Vernooij [Thu, 4 Jun 2009 21:43:31 +0000 (23:43 +0200)]
clikrb5: Prefer krb5_free_keytab_entry_contents to krb5_kt_free_entry.

Both functions exist in MIT Kerberos >= 1.7, but only
krb5_free_keytab_entry_contents has a prototype.
(cherry picked from commit b65ba0e26c781647e097f3f6fa279c7f3f7f4bd2)

Part of a fix for bug #6918 (Build breaks with krb5-client-1.7-6.1.i586).
(cherry picked from commit af52655be1852151421417035007cf3a127fdf34)

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 f9a9e3268212b0430588d7e727b37998ace23ba7)

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 80d2ad88d8deac953346d1ce98fb519d7f2bf3de)

14 years agos3: fixed krb5 build problem on ubuntu karmic
Andrew Tridgell [Thu, 15 Oct 2009 23:40:50 +0000 (10:40 +1100)]
s3: fixed krb5 build problem on ubuntu karmic

Karmic has MIT krb5 1.7-beta3, which has the symbol
krb5_auth_con_set_req_cksumtype but no prototype for it.

See also http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=531635
(cherry picked from commit a6e4cb500b4162cae1d906a1762507370b4ee89e)

Part of a fix for bug #6918.
(cherry picked from commit 8c2dfcd24f69aa8d71a2854feaf2e8ea1802537e)

14 years agos3:idmap_ldap: trim the " chars from the location string in idmap_ldap_db_init
Michael Adam [Fri, 20 Nov 2009 11:44:43 +0000 (12:44 +0100)]
s3:idmap_ldap: trim the " chars from the location string in idmap_ldap_db_init

Fix bug #6910 (idmap_ldap stumbles over idmap backend = ldap:"ldap://ldap1
ldap://ldap2"=.

When idmap backend is specified as
idmap backend = ldap:"ldap://server1 ldap://server2"
then currently "ldap://server1 ldap://server2" was passed to
ldap_initialize including the quotes, leading to an ldap error.

Michael
(cherry picked from commit 5d6ea139d413cb05370137e4d04c4db391a06ac1)

14 years agos3:idmap_ldap: trim the " chars from the location string in idmap_ldap_alloc_init
Michael Adam [Fri, 20 Nov 2009 11:38:44 +0000 (12:38 +0100)]
s3:idmap_ldap: trim the " chars from the location string in idmap_ldap_alloc_init

When idmap alloc backend is specified as
idmap alloc backend = ldap:"ldap://server1 ldap://server2"
then currently "ldap://server1 ldap://server2" was passed to
ldap_initialize including the quotes, leading to an ldap error.

Michael
(cherry picked from commit 210fc5a8cf384eea62cd51d398523d37723f72fb)

14 years agos3:fix endianness bug in dbwrap_change_int32_atomic() (bug #6901)
Michael Adam [Fri, 20 Nov 2009 23:23:22 +0000 (00:23 +0100)]
s3:fix endianness bug in dbwrap_change_int32_atomic() (bug #6901)

Michael
(cherry picked from commit d96bc12a8634d50c0c74f583c264cf8f89e22637)

14 years agos3:fix endianness bug in dbwrap_change_uint32_atomic() (bug #6901)
Michael Adam [Fri, 20 Nov 2009 23:21:56 +0000 (00:21 +0100)]
s3:fix endianness bug in dbwrap_change_uint32_atomic() (bug #6901)

Michael
(cherry picked from commit d3db4b2d3a56975b0170714828921e0871bfa4a2)

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)
(cherry picked from commit a23ff8b8f8c805bc052e531067733d283e4ebaee)

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

Part of a fix for bug #6697.
And hopefully a fix for bug #6889.
(cherry picked from commit bb86aea5007b8ccf6f2f01e5f3c7a32b74eb7d74)

14 years agoSecond part of the fix for bug 6828 - infinite timeout occurs when byte lock held...
Jeremy Allison [Tue, 27 Oct 2009 18:25:02 +0000 (11:25 -0700)]
Second part of the fix for bug 6828 - infinite timeout occurs when byte lock held outside of samba. Fixes case where a connection with a pending lock can me marked "idle", and ensures that the lock queue timeout is always recalculated. Jeremy.
(cherry picked from commit aecf2dba0b2bfd65a307d9edae1792b3896fc73f)

14 years agoFix bug 6861 - rfc1738_unescape converts '+' characters to spaces. Stop rfc1738_unesc...
Jeremy Allison [Fri, 30 Oct 2009 21:16:03 +0000 (14:16 -0700)]
Fix bug 6861 - rfc1738_unescape converts '+' characters to spaces. Stop rfc1738_unescape() from mangling '+' characters to spaces. Noticed by Andrew Bartlett. Jeremy.
(cherry picked from commit 66e356a4864373d63eee3dda00c826eaf69c7a82)

14 years agoFix bug 6875 - trans2 FIND_FIRST2 response --> FIND_FIRST2 Data -> Fille Attributes...
Jeremy Allison [Fri, 6 Nov 2009 22:08:09 +0000 (14:08 -0800)]
Fix bug 6875 - trans2 FIND_FIRST2 response --> FIND_FIRST2 Data -> Fille Attributes are returned as 0x220 for LANMAN2.1 dialect Jeremy.
(cherry picked from commit dc9b226d8ced06b8b24eb38b411eac11eace41be)

14 years agos3: Do not redefine strupr.
Matt Kraai [Wed, 26 Aug 2009 21:50:28 +0000 (14:50 -0700)]
s3: Do not redefine strupr.

Fixes bug #6751 (Fails to compile on QNX because of conflicting types for
strupr).

Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit 6657598168724d4fe076f9014c2b5c16a034fe52)
(cherry picked from commit 268fb0106c892c4dd22e0e9bd5392a1e04121d2e)

14 years agoFix bug 6880 - cannot list workgroup servers reported by Alban Browaeys <prahal@yahoo...
Jeremy Allison [Mon, 9 Nov 2009 18:45:50 +0000 (10:45 -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 6be57c378c0dbc4c4ab732fffee0d6a74011fd14)

14 years agos3: Fix Bug #6869: Various annoying build warnings.
Günther Deschner [Wed, 4 Nov 2009 14:58:08 +0000 (15:58 +0100)]
s3: Fix Bug #6869: Various annoying build warnings.

Guenther
(cherry picked from commit c59898d5e6ba2569e6691338a73c5ccffc08af0e)

14 years agoFix bug 6867 - trans2findnext returns reply_nterror(req, ntstatus) In a directory...
Jeremy Allison [Mon, 2 Nov 2009 20:53:46 +0000 (12:53 -0800)]
Fix bug 6867 - trans2findnext returns reply_nterror(req, ntstatus) In a directory with a lot of files. Jeremy.
(cherry picked from commit a6e7be60322b981f9eb81f2b686d28223bd735bc)

14 years agos3:configure: Fix typo in libtalloc check.
Karolin Seeger [Tue, 27 Oct 2009 15:29:20 +0000 (16:29 +0100)]
s3:configure: Fix typo in libtalloc check.

Fix bug #6849. Thanks to Mike Frysinger <vapier@gentoo.org> for reporting
and providing the patch!

Karolin
(cherry picked from commit 5897c3de95b8f9fad4e136d2fc1a390fb366b7b9)

14 years agos3/docs: Fix typo.
Karolin Seeger [Fri, 30 Oct 2009 15:47:22 +0000 (16:47 +0100)]
s3/docs: Fix typo.

Fix bug #4250. Thanks to TAKAHASHI Motonobu <monyo@samba.gr.jp> for reporting!

Karolin
(cherry picked from commit d1ad143a707b36b3aafcbb498554b73d2013f6e8)
(cherry picked from commit 5087e0ce311c68420c68c285fcdffc5174690621)
(cherry picked from commit 2a58988f5824e6561957ab916cbc72909040f9c7)

14 years agos3/docs: Remove reference to nonexistent file.
Karolin Seeger [Fri, 30 Oct 2009 15:31:55 +0000 (16:31 +0100)]
s3/docs: Remove reference to nonexistent file.

Fix bug #4252. Thanks to TAKAHASHI Motonobu <monyo@samba.gr.jp> for reporting!

Karolin
(cherry picked from commit 52aa522a550de45aa28969d0a679ff4e9b6575d6)
(cherry picked from commit f6a1bcb69aea271a7afed409530da02595064f71)
(cherry picked from commit 50d54597e71cd6c4aafc117cd41ecb0e13346711)

14 years agos3:configure: only check for gpfs_gpl.h
Stefan Metzmacher [Wed, 28 Oct 2009 10:21:27 +0000 (11:21 +0100)]
s3:configure: only check for gpfs_gpl.h

The header is everything we need in order to build vfs_gpfs.

metze

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

Fix bug #6856.
(cherry picked from commit b71f0e5f6f715d7c061d3a845f1e983e2472c1b0)

14 years agos3/docs: Document new pdbedit -K option.
Karolin Seeger [Tue, 27 Oct 2009 15:04:35 +0000 (16:04 +0100)]
s3/docs: Document new pdbedit -K option.

Karolin
(cherry picked from commit 354038f170f2541318336aa72c9f2a0426c6607e)

Part of a fix for bug #6851.
(cherry picked from commit dbcacda71d59bb5e5587d241ae034adee38f5b67)

14 years agos3: pdbedit: add option --kickoff-time/-K to set the user's kickoff time
Michael Adam [Mon, 26 Oct 2009 15:07:58 +0000 (16:07 +0100)]
s3: pdbedit: add option --kickoff-time/-K to set the user's kickoff time

Use "never" as argument to set this to unlimited.

Michael
(cherry picked from commit 8fdef14305ae1e32d61c80cb10859d41c5754023)

Fix bug #6851.
(cherry picked from commit 53c32c7f182266e73cd606a8de02bce9d6db16e8)

14 years agoWHATSNEW: Start 3.4.4 release notes.
Karolin Seeger [Thu, 29 Oct 2009 10:50:23 +0000 (11:50 +0100)]
WHATSNEW: Start 3.4.4 release notes.

Karolin
(cherry picked from commit 976763fd2cbafb79adb67409349498ffac9b07aa)

14 years agoVERSION: Raise version number up to 3.4.4.
Karolin Seeger [Thu, 29 Oct 2009 10:48:22 +0000 (11:48 +0100)]
VERSION: Raise version number up to 3.4.4.

Karolin
(cherry picked from commit 4a4871251b576a0d2c707b8688fb1d7940b126cd)

14 years agoWHATSNEW: Complete release notes. samba-3.4.3
Karolin Seeger [Thu, 29 Oct 2009 07:45:36 +0000 (08:45 +0100)]
WHATSNEW: Complete release notes.

Karolin
(cherry picked from commit 508ef0261c56a6d93257d4e2b4cb917cb8bd10bb)

14 years agoWHATSNEW: Update release notes.
Karolin Seeger [Mon, 26 Oct 2009 11:02:40 +0000 (12:02 +0100)]
WHATSNEW: Update release notes.

Karolin
(cherry picked from commit 5158bdcc222cb38b7cf4939e09f6d0fbb7868de2)

14 years agos3:docs: Public is not a synonym for access based shareenum.
Karolin Seeger [Mon, 26 Oct 2009 09:14:51 +0000 (10:14 +0100)]
s3:docs: Public is not a synonym for access based shareenum.

Fix build warning.

Karolin
(cherry picked from commit 35dc481289c28a77f354dd76193d6298de32c66d)
(cherry picked from commit 7601427a2db1263b0192c1a78d8bacb7eb0b74da)
(cherry picked from commit d6ecfb23cfc841ad0bfe8ae677ddbbba7fd36f31)

14 years agos3: Fix crash in pam_winbind, another reference to freed memory.
Bo Yang [Sat, 24 Oct 2009 01:20:00 +0000 (09:20 +0800)]
s3: Fix crash in pam_winbind, another reference to freed memory.

Fix bug #6840.

Signed-off-by: Bo Yang <boyang@samba.org>
(cherry picked from commit b9a3f1dd85d168c15df846dba525f4f882d1acf8)
(cherry picked from commit a0fbf067011ae50d63c6ed2a79f1ff00c2ce2d11)

14 years agoFix bug 6829 - smbclient does not show special characters properly. All successful...
Jeremy Allison [Thu, 22 Oct 2009 22:30:47 +0000 (15:30 -0700)]
Fix bug 6829 - smbclient does not show special characters properly. All successful calls to cli_session_setup() *must* be followed by calls to cli_init_creds() to stash the credentials we successfully connected with. There were 2 codepaths where this was missing. This caused smbclient to be unable to open the \srvsvc pipe to do an RPC netserverenum, and cause it to fall back to a RAP netserverenum, which uses DOS codepage conversion rather than the full UCS2 of RPC, so the returned characters were not correct (unless the DOS codepage was set correctly). Phew. That was fun to track down :-). Includes logic simplification in libsmb_server.c Jeremy.
(cherry picked from commit 587ca743bf1491e97c984ce4bec5a9bd0a1ae69a)

14 years agoFix bug 6828 - infinite timeout occurs when byte lock held outside of samba Jeremy.
Jeremy Allison [Wed, 21 Oct 2009 01:10:30 +0000 (18:10 -0700)]
Fix bug 6828 - infinite timeout occurs when byte lock held outside of samba Jeremy.
(cherry picked from commit a572c28ca3daa199d78fc340819c5c9ff53a3ed6)

14 years agos3: Don't fail authentication when one or some group of require-membership-of is...
Bo Yang [Wed, 14 Oct 2009 22:23:48 +0000 (06:23 +0800)]
s3: Don't fail authentication when one or some group of require-membership-of is invalid.

Signed-off-by: Bo Yang <boyang@samba.org>
(cherry picked from commit 31f1a36901b5b8959dc51401c09c114829b50392)

Fix bug #6826.
(cherry picked from commit f383e5f549f9f2075a064ba3d88fa9b34c5e3389)

14 years agoWHATSNEW: Update changes since 3.4.2.
Karolin Seeger [Thu, 22 Oct 2009 14:22:10 +0000 (16:22 +0200)]
WHATSNEW: Update changes since 3.4.2.

Karolin
(cherry picked from commit 8e55d149ab4de1a769a8a720e6f432476e719055)

14 years agos3:docs: Add info about how to obtain cifs module in cifs mount helper manpage
Volker Lendecke [Wed, 9 Sep 2009 21:08:28 +0000 (23:08 +0200)]
s3:docs: Add info about how to obtain cifs module in cifs mount helper manpage
(cherry picked from commit a224392649ffb81dc1d67f41a01dd983b76d513b)

Fixes bug #5129.
(cherry picked from commit 646f0534acf0c480a61e0a02d1d815347b5e6d52)

14 years agos3-spnego: Fix Bug #6815. Windows 2008 R2 SPNEGO negTokenTarg parsing failure.
Günther Deschner [Thu, 15 Oct 2009 14:01:36 +0000 (16:01 +0200)]
s3-spnego: Fix Bug #6815. Windows 2008 R2 SPNEGO negTokenTarg parsing failure.

When parsing a SPNEGO session setup retry (falling back from KRB5 to NTLMSSP),
we failed to parse the ASN1_ENUMERATED negResult in the negTokenTarg, thus
failing spnego_parse_auth() completely.

Guenther
(cherry picked from commit 78ba2e1b9e5a63443f4cd51d34c16bc7cc9c6941)

14 years agos3-spnego: avoid NULL talloc context in read_spnego_data().
Günther Deschner [Thu, 15 Oct 2009 14:00:57 +0000 (16:00 +0200)]
s3-spnego: avoid NULL talloc context in read_spnego_data().

Guenther
(cherry picked from commit a830aa269f44e28a2390e162adbb2e26092f179b)

14 years agoWHATSNEW: Start release notes for Samba 3.4.3.
Karolin Seeger [Mon, 19 Oct 2009 12:56:44 +0000 (14:56 +0200)]
WHATSNEW: Start release notes for Samba 3.4.3.

Karolin
(cherry picked from commit e97037236fb82bd990382301fbab20e8d44e9371)

14 years agoVERSION: Raise version number up to 3.4.3.
Karolin Seeger [Mon, 19 Oct 2009 12:54:37 +0000 (14:54 +0200)]
VERSION: Raise version number up to 3.4.3.

Karolin
(cherry picked from commit de5151e59f2e060938b957b074e3d0dabd60161c)

14 years agos3:configure: fix avahi activation
Björn Jacke [Sun, 18 Oct 2009 15:01:57 +0000 (17:01 +0200)]
s3:configure: fix avahi activation

Avahi was correctly found but not activated since e4a26c942.
(cherry picked from commit 718d2801d6bafedfe91d7b475294d69e2d6a77a4)

Fix bug #6824.
(cherry picked from commit f1023e5f6252bc8efa732f519ec9588deed6c774)

14 years agoFix symlink calls in all vfs modules.
Jeremy Allison [Mon, 19 Oct 2009 06:39:23 +0000 (08:39 +0200)]
Fix symlink calls in all vfs modules.

Additional patch to fix bug #6769.
(cherry picked from commit d8c7a5aafe0c17c69013766022418edcec481f8c)

14 years agos3:packaging: Fix building RHEL packages.
Karolin Seeger [Fri, 16 Oct 2009 14:00:26 +0000 (16:00 +0200)]
s3:packaging: Fix building RHEL packages.

Fix bug #6721.
Thanks to Eero Volotinen <eero.volotinen@medicel.com> for providing the patch!

Karolin
(cherry picked from commit 79c2c61b99eb7c47c8bfbbb479d9d2197d1ad1fb)
(cherry picked from commit 11a6d88ea387fa50690880561f0ffffefbeb8956)
(cherry picked from commit ece84bf7a8066999ac7198e7625a4d1a8fddb91b)

14 years agocifs.upcall: do a brute-force search for KRB5 credcache
Jeff Layton [Wed, 14 Oct 2009 14:59:00 +0000 (10:59 -0400)]
cifs.upcall: do a brute-force search for KRB5 credcache

A few weeks ago, I added some code to cifs.upcall to take the pid sent
by the kernel and use that to get the value of the $KRB5CCNAME
environment var for the process. That works fine on the initial mount,
but could be problematic on reconnect.

There's no guarantee on a reconnect that the process that initiates the
upcall will have $KRB5CCNAME pointed at the correct credcache. Because
of this, the current scheme isn't going to be reliable enough and we
need to use something different.

This patch replaces that scheme with one very similar to the one used by
rpc.gssd in nfs-utils. It searches the credcache dir (currently
hardcoded to /tmp) for a valid credcache for the given uid. If it finds
one then it uses that as the credentials cache. If it finds more than
one, it uses the one with the latest TGT expiration.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
Addresses bug #6810.
(cherry picked from commit 5df191a5fdad480d00d278c7f5046c6f0b80e386)

14 years agocifs.upcall: make using ip address conditional on new option
Jeff Layton [Wed, 14 Oct 2009 14:58:56 +0000 (10:58 -0400)]
cifs.upcall: make using ip address conditional on new option

Igor Mammedov pointed out that reverse resolving an IP address to get
the hostname portion of a principal could open a possible attack
vector. If an attacker were to gain control of DNS, then he could
redirect the mount to a server of his choosing, and fix the reverse
resolution to point to a hostname of his choosing (one where he has
the key for the corresponding cifs/ or host/ principal).

That said, we often trust DNS for other reasons and it can be useful
to do so. Make the code that allows trusting DNS to be enabled by
adding --trust-dns to the cifs.upcall invocation.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit f3b2402a737ff0a7e80a03ade9f57d65dabdc7eb)

14 years agocifs.upcall: switch to getopt_long
Jeff Layton [Wed, 14 Oct 2009 14:58:48 +0000 (10:58 -0400)]
cifs.upcall: switch to getopt_long

...to allow long option names.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit d95570b60832e980f0ff6bad96a3a45a7ba9789a)

14 years agocifs.upcall: fix IPv6 addrs sent to upcall to have colon delimiters
Jeff Layton [Wed, 14 Oct 2009 14:58:48 +0000 (10:58 -0400)]
cifs.upcall: fix IPv6 addrs sent to upcall to have colon delimiters

Current kernels don't send IPv6 addresses with the colon delimiters, add
a routine to add them when they're not present.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 00f298804be8f561e6ed584fcd516634ec74c4d7)

14 years agocifs.upcall: use ip address passed by kernel to get server's hostname
Jeff Layton [Wed, 14 Oct 2009 14:58:48 +0000 (10:58 -0400)]
cifs.upcall: use ip address passed by kernel to get server's hostname

Instead of using the hostname given by the upcall to get the server's
principal, take the IP address given in the upcall and reverse resolve
it to a hostname.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 95d7a6d7699604ec1b5b0e90b341c57c2d3c55c2)

14 years agocifs.upcall: clean up flag handling
Jeff Layton [Wed, 14 Oct 2009 14:58:47 +0000 (10:58 -0400)]
cifs.upcall: clean up flag handling

Add a new stack var to hold the flags returned by the decoder routine
so that we don't need to worry so much about preserving "rc".

With this, we can drop privs before trying to find the location of
the credcache.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 531a2f482d7519122f79d9d8049a96f63d361a2f)

14 years agocifs.upcall: try getting a "cifs/" principal and fall back to "host/"
Jeff Layton [Wed, 14 Oct 2009 14:58:20 +0000 (10:58 -0400)]
cifs.upcall: try getting a "cifs/" principal and fall back to "host/"

cifs.upcall takes a "-c" flag that tells the upcall to get a principal
in the form of "cifs/hostname.example.com@REALM" instead of
"host/hostname.example.com@REALM". This has turned out to be a source of
great confusion for users.

Instead of requiring this flag, have the upcall try to get a "cifs/"
principal first. If that fails, fall back to getting a "host/"
principal.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit edca7df0dd43ee1d7ae2fc4954470efdf64a4d8e)

14 years agocifs.upcall: declare a structure for holding decoded args
Jeff Layton [Wed, 14 Oct 2009 14:44:40 +0000 (10:44 -0400)]
cifs.upcall: declare a structure for holding decoded args

The argument list for the decoder is becoming rather long. Declare an
args structure and use that for holding the args. This also simplifies
pointer handling a bit.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 3eac202b211b382ebe299538647cbbd7d0c803b1)

14 years agocifs.upcall: formatting cleanup
Jeff Layton [Wed, 14 Oct 2009 14:44:22 +0000 (10:44 -0400)]
cifs.upcall: formatting cleanup

Clean up some unneeded curly braces, and fix some indentation.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 8bf083788bed03fdc7b535595eea8ce83a6f15f9)

14 years agocifs.upcall: clean up logging and add debug messages
Jeff Layton [Wed, 14 Oct 2009 14:43:18 +0000 (10:43 -0400)]
cifs.upcall: clean up logging and add debug messages

Change the log levels to be more appropriate to the messages being
logged. Error messages should be LOG_ERR and not LOG_WARNING, for
instance.

Add some LOG_DEBUG messages that we can use to diagnose problems with
krb5 upcalls. With these, someone can set up syslog to log daemon.debug
and should be able to get more info when things aren't working.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 7c7bb1572c86767658852426e6eb7de901b1cab2)

14 years agoAttempt to fix the build -- jlayton, please check!
Volker Lendecke [Wed, 14 Oct 2009 14:42:46 +0000 (10:42 -0400)]
Attempt to fix the build -- jlayton, please check!
(cherry picked from commit 78b53b878a7871ea0ef311317da561008ad07e08)

14 years agocifs.upcall: use pid value from kernel to determine KRB5CCNAME to use
Jeff Layton [Wed, 14 Oct 2009 14:42:28 +0000 (10:42 -0400)]
cifs.upcall: use pid value from kernel to determine KRB5CCNAME to use

If the kernel sends the upcall a pid of the requesting process, we can
open that process' /proc/<pid>/environ file and scrape the KRB5CCNAME
value out of it.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 416f92e3ae739d6ba6593c8e9c43192e4671fc77)

14 years agoFinal part of fix for bug 6793 - winbindd crash with "INTERNAL ERROR: Signal 6" Don...
Jeremy Allison [Wed, 14 Oct 2009 18:11:26 +0000 (11:11 -0700)]
Final part of fix for bug 6793 - winbindd crash with "INTERNAL ERROR: Signal 6" Don't use mapped_user uninitialized. Jeremy.
(cherry picked from commit 85ee2971db36455d908066eae2630925081792c9)

14 years agos3/aio: Correctly handle aio_error() and errno.
Olaf Flebbe [Tue, 6 Oct 2009 09:09:28 +0000 (11:09 +0200)]
s3/aio: Correctly handle aio_error() and errno.

Fix bug #6805.
(cherry picked from commit dd28b7850c7ace008558571caee9679ff97a5e91)

14 years agoFix bug 6811 - pam_winbind references freed memory. s3: Fix reference to freed memory...
Bo Yang [Wed, 14 Oct 2009 19:45:16 +0000 (12:45 -0700)]
Fix bug 6811 - pam_winbind references freed memory. s3: Fix reference to freed memory in pam_winbind.
(cherry picked from commit 106e3d5bdb1683d53b5525e3fe2e9e2d9de27e2c)

14 years agos3: Fix bug 6606
Volker Lendecke [Sat, 10 Oct 2009 09:15:42 +0000 (11:15 +0200)]
s3: Fix bug 6606

This is a port of 1f34ffa0caae5 and 24309bdb2efc to 3.4.

Fix file corruption using smbclient with NT4 server.
(cherry picked from commit c685beb091cb0fedfb3f64bcc2ec2beb00fc9328)

14 years agos3:winbind: Fix a double-free
Volker Lendecke [Tue, 13 Oct 2009 18:56:28 +0000 (20:56 +0200)]
s3:winbind: Fix a double-free

Part of a fix for bug #6793.
(cherry picked from commit 0fc64947526f4eea896fd83b01194e40416d15f4)

14 years agos3:winbind: Fix bug 6793 -- segfault in winbindd_pam_auth
Volker Lendecke [Fri, 9 Oct 2009 20:05:37 +0000 (22:05 +0200)]
s3:winbind: Fix bug 6793 -- segfault in winbindd_pam_auth
(cherry picked from commit 2e478cc8c31bc60325a8e01885222d1db29ca21c)

14 years agos3:net: Fix a segfault in "net rpc trustdom list" for overlong domain names
Volker Lendecke [Tue, 13 Oct 2009 13:56:00 +0000 (15:56 +0200)]
s3:net: Fix a segfault in "net rpc trustdom list" for overlong domain names

That was a complicated way to say "%-20.s"... But that code was from 2002 ...
(cherry picked from commit 8a27fdea89bc54aa35e363a376836662103c7cb7)

Fix Bug #6807.
(cherry picked from commit aa5a43143f26dee14dc1efe2a979a6701ddc650b)

14 years agos3/loadparm: Fix hpux compiler issue.
Olaf Flebbe [Tue, 13 Oct 2009 09:39:49 +0000 (11:39 +0200)]
s3/loadparm: Fix hpux compiler issue.

Fixes bug #6804.
(cherry picked from commit bf64668cb114ca7afdc81545d229bcb73b59c8f6)

14 years agos3: Fix a memleak reported by dmarkey
Volker Lendecke [Fri, 9 Oct 2009 20:58:14 +0000 (22:58 +0200)]
s3: Fix a memleak reported by dmarkey
(cherry picked from commit 5aeb954ba9382e1975c64ac96f1e377ed6af3ae0)

Fix bug #6797.
(cherry picked from commit a5e71f765927de5aa2a8e6a21cc297d274e8a1c2)

14 years agoFix bug 6796 - Deleting an event context on shutdown can cause smbd to crash.
Jeremy Allison [Fri, 9 Oct 2009 19:50:26 +0000 (12:50 -0700)]
Fix bug 6796 - Deleting an event context on shutdown can cause smbd to crash.

Sync's tevent signal code with 3.5.x tree.
Protects against ev pointer being NULL.

Jeremy
(cherry picked from commit 56290654c0c2056c31e0b348ba0d01e5c28ba89b)

14 years agoFix bug 6774 - smbd crashes if "aio write behind" is set.
Jeremy Allison [Fri, 9 Oct 2009 17:01:29 +0000 (10:01 -0700)]
Fix bug 6774 - smbd crashes if "aio write behind" is set.

Don't dereference a talloc_move'd pointer.

Jeremy.
(cherry picked from commit 951991df2976b5f8f57c0418257d9d817ebda661)

14 years agos3/aio: allow for outstanding_aio_calls to be decremented.
Olaf Flebbe [Wed, 30 Sep 2009 12:55:58 +0000 (14:55 +0200)]
s3/aio: allow for outstanding_aio_calls to be decremented.

Fixes bug #6772.
(cherry picked from commit a13f8bf949300079419cd86982012212323fcb65)

14 years agos3/Makefile: BUG 6791: Fix link order for libwbclient.
Karolin Seeger [Fri, 9 Oct 2009 06:58:55 +0000 (08:58 +0200)]
s3/Makefile: BUG 6791: Fix link order for libwbclient.

Patch was provided by Buchan Milne <bgmilne@mandriva.org>.

Signed-off-by: Björn Jacke <bj@sernet.de>
(cherry picked from commit c0cbfdef387bf70e589dec6a3bbd434d12cacc34)

14 years agos3/Makefile: BUG 6791: Fix linking order in cifs.upcall.
Karolin Seeger [Fri, 9 Oct 2009 06:55:53 +0000 (08:55 +0200)]
s3/Makefile: BUG 6791: Fix linking order in cifs.upcall.

Patch was originally provided by Buchan Milne <bgmilne@mandriva.org>.

Signed-off-by: Björn Jacke <bj@sernet.de>
(cherry picked from commit 7aea6adcede87a2389d933eedc50f836ba161f95)

14 years agoCorrect fix for bug 6781 - Cannot rename subfolders in Explorer view with recent...
Jeremy Allison [Wed, 7 Oct 2009 22:46:57 +0000 (15:46 -0700)]
Correct fix for bug 6781 - Cannot rename subfolders in Explorer view with recent versions of Samba. Without this fix, renaming a directory ./a to ./b, whilst a directory ./aa was already open would fail. Simplifies logic of earlier code. Jeremy.
(cherry picked from commit 37f42ad6a1fff1e43bfd6dcaa8244b738ea37363)

14 years agoFix bug 6769 - symlink unlink does nothing. Jeremy.
Jeremy Allison [Thu, 8 Oct 2009 23:40:26 +0000 (16:40 -0700)]
Fix bug 6769 - symlink unlink does nothing. Jeremy.
(cherry picked from commit 9f7d155001bc4c2808b6d17e9cb5ce87173b6061)

14 years agos3:winbind: Only ever handle one event after a select call
Volker Lendecke [Wed, 7 Oct 2009 12:06:53 +0000 (14:06 +0200)]
s3:winbind: Only ever handle one event after a select call

While handling an fd event, the situation with other fds can change. I've just
seen a winbind stuck in the accept() call on the privileged pipe. I can only
imagine this happen because under high load we first handled other requests and
meanwhile the client on the privileged pipe went away.
(cherry picked from commit 8ef4a183da8bdc9997c198678a931b111396c104)

14 years agoFix bug 6776 - Running overlapping Byte Lock test will core dump Samba daemon. Re...
Jeremy Allison [Mon, 5 Oct 2009 21:22:05 +0000 (14:22 -0700)]
Fix bug 6776 - Running overlapping Byte Lock test will core dump Samba daemon. Re-write core of POSIX locking logic. Jeremy.
(cherry picked from commit e3a41dd3167df58990d4b0f1f2ea6b6583826cf9)

14 years agos3:smbd: Fix bug 6690, wrong error check
Andrew Klosterman [Tue, 8 Sep 2009 15:38:37 +0000 (17:38 +0200)]
s3:smbd: Fix bug 6690, wrong error check
(cherry picked from commit f1f6df1747164f3f57adc9c6912b27592baa0802)

14 years agos3:winbindd: only notify the client when we exist, if the connection isn't dead already
Stefan Metzmacher [Fri, 25 Sep 2009 04:20:33 +0000 (06:20 +0200)]
s3:winbindd: only notify the client when we exist, if the connection isn't dead already

This is similar to commit 83edf3e43e86781872a07d8eb53084f59ad7384c.

metze
(cherry picked from commit 722ba568d79451a527976181b360de82b87b68e8)

14 years agos3:winbindd_cm: don't invalidate the whole connection when just samr gave ACCCESS_DENIED
Stefan Metzmacher [Thu, 24 Sep 2009 19:35:38 +0000 (21:35 +0200)]
s3:winbindd_cm: don't invalidate the whole connection when just samr gave ACCCESS_DENIED

metze
(cherry picked from commit bfd3a6f13aa935950142a24bf331feb98f987bde)
(cherry picked from commit 53a426986a0ead7903ff6cf576b3d5501210e379)

14 years agos3:rpc_client: don't randomly fragment rpc pdu's in developer mode
Stefan Metzmacher [Sun, 20 Sep 2009 21:29:11 +0000 (23:29 +0200)]
s3:rpc_client: don't randomly fragment rpc pdu's in developer mode

This is really confusing and also breaks against windows,
as it doesn't accept fragmented bind requests.

metze
(cherry picked from commit 68b8149d1fb26b2fe1138c99d971754b0a30378b)
(cherry picked from commit 10ff61b24f0604c9686e728ac92c1a2987a31aed)

14 years agos3:lib/select: don't overwrite errno in the signal handler
Stefan Metzmacher [Sun, 20 Sep 2009 21:29:34 +0000 (23:29 +0200)]
s3:lib/select: don't overwrite errno in the signal handler

metze
(cherry picked from commit 00e378f17c39c52689601bc622b9cd78a0cdce12)
(cherry picked from commit 8d8bcfbfbe95f1623870b54cfc9329187a06d526)

14 years agotevent: make sure we don't set errno within the signal handler function.
Stefan Metzmacher [Mon, 21 Sep 2009 01:16:18 +0000 (03:16 +0200)]
tevent: make sure we don't set errno within the signal handler function.

metze
(cherry picked from commit d13dfbeb6c6ab5b20277439da5b95f1a7f2850eb)
(cherry picked from commit 017586bb84a073f03a04ade6fb0bbe26af4112c1)

14 years agos3:rpc_server: we need to make a copy of my_name in serverinfo_to_SamInfo_base()
Stefan Metzmacher [Thu, 24 Sep 2009 04:38:08 +0000 (06:38 +0200)]
s3:rpc_server: we need to make a copy of my_name in serverinfo_to_SamInfo_base()

This is important for the case the server_info already contains a logon_server.

metze
(This is similar to commit 9ef39406d8072a1a102813fb4448af76e9020fcd)
(cherry picked from commit dd5519d926ecdccc38f488d9a6d5138bfd871aa0)

14 years agos3:winbind: Fix an uninitialized variable (cherry picked from commit 0724649a8a7c04d0...
Volker Lendecke [Wed, 23 Sep 2009 04:23:50 +0000 (06:23 +0200)]
s3:winbind: Fix an uninitialized variable (cherry picked from commit 0724649a8a7c04d015317d9dc2ae43ee87c1bd25)
(cherry picked from commit d6af2a5ff4e4f723e521a3f708751b3155f870fc)

14 years agos3-winbindd: Fix Bug #6711: trusts to windows 2008 (2008 r2) not working.
Günther Deschner [Thu, 17 Sep 2009 07:43:36 +0000 (09:43 +0200)]
s3-winbindd: Fix Bug #6711: trusts to windows 2008 (2008 r2) not working.

Winbindd should always try to use LSA via an schannel authenticated ncacn_ip_tcp
connection when talking to AD for LSA lookup calls.

In Samba <-> W2k8 interdomain trust scenarios, LookupSids3 and LookupNames4 via an
schannel ncacn_ip_tcp LSA connection are the *only* options to successfully resolve
sids and names.

Guenther
(cherry picked from commit 6a8ef6c424c52be861ed2a9806f917a64ec892a6)
(cherry picked from commit 3bd36630e402b6215a46f8b0ba98e9e2b18b44eb)

14 years agos3-winbindd: add cm_connect_lsa_tcp().
Günther Deschner [Sat, 12 Sep 2009 21:30:39 +0000 (23:30 +0200)]
s3-winbindd: add cm_connect_lsa_tcp().

Guenther
(cherry picked from commit 58f2deb94024f002e3c3df47f45454edc97f47e1)
(cherry picked from commit b35d5cf97fd610874583f0d03c6cda4def0cf0f5)