summaryrefslogtreecommitdiffstats
path: root/source/smbd/oplock.c
Commit message (Collapse)AuthorAgeFilesLines
* configure configure.in: Fixed the compile problem with Solaris 2.6/2.7 andJeremy Allison1999-01-131-13/+21
| | | | | | | | | | | | | | 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.
* HPUX fix. This looks like a big change but isn't actually, most of theJeremy Allison1998-12-101-3/+3
| | | | | | | | | | | | | | | | changes are bzero -> memset as the compiler on HPUX is very picky about bzero (probably a strange define). The significant changes are in configure.in, to fix the HPUX shadow.h problem and also move the large file support to the correct place. passdb/pass_check.c: Added includes for KRB5, DCE and AFS if requested in autoconf. tests/trapdoor.c: Fix to use setresuid and setresgid if defined. The rest of the changes are bzero -> memset. Jeremy.
* lib/access.c: Added checks for invalid '*' or '?' characters in hosts ↵Jeremy Allison1998-12-091-9/+2
| | | | | | | | | | allow/deny that could silently deny access. Log them if they occur. smbd/close.c smbd/oplock.c smbd/reply.c: Removed a global oplock variable (hurrah!). Removal of the oplocks flags and any kernel oplocks is now done in either close() or in reply_locking() by calling release_file_oplock(). Jeremy.
* Fixed critical bug with kernel oplock interface.....Jeremy Allison1998-12-051-3/+36
| | | | | This one was *nasty* to find... (sigh) Jeremy.
* Added lib/doscalls.c : This file collects all the calls that use dos_to_unix()Jeremy Allison1998-11-241-2/+2
| | | | | | | | | | | | | | | | | | | to map filenames before accessing the UNIX filesystem. The other changes are to make the code that previously allways called the ambiguous functions (such as file_size(), that internally called dos_to_unix()) to be unambiguous. For example: file_size() becomes "dos_file_size()", that calls dos_to_unix(), and file_size(), that does not. It is now very explicit when we are calling a dos mapping call and when we are not. Also added string_to_sid unsigned fix by adding the strtoul from libg++ code into lib/replace.c and testing for strtoul in configure.in. Jeremy.
* Fixed bug in oplock test file path specification.Jeremy Allison1998-11-241-1/+1
| | | | Jeremy.
* Fixed crash bug found by russian codepage problem.... although how theJeremy Allison1998-11-181-1/+1
| | | | | | | two are related I'm not sure :-). Problem was assuming that fd_ptr in the files_struct was always non-null (which is not the case when directories are open). Jeremy.
* Changed (most) open()/fopen()/creat()/mmap() calls to use sys_XXX() instead.Jeremy Allison1998-11-171-1/+1
| | | | | | Needed as in the 64 bit file spec new open types are needed on many OS's to be able to seek past 32bits. Jeremy.
* source/Makefile.in: Added quotes around ROFF arg.Jeremy Allison1998-11-161-3/+2
| | | | | | script/installman.sh: Make installman ignore ROFF argument if it is "". smbd/oplock.c: Move location of oplock test file to lockdir. Jeremy.
* Fixed O_EXCL problems with printing and oplocks.Jeremy Allison1998-11-161-1/+1
| | | | Jeremy.
* Makefile.in configure configure.in include/config.h.in: Changes for DGUX and ↵Jeremy Allison1998-11-131-1/+1
| | | | | | | | | | | | | | UNIXWARE. groupdb/aliasdb.c groupdb/aliasfile.c groupdb/groupfile.c: Don't use snprinf, use slprintf. include/includes.h: Fix YP problem. include/smb.h: Fix ZERO_STRUCTP. lib/util_sock.c: Added strerror() in debugs. passdb/ldap.c: Don't use snprinf, use slprintf. rpc_client/cli_lsarpc.c rpc_client/cli_pipe.c rpc_parse/parse_sec.c rpc_server/srv_pipe.c: Don't use snprinf, use slprintf. script/installman.sh: DGUX changes. smbd/open.c smbd/oplock.c: Fixed gcc warnings. web/swat.c: Changes USER to SWAT_USER.
* at the interop Isaac (at least I _think_ it was Isaac) said that if aAndrew Tridgell1998-10-211-1/+14
| | | | | | | | | | | | | | | MS client doesn't respond to a oplock break request then we might try resending the request. This morning Sues Win95 machine had this problem (thus forcing me to do something about it!). When starting winword her box refused to answer an oplock break request. I have added code to resend the oplock break request up to 3 times at 10 second intervals before killing the socket. of course, as soon as I did this her box started to behave again so I haven't been able to tell if this fix actually works, but it can't be worse than dropping the socket immediately.
* config: Fix crypt prototype on RedHat Linux.Jeremy Allison1998-10-151-1/+1
| | | | | | | | include/includes.h: Fix crypt prototype on RedHat Linux. smbd/fileio.c: Fix mmap bug found by WinCE client. smbd/ipc.c: Fix WinCE wierdness with pipes being opened as \server\pipe\lanman smbd/password.c: Fix encrypted null passwords. Jeremy.
* more warnings...Luke Leighton1998-10-141-1/+1
|
* libsmb/clientgen.c: Fixed signed/unsigned compile warnings spotted by Herb.Jeremy Allison1998-09-301-2/+4
| | | | | | | | param/loadparm.c: smbd/oplock.c: Allow kernel oplocks to be turned off in the smb.conf file. smbd/server.c: Move init_structs() to after the smb.conf file is loaded - preparation for making a "max open files" parameter. Jeremy.
* Changes to test in configure if capabilities are enabled on a system.Jeremy Allison1998-09-281-2/+2
| | | | | | | | | | Changes to get Samba to compile cleanly with the IRIX compiler with the options : -fullwarn -woff 1209,1174 (the -woff options are to turn off warnings about unused function parameters and controlling loop expressions being constants). Split prototype generation as we hit a limit in IRIX nawk. Removed "." code in smbd/filename.c (yet again :-). Jeremy.
* Makefile.in: Fixed bug with continuation line causing proto to fail.Jeremy Allison1998-09-251-34/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added $(PROGS) $(SPROGS) as targets for make clean. acconfig.h: Added HAVE_IRIX_SPECIFIC_CAPABILITIES. configure.in: Added sys/capability.h header check. Added function checks for srandom random srand rand. Added HAVE_IRIX_SPECIFIC_CAPABILITIES test. includes.h: Added #include <sys/capability.h>. ntdomain.h: Moved struct acct_info into here from smb.h smb.h: Added KERNEL_OPLOCK_CAPABILITY define. Moved enum action_type into rpcclient.h Moved struct cli_state into client.h Moved struct nt_client_info, struct tar_client_info, struct client_info into rpcclient.h lib/genrand.c: Changed to use sys_random() & friends. lib/smbrun.c: Lose capabilities after fork. lib/system.c: Added set_process_capability(), set_inherited_process_capability() sys_random(), sys_srandom(). lib/util.c: Added Ander's EFBIG lock check to fcntl_lock for 64 bit access to an 32 bit mounted NFS filesystem. nmbd/nmbd.c: Changed to use sys_random() & friends. nmbd/nmbd_browsesync.c: Changed to use sys_random() & friends. passdb/ldap.c: Missed one pdb_encode_acct_ctrl call. passdb/passdb.c: Changed to Ander's code for ' ' characters. passdb/smbpass.c: Added Ander's code to reset ACB_PWNOTREQ. script/mkproto.awk: Added 'long' to prototypes. smbd/chgpasswd.c: Lose capabilities after fork. smbd/open.c: Do the mmap *after* the kernel oplock. smbd/oplock.c: Removed stub code from kernel oplock path. Added set_process_capability(), set_inherited_process_capability() calls. smbd/reply.c: Initialize count = 0, offset = 0. smbd/server.c: Added set_process_capability(), set_inherited_process_capability() calls. tests/summary.c: Ensure we have RANDOM or RAND. utils/smbpasswd.c: Added Ander's code to reset ACB_PWNOTREQ. utils/torture.c: Changed to use sys_random() & friends. Jeremy.
* Integration of Anders Blomdell <anders.blomdell@control.lth.se>'sJeremy Allison1998-09-241-4/+35
| | | | | | smbpasswd changes. Not exactly the same as his code - several changes. Jeremy.
* Hoist by my own petard with warnings (forgot to set strict warningsJeremy Allison1998-09-231-6/+6
| | | | | in Makefile before compiling & checking in :-). Jeremy.
* smbd/oplock.c: Use O_CREAT and O_TRUNC and correct mode flagsJeremy Allison1998-09-231-1/+1
| | | | | | | when creating oplock test file. smbd/server.c: Check for existance of kernel oplocks before becoming a daemon. Jeremy.
* First cut at kernel oplocks. This should have no effect unless runninJeremy Allison1998-09-231-141/+477
| | | | | | | | | on a machine that supports them in autoconf. Move various functions out of lib/util.c into smbd/process.c and smbd/oplock.c where they belong. Jeremy.
* Fixed problems with premature kernel oplock checkin code.Jeremy Allison1998-09-181-2/+1
| | | | | | The ./configure & build now seem to work ok. Jeremy.
* configure configure.in include/config.h.in include/includes.hJeremy Allison1998-09-181-0/+61
| | | | | | | | | | Fixed bugs in readline autoconf. param/loadparm.c smbd/open.c smbd/oplock.c: Started on kernel oplock code - checking forced by above issue. Should not be used currently. Jeremy.
* Added ssize_t to configure code.Jeremy Allison1998-09-111-60/+0
| | | | | | | | | | | Got 'religion' about using size_t and ssize_t for read/write stuff as part of the code to expose 64 bits to the client. This checkin does all the 'easy' stuff - such as all the read/write/lock calls - but now comes the harder parts (open & friends) and all the file enquiry functions..... Jeremy.
* tridge the destroyer returns!Andrew Tridgell1998-09-051-1/+3
| | | | | | | | | | | | | | | | | | | | | | prompted by the interpret_security() dead code that Jean-Francois pointed out I added a make target "finddead" that finds potentially dead (ie. unused) code. It spat out 304 function names ... I went through these are deleted many of them, making others static (finddead also reports functions that are used only in the local file). in doing this I have almost certainly deleted some useful code. I may have even prevented compilation with some compile options. I apologise. I decided it was better to get rid of this code now and add back the one or two functions that are needed than to keep all this baggage. So, if I have done a bit too much "destroying" then let me know. Keep the swearing to a minimum :) One bit I didn't do is the ubibt code. Chris, can you look at that? Heaps of unused functions there. Can they be made static?
* Fixed one more Debug problem with inode in non-64 bit case.Jeremy Allison1998-09-051-1/+1
| | | | Jeremy.
* Modified dev_t and ino_t code to be 64 bit clean (including changesJeremy Allison1998-09-041-21/+102
| | | | | | | | | | to oplock break message passing). I think that smbd/nmbd are now inode and offset size independent (at least for 32 bit and 64 bit systems). Now to expose all this new functionality to NT clients..... Jeremy.
* configure.in, configure: include/config.h.in: Added stropts and poll.Jeremy Allison1998-08-311-8/+17
| | | | | | | | | | | include/smb.h: Moved old typedefs of uint8 etc. into include/includes.h where all the other defines live (changed them from typedefs to defines). Other changes : changed from using uint32 to SMB_DEV_T and SMB_INO_T in preparation for moving to size independed (ie. 64 bit clean) device and inode access. Stat call wrapper comes next :-). Jeremy.
* Fixed bug introduced by the recent changes where the chain_fnumJeremy Allison1998-08-171-0/+5
| | | | | could be overwritten in oplock processing code. Jeremy.
* move soem variables from server.c that don't belong there.Andrew Tridgell1998-08-171-5/+9
|
* this completes the splitup of server.c.Andrew Tridgell1998-08-171-0/+639
the splitup was done with an axe, not a scalpel, so there are some rough edges. I mostly wanted to get the general form right with fine tuning of what goes where to come later. Still, this is better than what we had before where server.c was a general repository for anything that didn't fit elsewhere.