summaryrefslogtreecommitdiff
path: root/source3/smbd
AgeCommit message (Collapse)AuthorFilesLines
2008-04-08Fix the build of reply_setattrE().Günther Deschner1-2/+2
How ever could this compile ? Guenther (This used to be commit 02f5f35e5ed3b061cfd020d0b13014c72fced5f4)
2008-04-08Destroy DMAPI session when main smbd daemon exits.Alexander Bokovoy2-0/+33
DMAPI session is precious resource maintained at kernel level. We open one of them and use across multiple smbd daemons but once last of them exits, DMAPI session needs to be destroyed. There are some HSM implementations which fail to shutdown when opened DMAPI sessions left. Ensure we shutdown our session when it is really not needed anymore. This is what recommended by DMAPI specification anyway. (This used to be commit a0cefd44009d414fa00ec6e08c70d21b74acdbcb)
2008-04-07Rewrite the wrap checks to deal with gcc 4.x optimisations.Jeremy Allison3-101/+142
Karolin, please pull once Volker has reviewed. Thanks. Jeremy. (This used to be commit 09852899cadc48abe2f2651ecbceaf881198e648)
2008-04-07Remove unused variable.James Peach1-1/+0
(This used to be commit 3ed2c65bde0c2e5ad10cf777dae8a2d3e626a42c)
2008-04-07Fix Kerberos interop with Mac OS X 10.5 clients.Bill Ricker2-23/+33
Ignore optional req_flags. Use the Kerberos mechanism OID negotiated with the client rather than hardcoding OID_KERBEROS5_OLD. (This used to be commit 59a2bcf30fef14ecc826271862b645dd3a61cb48)
2008-04-07smbd: make it possible to change the write time delay for testingStefan Metzmacher1-1/+7
metze (This used to be commit df8c100c2b53575a0d425a2daf52e2d59904746a)
2008-04-07smbd: make it possible to disable get_file_infos() on searchesStefan Metzmacher3-14/+36
metze (This used to be commit 404a865a34c3a7c67131b3f99e92c11b2abe3e39)
2008-04-07locking: combine get_delete_on_close_flag() and get_write_time() into ↵Stefan Metzmacher3-14/+19
get_file_infos() This means we need to fetch the record only once. metze (This used to be commit 4130b873291d39e363184fe4e38dc1f24ebe5056)
2008-04-07smbd: implement the strange write time update logicStefan Metzmacher8-130/+235
We now never call file_ntimes() directly, every update is done via smb_set_file_time(). This let samba3 pass the BASE-DELAYWRITE test. The write time is only updated 2 seconds after the first write() on any open handle to the current time (not the time of the first write). Each handle which had write requests updates the write time to the current time on close(). If the write time is set explicit via setfileinfo or setpathinfo the write time is visible directly and a following close on the same handle doesn't update the write time. metze (This used to be commit 2eab212ea2e1bfd8fa716c2c89b2c042f7ba12ea)
2008-04-07locking: store the write time in the locking.tdbStefan Metzmacher5-12/+24
This is needed to implement the strange write time update logic later. We need to store 2 time timestamps to distinguish between the time the file system had before the first client opened the file and a forced timestamp update. metze (This used to be commit 6aaa2ce0eeb46f6735ec984a2e7aadde7a7f456d)
2008-04-02Fix MSDFS bug noticed by Ofir Azoulay <Ofir.Azoulay@expand.com>.Jeremy Allison1-30/+0
There is no reason to ensure the target host is ourselves, and this breaks MS clients in some cases. Jeremy. (This used to be commit c19fdf43d16ce9fba3e8e12e6192bac31837715e)
2008-04-01smbd: always close the base_fsp even if the real close returned an errorStefan Metzmacher1-4/+0
Otherwise we may end up with share mode entry without an open file. Volker, Jeremy: please check... metze (This used to be commit 547eacf6058d2bc5b41b266b70f8f4747aca4eae)
2008-04-01smbd: ignore nttrans renames as w2k3 doesStefan Metzmacher1-24/+3
This lets us pass the RAW-RENAME test. metze Signed-off-by: Michael Adam <obnox@samba.org> (This used to be commit 2d50a1fef022023588e9963131951f8f3e4c7c23)
2008-03-31Ok, final move of this code :-). I think I've found the correctJeremy Allison1-9/+9
place for it now where it will cause minimal disruption (only call the extra message_dispatch just before reading the next smb off the wire). Jeremy. (This used to be commit da2c19c481d0041872b4ce2f5105052077f3d3b8)
2008-03-31Move the message_dispatch() call after the check for errno onJeremy Allison1-11/+11
the select return. We don't want the call to message_dispatch to mess up the errno value. Jeremy. (This used to be commit 26a74d01bb2b53ffa5d296ff1c7d8b2b0d17831a)
2008-03-31Reduce the race condition in Samba4 in RAW-RENAME test. We rename a fileJeremy Allison1-0/+9
using trans2 setfileinfo on one connection, and then check the file name has changed on the other. In Samba we achieve this by sending a local message to the other process. This change causes us to re-scan for incoming messages after we've woken up from the select (which is cheap if there are no pending messages). This reduces the race significantly. Volker please review. Jeremy. (This used to be commit a7499e994aef743ea9c443f9a1618b262f6eda93)
2008-03-28Fix missing '&&'.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 251df53811e4272b629575a4b50c29a99715ccf9)
2008-03-28Only allow sendfile on non-stream fsp's. Should fix make test for streamsJeremy Allison1-2/+2
as sendfile isn't implemented in the streams vfs modules yet. Jeremy. (This used to be commit eef53e9603d4f3d892ffe00b061def5d717ca481)
2008-03-28Add a talloc context parameter to current_timestring() to fix memleaks.Michael Adam1-1/+1
current_timestring used to return a string talloced to talloc_tos(). When called by DEBUG from a TALLOC_FREE, this produced messages "no talloc stackframe around, leaking memory". For example when used from net conf. This also adds a temporary talloc context to alloc_sub_basic(). For this purpose, the exit strategy is slightly altered: a common exit point is used for success and failure. Michael (This used to be commit 16b5800d4e3a8b88bac67b2550d14e0aaaa302a9)
2008-03-28printclose has only 1 vwvVolker Lendecke1-1/+1
(This used to be commit 99d980125054cbfef8ec85a31e83aa18a6e0bce3)
2008-03-27Fix up the comments on security=share to explain we'reJeremy Allison1-1/+5
ignoring passwords. Jeremy. (This used to be commit e7b6ea46532a26611dfd9d9e2727d52ba6a9cf50)
2008-03-27posix_acls: clarify loop condition code, removing unneeded counter variable.Michael Adam1-7/+2
Coverity ID 545 falsely classified this as a NULL dereferencing bug. By putting the loop of walking the list of aces more naturely not using additional counters, it becomes much more obvious that it is not entered when dir_ace == NULL. The same modifications are done for the file_ace loop. Michael (This used to be commit 6dab6cf0647d7db01e5e472f8b5cf21395b7dbf0)
2008-03-24Missing HAVE_UPDWTMPX check before using updwtmpx().Eric Cronin1-0/+4
In 10.5 Mac OS X added enough utmpx support to make it past the first two preprocessor checks around line 390 of src/smbd/utmp.c and on to the utmpx block which uses updwtmpx(). Unfortunately, as ./configure correctly surmised, 10.5 doesn't have that. https://bugzilla.samba.org/show_bug.cgi?id=5184 (This used to be commit f19d1e3d93d0d9dfe80372c6c5635f1047f9aa88)
2008-03-20smbd: fix session setup with security = share.Michael Adam1-1/+1
Broken by pstring removal in 9ed12bfc48fe7f9b1863a9dd88e881974083053c. Jeremy, please check. Thanks to Yannick Bergeron <yaberger@ca.ibm.com> for noting this. Michael (This used to be commit 008c4bdbe5de064b4469fc1f7c7173290f35b3ef)
2008-03-20Port 3c1f1f0797e from 3-0-ctdbroot1-3/+57
We need to inform ctdb about the client's TCP connection so that after a fail over ctdbd can trigger the client to reconnect very quickly (This used to be commit ddc989886deff173b8a2a2a753a896770efe7545)
2008-03-18[samba-3-0-ctdb.tridge @ tridge@samba.org-20070602053809-kpw5kjkcyjs8yjbl]Andrew Tridgell1-1/+1
suppress that darn message (cherry picked from commit 542e46a21898f6fcc8a0aeb63925607a60e0b99f) (This used to be commit 5e8c624c9c9775f255632717e6898d5f190ba51b)
2008-03-17Some simplificationsVolker Lendecke1-2/+3
(This used to be commit b59b436997fba47afd02ffb6f1194dfaef229d44)
2008-03-17Coverity fixesMarc VanHeyningen2-2/+7
(This used to be commit 3fc85d22590550f0539215d020e4411bf5b14363)
2008-03-12Add a debug message.Michael Adam1-0/+1
Michael (This used to be commit a39807044879ad9df7614e010db6ea16b51000a0)
2008-03-11Using Metze's S4 nttrans rename test, the nttrans renameJeremy Allison1-1/+1
behaves the same as the trans2 one. Jeremy. (This used to be commit c4fa4917dad97c5047f7336c6675739b44da256b)
2008-03-11Metze pointed out this we don't need FILE_ATTRIBUTE_READ here.Jeremy Allison1-1/+1
Jeremy. (This used to be commit 923aa9f330cb370221af6b66cf0f237a9bd06f8e)
2008-03-11Allow us to pass RAW-RENAME by testing that the connection structJeremy Allison1-1/+1
connection paths are equal, not just the conn structs themselves. Jeremy. (This used to be commit 632f3fe66fbcbe3cc25d070c3885177264f5ad65)
2008-03-11Try and fix bug #5315, as well as S4 torture tests RAW-OPLOCK BATCH19,Jeremy Allison3-10/+13
BATCH20 and RAW-RENAME. Jeremy. (This used to be commit 9065792d4bc42522f12f9732de3c0ad82c72a2d3)
2008-03-11Fix S3 to pass the test_raw_oplock_exclusive3 test.Jeremy Allison2-3/+4
Jeremy. (This used to be commit 028302fac53083d66c969b876db1d831e53b8e35)
2008-03-11registry shares: prevent creating regular share called "global".Michael Adam1-0/+4
This is a first quick fix. Registry shares should be rewritten to use libnet_conf. Michael (This used to be commit 71bd0bd0ea018e8c5033bbf904333c596330855a)
2008-03-10Convert secrets_lock_trust_account_password to tallocVolker Lendecke1-4/+7
This is preparing the conversion of secrets.c to ctdb (This used to be commit 1307f0130c47b8d740d2b7afe7a5d8d1a655e2a2)
2008-03-08Fix some typosVolker Lendecke1-1/+1
(This used to be commit cfa1b838144800c0758969921b8904fd62e46c07)
2008-03-06Be more verbose why create local token has failed duringGünther Deschner1-0/+2
NTLMSSP and Kerberos session setup Guenther (This used to be commit 18b8c2c19e50aee8fc900c7507244cb95014a4fa)
2008-02-25Fix inotify detectionVolker Lendecke1-1/+7
Bug 5271 -- thanks to Tiziano Müller (This used to be commit 4a1a138b0fe0f2200e5a37a0609481e4340a896c)
2008-02-24Allow "max mux" async i/o requestsVolker Lendecke1-5/+9
In the negprot reply, we allowed the client to issued "max mux" concurrent requests. The OS might allow less, for example AFAIK AIX has a configurable limit of concurrent AIO requests. We will fall back to sync operation for the requests that are too many when aio_read/aio_write return an error. Jeremy, please check! (This used to be commit 8f86f7f25c4eb71bbdfcc6bf2d12eaaae9a8d9ec)
2008-02-24Export aio_request_done()Volker Lendecke1-3/+9
This is for external modules implementing the Posix AIO API that not necessarily depend on the signal mechanism to indicate completion. (This used to be commit 9a069d306bb6f8a2cd51b8ba87b433884942d13f)
2008-02-24AIO on streams does not work (yet...)Volker Lendecke1-0/+12
(This used to be commit 1ba223f202a070a695581e0d7161473a3ebf4332)
2008-02-22Fix debug messages.Jeremy Allison1-4/+5
Jeremy. (This used to be commit d265cedb55b07c6b8a13b9632fbdf8a05fbba886)
2008-02-22Don't use fname after create_file has been calledVolker Lendecke3-18/+18
create_file calls unix_convert internally, so modifies fname. So we can't use "fname" after create_file has returned. Use fsp->fsp_name instead. Found during a lengthy debugging session with Karolin testing the xattr_tdb module... (This used to be commit 183fe570469963923864b732817a87f8660341ed)
2008-02-19Update position information also for AIOVolker Lendecke1-0/+5
Necessary to survive RAW-SEEK with AIO enabled. Jeremy, please check! (This used to be commit e2ca12c2345c0e3916dd09d097b2ba1ce2989fa8)
2008-02-19Inform level II oplock holders when we write using AIOVolker Lendecke1-0/+2
Jeremy, please check! (This used to be commit 81d823e026fb332a88b6e1f15030fe49719f2522)
2008-02-18Check return code of secrets_init() function.Tim Potter1-1/+2
(This used to be commit 2b1eead269e95142576d0c8c259874324ba83502)
2008-02-17Use new structs in reply_spnego_kerberos().Günther Deschner1-6/+5
Guenther (This used to be commit c55160f8e866d9b24a4dad234af78ae46c236a37)
2008-02-14Correctly use SPNEGO to negotiate down from krb5 to NTLMSSP.Jeremy Allison1-28/+81
Previously we didn't implement the 'NEGO' part of SPNEGO :-). Jeremy. (This used to be commit 8767a0dab95c544878b4187157e494e740974bb8)
2008-02-14Currently we don't SPNEGO negotiate back to NTLMSSP. Note this.Jeremy Allison1-4/+16
Jeremy. (This used to be commit 8cd04b948bfba3896d40c9e314a197f60ad76833)