summaryrefslogtreecommitdiffstats
path: root/source/smbd
Commit message (Collapse)AuthorAgeFilesLines
...
* genrand.c: Improved generation of random values, more secure.Jeremy Allison1998-04-223-4/+51
| | | | | | | | | loadparm.c: Started add of 'security=domain' code. password.c: Fix for security=server NT bugs. reply.c: Started add of 'security=domain' code. server.c: Started add of 'security=domain' code. smb.h: Started add of 'security=domain' code. Jeremy.
* put server-side long dce/rpc code in main branch.Luke Leighton1998-04-211-6/+6
|
* Added cli_ulogoff() calls to all the exit code paths in security=server.Jeremy Allison1998-04-211-0/+5
| | | | Jeremy.
* clientgen.c: Added cli_ulogoff() call.Jeremy Allison1998-04-211-0/+1
| | | | | password.c: Added call to cli_ulogoff on successfull sessionsetup. Jeremy.
* Added 'passwd chat debug' parameter to allow admins to debug theirJeremy Allison1998-04-201-6/+4
| | | | | Samba passwd chat scripts. Jeremy.
* Makefile: Added genrand.oJeremy Allison1998-04-202-0/+12
| | | | | | | | | | | | | | | clientgen.c: Changed to fill change password buffer with random stuff. password.c: Changed to get challenge from genrand.c server.c: Added #ifdef around O_SYNC. version.h: Changed to 1.9.19prealpha. genrand.c: New code to generate (hopefully) good random numbers for use in crypto challenges/session keys etc. PLEASE REVIEW THIS CODE AND SUGGEST IMPROVEMENTS !!!!!! Jeremy.
* reply.c: Fix bugs where debug statements were accessing the fd_ptr structJeremy Allison1998-04-161-6/+6
| | | | | | | internals after Andrews' code had memset it to zero (this was causing core dumps). charcnv.c: Fixes for ISO8859-2 from Petr Hubeny <psh@capitol.cz>. Jeremy.
* ipc.c: Fix for printer queue spinning with Win95.Jeremy Allison1998-04-151-1/+2
| | | | | | | | | nmbd.c: Fix for always overwriting log despite append setting. smb.h: Addition of last time password changed entry to account info. smbpass.c: Changes to support last time changed field in smbpasswd file. smbpasswd.c: Changes to support last time changed field in smbpasswd file. util.c: Fix for always overwriting log despite append setting. Jeremy.
* Modified interfaces to getting smb password entries fromJeremy Allison1998-04-143-8/+8
| | | | | | | | | | | | | | | | | | | | get_smbpwd_entry (now an internal function to smbpass.c) to a more UNIX-like : getsmbpwnam() - get entry by name. getsmbpwuid() - get entry by uid. Changed the type returned by the smbpasswd enumeration functions to be a void * so that people don't come to depend on it being a FILE *. These abstractions should make it much easier to replace the smbpasswd file with a better backend in future. Other files changed are to match the above changes. Jeremy.
* Fixed aggregate initializer problem for gcc.Jeremy Allison1998-04-131-1/+1
| | | | Jeremy.
* Changes include:Christopher R. Hertel1998-04-133-415/+700
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | proto.h: The unusual. ;) reply.c: I changes some function names, and updated reply.c to match. See mangle.c below for more. server.c: Changed function names and parameters in file mangle.c, so changed server.c calls to match. See mangle.c below for more. mangle.c: I replaced the caching mechanism used for caching reverse mangled name maps. The old method was a large array of 256-byte strings. Movement in the stack (including push and pop) was done by memcpy()ing whole chunks of memory around. The new system uses the ubi_Cache module which, in turn, uses a splay tree. Entries are dynamically allocated using a minimum amount of memory. Searches are non-linear, which should speed things up a bit, too. Overall, this should save memory and be faster. Other changes: I streamlined the is_mangled() test and made other speed enhancements including replacing some static functions with macros. Added comments, etc. Note: Per an E'mail conversation with Andrew, the 'mangled stack' parameter in smb.conf doesn't do anything anymore. The cache is now set for 16K bytes maximum memory usage. The mangle stack parameter is silently ignored. This can easily be changed, but I'd rather introduce a 'mangled cache memory' parameter and remove 'mangled stack'. Remaining problems: While testing the module, I noticed that something is calling name_map_mangle() twice. The result is that names which contain illegal characters are getting mangled twice. Also, the entire module works by overwriting the input string. This has a variety of nasty side effects. Summary: There's a lot still to be done, but the changes I have in place *should* work in exactly the same way (except for the mangle stack parameter). The rest of the bugs and other issues are separate. Chris -)-----
* Changes to allow Samba to be compiled with -Wstrict-prototypesJeremy Allison1998-04-136-87/+84
| | | | | | with gcc. (Not a big change although it looks like it :-). Jeremy.
* fixed a memory leak in close_file(). Each time a file was openedAndrew Tridgell1998-04-131-1/+7
| | | | we leaked memory equal to the length of the filename.
* support O_SYNC at open time in files (previously we only supported itAndrew Tridgell1998-04-121-0/+4
| | | | on individual writes)
* includes.h: Moved HPUX undefine of SEMMSL to where it actually does something.Jeremy Allison1998-04-101-0/+3
| | | | | | | | | | | | | | | ipc.c: Added Luke's debug statement. locking_slow.c: Added FTRUNCATE_NEEDS_ROOT code for broken systems that need it (not sure what these are yet). membuffer.c ntdomain.h proto.h lib/rpc/include/rpc_dce.h lib/rpc/include/rpc_srvsvc.h lib/rpc/parse/parse_prs.c lib/rpc/parse/parse_rpc.c lib/rpc/server/srv_pipe_hnd.c lib/rpc/server/srv_util.c: Re-merge of Luke's NTDOM changes 'cos he's a lazy git with carpel tunnel syndrome :-). Jeremy.
* Fix for [homes] problem with security=share. We were still relyingJeremy Allison1998-04-101-5/+19
| | | | | | on a valid vuid to get the connecting username - this is *never* true (anymore) with security=share. Jeremy.
* Makefile, loadparm.c, server.c, smb.h, util.c: Patch fromJeremy Allison1998-04-091-7/+7
| | | | | | | stn@techfak.uni-kiel.de (Stefan Nehlsen) to get homes from the NIS+ map. smbpasswd.c: Tidy up of cli_state structure. Jeremy.
* Added const cast to struct args to get rid of compile time warning.John Terpstra1998-04-091-1/+1
|
* Fix to stop Windows 95 spinning on print queue requests when itJeremy Allison1998-04-081-1/+1
| | | | | gets an error message it doesn't understand. Jeremy.
* loadparm.c: Cause IPC$ comment to be evaluated at runtime, rather thanJeremy Allison1998-04-061-2/+10
| | | | | | | load time (patch from "Marty Leisner" <leisner@sdsp.mc.xerox.com>. server.c: Patch from Josef Hinteregger <joehtg@joehtg.co.at> - string could be overwritten when find_service() called recursively. Jeremy.
* includes.h: Added semaphore fix for HPUX10.xJeremy Allison1998-03-312-1/+15
| | | | | | server.c trans2.c: Added oplock deadlock bug fix. lib/rpc/server/srv_netlog.c: Made code that changes machine account password the default. Jeremy.
* Fixed compile-time error introduced by log message change.Jeremy Allison1998-03-301-8/+19
| | | | | | Added support for 32bit error messages needed for NTDOM code (was in NTDOM branch, somehow missed during the merge). Jeremy.
* Added remote machine and address to debug message in make_connection() function.John Terpstra1998-03-291-1/+1
| | | | contributor: <ado@flower.nci.nih.gov>
* chgpasswd.c, ipc.c, loadparm.c: Added boolean "unix password sync"Jeremy Allison1998-03-272-19/+60
| | | | | | | | parameter which allows the new change password code to change the unix password also. Defaults to OFF. includes.h: Added termios.h to FreeBSD to allow password changing. namequery.c: Fixed missing name parameters to debug statements. Jeremy.
* Fix for client generated core-dump bug where offset to readrawJeremy Allison1998-03-271-1/+2
| | | | | | | | | was so large that when used with -DUSE_MMAP it caused the unsigned subtraction to wrap aound and become positive - thus causing a silly memcpy offset. Thanks to "Michael St. Laurent" <rowl@earthlink.net> for giving me the core dump that allowed me to track this one down. Jeremy.
* clientgen.c ipc.c smbpasswd.c: Fixes for warnings (from Herb).Jeremy Allison1998-03-242-1/+4
| | | | | | | | | | | quotas.c: Linux quota fix. util.c: Ensure smb_read_error is zero in all calls that can set it. lib/rpc/include/rpc_misc.h lib/rpc/include/rpc_netlogon.h lib/rpc/parse/parse_misc.c lib/rpc/parse/parse_net.c lib/rpc/server/srv_netlog.c : Modify Luke's code to call SamOEMhash(). Jeremy.
* Finally made OS/2 WP fix the default.Jeremy Allison1998-03-191-1/+1
| | | | Jeremy.
* Adding the same changes to HEAD as were added to BRANCH_1_9_18.Jeremy Allison1998-03-191-5/+24
| | | | | | | | | | | | | Changed smbpasswd to be client-server for a normal user, rather than accessing the private/smbpasswd file directly (it still accesses this file directly when run as root, so root can add users/change a users password without knowing the old password). A shakeout of this change is that smbpasswd can now be used to change a users password on a remote NT machine (yep - you heard that one right - we can now change a NT password from UNIX !!!!!). Jeremy.
* Added SamOEMChangePassword functionality.Jeremy Allison1998-03-182-0/+174
| | | | Jeremy.
* this isn't a big commit, it just looks like it :-)Andrew Tridgell1998-03-174-16/+19
| | | | | | | | | I needed the client_name() and client_addr() functions in swat so I could tell who was connecting from where. The problem was that these functions didn't take a file descriptor parameter they just used the global "Client". So I needed to change all calls to pass a parameter ... lots of files.
* Adding the same change as was added to 1.9.18 branch to add theJeremy Allison1998-03-163-12/+11
| | | | | | | | | | | | | | | | | | | | | | | "name resolve order" parameter. source/Makefile: Re-ordered link for name resolve order code. source/clientgen.c: source/clientutil.c: Added calls to resolve_name(). source/includes.h: Added HPUX zombie fix. source/loadparm.c: Added new name resolve order parameter. source/namequery.c: Re-wrote to include parsing of lmhosts file, new resolve_name() function requested by John. source/nmbd.c: Tell resolve_name not to do WINS lookups if we are the WINS server. source/nmbd_lmhosts.c: Call lmhosts parsing functions in namequery.c source/password.c: Call resolve_name() to lookup security=server name. source/reply.c: source/time.c: source/trans2.c: "fake directory create times" fix from Jim Hague - hague@research.canon.com.au. source/util.c: Removed isalnum() test in Get_Hostname() that seems to cause problems on many systems. Jeremy.
* includes.h: Addition of NetBSD 1.3 fix, fix for HPUX 9.x, 10.x zombieJeremy Allison1998-03-161-0/+4
| | | | | | | | | | problem. password.c: Fix for Thursby to stop Dave clients failing in share mode security (this was their bug - they were interpreting the uid field in share mode which is explicitly denied by the spec but it's easier for us to fix it than them :-). Jeremy.
* - claim the null connection after the session request to mak sure weAndrew Tridgell1998-03-152-4/+4
| | | | | | have the netbios name - fix another kill connection bug
* - added the ability to kill off individual connections from SWAT (fromAndrew Tridgell1998-03-152-181/+226
| | | | | | | | | the status page) - split the claim_connection() code into its own file - fixed the claim_connection() code to lock the file when manipulating it - always claim a null connection at startup - fixed a bug in the pidfile code
* added the ability to start/stop the server from SWAT.Andrew Tridgell1998-03-141-33/+3
| | | | | | | | I needed to modify the way the pidfile is handled in nmbd and smbd to do this. Jeremy, you may wish to look at what I've done as it probably breaks the Whistle use of pidfiles. In particular I've removed the -f option and instead smbd and nmbd always create a pidfile in the lock directory.
* another makeover of loadparm to support new stuff in swat andAndrew Tridgell1998-03-141-1/+1
| | | | | | | | | | | | | | | | | | testparm. In particular I added: - ability to optionally save default values of all parameters when calling lp_load(). This can then be used to save only non-default parameters in lp_dump(). This makes the saved smb.conf (and viewed parameters in testparm) much shorter - ability to not load ipc share in lp_load() - separators in parm_table[] so parameters can be grouped logically. - flag to mark parameters that are local but which should be also viewed as global as far as parameters editing is concerned
* move setup_groups() into password.c so that swat can link withoutAndrew Tridgell1998-03-122-83/+86
| | | | including server.o
* use FSTYPE_STRING not "SAMBA" for filesystem typeAndrew Tridgell1998-03-121-1/+1
|
* report the max size of raw reads as 65536 not 65535 (this now matchesAndrew Tridgell1998-03-121-1/+1
| | | | what Win95 reports)
* Missed fixes in NTDOM branch for doing readX via pipe IPC$.Jeremy Allison1998-03-112-1/+5
| | | | | | | Allows long share lists to be browsed. Browsing *into* a long share name still fails, though. (Luke - you may need to look into this). Jeremy.
* "For I have laboured mightily on Luke's code, and hath brokenJeremy Allison1998-03-116-470/+676
| | | | | | | | | | | | | | | | | | | | | | | | all I saw" - the book of Jeremy, chapter 1 :-). So here is the mega-merge of the NTDOM branch server code. It doesn't include the new client side pieces, we'll look at that later. This should give the same functionality, server wise, as the NTDOM branch does, only merged into the main branch. Any fixes to domain controler functionality should be added to the main branch, not the NTDOM branch. This code compiles without warnings on gcc2.8, but will need further testing before we are sure all the working functionality of the NTDOM server branch has been correctly carried over. I hereby declare the server side of the NTDOM branch dead (and all who sail in her :-). Jeremy.
* Removed broken change I made to mangle.c (ooops. Andrew's originalJeremy Allison1998-03-042-9/+4
| | | | | | | | | algorithm was correct). Finally (I think) fixed the mangled directory stack issue in scan_directory() correctly. Mangled & non-mangled names are now being checked correctly. Hurrah to Ulrik Dickow <ukd@kampsax.dk> who helped isolate this one. Jeremy.
* Adding Korean and Traditional Chinese codepage support.Jeremy Allison1998-03-042-1/+5
| | | | Jeremy.
* Change the multibyte character set support so thatJeremy Allison1998-03-032-88/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kanji support is one case of multibyte character support, rather than being a specific case in single byte character support. This allows us to add Big5 Chinese support (code page 950) and Korean Hangul support (code page 949) at very little cost. Also allows us to easily add future multibyte code pages. Makefile: Added codepages 949, 950 as we now support more multibyte codepages. asyncdns.c: Fixed problem with child being re-spawned when parent killed. charcnv.c charset.c client.c clitar.c kanji.c kanji.h smb.h util.c loadparm.c: Generic multibyte codepage support (adding Big5 Chinese and Korean Hangul). nmbd.c: Fixed problem with child being re-spawned when parent killed. mangle.c: Modified str_checksum so that first 15 characters have more effect on outcome. This helps with short name mangling as most 'long' names are still shorter than 15 chars (bug was foobar_mng and foobar_sum would hash to the same value, with the modified code they hash differently. Jeremy.
* Makefile, password.c, includes.h: Added KRB4 patches from Johan Hedin ↵Jeremy Allison1998-02-261-0/+30
| | | | | | | <johanh@fusion.kth.se> nmbd_packets.c: Patch for aliased interfaces from Daniel Haun <dhaun@ecf2.puc.edu>. Jeremy.
* Fix for NT redirector bug where deltree fails if the resume keyJeremy Allison1998-02-262-16/+71
| | | | | | | | indexes are changed between directory scans. This fix does what NT4.x SP3 does in that it stops using resume keys and returns zero instead. We now use the filename in findnext to continue the search in the correct place (as NT does). Jeremy.
* nmbd_packets.c: nmbd_subnetdb.c: Patch from Andrey Alekseyev ↵Jeremy Allison1998-02-202-2/+11
| | | | | | | | | | | | | <fetch@muffin.arcadia.spb.ru> to fix the fact that retransmit_or_expire_response_records() wasn't looking at the WINS subnet. server.c: Patch from jkf@soton.ac.uk to add %p (NIS server path) substitution. smbpass.c: Fix to stop parsing failing on non-valid lines. trans2.c: Fix for volume serial number code. util.c: Patch from jkf@soton.ac.uk to add %p (NIS server path) substitution. Fix for warnings under RH5. gcc 2.8. Jeremy.
* Ding-dong the witch is dead, the witch is dead......Jeremy Allison1998-02-132-22/+21
| | | | | | | | | | | | | | This is the checkin that fixes the infamous Visual C++ 'file has changed' bug. I feel *SO* good about that :-). charset.c: Added (void) to fix Herb's fussy compiler. loadparm.c: Removed "win95 bug compatibility" (didn't like it much anyway :-). Added "dos filetime resolution" instead. reply.c: Added the 2 second timestamp resolution fix that the song above is about. time.c: Removed unneeded get_access_time() function. trans2.c : Removed unneeded "win95 bug compatibility" code. Jeremy.
* make the initial logfile names consistent. This should mean that smbdAndrew Tridgell1998-02-121-0/+2
| | | | | | starts with log.smb and nmbd starts with log.nmb. It also gets rid of the "log." when using the log.%m construct as %m expands to smb before a client connects.
* Makefile: Added AIX 3.2.5.Jeremy Allison1998-02-114-9/+33
| | | | | | | | | | | | | | | | loadparm.c: Added "win95 bug compatibility" parameter. local.h: Replaced MAX_OPEN_FILES back to 100 from 10 (oops). reply.c: Fixed ulogoff check against uid - changed to vuid. server.c: Changed file struct save of uid - changed to vuid. smb.h: Changed id in struct current_user to vuid. Changed file struct uid to vuid. time.c: Added "win95 bug compatibility" atime -> mtime return. trans2.c: Added "win95 bug compatibility" fixes. uid.c: Changed id in struct current_user to vuid - added checks to set/reset it. util.c: Added code to expand environment variables. version.h : still at 1.9.18 (head branch doesn't matter too much at present). Jeremy.