summaryrefslogtreecommitdiffstats
path: root/source/smbd
Commit message (Collapse)AuthorAgeFilesLines
* Directory tidyups to help me track any problems.Jeremy Allison1999-02-051-12/+17
| | | | | | | | | Upped MAX_OPEN_DIRECTORIES to 256. Ensured new directory handles are only allocated between 255 - MAX. Stopped re-open of a directory about to be closed. Log a message if a directory is to be closed and the bitmap is not set. Jeremy.
* Someone sent me a trace showing a client doing a readraw requestJeremy Allison1999-02-031-7/+10
| | | | | | | | | with a completely bogus FID (0xFFFF). This was causing the new 2.0 code to crash by indirecting through a null pointer, as the old debug code wanted to print this fid value, and was using fsp->fnum to do it - erroneously assuming that fsp was non-null. Jeremy.
* Fixed bug where cli->timeout was in milliseconds, but open_sockets_outJeremy Allison1999-02-031-1/+8
| | | | | | | | | | | | | | was in seconds. This meant that PDC -> BDC failover took so long it essentiually didn't happen. include/client.h: Added explicit comment that cli->timeout should be milliseconds. include/local.h: Changed LONG_CONNECT_TIMEOUT & SHORT_CONNECT_TIMEOUT to be milliseconds. lib/smbrun.c: Tidied up fork failure catching. lib/util_sock.c: Ensured timeout treated as milliseconds. libsmb/clientgen.c: Added comment. rpc_server/srv_pipe_hnd.c: Luke's changes. smbd/chgpasswd.c: Paranoia code for EINTR around sys_waitpid. Jeremy.
* Fixed bug for Turbo Pascal users whereJeremy Allison1999-02-021-1/+8
| | | | | | | | echo >test.~pa would create a file called : test.~pa.~pa.~pa.~pa Jeremy.
* Fixed devide by zero on SIGHUP bug if no stat cache lookupsJeremy Allison1999-02-021-1/+6
| | | | | have been done. Jeremy.
* Turns out that Win98 *can* display large volume sizes, even withHerb Lewis1999-02-011-9/+9
| | | | | the non-trans2 call - if you set the return parameters right. Jeremy.
* locking/locking_shm.c: Added printf to help track down negative share mode ↵Jeremy Allison1999-02-014-17/+25
| | | | | | | | | | | | | | | problem. printing/print_svid.c: Fix for DG/UX lpstat. smbd/dfree.c: Added 'max_four_gig' parameter to normalize to 4GB when asked (used to be the default). smbd/open.c smbd/reply.c smbd/trans2.c: Changed to allow a <4GB volume size to be returned on a trans2 qfsinfo level 1 call. NT clients refuse to do the correct call to Samba servers (Herb recons it's the unicode bit) - this allows even a level 1 to return a volume size up to 9444732961341243916800 bytes (should be enough for now, until we get the unicode support added :-). Jeremy.
* Be very careful allowing "utility" functions to modify input strings.Matthew Chapman1999-01-311-0/+3
| | | | | | | | check_mangled_cache was not always restoring the filename correctly before returning False. Thanks to Christoph Scheeder <christoph.scheeder@Scheeder.de> for tracking this down.
* Fixed large (<4GB) filesystem size reporting.Jeremy Allison1999-01-291-2/+2
| | | | Jeremy.
* First set of changes for SSL support under Samba 2.0.xRichard Sharpe1999-01-261-1/+8
| | | | | Fix bugs in loadparm.c and move location of #ifdef WITH_SSL to a place that makes more sense!
* Andrew paranoia fix with errno and EINTR.Jeremy Allison1999-01-251-1/+3
| | | | Jeremy.
* Added HPUX signal fix for non-restarted waitpid syscall. Fix from Panu ↵Jeremy Allison1999-01-251-2/+6
| | | | | | Outinen <Panu.Outinen@vertex.fi> Jeremy.
* Added sys_setgroups wrapper if getgroups are broken. Mainly used on SunOS.Jeremy Allison1999-01-231-4/+4
| | | | | Code <from Elmar.Daegele@bln.siemens.de>. Jeremy.
* Fixed the 'truncate files' bug. NT uses the SMB_SET_FILE_ALLOCATION_INFOJeremy Allison1999-01-221-6/+36
| | | | | | setfileinfo call with allocation set to zero instead of SMB_SET_FILE_END_OF_FILE_INFO to truncate a file. Jeremy.
* Added code to let NT do a 'delete on close' request on an openJeremy Allison1999-01-216-167/+241
| | | | | | directory handle. WinCenter (multi-user NT system) is doing this. This code still needs testing.... Jeremy.
* Turns out NT can send an NTcancel request with an invalid uid. This canJeremy Allison1999-01-201-1/+1
| | | | | | cause smbd to crash. As we're only removing entries from a queue then remove the AS_USER flag for reply_ntcancel. Jeremy.
* smbd/ipc.c: Fixed potential return without calling va_end().Jeremy Allison1999-01-202-2/+11
| | | | | smbd/password.c: Fixed ACB_DISABLED flag when doing 'update encrypted'. Jeremy.
* Fixed potential core-dump bug where conn pointer was being dereferencedJeremy Allison1999-01-191-5/+5
| | | | | before check for NULL. Jeremy.
* Added bugfix from gotti@cs.tu-berlin.de for mangled name not matching in cache.Jeremy Allison1999-01-181-9/+10
| | | | Jeremy.
* As expected, people are complaining about the "32 bit lock message".Jeremy Allison1999-01-171-8/+10
| | | | | Moved the message so it's printed only in the case where we can't map the lock range. Jeremy.
* Changed 'large lock' warning message to debug level 1, not zero, toJeremy Allison1999-01-141-2/+2
| | | | | | allow people to turn it off if it really bugs them and in case we get it a lot. Jeremy.
* Fixed the *other* typo in the mapping of 64 bit to 32 bit lock ranges :-).Jeremy Allison1999-01-141-1/+1
| | | | Jeremy.
* fixed a missing IVAL in get_lock_offset(). There was no way that thisAndrew Tridgell1999-01-141-1/+1
| | | | | code could have worked, so I'm a little suspicious of the testing that has been done on it!
* utils/testparm.c: Fixed "passwd program" tests to look for the correct program.Jeremy Allison1999-01-131-2/+2
| | | | | | smbd/reply.c: Changed "Error" in level 0 debug message about NT bug to "Warning" as Samba will continue without it. Jeremy.
* configure configure.in: Fixed the compile problem with Solaris 2.6/2.7 andJeremy Allison1999-01-133-19/+34
| | | | | | | | | | | | | | gcc2.7.x - this condition is now auto detected and uses the correct flags. smbd/reply.c: Did more mapping for 64-bit lock requests on 32 bit systems. smbd/nttrans.c: smbd/oplock.c: Fixed the MS-Office not noticing files are open problem. This was a *subtle* problem and now needs testing to ensure the fix is correct. It's past 8pm, I'm tired and I'm going for a pizza. Jeremy.
* Fixed biffer too small error to have 0xC0000000 OR'ed into it justJeremy Allison1999-01-121-1/+2
| | | | | to be the same as NT (seems to work without it but you never know...). Jeremy.
* Implemented NT_QUERY_SECURITY_DESCRIPTOR in the same way that NT respondsJeremy Allison1999-01-122-16/+85
| | | | | | if you send this query to a FAT volume. Phew - I'm glad I got this one in under the wire for 2.0.0..... Jeremy.
* libsmb/nmblib.c: Fixed bug where odd byte count could cause nmbd toJeremy Allison1999-01-112-11/+32
| | | | | | | | do too many iterations. nmbd/nmbd.c: Fixed SIGHUP handling to act the same as smbd. smbd/reply.c: Added code to map 64-bit lock ranges where possible on 32-bit systems. smbd/server.c: Fixed comment. Jeremy.
* don't panic on a null params in api_reply(). instead just return anAndrew Tridgell1999-01-101-1/+4
| | | | error (smbtorture sends null params)
* fixed two compiler warningsAndrew Tridgell1999-01-101-2/+1
|
* fixed (harmless) bug in DEBUG() messageAndrew Tridgell1999-01-101-1/+1
|
* Fixed change notify for Visual C++.Jeremy Allison1999-01-091-28/+118
| | | | | | | | | | | No-one seemed to have noticed it wasn't working (this worries me....). ChangeNotify now scans the directory if necessary and uses the sum of all timestamps and the number of entries as the 'hash' to determin if anything changed. Jeremy.
* Fixed the 16-bit app directory handle problem (this took *way* longerJeremy Allison1999-01-083-162/+240
| | | | | | | | than it should :-). SMBsearch now gets directory handles that are 8 bit in the range 1-255 and will close the oldest non-expect-close handle if the table gets full. findfirst gets 16 bit directory handles starting at 256 and above. Jeremy.
* Now we're mallocing our directory handles rather then using a staticJeremy Allison1999-01-072-55/+68
| | | | | | | array, leaks are rather more severe :-). This fixes a bug in trans2 findfirst where I forgot to close a directory handle if returning a 'no such file' error. Also fixed a similar case in smbsearch. Jeremy.
* Removed 'counter' from timeout processing. Timeouts now depend on actualJeremy Allison1999-01-072-23/+49
| | | | | | | time calculations, not by incrementing a counter. The select timeout is set to the old (lower) value of 10 seconds if there are blocking locks pending, and to the newer 60 second value if not. Jeremy.
* Remember to return after idling the oldest dirptr so we don't idle allJeremy Allison1999-01-071-1/+3
| | | | | of them. Jeremy.
* Fixed the blocking locks and change notify code that got broken inJeremy Allison1999-01-062-145/+179
| | | | | | | | | | | beta5. The problem was that I had increased the select timeout so much that the client was sending echo requests as a sort of keepalive. As smbd only did timeout processing on select timeout then not much timeout processing was being done :-). I've fixed this by moving the timeout code to a function and calling it every time we get an SMBecho request (we must have been idle at that point). Jeremy.
* Allow force user to take %S substitution.Jeremy Allison1999-01-061-2/+6
| | | | Jeremy.
* Converted the code in smbd/dir.c to use bitmaps instead of a staticJeremy Allison1999-01-061-185/+239
| | | | | | | | array for directory handles. This tidied up the code a *lot*. Plus it means I've fixed the bug in PR#10058, which was due to an NT app that wanted to simultaneously open >256 directory handles. Jeremy.
* acconfig.h configure configure.in include/config.h.in lib/system.c: Fixed ↵Jeremy Allison1999-01-041-1/+1
| | | | | | | | | --with-mmap code. lib/time.c: Changed %T to %H:%M:%S for systems that don't have %T. locking/locking_slow.c: Re-added FTRUNCATE_NEEDS_ROOT code - now to test for it... smbd/quotas.c: Fixed IRIX quota compile. Jeremy.
* Fixed bug in nttrans call where parameter buffer was not beingJeremy Allison1998-12-301-0/+2
| | | | | zeroed out before use. Jeremy.
* client/client.c: Fixed comment.Jeremy Allison1998-12-302-2/+2
| | | | | | All others - added checks for the compiler understanding volatile and the system having sig_atomic_t. Changed sighup code to use this. Jeremy.
* In reply_lockread.Jeremy Allison1998-12-291-2/+9
| | | | | | | | Discovered by Menny Hamburger at Mainsoft. This is a core+ protocol request that predates the read/write lock concept. Thus instead of asking for a read lock here we need to ask for a write lock. Jeremy.
* lib/signal.c: Added CatchChildLeaveStatus() call needed in smbd/open.c and ↵Jeremy Allison1998-12-295-33/+137
| | | | | | | | | | | | | | | | | | | | | | | smbd/chgpasswd.c. smbd/chgpasswd.c smbd/open.c: Ensure that we replace SIGCLD handler with CatchChildLeaveStatus() *before* we expect to reap a child status - and reset it to CatchChild() after we've done the sys_waitpid(). The original CatchChild() code would eat the status code from the zombie in the signal handler, meaning that the sys_waitpid() calls in check_access_allowed_for_current_user() and chgpasswd would never return a status. smbd/open.c: smbd/reply.c: smbd/close.c: Check error return on close() calls - ensure a valid error return is sent back to the client. This catches the "file truncated" bug when a user has run out of quota (or space) and the ENOSPC error is returned on the *close()* call, not the write() (eg. on an nfs mounted drive). smbd/fileio.c: Added check for ESPIPE on sys_lseek() in file_seek() to allow people to use Windows clients to communicate with UNIX fifo's (like they could in 1.9.18). Jeremy.
* Fixing the last issue known about....Jeremy Allison1998-12-231-1/+1
| | | | | | (with a filename of log123.abcd, a dir command of dir l*.???.?.?.?.?.? should find the file, as it does on NT). Jeremy.
* Fixed issues with client wildcards. It turns out that NT matchesJeremy Allison1998-12-231-16/+20
| | | | | | | wildcards against both long and short filenames in a trans2 wildcard match. This fix gets us closer to NT compatibility (still not entirely there yet.... one more issue I know about to fix....). Jeremy.
* passdb/pass_check.c: Added log of AFS auth error.Jeremy Allison1998-12-231-1/+1
| | | | | | smbd/password.c: Set debug loglevel of disabled account to 1 (I was bitten by this recently). Jeremy.
* Spelling mistake change due to very pick people (you know who you are :-).Jeremy Allison1998-12-224-13/+46
| | | | | | | | | | Changed privilage to privilege. Also added set_real_uid() call to lib/util_sec.c. Removed last set[re]uid calls from quotas.c - all such calls now live only in lib/util_sec.c. Jeremy.
* Rather large (I'm afraid) tidyup of the setuid handling code.Jeremy Allison1998-12-224-183/+118
| | | | | | | | | | | | | | | | | | | | All setuid code now resides in the one module lib/util_sec.c. The interfaces this module exports are : void gain_root_privilage(void); - Set real/eff/saved uid's to 0. void gain_root_group_privilage(void); - Set real/eff/saved gid's to 0. int set_effective_uid(uid_t uid); - Set eff uid *only* to given value. int set_effective_gid(gid_t gid); - Set eff gid *only* to given value. BOOL become_user_permanently(uid_t uid, gid_t gid); - Set real/eff/saved uid's and gid's to uid and gid permanently - with no way back to root. Most of the quota code now uses these calls (except for a few special cases). smbd/chgpasswd.c: Ensured the dochild exits in the fork()'d child. libsmb/nmblib.c: Fix from Jasper for memory leak. Jeremy.
* Fixed missing include of smbw.h.Jeremy Allison1998-12-111-2/+2
| | | | | Added strerror print for initgroups fail. Jeremy.