Karolin Seeger [Fri, 26 Apr 2013 10:02:58 +0000 (12:02 +0200)]
WHATSNEW: Add some information on migrating printers.
Thanks to Andreas for providing the text and making sure that it ends up in the
release notes!
Karolin
(cherry picked from commit
5aba70a99dd8d3e7e12a4837c00194eaba5f271c)
Karolin Seeger [Fri, 26 Apr 2013 08:48:44 +0000 (10:48 +0200)]
WHATSNEW: Add changes since 3.6.13.
Karolin
(cherry picked from commit
544e41ec27bcc8c5fe3ec784c4a937830bc8096b)
Volker Lendecke [Fri, 19 Apr 2013 14:17:13 +0000 (16:17 +0200)]
docs: Fix bug 9809 -- missing entry in specfile
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Karolin Seeger <kseeger@samba.org>
Autobuild-User(master): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(master): Mon Apr 22 11:35:52 CEST 2013 on sn-devel-104
(cherry picked from commit
5512a43a93833d3d6f1721d69c894db0e2c77ef8)
(cherry picked from commit
7441f3d9f1d2cec29e0caaeaf7a4fc92761fe82f)
Jeremy Allison [Thu, 18 Apr 2013 18:19:20 +0000 (11:19 -0700)]
Fix bug 9811 - Old DOS SMB CTEMP request uses a non-VFS function to access the filesystem.
Fix bug in old create temp SMB request. Only use VFS functions.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
61d591bb1eacbd7bcdf6a1c4abe8442edfece524)
David Disseldorp [Wed, 17 Apr 2013 17:39:12 +0000 (10:39 -0700)]
Bug 9807 - wbinfo: fix segfault in wbinfo_pam_logon
wbinfo_pam_logon() incorrectly assumes that wbcLogonUser() always
returns an allocated wbcAuthErrorInfo struct on failure.
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Apr 17 21:29:29 CEST 2013 on sn-devel-104
(cherry picked from commit
8bb8f0011e567501a98a901adcfffbf4f34e73ae)
Andreas Schneider [Thu, 4 Apr 2013 10:18:25 +0000 (12:18 +0200)]
BUG 9766: Cache name_to_sid/sid_to_name correctly.
If there is no domain_name specified we still need to set to for
caching else we will not find the entry later if we lookup the entry
with the domain_name.
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Signed-off-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Tue Apr 9 16:32:44 CEST 2013 on sn-devel-104
(cherry picked from commit
afcbaf373a1959f2323ffa729886b688c2b965e3)
Andreas Schneider [Fri, 5 Apr 2013 12:07:37 +0000 (14:07 +0200)]
BUG 9139: Fix the username map optimization.
If we successfully map a user. We call
set_last_from_to(user_in, unixname);
in the while loop reading the map file. After a successfull map we don't
stop and continue the loop to check all other mappings in the username
mapfile. But when we hit the end of the file and leave the loop we call:
set_last_from_to(user_in, user_in);
This overwrites the successful mapping, and the next time we call
map_username() we skip the username and no mapping is done.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
d9b8bd03d002e0329a4b0ed4b1cc81d64fe9c6eb)
Andreas Schneider [Wed, 3 Apr 2013 13:46:00 +0000 (15:46 +0200)]
BUG 9699: Fix adding case sensitive spn.
We should be able to define the case of the spn cause it is important
for some services like nfs. 'net ads keytab add "nfs"' should not
result in an uppercase spn.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
6848fb121a3a16b2d87b2bf2f7cca8364a1343f1)
Volker Lendecke [Tue, 9 Apr 2013 19:43:28 +0000 (21:43 +0200)]
vfs_fake_perms: Fix bug 9775, segfault for "artificial" conn_structs
(cherry picked from commit
70107fc911570bbbc1cd613e9c594f5481e5685e)
Jeremy Allison [Mon, 25 Mar 2013 16:54:50 +0000 (09:54 -0700)]
Optimization suggested by Volker. Don't do a stat system call on normal read path.
Only do it if we need it in the sendfile() path.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Thu Mar 28 17:51:22 CET 2013 on sn-devel-104
Fix bug #9748 - Remove unneeded fstat system call from hot read path.
(cherry picked from commit
60a2fb5ddac02376d82f323f2acb1211bb7929e3)
Volker Lendecke [Thu, 21 Mar 2013 21:00:06 +0000 (22:00 +0100)]
smbd: Tune "dir" a bit.
for i in $(seq 1 20000) ; do echo dir ; done | smbclient //127.0.0.1/tmp -U%
without and with this patch:
$ time bin/smbd -d0 -i
smbd version 4.1.0pre1-GIT-
1f139ae started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
Beendet
real 0m28.342s
user 0m10.249s
sys 0m10.513s
$ time bin/smbd -d0 -i
smbd version 4.1.0pre1-GIT-
1f139ae started.
Copyright Andrew Tridgell and the Samba Team 1992-2013
Beendet
real 0m27.348s
user 0m9.089s
sys 0m10.853s
The "real" timestamp is irrelevant, this also contains the time between
starting smbd and the smbclient job. It's the "user" time. The result that this
patch improves the time spent in user space by 10% is consistent.
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Fix bug #9736 - Change to smbd/dir.c code gives significant performance
increases on large directory listings.
(cherry picked from commit
565d1409c7c424fbbeed1e98b042d3970b0acf73)
Andreas Schneider [Fri, 22 Mar 2013 13:15:57 +0000 (14:15 +0100)]
BUG 9735: Fix winbind seperator in upn to username conversion.
Reviewed-by: Günther Deschner <gd@samba.org>
Signed-off-by: Andreas Schneider <asn@samba.org>
(cherry picked from commit
01192ce939cf77737de8efe7072dded5c3e1da94)
Jeremy Allison [Thu, 21 Mar 2013 20:59:20 +0000 (13:59 -0700)]
Fix bug #9733 - smbcontrol close-share is not working.
As part of forcibly disconnecting a client from a share,
smbd must atomically call reload_services() to ensure that
the entry in the ServicePtrs[] array corresponding to
that share is removed if the share was removed from
the smb.conf or registry entries.
Otherwise the ServicePtrs[] array entry for the share
remains active and the client races to auto-reconnect to
the share before a second message to reload the smb.conf
file can be sent.
This has to be done as part of the close-share message
processing, as removing the share from the smb.conf file
first, then telling the smbd to reload followed by the
forcible disconnect message doesn't work as in this
sequence of events when the reload message is received
the client is still connected to the share, so the
ServicePtrs[] entry is still left active.
The forcible-disconnect + service reload has to be done
together as an atomic operation in order for this to work.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
1df61789ca466923a7a252244888bd1b7cfbc79e)
Jeremy Allison [Wed, 27 Mar 2013 18:54:34 +0000 (11:54 -0700)]
Final fix for bug #9130 - Certain xattrs cause Windows error 0x800700FF
The spec lies when it says that NextEntryOffset is the only value
considered when finding the next EA. We were adding 4 more extra
pad bytes than needed (i.e. if the next entry already was on a 4
byte boundary, then we were adding 4 additional pad bytes).
Signed-off-by: Jeremy Allison <jra@samba.org>
The last 5 patches address bug #9130 - Certain xattrs cause Windows error
0x800700FF.
(cherry picked from commit
57db33599589b06a60cb7cbb454f87bf40c542e0)
Jeremy Allison [Wed, 27 Mar 2013 00:07:55 +0000 (17:07 -0700)]
Ensure we don't return uninitialized memory in the pad bytes.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
79503841059e945e6b14fa8c92375041c5390764)
Jeremy Allison [Tue, 26 Mar 2013 23:55:03 +0000 (16:55 -0700)]
Fix bug #9130 - Certain xattrs cause Windows error 0x800700FF
Ensure we never return any zero-length EA's.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
8794bb97495a7de4bf98f497abdf713be68db7a9)
Jeremy Allison [Tue, 26 Mar 2013 23:53:45 +0000 (16:53 -0700)]
Change estimate_ea_size() to correctly estimate the EA size over SMB2.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
c6688532c8a01836f29a38806ced62b34617222d)
Jeremy Allison [Tue, 26 Mar 2013 23:50:13 +0000 (16:50 -0700)]
Modify fill_ea_chained_buffer() to be able to do size calculation only, no marshalling.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
45654424a5c686a43cd9edb8026c0d0424260fd9)
Volker Lendecke [Mon, 18 Mar 2013 08:36:17 +0000 (09:36 +0100)]
wkssvc: Fix bug 9727, NULL pointer dereference
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Mon Mar 18 11:39:27 CET 2013 on sn-devel-104
(cherry picked from commit
05a7a10c88be99d864eacd6f9d37a340022f01f6)
(cherry picked from commit
64fb72ccb26b8e48c50407bc58618499ab2f5603)
David Disseldorp [Fri, 15 Mar 2013 15:54:06 +0000 (16:54 +0100)]
printing: update registry and publish in background
Currently all smbd processes unnecessarily access each printer registry
TDB entry following printcap cache reload.
This change moves responsibility for this to the background print queue
process.
This and the last four commits address bug 9650: New or delete cups
printerqueues are not recognized by the samba.
(cherry picked from commit
ac6604868d1325dd4c872dc0f6ab056d10ebaecf)
David Disseldorp [Fri, 15 Feb 2013 11:17:53 +0000 (12:17 +0100)]
spoolss: only reload printers on pcap update message
Printcap cache updates are the responsibility of the background
printing process, which after doing so broadcasts a MSG_PRINTER_PCAP
message. Spoolssd should only reload printers after receiving such a
message.
(cherry picked from commit
c30c66d8b5b4ebbde1b148c51310e336f29ca04e)
David Disseldorp [Thu, 14 Feb 2013 16:02:08 +0000 (17:02 +0100)]
printing: add sighup and conf change handlers
The background printing process is now responsible for all printcap
cache updates, which should be done on SIGHUP and configuration change.
(cherry picked from commit
f4af7c4d4cafe15c437742d450c7753a8b6d8422)
David Disseldorp [Thu, 14 Feb 2013 13:42:21 +0000 (14:42 +0100)]
printing: move pcap change notifier to bg process
The background print queue process is responsible for printcap cache
updates, and should be the only process to send notifications.
(cherry picked from commit
23ac828ba93e2ffc60ced19656af9609dcc1b2ab)
David Disseldorp [Tue, 12 Feb 2013 17:57:53 +0000 (18:57 +0100)]
smbd: fix cups printcap cache updates on startup
On startup the parent smbd process currently calls pcap_cache_reload(),
which is done immediately before the background queue process is forked.
pcap_cache_reload() is asynchronous with cups, in that it forks a
separate process to obtain the printer listing. The cache_fd_event
print_cups.c global variable is used to track when a cups printer
listing is in progress.
cache_fd_event is set when the background queue process is forked, due
to smbd's pcap_cache_reload() call immediately prior. As a result, the
background queue process assumes an existing pcap_cache_reload() call is
indefinitely outstanding, causing the printcap cache to remain stale
thereafter.
(cherry picked from commit
d7286bb6520ebe03355e98e3311e1d79e2746791)
Jeremy Allison [Thu, 28 Mar 2013 16:36:41 +0000 (09:36 -0700)]
Make sure that we only propogate the INHERITED flag when we are allowed to.
Signed-off-by: Jeremy Allison <jra@samba.org>
Fix bug #9747 - When creating a directory Samba allows inherited bit to slip
through.
(cherry picked from commit
93bca1881e3a8993c76fec408d7c0c369556683d)
Andreas Schneider [Thu, 14 Mar 2013 06:29:20 +0000 (07:29 +0100)]
torture: Add ntprinting latin1 test.
Reviewed-by: Günther Deschner <gd@samba.org>
The last 7 patches address bug #9723 - Add a tool to migrate latin1 printing
tdb's to registry.
(cherry picked from commit
97bb3cc15bfa6572486e176aed9040ee3e7df714)
Andreas Schneider [Tue, 12 Mar 2013 17:42:02 +0000 (18:42 +0100)]
s3-net: Add encoding=<CP> to 'net printing dump'.
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
c28da2d725e70a5494bebee3b4bb35a85ea7cf3b)
Andreas Schneider [Tue, 12 Mar 2013 10:39:08 +0000 (11:39 +0100)]
s3-net: Add encoding=<CP> to 'net printing migrate'.
This allows you to convert printing tdb's which are in e.g. in latin1 to
convert to UTF-8 and import them into the registry.
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
3877c1865550446ed25ac06a809518135d62e4f8)
Andreas Schneider [Tue, 12 Mar 2013 14:17:54 +0000 (15:17 +0100)]
ndr: Pass down string_flags in ndr_pull_ntprinting_printer().
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
fa6a654790e2d61a3d69cdfed8ecba74450a870f)
Andreas Schneider [Mon, 11 Mar 2013 14:47:00 +0000 (15:47 +0100)]
idl: Add flags for strings in ntprinting idl.
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
171251595f18f5518f15d7b8c05aea68df0b024f)
Andreas Schneider [Mon, 11 Mar 2013 14:45:15 +0000 (15:45 +0100)]
ndr: Add ndr_ntprinting_string_flags() function.
It defaults to utf8string.
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
6abfeb7d806e40c932f09f0323f20535b54a5613)
Andreas Schneider [Tue, 12 Mar 2013 10:36:38 +0000 (11:36 +0100)]
pidl: Add skip option to elements.
This option allows to skip struct elements in pull and push function.
This can be used to pass flags to the structure e.g. for string values.
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
7f13e139825a4363d8d304c5b86c805bb2a1b0db)
Jeremy Allison [Fri, 15 Mar 2013 22:13:24 +0000 (15:13 -0700)]
Fix bug #9724 - is_encrypted_packet() function incorrectly used inside server.
The is_encrypted_packet() function should only be used on the raw received data
to determine if a packet came in encrypted. Once we're inside the SMB1
processing code in smbd/reply.c we should be looking at the
smb1request->encrypted field to determine if a packet was really encrypted or
not.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
3bc39aa493aa8d2db9ac423d82bed08bda10e754)
Karolin Seeger [Wed, 20 Mar 2013 08:55:41 +0000 (09:55 +0100)]
WHATSNEW: Start release notes for Samba 3.6.14.
Karolin
(cherry picked from commit
fb7971cf9305f4a596636c73c17a3c73bfcbdb02)
Karolin Seeger [Wed, 20 Mar 2013 08:52:47 +0000 (09:52 +0100)]
VERSION: Bump version number up to 3.6.14.
Karolin
(cherry picked from commit
5e70508c735dee1daab09bbf394b65080e21c551)
Karolin Seeger [Mon, 18 Mar 2013 08:58:45 +0000 (09:58 +0100)]
WHATSNEW: Prepare release notes for Samba 3.6.13.
Karolin
(cherry picked from commit
f70d3d214c7d3f45cac98678a37762b9a67d56f1)
Guenter Kukkukk [Sat, 9 Mar 2013 03:45:15 +0000 (04:45 +0100)]
vfs_catia: new version of the manual page for samba-3.6.x
well, i was not aware of the change
./docs-xml/manpages-3/
./docs-xml/manpages/
in samba-4.0.x
Signed-off-by: Guenter Kukkukk <kukks@samba.org>
The last 4 patches address bug #9701 - vfs_catia is not working anymore (due to
a former regression).
(cherry picked from commit
17113c33a77a257560f33dbb35286ae20250a8f5)
Guenter Kukkukk [Thu, 28 Feb 2013 23:58:05 +0000 (00:58 +0100)]
vfs_catia: add my copyright
Signed-off-by: Guenter Kukkukk <kukks@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
ddb98cae501020e2fc02523b4083d16dc44d8908)
Guenter Kukkukk [Wed, 27 Feb 2013 04:50:52 +0000 (05:50 +0100)]
vfs_catia: fix the translation to "vfs_translate_to_windows"
THANKS to an IRC user (Raimund ?) who asked for a char mapping possibility.
I suggested vfs_catia - but it did not work!
Hopefully now it will. :-)
Signed-off-by: Guenter Kukkukk <kukks@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
ad8fe6215f68d2aaf143b44888b75498cfd03e6d)
Guenter Kukkukk [Wed, 27 Feb 2013 04:34:05 +0000 (05:34 +0100)]
vfs_catia: add debug class for that module
Signed-off-by: Guenter Kukkukk <kukks@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
58ac0d30aba4a0c0aab2a358b42e17d8c0e896ca)
Karolin Seeger [Wed, 6 Mar 2013 11:11:53 +0000 (12:11 +0100)]
selftest: Skip tests failing on ext4 fs.
Signed-off-by: Karolin Seeger <kseeger@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit
797c7ff362fad007b0bb1d24f5b10a77c77af5fb)
Jeremy Allison [Wed, 6 Mar 2013 00:23:06 +0000 (16:23 -0800)]
Fix bug #9637 - Renaming directories as guest user in security share mode doesn't work.
Ensure guest is treated consistently when creating a auth_serversupplied_info struct.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
9d4d9b99740f3500e682a4067a1b5e566845ea27)
Andreas Schneider [Wed, 20 Feb 2013 08:51:43 +0000 (09:51 +0100)]
winbind: Don't leak centry memory. Reviewed-by: Alexander Bokovoy <ab@samba.org>
The last two patches address bug #9684 - Fix two resource leaks in winbindd.
(cherry picked from commit
eb657c324f83e94d46f80b9c1b97fa0228c3a47a)
Andreas Schneider [Wed, 20 Feb 2013 08:41:55 +0000 (09:41 +0100)]
winbind: Don't leak memory on return. Reviewed-by: Alexander Bokovoy <ab@samba.org>
(cherry picked from commit
30d7a3ad920456fee2a589b501ba835d13de6c29)
Daniel Kobras [Sat, 23 Feb 2013 00:24:26 +0000 (16:24 -0800)]
Fix bug #9039 'map untrusted to domain' treats WORKSTATION as bogus domain.
s3: never try to map global SAM name
Do not treat the global SAM name as a BOGUS domain, and exempt
local users from mapping, instead. This change reinstates the
exact mapping behaviour of Samba 3.2 if parameter 'map untrusted
to domain' is set.
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
(cherry picked from commit
180ef28a4874026740e3b5381fe4d25fb70167bf)
Andreas Schneider [Tue, 19 Feb 2013 08:23:53 +0000 (09:23 +0100)]
pdb: Fix array overrun by one. Reviewed-by: Alexander Bokovoy <ab@samba.org>
Signed-off-by: Andreas Schneider <asn@samba.org>
Fix bug #9686 - Fix a possible buffer overrun in pdb_smbpasswd.
(cherry picked from commit
b174e1b496659c9e7a0fc70ad49ed0fc5906d252)
Björn Jacke [Wed, 20 Feb 2013 16:06:49 +0000 (17:06 +0100)]
build/autoconf: put ld check variable in quotes
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit
ac9620b942d6d51a1c35c4177c3f241351fc1ebd)
The last 2 patches address bug #7825 (need to fix GNU ld version detection with
old gcc releases).
(cherry picked from commit
b76501dbf14bcba0eba7b5420b191caf237f0b35)
Björn Jacke [Tue, 19 Feb 2013 14:30:34 +0000 (15:30 +0100)]
build/autoconf: fix check for GNU ld version
we need to look for the version once in the stdout and once in the stderr
output. Some version of ld output to stdout, some output to stderr. redirecting
stderr to stdout messes the output up in our case, that's why we have to do two
runs. See also bug #7825.
Signed-off-by: Bjoern Jacke <bj@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Björn Jacke <bj@sernet.de>
Autobuild-Date(master): Tue Feb 19 20:56:12 CET 2013 on sn-devel-104
(cherry picked from commit
ff8ba0628f6f13a5be1df94e5ac2e83008b7c69c)
(cherry picked from commit
1f1feddc6f414a91859b0dae77b34953b479d47e)
David Disseldorp [Tue, 12 Feb 2013 10:58:06 +0000 (11:58 +0100)]
smbd: fix initial large PAC sess setup response
An oversize Kerberos security token may be split across multiple Session
Setup AndX requests when authenticating as a user who is a member of
many (~2000) groups.
In such a case the NativeOS, NativeLanMan & PrimaryDomain fields must be
sent with the NT_STATUS_MORE_PROCESSING_REQUIRED response. Otherwise
Windows clients may resend the same security token data in subsequent
session setup andX requests, as observed with Windows 7 and Server 2012.
This change fixes the SMB1 server only.
Fix bug #9658 - Session Setup AndX exchange fails with an oversize security
token.
(cherry picked from commit
e28ec902a207655acab665c4cfabb1f2031fb24f)
Jeremy Allison [Tue, 12 Feb 2013 18:48:09 +0000 (10:48 -0800)]
Fix bug 9519 - Samba returns unexpected error on SMB posix open.
Explicitly ignore bare O_EXCL flags instead of returning INVALID_PARAMETER.
That's what the Linux kernel does.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
d21280f983249038bf7efda4edc1b1eadaff546a)
Ira Cooper [Fri, 8 Feb 2013 22:47:57 +0000 (14:47 -0800)]
s3: Make SMB2_GETINFO multi-volume aware.
Not all shares are a single volume. Some actually
expose multiple volumes under a single share. In these
cases showing the amount of space free as the space free
at the base of the directory heirarchy is wrong.
Reviewed-by: Jeremy Allison <jra@samba.org>
Fix bug #9646 - dir and similar commands are returning the wrong amount of free
space.
(cherry picked from commit
872a7d61ca769c47890244a1005c1bd445a3bab6)
David Disseldorp [Mon, 4 Feb 2013 18:04:39 +0000 (19:04 +0100)]
Fix bug 9633: recursive mget should continue on EPERM
Regression introduced by
14ff2e8de9bd8d0064762234555260f5eea643fe.
When downloading files recursively, smbclient halts if it encounters
a folder to which it does not have permission to traverse.
(cherry picked from commit
e5b4ac7978213acf7517b6852f7750e41cad787a)
Stefan Metzmacher [Thu, 31 Jan 2013 12:39:42 +0000 (13:39 +0100)]
s3:auth: wbcAuthenticateEx gives unix times (bug #9625)
We also need to convert last_logon, last_logoff and acct_expiry
from unix time to nt time.
Otherwise a windows member server will reject clients
using CAP_DYNAMIC_REAUTH or smb2) with STATUS_NETWORK_SESSION_EXPIRED,
if the logoff and kickoff time is expired.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
(cherry picked from commit
292504a759caf811fb6201e273ffeab20522a991)
Jeremy Allison [Tue, 29 Jan 2013 00:01:27 +0000 (16:01 -0800)]
Fix bug #9585 - Samba 3.6.x not correctly signing any but the last response in a compound request/response
Add in the missing code we already have in master
and 4.0.x.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
022e1d889cbb752fc4f339dd537486bf3a52e34e)
Jeremy Allison [Wed, 23 Jan 2013 22:39:09 +0000 (14:39 -0800)]
Fix bug #9586 - smbd[29175]: disk_free: sys_popen() failed" message logged in /var/log/message many times.
Ensure when reading lines from an interruptible
pipe source we ignore EINTR.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Thu Jan 24 10:45:48 CET 2013 on sn-devel-104
(cherry picked from commit
497febfe36354c4aff3696cd32c6c7e8fee55af8)
(cherry picked from commit
035be05db96b0544434febc33349adb910dba78e)
Pavel Shilovsky [Wed, 16 Jan 2013 11:02:26 +0000 (15:02 +0400)]
Fix bug #9571 - Unlink after open causes smbd to panic.
s3:smbd: fix wrong lock order in posix unlink
Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
fb0868e290cdc23671a84b7600af689a8b8b806f)
Jeremy Allison [Fri, 25 Jan 2013 18:21:48 +0000 (10:21 -0800)]
Fix bug #9588 - ACLs are not inherited to directories for DFS shares.
We can return with NT_STATUS_OK in an error code path. This
has a really strange effect in that it prevents the ACL editor
in Windows XP from recursively changing ACE entries on sub-directories
after a change in a DFS-root share (we end up returning a path
that looks like: \\IPV4\share1\xptest/testdir with a mixture
of Windows and POSIX pathname separators).
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
99d2cb211f04e907bf2ed19656843026207ae0e3)
Jeremy Allison [Thu, 24 Jan 2013 19:02:30 +0000 (11:02 -0800)]
Fix bug #9587 - archive flag is always set on directories.
Creating a directory to a Samba share sets the attributes to 'D' only
(correct) - only when creating a new file should the 'A' attribute
be set.
However, doing a rename of that directory sets the 'A' attribute in error.
This should only be done on a file rename. smbclient regression test to follow.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
6603013f8f03773d141c33fd1c4923197a5350c8)
Günther Deschner [Thu, 17 Jan 2013 23:22:31 +0000 (00:22 +0100)]
BUG 9474: Downgrade v4 printer driver requests to v3.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Jan 21 16:11:02 CET 2013 on sn-devel-104
(cherry picked from commit
58fadf2f48a2a409b4ee98fdc0166c7f801a7629)
(cherry picked from commit
ae0cf58a75874541c4c9b8b29a2b1fc45928be69)
Günther Deschner [Mon, 7 Jan 2013 14:14:30 +0000 (15:14 +0100)]
spoolss: add SPOOLSS_DRIVER_VERSION_2012 (4) define to IDL.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
(cherry picked from commit
638ed90620e3c6a35ef56a11c612c13d6b7d6ff5)
(cherry picked from commit
93a1d4ee4685305e0060e9d5c8028c96ff83257d)
David Disseldorp [Thu, 17 Jan 2013 12:21:25 +0000 (13:21 +0100)]
BUG 9378: Add extra attributes for AD printer publishing.
Currently attempting to publish a printer in AD fails with "Object class
violation", due to a number of missing attributes in the LDAP request.
Reviewed-by: Andreas Schneider <asn@samba.org>
(cherry picked from commit
069f1029a76c9b9c0a48ac7cb3d2c5f45c3a231c)
David Disseldorp [Fri, 18 Jan 2013 10:48:20 +0000 (11:48 +0100)]
printing: Remove invalid free from error path.
Reviewed-by: Andreas Schneider <asn@samba.org>
(cherry picked from commit
31d61ad8f9c850c302c83a65af8474545723ea1c)
Andreas Schneider [Fri, 18 Jan 2013 17:04:17 +0000 (18:04 +0100)]
BUG 9574: Fix a possible null pointer dereference in spoolss.
If the the client enumerates the printers and didn't specify a
servername we have a null pointer dereference, so the process serving
the connection crashes.
Reviewed-by: David Disseldorp <ddiss@samba.org>
Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Mon Jan 21 13:30:11 CET 2013 on sn-devel-104
(cherry picked from commit
c38fb0b106b62e42a5b75b1c78386bb8912c7d7e)
(cherry picked from commit
a2d68842ea33733fa7900831ed10e73f820afcf7)
Andreas Schneider [Mon, 17 Dec 2012 14:31:21 +0000 (15:31 +0100)]
s3-rpc_server: Fix a possible null pointer dereference.
This variable can be set to NULL in an earlier function call.
Found by Coverity.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
72e02c73b64f1ff56b2d53ec63d68486a4f1ff90)
(cherry picked from commit
43810c80936c8f509cc2adba6193dd4c55325875)
Volker Lendecke [Fri, 11 Jan 2013 09:36:04 +0000 (10:36 +0100)]
samr: Make use of posix_openpt
The last 2 patches address bug #9541 - Add support for posix_openpt.
(cherry picked from commit
cd9c1a0a3abf0b44afd1054cca9c1da1cace1e52)
Volker Lendecke [Fri, 11 Jan 2013 09:31:42 +0000 (10:31 +0100)]
samr: Split up an assignment from an if condition
(cherry picked from commit
00184412950adde1a3db0a16822d771d0868dfc3)
Björn Baumbach [Mon, 15 Oct 2012 15:17:29 +0000 (17:17 +0200)]
docs-xml: add dbwrap_tool.1 manual page (fix bug #9568)
Based on commit
8d6104f02d9ab879efe7867fec53cbe5cc408ded.
Signed-off-by: Björn Baumbach <bb@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
(cherry picked from commit
329ba78272a03e2011743f4fd47b6094b271d573)
Karolin Seeger [Wed, 30 Jan 2013 10:42:53 +0000 (11:42 +0100)]
WHATSNEW: Start release notes for Samba 3.6.13.
Karolin
(cherry picked from commit
2d8c6de869b88d3c8c9313290ee285c419fec58a)
Karolin Seeger [Wed, 30 Jan 2013 10:42:18 +0000 (11:42 +0100)]
VERSION: Bump version number up to 3.6.13.
Karolin
(cherry picked from commit
a9f770e65876fbcfd3967a893dbd1f0770d2789a)
Kai Blin [Mon, 28 Jan 2013 20:41:07 +0000 (21:41 +0100)]
swat: Use additional nonce on XSRF protection
If the user had a weak password on the root account of a machine running
SWAT, there still was a chance of being targetted by an XSRF on a
malicious web site targetting the SWAT setup.
Use a random nonce stored in secrets.tdb to close this possible attack
window. Thanks to Jann Horn for reporting this issue.
Signed-off-by: Kai Blin <kai@samba.org>
Fix bug #9577: CVE-2013-0214: Potential XSRF in SWAT.
Kai Blin [Fri, 18 Jan 2013 22:11:07 +0000 (23:11 +0100)]
swat: Use X-Frame-Options header to avoid clickjacking
Jann Horn reported a potential clickjacking vulnerability in SWAT where
the SWAT page could be embedded into an attacker's page using a frame or
iframe and then used to trick the user to change Samba settings.
Avoid this by telling the browser to refuse the frame embedding via the
X-Frame-Options: DENY header.
Signed-off-by: Kai Blin <kai@samba.org>
Fix bug #9576 - CVE-2013-0213: Clickjacking issue in SWAT.
Karolin Seeger [Tue, 29 Jan 2013 08:45:06 +0000 (09:45 +0100)]
WHATSNEW: Prepare release notes for Samba 3.6.12.
This is a Security Release in order to address
CVE-2013-0213 (Clickjacking issue in SWAT) and
CVE-2013-0214 (Potential XSRF in SWAT).
Karolin
Karolin Seeger [Mon, 21 Jan 2013 09:09:38 +0000 (10:09 +0100)]
WHATSNEW: Start release notes for Samba 3.6.12.
Karolin
(cherry picked from commit
6a11d2572ebe83a696c6366da7765fb123fa2987)
Karolin Seeger [Mon, 21 Jan 2013 09:06:31 +0000 (10:06 +0100)]
VERSION: Bump version number up to 3.6.12.
Karolin
(cherry picked from commit
29199e6771002e95ac9225be77226dc191c22325)
Karolin Seeger [Fri, 18 Jan 2013 10:23:51 +0000 (11:23 +0100)]
WHATSNEW: Prepare release notes for 3.6.11.
Karolin
(cherry picked from commit
090d346017d5b3afb1baaa26d3c05ecb721fbd24)
Björn Baumbach [Tue, 4 Dec 2012 09:54:05 +0000 (10:54 +0100)]
ntlm_auth(1): fix format and make examples visible (bug #9569)
"<example>" is no child of "<para>". So these examples were not visible.
Using a varlist instead may be not the best way but it does look nice.
Signed-off-by: Björn Baumbach <bb@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
(cherry picked from commit
cabc89a1e72fc95300d4b6f8d480a7d666221b8b)
(cherry picked from commit
2cd0314f1fe47ac30e0df6791ff27850b09e6d83)
Tsukasa Hamano [Thu, 6 Dec 2012 21:01:33 +0000 (13:01 -0800)]
Fix bug #9471 - SEGV when using second vfs module.
Don't use default_classname_table when we obviously shoud be using
classname_table.
Reviewed by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Fri Dec 7 17:51:50 CET 2012 on sn-devel-104
(cherry picked from commit
16d725b4f5ed77db865e2a3c27ae0eb4accca5a8)
(cherry picked from commit
25eb1af07cc09e5e019a0702c60a763cc3266196)
(cherry picked from commit
82db35cdb426355e4b7fd7ecf1ce9d9fca59ecd3)
Jeremy Allison [Fri, 14 Dec 2012 16:56:52 +0000 (08:56 -0800)]
Fix bug #9196 - defer_open is triggered multiple times on the same request.
get_deferred_open_message_state_smb2() is buggy in that it is checking
the wrong things to determine if an open is in the deferred state.
It checks if (smb2req->async == NULL) which is incorrect,
as we're not always async in a deferred open - remove this.
It should check instead state->open_was_deferred as this
is explicity set to 'true' when an open is going deferred,
so add this check.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
a8658bcb67927282288af5a579e3e66d3eaaac7b)
Volker Lendecke [Sat, 12 Jan 2013 15:08:07 +0000 (16:08 +0100)]
Fix bug 9548: Correctly detect O_DIRECT
(cherry picked from commit
c89f3ddd5db2de099e5b871d41553637d35e4097)
Jeremy Allison [Mon, 14 Jan 2013 23:06:12 +0000 (15:06 -0800)]
lib/replace: Add missing check for sys/wait.h
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit
8de4edd42cf16bd761a6acc2c8b5656d088969a7)
Jeremy Allison [Tue, 15 Jan 2013 18:16:27 +0000 (10:16 -0800)]
lib/replace: Add ucontext configure autoconf checks.
Signed-off-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit
d78f760280473c35b33d4f17d31528dd6269405a)
Jeremy Allison [Mon, 14 Jan 2013 23:21:52 +0000 (15:21 -0800)]
lib/replace: Include sys/ucontext.h if available.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
(cherry picked from commit
9a21bc35c565210767e71f4bc03a558fe61bdbc8)
Jeremy Allison [Mon, 14 Jan 2013 23:22:11 +0000 (15:22 -0800)]
tevent: Fix bug 9550 - sigprocmask does not work on FreeBSD to stop further signals in a signal handler
Mask off signals the correct way from the signal handler.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Jan 15 12:13:43 CET 2013 on sn-devel-104
(cherry picked from commit
64a29fdf0e3ec9138e946bab03ad28a965f3ebd0)
Volker Lendecke [Mon, 7 Jan 2013 10:06:15 +0000 (11:06 +0100)]
configure: Fix bug 9546, aio_suspend detection on FreeBSD
NULL is not defined without some includes
(cherry picked from commit
653ebe132287ba66ef54675a3b58988994f0a486)
Karolin Seeger [Mon, 10 Dec 2012 08:47:43 +0000 (09:47 +0100)]
WHATSNEW: Start release notes for Samba 3.6.11.
Karolin
(cherry picked from commit
7807141241f64253f0bc3f170b5beb0712d5bd27)
Karolin Seeger [Mon, 10 Dec 2012 08:45:54 +0000 (09:45 +0100)]
VERSION: Bump version up to 3.6.11.
Karolin
(cherry picked from commit
03e841a814d8114e4b5c4d489302e29bd82cfbe5)
Karolin Seeger [Thu, 6 Dec 2012 09:26:19 +0000 (10:26 +0100)]
WHATSNEW: Prepare release notes for Samba 3.6.10.
Karolin
(cherry picked from commit
29b36a1fb4e494be0851ebbea17a22839a344bf3)
Richard Sharpe [Wed, 5 Dec 2012 01:21:29 +0000 (17:21 -0800)]
Fix bug #9460 - Samba 3.6.x and Master respond incorrectly to FILE_STREAM_INFO requests.
Ensure we check the buffer size correctly.
Reviewed by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Dec 6 01:31:08 CET 2012 on sn-devel-104
(cherry picked from commit
943797c232f96a5dd411a803ad90b6980b2785b0)
(cherry picked from commit
0eba72e42174b01792a5434f4b163d6241a64b35)
Günther Deschner [Mon, 1 Oct 2012 14:19:28 +0000 (16:19 +0200)]
s3-net: Fix DEBUG() location.
Guenther
Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Tue Oct 2 18:06:17 CEST 2012 on sn-devel-104
Signed-off-by: Günther Deschner <gd@samba.org>
The last 5 patches address bug #9451 - Allow to force DNS updates using net.
(cherry picked from commit
ceb2c81481ea8a37bb281a4d4df604573b371a2d)
Günther Deschner [Tue, 25 Sep 2012 09:09:45 +0000 (11:09 +0200)]
s3-net: give more control how to update/register DNS entries.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
ac0f0e7bc9126ee897d6eaac753c66853514326a)
Günther Deschner [Tue, 25 Sep 2012 09:08:48 +0000 (11:08 +0200)]
s3-net: pass down a flags field to DoDNSUpdate().
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
0d41b631faf95714eafec4836f7424edb4dda4af)
Günther Deschner [Wed, 19 Sep 2012 13:35:15 +0000 (15:35 +0200)]
s3-net: move out some prototypes to net_dns.h.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
a294a6d2fdbbd9fe54882a365cb54c1f49b900bc)
Günther Deschner [Wed, 19 Sep 2012 13:31:57 +0000 (15:31 +0200)]
s3-net: pass down struct net_context to the dns update calls.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
(cherry picked from commit
2443f18b0c90956ae7840ac13487b9595b4cff4b)
Jeremy Allison [Tue, 13 Nov 2012 00:30:32 +0000 (16:30 -0800)]
Final part of #9374 - Allow smb2.acls torture test to pass against smbd with a POSIX ACLs backend.
We need to do the same check for overriding ACCESS_DENIED on DELETE_ACCESS
as we do in smbd/open.c, as the ACL check is duplicated here. This has
been fixed in 4.0.0 and later code.
(cherry picked from commit
005d7c28e35f58d5f8b114fb6234e663a6c30824)
Jeremy Allison [Tue, 13 Nov 2012 00:26:25 +0000 (16:26 -0800)]
More for #9374 - Allow smb2.acls torture test to pass against smbd with a POSIX ACLs backend.
Change can_delete_directory() to can_delete_directory_fsp(), as
we only ever call this from an open directory file handle.
This allows us to use OpenDir_fsp() instead of OpenDir().
OpenDir() re-checks the ACL on the directory, which may
refuse DIR_LIST permissions. OpenDir_fsp() does not. As
this is a file-server internal check to see if the directory
actually contains any files before setting delete on close,
we can ignore the ACL here (Windows does).
(cherry picked from commit
cc17ce366a459bf1cb2207a45e5528ea0167b323)
Jeremy Allison [Tue, 13 Nov 2012 00:22:52 +0000 (16:22 -0800)]
Ensure when calculating the access mask for MAXIMUM_ALLOWED_ACCESS that we add in FILE_READ_ATTRIBUTES, even if this doesn't come from the file/directory ACL.
If we can access the path to this file, by
default we have FILE_READ_ATTRIBUTES from the
containing directory. See the section.
"Algorithm to Check Access to an Existing File"
in MS-FSA.pdf.
(cherry picked from commit
32892d6357469287bf9594b269bde5b9ffabd54e)
Jeremy Allison [Tue, 13 Nov 2012 00:21:15 +0000 (16:21 -0800)]
Add comment explaining exactly *why* we don't check FILE_READ_ATTRIBUTES when evaluating file/directory ACE's.
If we can access the path to this file, by
default we have FILE_READ_ATTRIBUTES from the
containing directory. See the section.
"Algorithm to Check Access to an Existing File"
in MS-FSA.pdf.
(cherry picked from commit
a115a4e9799e8e5497232a149d4d927308c81a5b)
Jeremy Allison [Tue, 13 Nov 2012 00:17:19 +0000 (16:17 -0800)]
First part of #9374 - Allow smb2.acls torture test to pass against smbd with a POSIX ACLs backend.
Use the requested access mask before making the fd_open request in
open_directory() rather than faking up an access mask of
FILE_READ_DATA | FILE_READ_ATTRIBUTES.
The underlying ACL may not permit FILE_READ_DATA.
(cherry picked from commit
1c7d00e8ef48c2cd57d79a00cb26bc56a2979241)
Sumit Bose [Mon, 29 Oct 2012 11:09:22 +0000 (12:09 +0100)]
Use work around for 'winbind use default domain' only if it is set
Currently in smb_getpwnam() the NetBIOS domain name and the winbind separator
character is always added to the user name returned by Get_Pwnam_alloc() if it
does not contain the winbind separator character. As comments in the code
indicates this is done as a work around if 'winbind use default domain' is set
to yes in the samba configuration.
This make sense if the option is set because otherwise the domain information is
lost from the user name. But it causes errors if other services than winbind are
used for user lookup, e.g. sssd. sssd can handle different kind of fully
qualified user names as input, e.g. user@domain.name or DOM\user, but returns a
canonical name, by default user@domain.name.
While it would be possible to get around this issue with a special configuration
either on the sssd or samba side I think the cleaner solution is to use the work
around only if 'winbind use default domain' is set to yes which is what this
patch does.
Fix bug #9367 - Use work around for 'winbind use default domain' only if it is
set.
(cherry picked from commit
6c0b864654001046b8bbb585112e60a7e146cb2a)
(cherry picked from commit
de2c0f0d3d1217814fce840a5050741de3938e0f)
Günther Deschner [Thu, 29 Nov 2012 13:31:19 +0000 (14:31 +0100)]
s3-winbind: use new reconnect logic in rpc_lookup_sids() also.
Volker, please check.
Guenther
Signed-off-by: Günther Deschner <gd@samba.org>
The last 10 patches address bug #9439 - ncacn_ip_tcp reconnection code for lsa
lookups still broken.
(cherry picked from commit
4ab547a8ddcb45e479079361a601e08476954110)