summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixed incorrect last arg to safe_strcpy in new wildcard code.Jeremy Allison1998-05-201-1/+1
| | | | Jeremy.
* Minor tweak for wcard compatibility paranoia.Jeremy Allison1998-05-201-1/+1
| | | | Jeremy.
* Fixed Samba's wildcard algorithm to be *exactly* the sameJeremy Allison1998-05-201-1/+10
| | | | | | as NT. You do not want to know how this code works :-). Jeremy
* Fix to do NT wildcard matching.Jeremy Allison1998-05-191-2/+24
| | | | Jeremy.
* passdb.c: Fixed typo in coment.Jeremy Allison1998-05-194-44/+28
| | | | | | | | smb.h: Removed comments no longer valid. smbpass.c: Stopped dummy function from being prototyped. util.c: Fix for multibyte char problems with strlower, strupper and string_replace. Jeremy.
* made mod_smbfilepwd_entry() and getsmbfilepwent() static. they need notLuke Leighton1998-05-191-98/+97
| | | | be exposed.
* oops - got some of the default (conversion) functions wrong.Luke Leighton1998-05-192-35/+19
|
* removed "default" system for password database api: all functions mustLuke Leighton1998-05-196-196/+179
| | | | | | | be supported. there are some stub routines in passdb.c which can be copied into a password database api which do conversion. the module writer can choose which of these to provide full support for instead of using the conversion routines.
* ldap.c :Luke Leighton1998-05-198-132/+335
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - added support for some of the new passdb_ops functions. - removed functions that are supported "indirectly" through passdb.c nisppass.c : - modified make_nisname_from_xxx() functions to take a "file" arg. - turned getnisp21pwuid() into getnisp21pwrid(). getnisp21pwuid() functionality is available through "indirect" support in passdb.c - removed functions that are supported "indirectly" through passdb.c - added support for some of the new passdb_ops functions. passdb.c : - created getsam21pwrid() function to go alongside getsam21pwuid. it is not expected that getsam21pwuid ever be used, certainly not from the lib/rpc code. - created getsamdisprid() and getsamdispent(). these are primarily for support of SamrQueryDisplayInfo, however given that they [struct sam_disp_info] return username, rid and fullname, there may be further instances where these functions will be useful. - added support where either the get/add/mod-smb or get/add/mod-sam21 functions are optional. this can be done very easily by checking whether the struct passdb_ops table functions are NULL or not. documented this capability in the notes at the top of the module. - where unix uid was referenced, use uid_t. - where unix gid was referenced, use gid_t. smb.h : - added sam_disp_info functions to passdb_ops. - added getsam21pwrid() function. smbpass.c : - added reference to iterate_getsam21pwrid(). lib/rpc/server/srv_samr.c : - removed group rid code added to get_user_info_21() code: this had been added in the wrong place. the client / server should already know whether it wants to do a lookup by user rid or by group rid. the test of whether the rid is a user or group rid has been left in because this may become useful consistency-check code. - converted back to getsam21pwrid() not getsam21pwuid(pdb_user_rid_to_uid()). this is because the unix uid to user rid mapping can be non-monotonic in some password database systems, and monotonic in others. imposing the restriction by converting immediately from rid to uid at this point is inadviseable, and will place this potential restriction on _all_ password database systems, not just some which, for whatever reason, do not support user rids. it should be up to the individual password database writer to convert from user rid to unix uid, should that module not support rids. lib/rpc/server/srv_util.c : - got lookup_user_name() to call getsamdisprid() not getsmbpwuid(). a bug was introduced (or at least the bug already there was not fixed) whereby the nt user rid was converted to a unix uid, and then not used.
* Fixed signed/unsigned warning.Jeremy Allison1998-05-191-1/+1
| | | | Jeremy.
* Forgot to add the initialize_password_db() call to nmbd also.Jeremy Allison1998-05-191-0/+3
| | | | Jeremy.
* Abstracted all the crappy password interfaces through an indirectJeremy Allison1998-05-188-320/+328
| | | | | | | | function table, selectable at compile time. This should make the code that implements all the password functions much cleaner, as it's now very clear exactly what a particular password database needs to provide to Samba. Jeremy.
* chgpasswd.c: Changed back to getsmb... from getsam...Jeremy Allison1998-05-1817-393/+607
| | | | | | | | | | | | | | | | | | | | ldap.c: Stoped dummy_function being prototyped. loadparm.c: Fixed slprintf sizes. nisppass.c: Fixed safe_strcpy sizes. nmbd_processlogon.c: Changed back to getsmb... from getsam... nttrans.c: Just a dump of new code. passdb.c: Moved stuff around a lot - stopped any lookups by rid. This needs to be indirected through a function table (soon). password.c: Changed back to getsmb... from getsam... reply.c: Changed back to getsmb... from getsam... slprintf.c: Fixed prototype problems. smb.h: Fixed prototype problems. smbpass.c: Changed to getsmbfile.... smbpasswd.c: Changed back to getsmb... from getsam... lib/rpc/server/srv_netlog.c: Changed back to getsmb... from getsam... lib/rpc/server/srv_samr.c: Fixed rid lookup - use uid or gid lookup. lib/rpc/server/srv_util.c: Changed back to getsmb... from getsam... Jeremy.
* linker errors with -DUSE_NISPLUS_DB - difficult to spot when you're notLuke Leighton1998-05-182-4/+4
| | | | using nis+ on your system, so you get 100 linker errors...
* sorting out removal of some smb_passwd functions by calling pdb_smb_to_sam()Luke Leighton1998-05-181-10/+11
| | | | instead, for use by nisppass.c
* removed references to some of the smb_passwd routines from ldap and nis+Luke Leighton1998-05-183-117/+96
| | | | code, use pdb_sam_to_smb(...sam21...) calls instead. this is a lot simpler.
* creating and using some pdb_init_(sam/smb) routines. putting ldap headersLuke Leighton1998-05-184-25/+14
| | | | | back in (they had been taken out of includes.h because they are only local to ldap.c.
* no include headers in ldap.c.Luke Leighton1998-05-182-0/+72
| | | | passdb.c sam_passwd <-> smb_passwd conversion routines
* resolving compilation errorsLuke Leighton1998-05-185-5/+7
|
* received update from jean francois for ldap.c: he is doing add / modLuke Leighton1998-05-182-75/+434
| | | | functions
* - renamed some of the passdb.c functions: they have a prefix pdb_ on themLuke Leighton1998-05-187-304/+323
| | | | | - split smbpass.c "password file lock" routines into smbpassfile.c: moved trust account routines into smbpassfile.c as well
* oops. pressed ctrl-z while editing the previous cvs message: this wasLuke Leighton1998-05-181-19/+105
| | | | taken to mean ":x".
* Makefile:Luke Leighton1998-05-1810-183/+546
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - added nisppass.c and NISPLUS_FLAGS includes.h: - renamed USE_LDAP to USE_LDAP_DB. renamed NISPLUS to USE_NISPLUS_DB. added default define of USE_SMBPASS_DB. - removed ldap headers: they are local only to ldap.c ldap.c : - made all ldap-specific functions static. - added dummy sam21 functions loadparm.c : - renamed NISPLUS to NISPLUS_HOME mkproto.awk - commented out ldap-specific #ifdef generation code: it's not needed now that ldap-specific functions in ldap.c are static nisppass.c : - first attempt at an add function from
* Change getpwnam to Get_Pwnam(xx , True) to allow lazy matchingJeremy Allison1998-05-151-1/+1
| | | | | in /etc/passwd. Fix from "Mike Black" <mblack@csihq.com>. Jeremy.
* Fix from "Gerald W. Carter" <cartegw@eng.auburn.edu>, we wereJeremy Allison1998-05-151-1/+1
| | | | | copying from a parameter into an unitialized variable (doh !). Jeremy.
* some databases have search capabilities. acknowledging this in designLuke Leighton1998-05-151-19/+60
| | | | of passdb.c api.
* first non-compiling, unused, mostly stub version of NIS+ password database.Luke Leighton1998-05-151-0/+330
| | | | based on Benny Holmgren's samba patch (copyright acknowledged).
* adding copyright messages for Benny HolmgrenLuke Leighton1998-05-152-0/+4
|
* two scripts from benny holmgren which a) create NIS+ table b) populate itLuke Leighton1998-05-152-0/+69
| | | | from private/smbpasswd.
* util.c: Re-seed the crypto random number generator after a fork, so allJeremy Allison1998-05-151-0/+10
| | | | | smbds started from the same parent won't use the same sequence. Jeremy.
* passdb.cJeremy Allison1998-05-145-191/+210
| | | | | | | | | | server.c: Moved generate_machine_sid() into passdb.c for Jean-Francois (who might want an LDAP version). Changed locking to free exclusive lock as soon as possible to prevent contention. lib/rpc/parse/parse_samr.c lib/rpc/server/srv_samr.c: Changed last SID-as-string manipulation function to use DOM_SID structure. Jeremy.
* sync with 1.9.18 branch (clean up comments)Herb Lewis1998-05-141-19/+21
|
* some pretty horrible formatting in standard_sub_basic(): makes the functionLuke Leighton1998-05-141-48/+56
| | | | unreadable and unmaintainable
* robert frank - some Next3 compilation errors detected.Luke Leighton1998-05-141-1/+1
|
* Fixed dce/rpc to use global_machine_sid (auto generated in server.c ifJeremy Allison1998-05-144-24/+13
| | | | | not present in smb.conf). Jeremy.
* namequery.c: Fixed SGI IRIX 5.x compiler problem.Jeremy Allison1998-05-144-7/+199
| | | | | | server.c: Added MACHINE.SID file generation - use lp_domain_sid() be default. smbpass.c: Exposed do_file_lock() as I now use it in server.c Jeremy.
* chgpasswd.c: Added comments to #ifdefsJeremy Allison1998-05-1417-427/+491
| | | | | | | | | | | | | | | | | | | | | ipc.c: Caused samba password changing not to be done if UNIX password changing requested and not successful. util.c: Added string_to_sid() and sid_to_string() functions. lib/rpc/client/cli_samr.c: lib/rpc/include/rpc_misc.h: lib/rpc/parse/parse_lsa.c: lib/rpc/parse/parse_misc.c: lib/rpc/parse/parse_net.c: lib/rpc/parse/parse_samr.c: lib/rpc/server/srv_lsa.c: lib/rpc/server/srv_lsa_hnd.c: lib/rpc/server/srv_netlog.c: lib/rpc/server/srv_samr.c: lib/rpc/server/srv_util.c: Changes so that instead of passing SIDs around as char *, they are converted to DOM_SID at the earliest opportunity, and passed around as that. Also added dynamic memory allocation of group sids. Preparing to auto-generate machine sid. Jeremy.
* Fixed up HPUX entry.Jeremy Allison1998-05-131-2/+4
| | | | Jeremy.
* initialise some variables (stops warning)Andrew Tridgell1998-05-131-2/+2
|
* test for overflow in nmb name parsing codeAndrew Tridgell1998-05-131-1/+1
|
* initialise a variableAndrew Tridgell1998-05-131-1/+1
|
* we don't need a typedef for stringAndrew Tridgell1998-05-131-2/+0
|
* includes.h: SunOS doesn't have strcasecmp, solaris versions prior to 2.6 don'tJeremy Allison1998-05-127-75/+15
| | | | | | | | | | have vsnprintf. locking_slow.c: slight tidy. make_smbcodepage.c: Use safe_strcpy instead of pstrcpy. nmbd_winsserver.c: Use pstrcpy instead of fstrcpy. smbmount.c: Fixed reported bug. util.c: Removed old fstrcpy/fstrcat functions. Jeremy.
* - removed ldap_get_trust()Luke Leighton1998-05-121-101/+74
| | | | - #ifdef around putting 16 byte hashes instead of plaintext password.
* function comments wrongLuke Leighton1998-05-121-2/+2
|
* removed lp_domain_workstation() parameterLuke Leighton1998-05-123-10/+1
|
* retired this file: it's not actually needed now that passdb.c providesLuke Leighton1998-05-121-152/+0
| | | | the interface point.
* a new slprintf() function. This one is totally portable but a bit of aAndrew Tridgell1998-05-121-27/+41
| | | | | | | | | | | | | | | | | | kludge. It is a safe kludge with our current code but I would like to revisit it at some point in the future. The problem with the one I committed yesterday is it used non-portable functions. (it also had a bug in it, but that's another matter) This one works by just using vsprintf() into a 8k buffer and a memcpy from there. No memory protection tricks or other non-portable stuff. This is safe because all calls to slprintf() in samba use strings which have been through a pstrcpy and thus are less than 1024 bytes. No call uses more than 2 of these strings. See what I mean by kludge? Note that the 8k is way overkill but I like overkill :) Someday (after autoconf) we will replace this with something better, but meanwhile this is simple, secure and portable.
* This is a security audit change of the main source.Jeremy Allison1998-05-1268-787/+887
| | | | | | | | | | | | | | | | | | It removed all ocurrences of the following functions : sprintf strcpy strcat The replacements are slprintf, safe_strcpy and safe_strcat. It should not be possible to use code in Samba that uses sprintf, strcpy or strcat, only the safe_equivalents. Once Andrew has fixed the slprintf implementation then this code will be moved back to the 1.9.18 code stream. Jeremy.
* password back-end database supportLuke Leighton1998-05-114-118/+168
| | | | | | | | | | | | | | | | | | | | | ldap.c : - added getldap21pwent() function passdb.c : - getsam21pwent() no longer a stub: calls ldap21 or smb21 smbpass.c : - added getsmb21pwent() function (he he :-) lib/rpc/server/srv_samr.c : - removed "specific" calls to ldap functions; replaced with call to get_sampwd_entries instead (which is unfinished). - rewrote get_user_info_21 function to call getsam21pwrid.