summaryrefslogtreecommitdiffstats
path: root/source/passdb
Commit message (Collapse)AuthorAgeFilesLines
* A couple of malloc fail catches.Jeremy Allison1999-02-031-0/+5
| | | | Jeremy.
* Reversed the sense of the 21 -> 0x21 code test.Jeremy Allison1999-01-211-14/+11
| | | | | This will cause trouble........ Jeremy.
* Added autoconf detect tests for broken Solaris 2.6 NIS+ include files.Jeremy Allison1998-12-291-2/+6
| | | | Jeremy.
* passdb/nispass.c: Fixed compile --with-nisplus (I now have access to a ↵Jeremy Allison1998-12-292-52/+103
| | | | | | | | Solaris 2.6 box:-). passdb/passdb.c: Fixed reading of machine sid so that we correctly change the (decimal)21 to hex 0x21 to be in line with NT. Jeremy.
* passdb/pass_check.c: Added log of AFS auth error.Jeremy Allison1998-12-231-0/+1
| | | | | | smbd/password.c: Set debug loglevel of disabled account to 1 (I was bitten by this recently). Jeremy.
* Rather large (I'm afraid) tidyup of the setuid handling code.Jeremy Allison1998-12-221-38/+22
| | | | | | | | | | | | | | | | | | | | 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.
* acconfig.h configure configure.in include/config.h.in: Added krb5 libs code ↵Jeremy Allison1998-12-162-2/+19
| | | | | | | | | | | back, based on 1.9.18 tree. tests/crypttest.c: Added test for truncated salt in crypt. passdb/ldap.c: Malloc checks. passdb/pass_check.c: Added test for truncated salt in crypt. Added OSF1 enhanced security fix. Jeremy.
* HPUX fix. This looks like a big change but isn't actually, most of theJeremy Allison1998-12-104-14/+24
| | | | | | | | | | | | | | | | 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.
* Fix for non-termination of string in osf1_bigcrypt.Jeremy Allison1998-12-041-0/+1
| | | | Jeremy.
* client/clientutil.c: Changed workgroup to "" for smbmount (only codeJeremy Allison1998-12-032-3/+14
| | | | | | | | | that still uses clientutil.c). passdb/passdb.c: Changed dos_mkdir to mkdir. Changed fchmod to chmod for some UNIX's that don't have fchmod. passdb/smbpass.c: Added test for uid with leading '-'. smbd/ipc.c: Added fix for invalid info level from Scott Moomaw <scott@bridgewater.edu>. Jeremy.
* Tidied up many string functions with const & size_t.Jeremy Allison1998-11-171-5/+5
| | | | Jeremy.
* Changed (most) open()/fopen()/creat()/mmap() calls to use sys_XXX() instead.Jeremy Allison1998-11-174-6/+6
| | | | | | 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.
* 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.
* Removed code that used printf/fprintf in password changin libraries.Herb Lewis1998-11-121-11/+18
| | | | Now passes strings instead.
* extracted the password change code from smbpasswd and used it in swatAndrew Tridgell1998-11-121-0/+162
| | | | instead of opening pipes and other horrible stuff.
* util functions split into relevant modules, first pass.Luke Leighton1998-11-101-43/+0
|
* codepages/codepage_def.936: Updated comment.Jeremy Allison1998-11-071-5/+3
| | | | | | | | | param/loadparm.c: Removed "networkstation user login", "domain controller", and "domain sid" parameters. passdb/passdb.c: Removed "networkstation user login" code and changed bug test code to only check once for a bad password server. This will stop the complaints of many "bad login" audit records in NT PDC logs. utils/smbpasswd.c: Removed check for "domain controller". Jeremy.
* the start of the start of the SAM database APILuke Leighton1998-11-052-0/+417
|
* domain aliases added a bit better: does local aliases if you queryLuke Leighton1998-10-211-5/+6
| | | | | for sid S-1-5-20 and does (nothing at the moment) if you query for your own sid.
* the next dialog: user-groups. it's not very sensible what appears, but hey:Luke Leighton1998-10-214-0/+40
| | | | it appears!
* Small tidyups for gcc in 'preen' mode....Jeremy Allison1998-10-172-0/+2
| | | | Jeremy.
* trust passwordLuke Leighton1998-10-161-2/+2
|
* rpcclient interactive login (with trust account changing if you are root)Luke Leighton1998-10-152-2/+38
| | | | cli_session_setup handles null sessions correctly
* getpwnam() failing is a serious error (corrupt smbpasswd database)Luke Leighton1998-10-151-1/+6
|
* bug-fixing against:Luke Leighton1998-10-151-0/+2
| | | | | | | | | | | | | | | | | | AS/U: it returns dce/rpc "first" and "last" bits _clear_ in a bind/ack response, when they should be set in a (small) packet. they also, in the bind/ack do not set a secondary address string at all, so we can't check against that... Win95: client-side dce/rpc code is a bit odd. it does a "WaitNamedPipeState" and has slightly different pipe-naming (\PIPE\LANMAN is joined by \PIPE\SRVSVC, \PIPE\WINREG etc whereas nt just has \PIPE\LANMAN and \PIPE\). Win95-USRMGR.EXE: added LsaOpenPolicy (renamed existing to LsaOpenPolicy2). added SamrConnect (renamed existing to SamrConnect2).
* anders blomdell spotted an unititialised fstring causing strlen to goLuke Leighton1998-10-091-0/+1
| | | | awry (ascii_p16)
* Fixed warning in get_time_from_string().Jeremy Allison1998-09-291-1/+1
| | | | Jeremy.
* missed the pdb_sam_to_smb function needed by nispass.cLuke Leighton1998-09-291-19/+22
|
* added in some pdb_xxx routines that are needed by nispass.cLuke Leighton1998-09-291-0/+121
|
* Added fix from gildea@intouchsys.com - smbpasswd file could be leftJeremy Allison1998-09-281-1/+5
| | | | | locked. 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.
* automated generation of .dummy files for each subdirectory;Alexandre Oliva1998-09-281-1/+0
| | | | | dummy.in files are no longer needed, and new directories will be taken care of automatically, at configure (or config.status --recheck) time
* Added Kerberos4 support patches from Johan Hedin <johanh@fusion.kth.se>Jeremy Allison1998-09-261-1/+3
| | | | Jeremy.
* Makefile.in: Fixed bug with continuation line causing proto to fail.Jeremy Allison1998-09-253-2/+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-244-71/+109
| | | | | | smbpasswd changes. Not exactly the same as his code - several changes. Jeremy.
* removed function names printed out in debug statements (duplicated inLuke Leighton1998-09-241-33/+37
| | | | DEBUG macro, automatically)
* major autoconf clean-upAlexandre Oliva1998-09-211-0/+1
| | | | fix problems in builds with srcdir!=builddir
* configure configure.in: Added checks for statvfs64. Last bit of 64 bit ↵Jeremy Allison1998-09-173-15/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | widening (I hope :-). include/config.h.in: Added #undef STAT_STATVFS64. include/includes.h: Added SMB_STRUCT_STATVFS type, Changed SMB_BIG_INTEGER to SMB_BIG_UINT and SMB_BIG_INT types. include/smb.h: Added flag defines from CIFS spec. lib/debug.c: Fixed one more mode_t issue. lib/system.c: Added sys_statvfs wrapper. lib/util.c: Changed trim_string to use size_t. param/loadparm.c: Moved "blocking locks" into locking section. Alphabetised locking options. Question - shuld we do this for all options ? passdb/ldap.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. passdb/nispass.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. passdb/smbpass.c: Changed SMB_BIG_INTEGER to SMB_BIG_UINT. smbd/dfree.c: Changed to use 64 bit types if available. Moved to use unsigned types. smbd/dosmode.c: Fixed one more mode_t issue. smbd/negprot.c: Changed literals to be FLAG_ #defines. smbd/nttrans.c: Removed dead code. smbd/open.c: Changed disk_free call. smbd/process.c: Changed literals to be FLAG_ #defines. smbd/reply.c: Changed disk_free call. smbd/trans2.c: Fixed but in SMB_QUERY_FS_VOLUME_INFO call. Was using UNICODE - should use ascii. tests/summary.c: Added STAT_STATVFS64 check. Jeremy.
* configure configure.in: Added tests for fseek64 and ftell64.Jeremy Allison1998-09-174-17/+17
| | | | | | | | | | | | | | | | | | | | | | | config.h.in: Added fseek64 and ftell64. includes.h: Added definition of SMB_BIG_INTEGER. smb.h: Changed (*getsmbpwpos) and (*setsmbpwpos) to use SMB_BIG_INTEGER. access.c: Tidyup of dbug statement. system.c: Added sys_fseek and sys_ftell. Changed mode calls to use mode_t. asyncdns.c: Tidyup of comment. loadparm.c: Tidyup of set_default_server_announce_type() function definition. ldap.c: Changed (*getsmbpwpos) and (*setsmbpwpos) to use SMB_BIG_INTEGER. nispass.c: Changed (*getsmbpwpos) and (*setsmbpwpos) to use SMB_BIG_INTEGER. smbpass.c: Changed (*getsmbpwpos) and (*setsmbpwpos) to use SMB_BIG_INTEGER. smbpassfile.c: Use sys_fseek(). chgpasswd.c: Tidyup of debug statement. dosmode.c: Changed mode calls to use mode_t. ipc.c: Removal of dead code. nttrans.c: Changed mode calls to use mode_t. open.c: Changed mode calls to use mode_t. pipes.c: Removal of dead code. reply.c: Removal of dead code. trans2.c: Removal of dead code. Changed mode calls to use mode_t. Jeremy.
* some cleanups to use ZERO_STRUCT() and friendsAndrew Tridgell1998-09-051-1/+1
|
* tridge the destroyer returns!Andrew Tridgell1998-09-052-246/+4
| | | | | | | | | | | | | | | | | | | | | | 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?
* More 64 bit stuff - now the fcntl locks are 64 bit clean.Jeremy Allison1998-09-041-2/+2
| | | | | | Nearly at the stage where I can expose the 64-bit-ness to the NT clients.... Jeremy.
* Ok - this is the 64 bit widening check in. It changes the configureJeremy Allison1998-09-032-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | to check for stat64 and friends, and then changes much of Samba to use the data type SMB_OFF_T for file size information. stat/fstat/lstat/lseek/ftruncate have now become sys_stat etc. to hide the 64 bit calls if needed. Note that this still does not expose 64 bit functionality to the client, as the changes to the reply_xxx smb's are not yet done. This code change should make these changes possible. Still to do before full 64 bit-ness to the client: fcntl lock code. statfs code widening of dev_t and ino_t (now possible due to SMB_DEV_T and SMB_OFF_T types being in place). Let me know if wierd things happen after this check-in and I'll fix them :-). Jeremy.
* More abstraction of file system data types, to move to a 64Jeremy Allison1998-09-011-2/+2
| | | | | | | | | | | | | | | | | | | | | bit file interface for the NT SMB's. Created a new define, SMB_STRUCT_STAT that currently is defined to be struct stat - this wil change to a user defined type containing 64 bit info when the correct wrappers are written for 64 bit stat(), fstat() and lstat() calls. Also changed all sys_xxxx() calls that were previously just wrappers to the same call prefixed by a dos_to_unix() call into dos_xxxx() calls. This makes it explicit when a pathname translation is being done, and when it is not. Now, all sys_xxx() calls are meant to be wrappers to mask OS differences, and not silently converting filenames on the fly. Jeremy.
* got rid of calls to update_protected_database(). It was causing coreAndrew Tridgell1998-08-291-37/+0
| | | | | dumps. It is gone until someone can tell us why its needed and what it does. (It was only used on OSF1 and core dumped there anyway!)
* moved connection_struct handling code into smbd/conn.c and changed itAndrew Tridgell1998-08-171-4/+4
| | | | to a linked list with bitmap format.
* use user instead of this_user to prevent global shadowingAndrew Tridgell1998-08-151-18/+18
|
* configure: Changes for extra headers.Jeremy Allison1998-08-152-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 is the bug change to using connection_struct* instead of cnum.Andrew Tridgell1998-08-141-2/+2
| | | | | | | | 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.
* split the system password checking routines out of smbd/password.c andAndrew Tridgell1998-08-101-0/+950
| | | | | into passdb/pass_check.c. This means SWAT no longer needs to link to smbd/password.c