summaryrefslogtreecommitdiff
path: root/source3/rpc_server
AgeCommit message (Collapse)AuthorFilesLines
1999-02-11UNICODE issues.Luke Leighton1-3/+3
(This used to be commit 6a437cfb33f24913e0c1f8484c0b08ef317e513b)
1999-02-10use jeremy's versions of the UNICODE routines.Luke Leighton1-3/+3
(This used to be commit c5109ff782be8774db47a92b48ca6335ec8d6065)
1999-02-09Having Well-known Domain Groups ("Domain Admins/Guests/Users") returnedLuke Leighton1-1/+1
under SID_NAME_ENUM 0x5 instead of 0x2 (Well-known group instead of Domain Group) was making it impossible to view these groups from USRMGR.EXE. (This used to be commit 3072044134eadbf46350b32c1ed0703681b0d590)
1999-02-09groups and aliases being "manually" added which do not necessarily haveLuke Leighton1-45/+7
representation in the underlying database: removed this code. for example, with the nt->unix mapping system (don't know about the ldap one) if you want "Domain Admins" to appear you _must_ put it in the domaingroup.map file. the previous code was adding builtin aliases and well-known groups even if they weren't in the domain maps. bad idea. (This used to be commit 56469578a1af0fbcf6edddf94c498c7bbfb385c6)
1999-02-09when multiple independent large rpc calls come in on the same pipe,Luke Leighton1-5/+2
prev_pdu_file_offset was not being re-initialised to zero. (This used to be commit fcaa1214412f5a417a648d4da5c4332f75f59f57)
1999-02-09removal of the use of unistrn2 function: replace it with unistr2_to_strLuke Leighton2-5/+4
which is more appropriate. (This used to be commit ac72fe1ab3d10f64a5945ccbd4ed3817e30f9f7b)
1999-02-09pwdb_smb_to_sam was not returning NULL for nt name so thatLuke Leighton1-5/+5
pwdb_sam_map_names() was using a "blank" static string instead of a NULL pointer for nt names. NULL means over-ride, so the nt name got left as "blank". this causes nt clients to terminate with extreme prejudice. (This used to be commit ddd350198202d6a1d2c715b3dce7db3a5d76a63a)
1999-02-09Fix for NT BSOD problem. There's no reason to have two "NT usernames" runningMatthew Chapman1-3/+1
around anyway. The real problem is, once again, the brokenness of pwdb_sam_map_names et al. This time it is deciding to return blank NT usernames, which NT's redirector objects to. I'm currently working on improving the pwdb/mapping code, should be ready in a couple of weeks. (This used to be commit 30a085bf80982c619cd78aee9ad410ece5f88679)
1999-02-08UNICODE byte ordering issue: typecast to uint16* replaced with SSVAL()Luke Leighton1-3/+3
(This used to be commit 9084b7e33dfe717bd8d5604ee71d137e3baef0f5)
1999-02-03corrections to get data stream for 2nd and subsequent pdus copied fromLuke Leighton2-22/+19
right place (forgot to subtract 0x18 header bytes) (This used to be commit 5b9a7278da4a25ea217f914c8daae31238fa5cfe)
1999-02-03cache unix groups so that two-level getgrent calls don't occur.Luke Leighton1-1/+1
(This used to be commit f7dfa55a2e191ae780d399026bce48f68cda4bf0)
1999-02-03multiple dce/rpc PDUs failed to work after ntlmssp update was added.Luke Leighton2-32/+23
(This used to be commit f082f07e764c04b75b6880f852b80faec86f1b1c)
1999-02-02server type announcements modified to include the "role" of the server:Luke Leighton1-6/+11
domain member, pdc, bdc. (This used to be commit d95bb252f838b3612f5eba5d2b61d7b38b01f5ef)
1999-01-29fix for enumerate domain users (bug spotted by sean matthews).Luke Leighton1-3/+7
also needed to use start index properly and generate next index. both client and server code need to recognise error code 0x105 when there's not enough room to store all the users in one call. sort this out another time. (This used to be commit ad58cdfac6b85d9431216e32e532ad4d60f9c6dd)
1999-01-29uni_svc_name not uni_srv_nameLuke Leighton1-1/+1
(This used to be commit 14080a564a24f8f35cb8711b912c46f7243cd723)
1999-01-28error code cleanupLuke Leighton1-27/+27
(This used to be commit 61c40982d6fde34729dc6850cf3372482392f4c9)
1999-01-15Fixed typo in srv_samr.c where samr_add_groupmem and samr_del_groupmem wereMatthew Chapman1-4/+4
the wrong way around. (This used to be commit 2b6f4818858d422399321064245a36be1dba9738)
1998-12-20fix for potential lsass.exe crashing due to negative response fromLuke Leighton1-1/+1
LsaLookupNames being incorrect. this is a bit wierd: why would the lsass.exe on the nt _client_ crash due to an LsaLookupNames response from a samba _server_? (This used to be commit a15a3f95f2a14ab164ca758e2145444a803190b2)
1998-12-14added sid_name_use array argument to lsa_lookup_names and lsa_lookup_sids.Luke Leighton1-1/+1
(This used to be commit 0b2095e092d747f741e78a3349f0b81a72811629)
1998-12-09adding svcctl parsing codeLuke Leighton1-9/+67
(This used to be commit c6f2f58c74cd79d84ec4a7802882da07a9af80d4)
1998-12-09adding some enumerate services code, client and server.Luke Leighton1-0/+114
(This used to be commit dacf5b152bf74cc3ee9a816911384a5eb0e77afa)
1998-12-08adding "Service Control Manager" commands to rpcclient.Luke Leighton1-14/+14
(This used to be commit e5ee965f8d8452ab694bc5d88e474c4b91dce5b0)
1998-12-08adding srvsvc pipe.Luke Leighton3-2/+157
(This used to be commit d06d6369942828ec89e90f99bd0d0d3f91d61d13)
1998-12-07- lib/unix_sec_ctxt.cLuke Leighton3-187/+722
attempt at taking lib/uid.c and getting a unix security context change module that is independent of "cnums" and "snums". a security context is needed for pipes, not just IPC$ or other services. - group database API added add_group/alias_member, del_group/alias_member, del_group/alias_entry functions. del_builtin_entry() is deliberately set to NULL to cause an exception, you cannot delete builtin aliases. - parse_lsa.c srv_lsa.c fixed lookup_names code, it was a load of trash and didn't do anything. - cmd_samr.c rpcclient.c srv_samr.c added "deletegroup", "deletealias", "delaliasmem", "delgroupmem", "addgroupmem", "addaliasmem", "createalias", "creategroup", to both client and server code. server code calls into unix stubs right now, which don't actually do anything. the only instance where they are expected to do anything is in appliance mode NOT even in the ldap code or anything. client code modified to call samr_lookup_names() for group code (because we can) and lsa_lookup_names() for alias code (because we have to). - srv_lookup.c oops, lookup on unsplit name, we got lookup on DOMAIN, DOMAIN\name instead of DOMAIN, name. (This used to be commit b8175702ef61b8b37b078f38e81452c00a5e2986)
1998-12-04- oops, i got "add alias member" and "delete alias member" swapped.Luke Leighton1-3/+2
- samr_enum_dom_users, the first 4 bytes is some sort of garbage, nt5-beta2 clears them out to zeros whereas nt4 does not. fixed bug where we were assuming that the first 4 bytes of a response _had_ to be non-zero. - cli_lsarpc.c: forgot to append the rid on the lsa_lookup_names() client call. - added in "addaliasmem" and "addgroupmem" commands. the addaliasmem command actually turned out to be a "delaliasmem" :-) :-) - parse_lsa.c: moved assert array check to after the size of useable array space is set... (This used to be commit 165b15a8cacc4bc7cf8cc0b9aaabb6b92cef7fdb)
1998-12-04- renamed do_samr_xxx to samr_xxxLuke Leighton1-20/+20
- renamed do_lsa_xxx to lsa_xxx - added "enumgroups [-m]" command, enumerates groups, shows members. - added cmd_sam_add_groupmem(), need to call these in rpcclient.c - added cmd_sam_add_aliasmem(), need to call these in rpcclient.c - modified "enumaliases [-m]" command - improved "enumgroups" and "enumaliases" to display names not just RIDS/SIDs. - renamed "samr_unknown_12" to "samr_lookup_rids". - added the following client-side functions: get_samr_query_groupmem() get_samr_query_aliasmem() get_samr_query_groupinfo() samr_enum_dom_groups() samr_enum_dom_aliases() samr_add_aliasmem() samr_add_groupmem() - improved display output (display.c) (This used to be commit eacc5e581af2b4de24186b9be3238b352c54effe)
1998-12-03added createalias command to rpcclientLuke Leighton1-1/+1
(This used to be commit 4771d5451b49375cc2fd4246d7d746b0d03cd5ba)
1998-12-03create domain group command (creategroup) added to rpcclient.Luke Leighton1-2/+2
renamed do_samr_xxxx to samr_xxxx. (This used to be commit 1e5d81c154740349a2cda4c1892b33a21c0683a8)
1998-12-02added rid and sid_name_use to DOMAIN_GRP_MEMBER, for use in group memberLuke Leighton1-8/+10
query. domain groups now work, hurrah! only thing is that the description is one character long, don't know why (which is wierd in itself). (This used to be commit 78a86c64960a7823b0db8b7bebfffabb4a5ba864)
1998-12-02issues spotted by andrej: %s\\%s not %s\%sLuke Leighton1-1/+1
(This used to be commit 779a7aa30d4b8a3c8ca1d817a3fd9886c0437def)
1998-12-02adding group member code, made a start. found that the group members'Luke Leighton1-0/+235
rid is needed not the name (see DOMAIN_GRP_MEMBER) decided to go home. (This used to be commit 9337049dfc98becfa74522d418dae64a97c7a304)
1998-12-01query_aliasmem code. it works (hurrah).Luke Leighton1-5/+9
(This used to be commit f7f2516df46dde1671235f788f7689c93d9395ae)
1998-12-01rpc_samr.h parse_samr.c srv_samr.c :Luke Leighton1-4/+114
samr_query_aliasmembers (cool!) util_pwdb.c sids.c nmbd.c server.c smbpasswd.c swat.c : pwdb_initialise(BOOL is_server) now creates / reads DOMAIN_NAME.SID if is_server is True, and does LsaQueryInfoPolicy(levels 3 and 5) to obtain member and pdc sids. (This used to be commit 3e1eb4f26b67e484b05e1dde94fd4e4dae982631)
1998-12-01adding some samr parsing calls (group / alias adding / deleting)Luke Leighton1-7/+12
added code that moves MACHINE.SID to DOMAIN_NAME.SID if it exists. (This used to be commit 51c1c31768a92d9c57ee6c09b78419bcbc544f03)
1998-11-30attempting to fix "domain user map" up, but it's a bit complicated.Luke Leighton1-19/+62
i may simply go for a response in the NetSamLogon returning the unix username, forcing the NT user to appear to be a unix user, however even that is fraught with implications. might just have to go the whole hog and do this tuple thing, "unix_name + nt_name" always associated together... issue with api_net_sam_logon, getsam21pwent() being called twice, the second time overwriting static buffer data (argh) so had to make a copy. noticed a nested "become_root()"/"unbecome_root()" which will have to be tracked down... (This used to be commit 474f94f419a531e33b475249da7efb99ac22f454)
1998-11-30- adding builtin[alias]db.Luke Leighton2-12/+18
- lib/sids.c: generate_sam_sid() modified to take a domain name: it now generates "DOMAIN_NAME.SID". reasons: 1) if you run multiple samba servers on the same machine under different netbios names as members of a domain, they won't all use the same SID, which is a _big_ mistake but it would happen _by default_. 2) we have (had) a problem with sid_to_string() and string_to_sid() which cause SIDs to be incorrectly read. one of the major reasons for *NOT* making this change was so as not to disrupt existing users. but as they will be anyway by this bug, we might as well go ahead. - passdb/smbpass.c: wanted to change the meaning of the name in the smbpasswd file to an "nt" name not a "unix" name. this is probably not a good idea: reverted this. - output formatting / bug-fixing in rpcclient query_useraliases code. (This used to be commit e4930f5f48f8246ceec8add8bf769954a963190c)
1998-11-29"retired" two modules to preserve their cvs history.Luke Leighton1-520/+1
added their replacements, added sam password database API modules (This used to be commit b1d1c1337c69c6f6bf25ab932a1a6a757e3ea2ae)
1998-11-29weekend work. user / group database API.Luke Leighton3-394/+152
- split sam_passwd and smb_passwd into separate higher-order function tables - renamed struct smb_passwd's "smb_user" to "unix_user". added "nt_user" plus user_rid, and added a "wrap" function in both sam_passwd and smb_passwd password databases to fill in the blank entries that are not obtained from whatever password database API instance is being used. NOTE: whenever a struct smb_passwd or struct sam_passwd is used, it MUST be initialised with pwdb_sam_init() or pwd_smb_init(), see chgpasswd.c for the only example outside of the password database APIs i could find. - added query_useraliases code to rpcclient. - dealt with some nasty interdependencies involving non-smbd programs and the password database API. this is still not satisfactorily resolved completelely, but it's the best i can do for now. - #ifdef'd out some password database options so that people don't mistakenly set them unless they recompile to _use_ those options. lots of debugging done, it's still not finished. the unix/NT uid/gid and user-rid/group-rid issues are better, but not perfect. the "BUILTIN" domain is still missing: users cannot be added to "BUILTIN" groups yet, as we only have an "alias" db API and a "group" db API but not "builtin-alias" db API... (This used to be commit 5d5d7e4de7d1514ab87b07ede629de8aa00519a1)
1998-11-25yeehaah got users to be included in S-1-5-xxx-yyy-zzz's local groups.Luke Leighton1-19/+19
now need search capability on S-1-5-20, which will need argh, a "group database API" on S-1-5-20, and the ability to add BUILTIN\Admins etc to "local group map" argh. (This used to be commit a24f6eb00ba7486479cbcf7fadf5456521c56179)
1998-11-25fixing group database issuesLuke Leighton2-12/+16
(This used to be commit 591c63e3e1e3201ddcd7582585b652fb848d80ca)
1998-11-25Makefile.in: Added maintainer mode fixes.Jeremy Allison2-5/+3
aclocal.m4: Added AC_LIBTESTFUNC. configure.in: Fixed -lsecurity -lsec problems. client.c: dos_ fixes. groupdb/aliasunix.c: Dead code removal. include/includes.h: Added default PRINTCAP_NAME. lib/genrand.c: dos_ fixes. lib/replace.c: Added strtoul. lib/system.c: dos_ fixes. lib/util.c: dos_ fixes. lib/util_sid.c: Signed/unsigned fixes. lib/util_str.c: removed bad const. locking/locking_slow.c: dos_ fixes. printing/printing.c: dos_ fixes. rpc_server/srv_samr.c: Dead code removal. rpc_server/srv_sid.c: global_myworkgroup defined with wrong size AGAIN ! smbd/dir.c: dos_ fixes. smbd/open.c: dos_ fixes. smbd/oplock.c: dos_ fixes. smbd/reply.c smbd/server.c smbd/service.c smbd/uid.c: dos_ fixes. Jeremy. (This used to be commit 6acb4b68f68d516e2ac3c47e500f5600d653435e)
1998-11-25LsaLookupNames client call (first used as lookupnames command in rpcclient).Luke Leighton2-16/+22
(This used to be commit 68342a29a892e515cf2b22d759476d61944bcd59)
1998-11-25fixing domain join and domain login problemsLuke Leighton2-5/+20
(This used to be commit 90a24664318da97a6e8cfe4622a8573c0e3cbe5e)
1998-11-23uninitialised counterLuke Leighton1-1/+1
(This used to be commit 403f53d696d17f34dd1afc035a72eda792dd20ea)
1998-11-23unix instance of group database APILuke Leighton4-218/+263
(This used to be commit e76f593b3572ac881f1aa1fb3326d8b7169b0078)
1998-11-17Added the same open()/fopen()/creat()/mmap() -> sys_XXX calls.Jeremy Allison2-6/+4
Tidied up some of the mess (no other word for it). Still doesn't compile cleanly. There are calls with incorrect parameters that don't seem to be doing the right thing. This code still needs surgery :-(. Jeremy. (This used to be commit 18ff93a9abbf68ee8c59c0af3e57c63e4a015dac)
1998-11-17lookup_alias_name() %s not %d for sid_strLuke Leighton1-1/+1
(This used to be commit 2a98135bbc759ab334d76cce98ea673871445db1)
1998-11-17somehow this file got missed in the groupdb commit.Luke Leighton1-35/+88
(This used to be commit 06da8e49f1cf5d6b954f586f6720ade1c5b8de74)
1998-11-17make_uni_hdr() reverted accidentally with a -1 on username lengthLuke Leighton1-2/+2
(This used to be commit 7da1b0bb511e6c5e44ab83759914134cf91f6f78)
1998-11-17- group database API. oops and oh dear, the threat has been carried out:Luke Leighton5-738/+538
the pre-alpha "domain group" etc parameters have disappeared. - interactive debug detection - re-added mem_man (andrew's memory management, detects memory corruption) - american spellings of "initialise" replaced with english spelling of "initialise". - started on "lookup_name()" and "lookup_sid()" functions. proper ones. - moved lots of functions around. created some modules of commonly used code. e.g the password file locking code, which is used in groupfile.c and aliasfile.c and smbpass.c - moved RID_TYPE_MASK up another bit. this is really unfortunate, but there is no other "fast" way to identify users from groups from aliases. i do not believe that this code saves us anything (the multipliers) and puts us at a disadvantage (reduces the useable rid space). the designers of NT aren't silly: if they can get away with a user- interface-speed LsaLookupNames / LsaLookupSids, then so can we. i spoke with isaac at the cifs conference, the only time for example that they do a security context check is on file create. certainly not on individual file reads / writes, which would drastically hit their performance and ours, too. - renamed myworkgroup to global_sam_name, amongst other things, when used in the rpc code. there is also a global_member_name, as we are always responsible for a SAM database, the scope of which is limited by the role of the machine (e.g if a member of a workgroup, your SAM is for _local_ logins only, and its name is the name of your server. you even still have a SID. see LsaQueryInfoPolicy, levels 3 and 5). - updated functionality of groupname.c to be able to cope with names like DOMAIN\group and SERVER\alias. used this code to be able to do aliases as well as groups. this code may actually be better off being used in username mapping, too. - created a connect to serverlist function in clientgen.c and used it in password.c - initialisation in server.c depends on the role of the server. well, it does now. - rpctorture. smbtorture. EXERCISE EXTREME CAUTION. (This used to be commit 0d21e1e6090b933f396c764af535ca3388a562db)