summaryrefslogtreecommitdiffstats
path: root/source/nsswitch/wb_client.c
Commit message (Collapse)AuthorAgeFilesLines
* Cleanup of winbind client side code.Tim Potter2003-03-311-1/+1
| | | | | | | Mostly this consists of untangling the existing code and moving it in to operating system specific files. The winbind client code for all supported operating systems is now in nsswitch/winbind_nss_OSNAME.[ch] to make things a bit clearer.
* Check return code from string_to_sid.Martin Pool2003-02-181-3/+6
|
* Add some more const :-)Andrew Bartlett2002-08-071-3/+3
| | | | | | | This also makes it a easier to see which paramaters are 'in', and which are 'out'. Andrew Bartlett
* more debug classess activatedSimo Sorce2002-06-181-0/+1
|
* Remove "sids.h" as it really wasn't being used anywhere, and was exportingAndrew Bartlett2002-06-101-0/+1
| | | | | | | | | the (now static) global_sam_sid. The only place it was being used was to return global_sid_NULL to some uid->sid functions - and I'm not convinced this is correct in any case. Andrew Bartlett
* debug classizedSimo Sorce2002-05-211-0/+3
|
* Removed version number from file header.Tim Potter2002-01-301-2/+1
| | | | Changed "SMB/Netbios" to "SMB/CIFS" in file header.
* Some more 'winbind default domain' support patches from Alexander BokovoyAndrew Bartlett2002-01-271-81/+1
| | | | | | | | | | | <a.bokovoy@sam-solutions.net>. This patch is designed to remove the 'special cases' required for this support. In particular this now kills off winbind_initgroups, as it appears no longer to be required. Andrew Bartlett
* Change the winbind interface to use seperate 'domain' and 'username' feilds forAndrew Bartlett2002-01-261-131/+7
| | | | | | | | | the sid->uid and uid->sid conversions. Remove some duplicate arguments from these funcitons, and update the request/response structures for this and the 'winbind domain name' feature. As such 'winbindd_lookup_name' now takes both a domain and username.
* This is the 'winbind default domain' patch from Alexander BokovoyAndrew Bartlett2002-01-181-19/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | <a.bokovoy@sam-solutions.net>. The idea is the domain\username is rather harsh for unix systems - people don't expect to have to FTP, SSH and (in particular) e-mail with a username like that. This 'corrects' that - but is not without its own problems. As you can see from the changes to files like username.c and wb_client.c (smbd's winbind client code) a lot of assumptions are made in a lot of places about lp_winbind_seperator determining a users's status as a domain or local user. The main change I will shortly be making is to investigate and kill off winbind_initgroups() - as far as I know it was a workaround for an old bug in winbind itself (and a bug in RH 5.2) and should no longer be relevent. I am also going to move to using the 'winbind uid' and 'winbind gid' paramaters to determine a user/groups's 'local' status, rather than the presence of the seperator. As such, this functionality is recommended for servers providing unix services, but is currently less than optimal for windows clients. (TODO: remove all references to lp_winbind_seperator() and lp_winbind_use_default_domain() from smbd) Andrew Bartlett
* make sure we find NSS_STATUS structAndrew Tridgell2001-12-131-0/+1
|
* Fixed parse_domain_user to be bool.Jeremy Allison2001-12-051-11/+9
| | | | Jeremy.
* added name_to_sid to the backendAndrew Tridgell2001-12-031-1/+1
|
* Fix winbind client code so that winbind calls are not made if theJeremy Allison2001-11-131-15/+22
| | | | | | | requested name does not have a winbind separator character. This makes the intent explicit. Tim, contact me if this is not what you indended. Jeremy.
* This commit is number 4 of 4.Andrew Bartlett2001-10-291-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In particular this commit focuses on: Actually adding the 'const' to the passdb interface, and the flow-on changes. Also kill off the 'disp_info' stuff, as its no longer used. While these changes have been mildly tested, and are pretty small, any assistance in this is appreciated. ---- These changes introduces a large dose of 'const' to the Samba tree. There are a number of good reasons to do this: - I want to allow the SAM_ACCOUNT structure to move from wasteful pstrings and fstrings to allocated strings. We can't do that if people are modifying these outputs, as they may well make assumptions about getting pstrings and fstrings - I want --with-pam_smbpass to compile with a slightly sane volume of warnings, currently its pretty bad, even in 2.2 where is compiles at all. - Tridge assures me that he no longer opposes 'const religion' based on the ability to #define const the problem away. - Changed Get_Pwnam(x,y) into two variants (so that the const parameter can work correctly): - Get_Pwnam(const x) and Get_Pwnam_Modify(x). - Reworked smbd/chgpasswd.c to work with these mods, passing around a 'struct passwd' rather than the modified username --- This finishes this line of commits off, your tree should now compile again :-) Andrew Bartlett
* move to SAFE_FREE()Simo Sorce2001-09-171-2/+2
|
* get rid of compiler warningsHerb Lewis2001-08-241-2/+3
|
* More Realloc fixes.Jeremy Allison2001-08-181-1/+1
| | | | Jeremy.
* Fixed up 'orrible formatting.Tim Potter2001-08-131-21/+21
|
* this is a big global fix for the ptr = Realloc(ptr, size) bug.Simo Sorce2001-08-121-3/+4
| | | | | | many possible mem leaks, and segfaults fixed. someone should port this fix to 2.2 also.
* the nss and pam modules in winbind don't have strchr_m() yet, so useAndrew Tridgell2001-07-181-3/+3
| | | | strchr() for the moment
* strchr and strrchr are macros when compiling with optimisation in gcc, so we ↵Andrew Tridgell2001-07-041-3/+3
| | | | can't redefine them. damn.
* Fixed bug in winbind_sid_to_gid() function.Tim Potter2001-06-071-1/+1
|
* Indent dodgy function prototype to avoid make proto picking it up andTim Potter2001-06-061-1/+1
| | | | causing mayhem throughout the tree.
* More compile fixups for winbind portability.Tim Potter2001-06-041-2/+6
|
* Preliminary merge of winbind into HEAD. Note that this compiles and linksTim Potter2001-05-071-0/+22
| | | | but I haven't actually run it yet so it probably doesn't work. (-:
* Fix for crash when doing name lookup with a quoted string. Part ofJeremy Allison2001-03-201-1/+1
| | | | | | lookup_name was expecting to be able to write to the string. Changed lookup_name to use const. Jeremy.
* Changes from APPLIANCE_HEAD:David O'Neill2001-01-151-2/+9
| | | | | | | | | | | | | | | | | | | | | source/rpc_parse/parse_lsa.c - off by one unistr length bug in init_lsa_trans_name() source/lib/util_sid.c - resolve more BUILTIN sid values to names. source/nsswitch/wb_client.c - fix typo in debug message - set errno on error so we don't get bogus value from last failure. source/rpc_server/srv_spoolss_nt.c - add debug to track number of open printer handles for ease of tracking handle leaks in the future. source/rpc_server/srv_lsa.c - fix off-by-one string bug. This was preventing NT from displaying names for well-know SIDs in printer permissions dialog.
* Changes from APPLIANCE_HEAD:David O'Neill2001-01-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | source/Makefile.in - changes to ctags and etags rules that somehow got lost along the way. source/include/proto.h - make proto source/smbd/sec_ctx.c source/smbd/password.c - merge debugs for debugging user groups and NT token stuff. source/lib/util_str.c - capitalise domain name returned from parse_domain_user() source/nsswitch/wb_client.c - fix broken conditional in debug statement. source/include/rpc_secdes.h source/include/rpc_spoolss.h source/printing/nt_printing.c source/lib/util_seaccess.c - fix printer permission bugs related to ACE masks for printers. This adds mapping of generic access rights to object specific rights for NT printers. Still need to work out whether or not to ignore ACEs with certain flags set, though. See comments in util_seaccess.c:check_ace() for details. source/printing/nt_printing.c source/printing/printing.c - use PRINTER_ACCESS_ADMINISTER instead of JOB_ACCESS_ADMINISTER until we sort out printer/printjob permission stuff.
* Fix for uidtoname not returning DOMAIN\name but just name. This causedJeremy Allison2000-10-251-2/+9
| | | | | printer_access_check to break in a domain environment. Jeremy.
* Fix to allow smbd to call winbindd if it is running for all group enumeration,Jeremy Allison2000-10-131-196/+51
| | | | | | | | falling back to the UNIX calls on error. This should fix all problems with smbd enumerating all users in all groups in all trusted domains via winbindd. Also changed GETDC to query 1C name rather than 1b name as only the PDC registers 1b. Jeremy.
* Use sys_setgroups - systems with broken getgroups need this.Jeremy Allison2000-10-111-1/+1
| | | | Jeremy.
* Renamed WINBINDD_INITGROUPS constant to WINBINDD_GETGROUPS.Tim Potter2000-10-111-1/+1
|
* Modified initgroups to provide a get groups a user is a member ofTim Potter2000-10-111-6/+132
| | | | | | functionality. This is much faster than inverting the group database. Added client side command for this to wbinfo.
* Added debug so we can see how winbindd converts SIDS.Jeremy Allison2000-10-101-13/+40
| | | | Jeremy.
* Spelling flames. (-:Tim Potter2000-10-051-6/+6
|
* Fixed compiler warnings.Tim Potter2000-10-051-4/+6
|
* Fix from John Reilly @ HP for my typo with the parameters being reversed. Ooops.Jeremy Allison2000-09-011-3/+3
| | | | Jeremy.
* Added code to do SID to uid/gid conversion. Needed for ACL support.Jeremy Allison2000-08-231-10/+178
| | | | Jeremy.
* Started to canonicalize our handling of uid -> sid code in order toJeremy Allison2000-08-021-23/+83
| | | | | | | | | | | | | | | | | | | | | | | | | get ready and fix se_access_check(). Added cannonical lookup_name(), lookup_sid(), uid_to_sid(), gid_to_sid() functions that look via winbind first the fall back on local lookup. All Samba should use these rather than trying to call winbindd code directly. Added NT_USER_TOKEN struct in user_struct, contains list of NT sids associated with this user. se_access_check() should use this (cached) value rather than attempting to do the same thing itself when given a uid/gid pair. More work needs to be done to preserve these things accross security context changes (especially with the tricky pipe problem) but I'm beginning to see how this will be done..... probably by registering a new vuid for an authenticated RPC pipe and not treating the pipe calls specially. More thoughts needed - but we're almost there... Jeremy.
* Add local fallback for name lookup if no winbindd running...Jeremy Allison2000-07-111-9/+20
| | | | Jeremy.
* Moved winbind client functions from various odd locations toTim Potter2000-07-101-0/+174
nsswitch/wb_client.c Merge of nsswitch/common.c rename to nsswitch/wb_common.c from TNG.