summaryrefslogtreecommitdiff
path: root/source3/smbd
AgeCommit message (Collapse)AuthorFilesLines
1998-08-17moved connection_struct handling code into smbd/conn.c and changed itAndrew Tridgell4-128/+227
to a linked list with bitmap format. (This used to be commit b7aaab1b6b2d2f72b2bb7c11f5c7bf081a6093d9)
1998-08-17much cleaner chain pointer handling for both files and pipes.Andrew Tridgell6-60/+67
the chain pointer is now stored as a static and is set whenever a handle is created or extracted. This also makes the code less error prone. (This used to be commit 068a862982bea726e8d7b1b4065d510b9840a272)
1998-08-17some cleanups from the conversion of Pipes[] to a linked list. I alsoAndrew Tridgell5-134/+114
removed most cases where a pnum is used and substituted a pipes_struct*. in files.c I added a offset of 0x1000 to all file handles on the wire. This makes it much less likely that bad parsing will give us the wrong field. (This used to be commit 8bc2627ff28d340db65bfa017daca2dc291d5ef7)
1998-08-16- some tidying up in files.cAndrew Tridgell3-11/+10
- handle null fsp in DEBUG() at end of reply_ntcreate_and_X(). Jeremy, can you fix this properly? - get snum right in print queue code in ipc.c (it was broken by my connections_struct changes). (This used to be commit b3dd3785751db2d5d0a80ffac9c3df01c9909891)
1998-08-16got rid of the Files[] array completely (previously I'd just made itAndrew Tridgell4-151/+212
private to files.c) It now is a doubly linked list with a bitmap for allocated file numbers. Similarly for the fd_ptr code. I also changed the default maximum number of open files to 4096. The static cost is 1 bit per file. It all seems to work, and it passes the "does Sue scream" test, but if you see weird behaviour then please investigate. With the volume of new code that has gone in there are bound to be one or two bugs lurking. note that you must do a "make clean" before building this as many data structures have changed in size. (This used to be commit 79755ce97004b787d7e83a8d18fc4c7c003b7231)
1998-08-16server.c: fixed a bug in close_file() with the new files.c handling codeAndrew Tridgell1-15/+14
bitmap.c: added bitmap hanlding code in preparation for increasing the default max open files to several thousand (This used to be commit f573a65b67e7a57586fec57845598e49b157ee0a)
1998-08-16changed find_free_file() to file_new().Andrew Tridgell4-11/+11
(This used to be commit 3daee29636dcb2d99a0e7c08179a098befae00dc)
1998-08-15this checkin gets rid of the global Files[] array and makes it localAndrew Tridgell7-806/+820
in files.c it should now be faily easy to expand the default MAX_OPEN_FILES to many thousands. (This used to be commit b088c804f98908eb02f05ab2f2e8a61691a0a582)
1998-08-15configure: Changes for extra headers.Jeremy Allison8-28/+28
configure.in: Source for header changes. client/clitar.c: Fixed isXXX macros & debugs for gcc pedantic compile. include/config.h.in: Added MEMSET, BZERO, MEMORY, RPCSVC_YPCLNT, STRINGS headers. include/includes.h: Headers for the above. include/smb.h: Made SIGNAL_CAST POSIX by default void (*)(int). lib/access.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/charset.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/debug.c: Fixed signal functs. lib/kanji.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/smbrun.c: Fixed isXXX macros & debugs for gcc pedantic compile. lib/util.c: Fixed isXXX macros & debugs for gcc pedantic compile. libsmb/namequery.c: Fixed isXXX macros & debugs for gcc pedantic compile. locking/shmem.c: Fixed isXXX macros & debugs for gcc pedantic compile. locking/shmem_sysv.c: Fixed error messages in sysV stuff. nmbd/asyncdns.c: Fixed signal functs. nmbd/nmbd.c: Fixed isXXX macros & debugs for gcc pedantic compile. passdb/passdb.c: Fixed isXXX macros & debugs for gcc pedantic compile. passdb/smbpassfile.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/chgpasswd.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/ipc.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/nttrans.c: Fixed fsp code path. smbd/password.c: fixed HAVE_YP_GET_DEFAULT_DOMAIN problem. smbd/printing.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/reply.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/server.c: Fixed isXXX macros & debugs for gcc pedantic compile. smbd/trans2.c: Fixed core dump bug. smbd/uid.c: Fixed isXXX macros & debugs for gcc pedantic compile. Jeremy. (This used to be commit 1b9cbcd02e575dc0a95fa589f720df30a4acc46b)
1998-08-14this is the bug change to using connection_struct* instead of cnum.Andrew Tridgell13-2946/+2648
Connections[] is now a local array in server.c I might have broken something with this change. In particular the oplock code is suspect and some .dll files aren't being oplocked when I expected them to be. I'll look at it after I've got some sleep. (This used to be commit c7ee025ead4a85b6fa44a832047b878451845fb6)
1998-08-13Debug output formatting change. I'm trying to combine log lines thatChristopher R. Hertel1-4/+4
really should be together. Chris -)----- (This used to be commit 8880fc58fa61edfd5a83cc75ef627b430b8a4437)
1998-08-11include/smb.h: Removed dir_ptr. Not needed.Jeremy Allison4-93/+95
locking/locking.c: First cut a blocking lock code. #ifdef'ed out for now. locking/locking_shm.c: Removed dir_ptr. Not needed. smbd/nttrans.c: More work on ChangeNotify - return is not an error and needs to be handled as a nttrans with zero params. Removed dir_ptr. Not needed. smbd/reply.c: smbd/server.c: smbd/trans2.c: Removed dir_ptr. Not needed. Hmmm. At the moment smbclient is broken - doesn't issue prompt correctly. This needs looking at. Jeremy. (This used to be commit ddfbcc05815621d3c463f92faed047f126412342)
1998-08-11Makefile.in: Added CHECK target back in (at Herb's request). AddedJeremy Allison1-1/+13
manpath in (although we don't currently use it). client/client.c: Added John Blair's fixes for "put -". include/nterr.h: Added NT_STATUS_NOTIFY_ENUM_DIR error code. smbd/nttrans.c: Added in devious fix for one-shot NT change notify bug. Jeremy. (This used to be commit 4ac3091e57e9ab234b3c051333ba521a92defa99)
1998-08-10Makefile.in: Fixed make clean bug with CVS directory in bin/.Jeremy Allison1-0/+19
include/smb.h: Fixed bugs in Debug macro's with SGI compiler. smbd/trans2.c: Fixed bug reported by Zoltan Palmai <ZSPA@chevron.com> PR#8903 where get_lanman2_dir_entry() could return a mangled name as a resume key and call_trans2findnext() wasn't doing the same. Jeremy. (This used to be commit 9d010e721c27af1d9498fd1e147993ba8ac8b41e)
1998-08-10moved access.c into lib/ from smbd/ as it is needed by testparm. IAndrew Tridgell1-3/+9
modified it not to need any smbd specific structures and instead pass things from smbd. (This used to be commit 162141d3b3fcf53fbc6a1f18702df85c2b7f1781)
1998-08-10split the system password checking routines out of smbd/password.c andAndrew Tridgell2-1042/+143
into passdb/pass_check.c. This means SWAT no longer needs to link to smbd/password.c (This used to be commit 90d93889d722670cbb517017531264630af759bf)
1998-08-09this gets smbd compiling and linking correctly with the new layout.Andrew Tridgell4-599/+18
(This used to be commit d08fa39cec5c71a9034dbf4241fc7e195f1bbaa5)
1998-08-09added ignore rules for the dummy filesAndrew Tridgell1-0/+1
(This used to be commit 687f76a17d6d3ebd33b4d9a848deef56f3c1f56a)
1998-08-09these dummy files are needed for autoconf processingAndrew Tridgell1-0/+0
(This used to be commit be762dc3de6c1ef768790522dfe93007a61ce5d7)
1998-08-05Fixed memory leak when freeing ChangeNotify structures.Jeremy Allison1-6/+6
Jeremy. (This used to be commit 996c5ac97a8d1443bc8abc59b9a10ff3aeb77389)
1998-08-04nttrans.c: Fix change_notify. Queue processing code wasn't changing toJeremy Allison2-18/+54
the correct directory before doing the stat. Doh ! uid.c: Fix for performance in security=share mode. Invalid vuid meant that in security=share mode Samba was always doing the become_user/ undebome_user pairs for *every* smb. This code fixes it, but tridge should review for security implications. Jeremy. (This used to be commit c3663379fdcec487feea2e5d848ee012ee6c6baf)
1998-08-04loadparm.c: Added "debug timestamp" synonym for Chris.Jeremy Allison3-39/+28
nttrans.c: Moved common code into function in server.c Removed left over debug level 0. server.c: Moved common code into function in server.c Jeremy. (This used to be commit 34ef55b7228155cef40cbdfcdc1fe623c1037bd6)
1998-08-03First implementation of ChangeNotify - this version only checksJeremy Allison2-20/+297
for changes in the directory modify timestamps. A better version will look at the requested client flags, and create a hash that represents the current state of the directory, and check against this instead. debug.c: Added lp_timestamp_logs() function. loadparm.c: Added "change notify timeout" in seconds (default 60) - this is the scan rate for a directory. Added ""timestamp logs" boolean - default True. Turns off log timestamps (so I can read them :-). nttrans.c: ChangeNotify implementation. server.c: ChangeNotify implementation. shmem_sysv.c: Added exits on shmem errors (without them smbd can core dump if some calls fail). smb.h: Added ChangeNotify flags for future use. util.c: Tidied up typedef. Jeremy. (This used to be commit a0748c3f53974483680ebe2ea4f556ece8d7fa43)
1998-07-31As per a Andrew's message, I went through and removed the timestring()Christopher R. Hertel9-237/+280
timestamps from several DEBUG messages. The timestamps are redundant now that DEBUG() provides them automatically. There are still a few more files to do, but I've got to get home for dinner. Chris -)----- (This used to be commit 60286ccecaa6028d687e6406755016455e3b3a26)
1998-07-30Makefile.in: Moved UBIQX stuff into UTILOBJ.Jeremy Allison4-217/+332
loadparm.c: Added "ole locking compatibility" option (default "true"). locking.c: Changes to implement union in files_struct. locking_shm.c: Changes to implement union in files_struct. nttrans.c: Made opening a directory explicit (we have to). Added create directory code for nttrans. reply.c: Changes to implement union in files_struct. server.c: Changes to implement union in files_struct. Added create directory code. trans2.c: Changes to implement union in files_struct. smb.h: Changes to implement union in files_struct. util.c: Changed linked list code to UNIQX linked list. This will make the other lists I need to implement for ChangeNotify and blocking locks easier. Jeremy. (This used to be commit 3a5eea850bb256b39cff8ace1e4fb4e0c1f5472b)
1998-07-29get rid of the runtime test for broken getgroups() and add a compileAndrew Tridgell3-85/+37
time test instead. This also allows us to get rid of the igroups element of a couple of structures. (This used to be commit 8b25fe734166b76ceebf8d9543c706ebe0fddc96)
1998-07-29merge from the autoconf2 branch to the main branchAndrew Tridgell11-976/+440
(This used to be commit 3bda7ac417107a7b01d91805ca71c4330657ed21)
1998-07-29locking.c: Print messages when we downgrade a lock.Jeremy Allison2-19/+32
reply.c: Do the same mask expansion we do in trans2.c - needed for Win98. trans2.c: Make the mask expansion into a function call now we have to do it twice. Jeremy. (This used to be commit 7b3a9d6285cc0d1967155a68845e28c6296ecc67)
1998-07-28loadparm.c: Added strict sync parameter.Jeremy Allison2-16/+14
locking.c: Added code to deal with real open mode of file. reply.c: Added strict sync parameter. server.c: Added strict sync parameter. Fixed open modes. Jeremy. (This used to be commit ed57b603b5c9333d588e62d774ad2be67e43ffd9)
1998-07-27chgpasswd.c: Fixed up debug calls to stop crashes if ptsname failed.Jeremy Allison4-29/+18
local.h: Kept FSTYPE_STRING as Samba for now. nmbd_browsesync.c: Added bugfix from Matt Chapman mattyc@cyberdude.com - lmb_browserlist is now a struct ubi_dlList not a struct browse_cache_record *. server.c: smb.h: uid.c: password.c: Removed attrs code - it is not used anywhere. Jeremy (This used to be commit ef1af7fe6d5c58ae57b8e4efff0729e1a315da43)
1998-07-25Noticed that I was using the strlen() of a string that I had strdup()'dChristopher R. Hertel1-1/+1
before testing that the strdup() worked. Fixed. (This used to be commit 899d0d5de5dd9d080d5c4cb94874d4f939427d1b)
1998-07-24Changed the definition of the linked list header used in the directoryChristopher R. Hertel1-1/+1
cache so that it uses the new ubi_dlNewList() macro in ubi_dLinkList.h. (This used to be commit 16f0ad0c913e2d5b0198409485c56ad4809ca077)
1998-07-23locking.c: Added lock type to is_locked() and do_lock()Jeremy Allison3-20/+35
as the code in reply_lockingX wasn't taking account of the difference between read and write locks ! How did this ever work :-) ! reply.c: server.c: Add lock type to is_locked() and do_lock(). util.c: Also added code from klausr@ITAP.Physik.Uni-Stuttgart.De to fix problem with log files growing too large if an smbd writes less than 100 debug messages. Jeremy. (This used to be commit 80080abf772a470d5f0f4dcd4a75fb2a09a9fb2a)
1998-07-22Fixed bug found by Richard Sharpe. After increasing files_struct size byJeremy Allison3-12/+12
MAX_OPEN_DIRECTORIES for nttrans I forgot to update the code that enumerates the array. Created new MAX_FNUMS in local.h, changed all code that iterates through the files_struct array to use this. (sorry Richard). Jeremy. (This used to be commit 339b10222269d71c7a493cc08b7b1bfd35fd55fc)
1998-07-22includes.h: Added feature type USE_GRANTPT for pty code.Jeremy Allison1-5/+9
chgpasswd.c: Updated to use USE_GRANTPT feature definition. Jeremy. (This used to be commit 953c5dbbae8c1370e5988619746b508f26cb0390)
1998-07-17Forgot to increase size of files_struct by MAX_OPEN_DIRECTORIES inJeremy Allison1-1/+1
previous checkin. Jeremy. (This used to be commit 7dfaca5d370ccb472d85416c623692ae7ec2176f)
1998-07-17Code added to fix the renaming of a directory under NT SMB calls.Jeremy Allison4-61/+204
local.h: Changed MAXDIR to MAX_OPEN_DIRECTORIES - shmem size also tuned by this. dir.c: Use MAX_OPEN_DIRECTORIES. nttrans.c: Allow opening of a directory to succeed. Doesn't actually open a file descriptor but takes a files_struct slot marked as an fd. reply.c: Changed to close any outstanding is_directory files. reply_close changed to understand directory files. server.c: Added open_directory(), close_directory() calls. smb.h: Added is_directory to files_struct. Changed OPEN_FNUM to check that target is !is_directory (this prevents the normal file calls from processing a directory files_struct. Jeremy. (This used to be commit e01ce693f47e75e277f3440d46e32b0bd866b550)
1998-07-17nttrans.c: Added FILE_EXECUTE to required permissions checked.Jeremy Allison2-11/+13
trans2.c: Fixed up the SMB_QUERY_FILE_ALT_NAME_INFO code, now I've got an NT client to generate it. It uses unicode without bothering to check the unicode bit of course, but now we can execute 16 bit exe's on a WinNT client from a long filename directory (hurrah). Jeremy. (This used to be commit 6c31be7d3ffff6a40bbbac6de53663fa707ac859)
1998-07-17local.h: Added NTFS define if HAVE_NT_SMBS is defined.Jeremy Allison1-4/+10
nttrans.c: Fixed issue with access DELETE on renaming files. Jeremy. (This used to be commit 0fcf167af898a9c7a20fddc0d95c887477a22ed1)
1998-07-16Makefile: Added nttrans.oJeremy Allison3-213/+283
includes.h: Added termios.h for AIX. nttrans.c: Working NT SMB calls ! pipes.c: Use strequal instead of strcmp. server.c: Use #defines rather than numbers. smb.h: Updated NT SMB #defines. Jeremy. (This used to be commit 3e5cada9885059e9926eb6a56d350c4b1b53d245)
1998-07-16Makefile: Added CC=gcc to DGUX on Intel. Comment from ross@filmworks.com.Jeremy Allison1-9/+26
ipc.c: loadparm.c: printing.c: Added code from <Dirk.DeWachter@rug.ac.be> to implement print queue pausing. New parameters are "queuepause command" and "queueresume command". util.c: Added fix for mount options in autmount map. lib/rpc/include/rpc_misc.h: Removed duplicate pipe names for Jean-Francois. Jeremy. (This used to be commit 559a9bf2bbdeae3e76ba9178779cd3a9537c4e91)
1998-07-14loadparm.c:Jeremy Allison3-103/+102
With apologies to Charlton Heston and Pierre Boule. "You damn fools, you finally did it". Changed default security mode to be security=user. Yes this is a big (although small in code) change. It's something we've been discussing for a while, to finally wean people off the legacy security=share mode which is *never* what you want. Jeremy. nmbd_incomingrequests.c: Bug fix for nmbd core dumps caused by overrun. Found by <samuel@public.szonline.net>. nttrans.c: More NT smb stuff. reply.c: Unlink will overwrite an existing file. Well you learn something new about POSIX every day. :-). server.c: Tidyup unreadable code. smbpasswd.c: Code to allow -U remote_username to allow ordinary users to change remote passwords if their NT username is different from their UNIX username. Patch from <torbjorn.lindh@allgon.se>. Jeremy. (This used to be commit 4eccb47cfb3c8907a6558b6ea9a02b0184458e34)
1998-07-11nntrans.c: Fully implemented transact rename.Jeremy Allison2-6/+40
reply.c: Added NT specific rename if exists flag to rename_internals(). smb.h: Added NT rename flag. Jeremy. (This used to be commit b398f7daf58459db6e8d3496502abeb634ac2183)
1998-07-11nttrans.c: More NT SMB stuff.Jeremy Allison3-76/+103
reply.c: Broke out the internals of reply_mv so that they may be called externally from the NT transact rename. server.c: Changed stat calls to sys_stat - found in code review of bugfix. Jeremy. (This used to be commit fb19dad88edfd7a5c7257a15afc9253fb41f4b99)
1998-07-10Fix for bug PR#8294 reported by <detlef.lammermann@er.materna.de>Jeremy Allison1-1/+8
- the Files array was storing the 'dos_to_unix' translated name, rather than the untranslated name. This could case problems when the name was run through dos_to_unix again. Jeremy. (This used to be commit 5f4be1498f7c907a539fe9b5998dfbcaa9e20e20)
1998-07-10AIX patch from Michael Wojcik <mww@microfocus.com> adding detailJeremy Allison1-4/+135
to the AIX specific (and undocumented) setpriv and setuidx calls. Jeremy. (This used to be commit 7a8d0a4ed4e07090bfe776b5544712274d2426e4)
1998-07-09Needed fix to SIGHUP handling donated by branko.cibej@hermes.siJeremy Allison1-8/+29
(I can't believe we've had that bug so long :-). Jeremy. (This used to be commit 4d26757776af2aaba9cdaf4c956fab29bfde1599)
1998-07-09New version of the DFS_AUTH code from Karsten Muuss <muuss@or.uni-bonn.de>Jeremy Allison1-39/+242
Jeremy. (This used to be commit cf7402c5325afd1f9a737facf285cb905702adb2)
1998-07-09NT SMB trans reply code.Jeremy Allison2-74/+291
Jeremy. (This used to be commit 556254d72517c8a5bf70cafaf443df1675fe64d9)
1998-07-08Implementing more NT SMB functionality.Jeremy Allison1-82/+332
Jeremy. (This used to be commit d34c91126049b7d3094455d407aa99a6d0452304)