amitay/samba.git
24 years agoThis commit was manufactured by cvs2svn to create tag release-alpha-0-2 samba-misc-tags/tng/release-alpha-0-2
cvs2svn Import User [Fri, 11 Feb 2000 08:23:46 +0000 (08:23 +0000)]
This commit was manufactured by cvs2svn to create tag
'release-alpha-0-2'.

24 years agopreparing for release of alpha.0.2
Samba Release Account [Fri, 11 Feb 2000 08:23:45 +0000 (08:23 +0000)]
preparing for release of alpha.0.2

24 years agodid someone mention a code-freeze? oh well.
Luke Leighton [Fri, 11 Feb 2000 08:16:45 +0000 (08:16 +0000)]
did someone mention a code-freeze?  oh well.

this trivial set of cosmetic changes creates a set of client-side rpc commands:

net, regedit, samedit, eventlog, spoolss, lsa, cmdat, svccontrol.

rpcclient is still supported.  the -S server option has been dropped
(except on the command-line), in favour of specifying \\servername
or //servername as the first argument.

24 years agoGeneral cleanup of debugs.
Tim Potter [Fri, 11 Feb 2000 00:22:51 +0000 (00:22 +0000)]
General cleanup of debugs.

Implemented mapping for well-known RIDs.

Split up into different bits.

24 years agoyes, it's a biggie. another semi-automated job, sed script by sander striker.
Luke Leighton [Fri, 11 Feb 2000 00:13:06 +0000 (00:13 +0000)]
yes, it's a biggie.  another semi-automated job, sed script by sander striker.

i had to use :map = /_io_^[bX$xA &&^[^M6ddcf(  ^[ in vi to modify what you
did, sander, to change this:
if (!xxx_io_xxx(....))
{
return False;
}

/* ..... */
if (rpc_con_pipe_req(...))
{
....

into this:
if (xxx_io_xxx(....) &&
    rpc_con_pipe_req(...))
{
....

because the return False; would have resulted in memory leaks.

24 years agoRemoved debugs.
Tim Potter [Thu, 10 Feb 2000 23:49:34 +0000 (23:49 +0000)]
Removed debugs.

Added post-processing of calls to winbindd daemon.

24 years agopatch from elrond for dynamic UNICODE string management.
Luke Leighton [Thu, 10 Feb 2000 23:30:53 +0000 (23:30 +0000)]
patch from elrond for dynamic UNICODE string management.

24 years agopatch from elrond to do [important] dynamic memory allocation of
Luke Leighton [Thu, 10 Feb 2000 22:57:02 +0000 (22:57 +0000)]
patch from elrond to do [important] dynamic memory allocation of
net_share_enum, client and server.

24 years agopatch from lars for reg conversion
Luke Leighton [Thu, 10 Feb 2000 22:28:56 +0000 (22:28 +0000)]
patch from lars for reg conversion

24 years agomissed one - msrpc_trust_account_passwd takes $MACHINE.ACC as arg.
Luke Leighton [Thu, 10 Feb 2000 17:25:31 +0000 (17:25 +0000)]
missed one - msrpc_trust_account_passwd takes $MACHINE.ACC as arg.

24 years agopatch from lars for _srv_close conversion
Luke Leighton [Thu, 10 Feb 2000 17:13:37 +0000 (17:13 +0000)]
patch from lars for _srv_close conversion

24 years agomade sure that the secrets tdb was only initialised once!
Luke Leighton [Thu, 10 Feb 2000 15:25:01 +0000 (15:25 +0000)]
made sure that the secrets tdb was only initialised once!

24 years agomoving away from trust_get_passwd(), using lsa_query_secret() on either
Luke Leighton [Thu, 10 Feb 2000 15:23:23 +0000 (15:23 +0000)]
moving away from trust_get_passwd(), using lsa_query_secret() on either
$MACHINE.ACC or G$$TRUSTDOMAINNAME, instead.

the DOMAINNAME.SERVERNAME.mac file is pre-loaded into the
domainname.servername.tdb secrets file when it is first created.

24 years agoyess :) fixed the client / server reusage mixup by adding code to msrpc_find
Luke Leighton [Thu, 10 Feb 2000 14:57:55 +0000 (14:57 +0000)]
yess :) fixed the client / server reusage mixup by adding code to msrpc_find
that checks the vuser_key.  all client-side connections must now be separated
by the client's security context (vuser_key).

24 years agointeresting. this is quite a problem, i don't know the solution, yet.
Luke Leighton [Thu, 10 Feb 2000 14:13:35 +0000 (14:13 +0000)]
interesting.  this is quite a problem, i don't know the solution, yet.

client-side security contexts from msrpc functions *called* in smbd
are being confused with server-side security contexts in pass-through
(loop-back) msrpc functions!

24 years agoyess! rpcclient no longer links with libsmbpw.so, which was so grossly
Luke Leighton [Thu, 10 Feb 2000 12:22:48 +0000 (12:22 +0000)]
yess!  rpcclient no longer links with libsmbpw.so, which was so grossly
unnecessary.

24 years agopatch from lars kneschke for _reg_close conversion
Luke Leighton [Thu, 10 Feb 2000 11:55:43 +0000 (11:55 +0000)]
patch from lars kneschke for _reg_close conversion

24 years agoadded _lsa_set_secret implementation. fixed nt_decrypt_string() it
Luke Leighton [Thu, 10 Feb 2000 10:31:22 +0000 (10:31 +0000)]
added _lsa_set_secret implementation.  fixed nt_decrypt_string() it
shouldn't be leaving out the length bit, that's kinda-needed!

24 years agoadded _lsa_create_secret implementation.
Luke Leighton [Thu, 10 Feb 2000 09:58:37 +0000 (09:58 +0000)]
added _lsa_create_secret implementation.

24 years agoadded _lsa_query_secret implementation.
Luke Leighton [Thu, 10 Feb 2000 09:34:12 +0000 (09:34 +0000)]
added _lsa_query_secret implementation.

24 years agoadded implementation of _lsa_open_secret.
Luke Leighton [Thu, 10 Feb 2000 08:31:34 +0000 (08:31 +0000)]
added implementation of _lsa_open_secret.

24 years agostub _lsa_create_secret.
Luke Leighton [Thu, 10 Feb 2000 06:30:50 +0000 (06:30 +0000)]
stub _lsa_create_secret.

created LSA_SECRET parsing structure.

24 years agowell _that_ was unbelievably easy!!! switched off read-only in netmon,
Luke Leighton [Thu, 10 Feb 2000 05:50:11 +0000 (05:50 +0000)]
well _that_ was unbelievably easy!!!  switched off read-only in netmon,
edited the opcode until i got the right one, then it turns out that
lsa_create_secret is identical to lsa_open_secret except for the opcode.

anyway, upshot is: added rpcclient createsecret command.

why am i doing this? :) because i want to add lsa_create_secret(),
lsa_set_secret() to lsarpcd, which will then allow me to create
trust accounts ($MACHINE.ACC) *without* writing them direct to
/usr/local/samba/private/DOMAINNAME.MACHINENAME.mac.

i'm fed up with rpcclient having passdb/*.c and groupdb/*.c code linked
in to it.

24 years agofinally got it. lsa_set_secret(). now only need lsa_create_secret().
Luke Leighton [Thu, 10 Feb 2000 05:25:47 +0000 (05:25 +0000)]
finally got it.  lsa_set_secret().  now only need lsa_create_secret().

24 years agofinally getting somewhere with querysecret, setsecret
Luke Leighton [Thu, 10 Feb 2000 05:15:23 +0000 (05:15 +0000)]
finally getting somewhere with querysecret, setsecret

24 years agoattempting to add an lsa_set_secret(), client-side. consequently,
Luke Leighton [Thu, 10 Feb 2000 02:52:43 +0000 (02:52 +0000)]
attempting to add an lsa_set_secret(), client-side.  consequently,
found a bug in lsa_open_pol2().

24 years agotracking down memory leaks with yamd.
Luke Leighton [Thu, 10 Feb 2000 02:10:42 +0000 (02:10 +0000)]
tracking down memory leaks with yamd.

24 years agomake proto
Tim Potter [Wed, 9 Feb 2000 23:57:04 +0000 (23:57 +0000)]
make proto

24 years agoAdded *.po
Tim Potter [Wed, 9 Feb 2000 23:48:17 +0000 (23:48 +0000)]
Added *.po

24 years agoPreliminary commit of ntdom nss module allowing users and groups to be
Tim Potter [Wed, 9 Feb 2000 23:47:04 +0000 (23:47 +0000)]
Preliminary commit of ntdom nss module allowing users and groups to be
resolved from a remote sam database on a nt machine.  This is pretty
rough at the moment:

  - server name hardcoded into winbindd.c
  - single threaded, blocking server
  - must rm -f /tmp/winbindd before running server
  - no memory leak checking
  - only _nss_ntdom_getpwnam_r function fully implemented

It's still pretty funky though.  I'm only committing it for tridge and
jeremy to have a look.  (-:

24 years agoThis commit was manufactured by cvs2svn to create branch 'SAMBA_TNG'.
cvs2svn Import User [Wed, 9 Feb 2000 23:47:03 +0000 (23:47 +0000)]
This commit was manufactured by cvs2svn to create branch 'SAMBA_TNG'.

24 years agopatch from lars kneschke (the first!) for _reg_close() conversion
Luke Leighton [Wed, 9 Feb 2000 22:32:25 +0000 (22:32 +0000)]
patch from lars kneschke (the first!) for _reg_close() conversion

24 years agodisabled samtdb user alias lookup, it's broken.
Luke Leighton [Wed, 9 Feb 2000 20:59:31 +0000 (20:59 +0000)]
disabled samtdb user alias lookup, it's broken.

24 years agoreplace standard_sub_basic() and samlogon_user with standard_sub_vuser.
Luke Leighton [Wed, 9 Feb 2000 19:24:28 +0000 (19:24 +0000)]
replace standard_sub_basic() and samlogon_user with standard_sub_vuser.
currently code does NOT pick up correct user-context, so %U and %G will
NOT be substituted.

24 years agofix from luke howard for --with-ldap compile.
Luke Leighton [Wed, 9 Feb 2000 17:00:15 +0000 (17:00 +0000)]
fix from luke howard for --with-ldap compile.

24 years agofixing _samr_set_userinfo() - just added it to samtdb. and the other
Luke Leighton [Wed, 9 Feb 2000 07:08:22 +0000 (07:08 +0000)]
fixing _samr_set_userinfo() - just added it to samtdb.  and the other
samdb impls (as a stub).

24 years agoadded start of samtdb group database
Luke Leighton [Wed, 9 Feb 2000 07:01:23 +0000 (07:01 +0000)]
added start of samtdb group database

24 years agooops, fixing --with-sam-pwdb= types
Luke Leighton [Tue, 8 Feb 2000 22:09:04 +0000 (22:09 +0000)]
oops, fixing --with-sam-pwdb= types

24 years agoweird. another make proto out-of-sync.
Luke Leighton [Tue, 8 Feb 2000 20:46:06 +0000 (20:46 +0000)]
weird.  another make proto out-of-sync.

24 years agoadded samrpassd and netlogonpassd which have to be explicitly compiled.
Luke Leighton [Tue, 8 Feb 2000 20:41:40 +0000 (20:41 +0000)]
added samrpassd and netlogonpassd which have to be explicitly compiled.
i compile --with-sampwdb=tdb, so if i want to test passdb/ i couldn't!

24 years agopatch from elrond
Luke Leighton [Tue, 8 Feb 2000 20:15:52 +0000 (20:15 +0000)]
patch from elrond

- --with-sam-pwdb=tdb,passdb,nt5ldap.

- code cleanups (made some fns static)

- reduced linking options to lsarpcd, it's really simple, now!

24 years agopatch from elrond for lsarpc conversion. this one's taking a long time,
Luke Leighton [Tue, 8 Feb 2000 20:06:04 +0000 (20:06 +0000)]
patch from elrond for lsarpc conversion.  this one's taking a long time,
it's not trivial!

24 years agopreparing for release of alpha.0.1
Samba Release Account [Tue, 8 Feb 2000 17:40:35 +0000 (17:40 +0000)]
preparing for release of alpha.0.1

24 years agohm, someone changed open_socket_in and didn't do a make proto :)
Luke Leighton [Tue, 8 Feb 2000 16:34:46 +0000 (16:34 +0000)]
hm, someone changed open_socket_in and didn't do a make proto :)

24 years agocreating user alias groups and user domain groups.
Luke Leighton [Tue, 8 Feb 2000 09:10:47 +0000 (09:10 +0000)]
creating user alias groups and user domain groups.

24 years agodisabled but pwnotreq accounts were being allowed login access, i don't
Luke Leighton [Tue, 8 Feb 2000 05:48:25 +0000 (05:48 +0000)]
disabled but pwnotreq accounts were being allowed login access, i don't
think this should be allowed.  disabled is disabled, end of story.

24 years agopolicy link for rest of msrpc daemons.
Luke Leighton [Tue, 8 Feb 2000 05:45:48 +0000 (05:45 +0000)]
policy link for rest of msrpc daemons.

fixing createuser command to take a -p option.  currently, the default
action for samrtdbd if no password is specified is to set the account
to "DISABLED" and "NOPASSWORDREQUIRED".  setting this with the
samuserset2 rpcclient command is a minor pain in the neck.

24 years agothis weird-looking code uses the user_struct* that was obtained from
Luke Leighton [Tue, 8 Feb 2000 05:02:33 +0000 (05:02 +0000)]
this weird-looking code uses the user_struct* that was obtained from
an SMBsesssetupX to provide a response to api_WkstaUserLogon and
api_NetUserGetInfo.

IF my suspicions are correct, an api_NetUserGetInfo or api_WkstaUserLogon
against an anonymous IPC$ connection will produce a failure, resulting
in the Win9x client DROPPING the anonymous connection and re-establishing
an authenticated SMBsesssetupX.

this will cause the smbd server to get a NET_USER_INFO_3 structure from
either the PDC or from itself (MSRPC remote or MSRPC loop-back, doesn't
matter which, it's all the same to domain_client_validate()), thence the
api_Net... or api_Wksta... call to follow will be provided with the correct
user logon info.

it also means that we can start filling in some of the "stub" fields,
such as last_logon_time, with _real_ info.  well, real, if netlogond
bothered to fill it in, but you get the idea :)

24 years ago1) made standard_sub_vuser take a const user_struct* instead of a const
Luke Leighton [Tue, 8 Feb 2000 04:25:56 +0000 (04:25 +0000)]
1) made standard_sub_vuser take a const user_struct* instead of a const
   vuser_key*.  this stops stupid-amounts of linking to all sorts of
   crap in programs like make_codepage and testprns, which know _nothing_
   of users.  the original link was just a temporary hack to get binaries.

2) make vuid_free_user_struct() free the vuser malloc'd structure, too.

24 years agofirst stage of making some sort of "thread" context ... er, thing :) in
Luke Leighton [Tue, 8 Feb 2000 03:43:58 +0000 (03:43 +0000)]
first stage of making some sort of "thread" context ... er, thing :) in
the msrpc code.  it's not really threads, it's just a thread context,
so that if different thread-contexts are requested, then the msrpc daemon
will at least be able to switch user-security-context.

eventually, i will have to go so far as to be able to reconstruct PDUs
depending on the user context, but that will require one socket per
thread-context, and some means to set that up *inside* the Bind/Bind-Request
processing code [argh!], because that's what triggers a "new" user-context,
really.

i hope.

24 years agoPort of rebind argument to lib/util_sock:open_socket_in() function.
Tim Potter [Tue, 8 Feb 2000 03:13:38 +0000 (03:13 +0000)]
Port of rebind argument to lib/util_sock:open_socket_in() function.

24 years agoHOORAY! password setting is back. this through fixing policy handle
Luke Leighton [Tue, 8 Feb 2000 00:36:10 +0000 (00:36 +0000)]
HOORAY!  password setting is back.  this through fixing policy handle
chain linking _and_ an odd bug where password_ok() was ZERO_STRUCTING
the NET_USER_INFO_3 structure and it was being stored in the vuser.tdb
table, blanking out the NT user info!

i added code to authorise_login() to get and then store the vuser info
after seeing it set vuser->guest = True.

i'm not sure i like that code...

24 years agohmm, looks like there's a bug in become_unix_sec_ctx(), it does a
Luke Leighton [Tue, 8 Feb 2000 00:15:08 +0000 (00:15 +0000)]
hmm, looks like there's a bug in become_unix_sec_ctx(), it does a
become_initial_uid and _then_ checks to see if the context hasn't
changed.  odd.

24 years agofinally got bugs fixed in rpcclient samuserset command. hint: don't
Luke Leighton [Tue, 8 Feb 2000 00:02:15 +0000 (00:02 +0000)]
finally got bugs fixed in rpcclient samuserset command.  hint: don't
typecast things to void*...

24 years agotrying to sort out policy handle state info, and making a mess of it.
Luke Leighton [Mon, 7 Feb 2000 23:46:09 +0000 (23:46 +0000)]
trying to sort out policy handle state info, and making a mess of it.
how to set up user-security-context info on a per-connection basis:
each POLICY_HND that is created must have a vuser_key associated with
it.  this must be transferred from POLICY_HND to POLICY_HND (e.g
samr_open_domain(connect_pol, &domain_pol)
{
policy_link_key(connect_pol, domain_pol);
}
so that the user session key can be picked up from a chain of samr_connect(),
samr_open_domain(), samr_open_user(), samr_set_userinfo().

the only consistent info is the POLICY_HND, passed from one call to the next.

24 years agomissed one vuid to user_key conversion.
Luke Leighton [Mon, 7 Feb 2000 20:06:25 +0000 (20:06 +0000)]
missed one vuid to user_key conversion.

24 years agoAdded check for SGI IRIX brokenness with semaphores when using gcc.
Jeremy Allison [Mon, 7 Feb 2000 14:27:04 +0000 (14:27 +0000)]
Added check for SGI IRIX brokenness with semaphores when using gcc.
Code from Don Badrak <dbadrak@census.gov>
Jeremy.

24 years agoSpelling flame. (-:
Tim Potter [Mon, 7 Feb 2000 05:26:41 +0000 (05:26 +0000)]
Spelling flame.  (-:

24 years agoargh. had to add a "minimalist" creds interface back in. reason:
Luke Leighton [Mon, 7 Feb 2000 03:08:57 +0000 (03:08 +0000)]
argh.  had to add a "minimalist" creds interface back in.  reason:
pass-through (rpcclient->smbd->msrpcdaemon) doesn't know anything about
how to let msrpcdaemon "inherit" the credentials of the smbd process.

i forgot about that.

24 years agooops, i put the lm# in the trust account not the nt#.
Luke Leighton [Mon, 7 Feb 2000 02:41:56 +0000 (02:41 +0000)]
oops, i put the lm# in the trust account not the nt#.

24 years agoAdded *.lo to .cvsignore file.
Tim Potter [Mon, 7 Feb 2000 01:24:41 +0000 (01:24 +0000)]
Added *.lo to .cvsignore file.

24 years agoFix some more compile warnings.
Tim Potter [Mon, 7 Feb 2000 00:41:58 +0000 (00:41 +0000)]
Fix some more compile warnings.

24 years agoFixed compile warning in locking.c:traverse_fn()
Tim Potter [Mon, 7 Feb 2000 00:24:04 +0000 (00:24 +0000)]
Fixed compile warning in locking.c:traverse_fn()

24 years agonew loop-back authentication mechanism.
Luke Leighton [Sun, 6 Feb 2000 20:38:47 +0000 (20:38 +0000)]
new loop-back authentication mechanism.

24 years agowe're back full circle! i removed the "creds" interface. it turns out
Luke Leighton [Sun, 6 Feb 2000 18:39:28 +0000 (18:39 +0000)]
we're back full circle!  i removed the "creds" interface.  it turns out
that there is, in the DCE/RPC bind request, a 32-bit field (assoc_gid).
i'm overloading that with the CALLER's pid.  combined with the context_id
field, which is 16-bit, that can be overloaded with the smbd vuid, we
have sufficient info to make MSRPC calls over loop-back that reference
the correct vuid database.

24 years agomake proto
Luke Leighton [Sun, 6 Feb 2000 16:54:45 +0000 (16:54 +0000)]
make proto

24 years agopatch from sander for svcctl conversion.
Luke Leighton [Sun, 6 Feb 2000 16:50:56 +0000 (16:50 +0000)]
patch from sander for svcctl conversion.

24 years agoimplemented invalidate_vuid as a tdb_delete.
Luke Leighton [Sun, 6 Feb 2000 05:30:23 +0000 (05:30 +0000)]
implemented invalidate_vuid as a tdb_delete.

24 years agothis is probably one of THE most reluctant commits i've ever made.
Luke Leighton [Sun, 6 Feb 2000 05:17:28 +0000 (05:17 +0000)]
this is probably one of THE most reluctant commits i've ever made.

it's far-reaching, and necessary.

this adds a vuser_struct tdb database, with a key [smbd's pid, vuid].
smbd uses it in every instance of standard_sub() and standard_sub_vuser().
that's almost every single SMB call for any IPC$ access.

the next stage is to remove sesssetup_user, probably sessetup_user_list too,
and review all occurences of standard_sub_basic used by smbd because if
they use standard_sub_basic() they might be expecting to read sesssetup_user,
and if they do _that_, they should be using standard_sub_vuser() instead.

all i wanted was a means to get vuids across to msrpc daemons.

24 years ago*sigh*. libsamnt5ldap doesn't compile. libsamtdb shouldn't be compiled
Luke Leighton [Sat, 5 Feb 2000 23:37:02 +0000 (23:37 +0000)]
*sigh*.  libsamnt5ldap doesn't compile.  libsamtdb shouldn't be compiled
either - not on a make install, anyway!

24 years agoadded libsampass* to install-lib SHARED_LIBS.
Luke Leighton [Sat, 5 Feb 2000 20:33:30 +0000 (20:33 +0000)]
added libsampass* to install-lib SHARED_LIBS.

24 years agoadding functions that are common-code between samrtdbd and samrnt5ldapd
Luke Leighton [Sat, 5 Feb 2000 18:19:35 +0000 (18:19 +0000)]
adding functions that are common-code between samrtdbd and samrnt5ldapd
so as not to waste luke howard's time.

security checks in netlogond on _net_srv_pwset(): account-type checking.

24 years agopatch from elrond for _lsa_query_info_policy conversion.
Luke Leighton [Sat, 5 Feb 2000 17:43:03 +0000 (17:43 +0000)]
patch from elrond for _lsa_query_info_policy conversion.

elrond, could you please collapse reply_xxx() functions into api_xxx()
as they are static?  makes the code look cleaner!  thx!

24 years agonetlogontdbd now links. i had to disable net_login_general() from
Luke Leighton [Sat, 5 Feb 2000 15:24:13 +0000 (15:24 +0000)]
netlogontdbd now links.  i had to disable net_login_general() from
using "update encrypted" because the method used (update_smbpasswordfile)
is, as you can see, specific to the smbpasswd file!

i need to create a "create SAM user" function for this to be done properly.

24 years agoreplacing enumeration of passdb/*.c in _net_sam_sync with _samr* API.
Luke Leighton [Fri, 4 Feb 2000 23:41:30 +0000 (23:41 +0000)]
replacing enumeration of passdb/*.c in _net_sam_sync with _samr* API.
netlogontdbd fails to link (deliberately) because it's not linked
with the passdb/*.c API.  by the time i'm finished, it will, because
there won't _be_ any references to the passdb/*.c API.

24 years agofinally getting somewhere by creating an _samr* API as a library.
Luke Leighton [Fri, 4 Feb 2000 22:38:07 +0000 (22:38 +0000)]
finally getting somewhere by creating an _samr* API as a library.

the idea is to never, ever call passdb/*.c or groupdb/*.c functions
[which are an abomination] but to use _samr_*() instead.

e.g, smbpasswd calls _samr_set_userinfo() instead of mod_smbpwd_entry().

24 years agodummy functions need to be unique.
Luke Leighton [Fri, 4 Feb 2000 21:13:39 +0000 (21:13 +0000)]
dummy functions need to be unique.

24 years agoconsistency updates to luke howard's work. make sure it compiles
Luke Leighton [Fri, 4 Feb 2000 19:23:49 +0000 (19:23 +0000)]
consistency updates to luke howard's work.  make sure it compiles
in non-ldap environments.  luke, i did this by moving the typedefs
for LDAPDB and related typedefs to _outside_ the #ifdef WITH_NT5LDAP

24 years agopatch from luke howard to do a passdb/*.c-compatible nt5 ldap schema.
Luke Leighton [Fri, 4 Feb 2000 18:58:18 +0000 (18:58 +0000)]
patch from luke howard to do a passdb/*.c-compatible nt5 ldap schema.

he also created a samrnt5ldapd, this is the beginning of it.

24 years agomake proto
Luke Leighton [Fri, 4 Feb 2000 18:38:31 +0000 (18:38 +0000)]
make proto

24 years agopatch from Elrond for _lsa_lookup_sids conversion. starting with
Luke Leighton [Fri, 4 Feb 2000 18:23:58 +0000 (18:23 +0000)]
patch from Elrond for _lsa_lookup_sids conversion.  starting with
creating [unused] UNISTR2* dynamic memory allocation routines.

24 years agocompletes the patch to create and use standard_sub_vuser(). in some
Luke Leighton [Fri, 4 Feb 2000 17:58:45 +0000 (17:58 +0000)]
completes the patch to create and use standard_sub_vuser().  in some
instances i have added UID_FIELD_INVALID so that standard_sub_vuser
defaults to the same functionality and standard_sub_basic().

24 years agocreating vuser-specific substitution function standard_sub_vuser().
Luke Leighton [Fri, 4 Feb 2000 16:58:54 +0000 (16:58 +0000)]
creating vuser-specific substitution function standard_sub_vuser().

24 years agoAfter 3AM, it's getting hard for Luke :-)
Jean-François Micouleau [Fri, 4 Feb 2000 15:19:28 +0000 (15:19 +0000)]
After 3AM, it's getting hard for Luke :-)

24 years agoFix some compile warnings.
Tim Potter [Fri, 4 Feb 2000 05:18:06 +0000 (05:18 +0000)]
Fix some compile warnings.

24 years agook, this _is_ as big as it looks, conceptually, and i haven't even
Luke Leighton [Fri, 4 Feb 2000 05:16:57 +0000 (05:16 +0000)]
ok, this _is_ as big as it looks, conceptually, and i haven't even
done what i wanted to: this is only preparation!!!!

i started off in smbd/lanman.c, and noticed that api_NetUserGetInfo
takes all its info from user_struct *vuser.  i thought, that's odd,
that doesn't look right.

then i realised that the info there is exactly what is contained in
the NET_USER_INFO_3 structure: the return result from an NT Domain
User Logon.

various lights went on, and i realised that when an SMBsesssetupX
is carried out, internally, NT must do an NT Domain User Logon
with the SMB user's challenge/response password, and then store the
return result associated with the SMB session.

in this way, when an api_NetUserGetInfo call comes in, the CORRECT
info can be returned, not some faked-up information.

anyway, this commit is all the consequences of putting NET_USER_INFO_3
into user_struct, which feeds up through _several_ layers of function
calls.  i sort-of understood that i needed to do this, but not quite.

the upshot of this is that user_struct now contains the REAL nt
domain username (in NET_USER_INFO_3) so the confusion between nt
user names and unix usernames now can be removed from samba code.

if you want a unix user name, you use vuser->unix_name.

if you want an NT user name, you use (UNISTR2*)vuser->usr.uni_user_name.

p.s it's in UNICODE :)

p.p.s if you want the RID of the user, it's vuser->usr.user_rid.

p.p.p.s there's over 25 NT-specific other bits of info in NET_USER_INFO_3
too!

24 years agoHopefully these changes will actually stick.
Tim Potter [Fri, 4 Feb 2000 05:08:16 +0000 (05:08 +0000)]
Hopefully these changes will actually stick.

24 years ago1) added void* state argument to tdb_traverse. guess what! there were
Luke Leighton [Fri, 4 Feb 2000 04:59:31 +0000 (04:59 +0000)]
1) added void* state argument to tdb_traverse.  guess what!  there were
two places i found where it was appropriate to _use_ that third argument,
in locking.c and brlock.c!  there was a static traverse_function and
i removed the static variable, typecast it to a void*, passed it to
tdb_traverse and re-cast it back to the traverse_function inside the
tdb_traverse function.  this makes the use of tdb_traverse() reentrant,
which is never going to happen, i know, i just don't like to see
statics lying about when there's no need for them.

as i had to do in samba-tng, all uses of tdb_traverse modified to take
the new void* state argument.

2) disabled rpcclient: referring people to use SAMBA_TNG rpcclient.
i don't know how the other samba team members would react if i deleted
rpcclient from cvs main.  damn, that code's so old, it's unreal.
20 rpcclient commands, instead of about 70 in SAMBA_TNG.

24 years agoacb_info in usr21, not acct_ctrl
Luke Leighton [Fri, 4 Feb 2000 00:35:24 +0000 (00:35 +0000)]
acb_info in usr21, not acct_ctrl

24 years agomore fixing up netlogond. const issues. removed pass_check_smb() it
Luke Leighton [Fri, 4 Feb 2000 00:23:34 +0000 (00:23 +0000)]
more fixing up netlogond.  const issues.  removed pass_check_smb() it
was a nuisance.  someone should check that this is ok to do, cos i
got rid of an if (lp_null_passwords()) call!  we now have ACB_PWNOTREQ
bits set on a per-user basis.

is that ok?

24 years agolooking to fix nt error message reporting in rpc client code
Luke Leighton [Thu, 3 Feb 2000 23:57:16 +0000 (23:57 +0000)]
looking to fix nt error message reporting in rpc client code

24 years agoanother removal of get_smbpwd_entry() calls.
Luke Leighton [Thu, 3 Feb 2000 23:38:57 +0000 (23:38 +0000)]
another removal of get_smbpwd_entry() calls.

the last one to do here is the sam sync code, which needs improvements
anyway.

24 years agoPut back lots of missing calls to dos_to_unix(). Thanks to
Tim Potter [Thu, 3 Feb 2000 23:08:24 +0000 (23:08 +0000)]
Put back lots of missing calls to dos_to_unix().  Thanks to
aono@cc.osaka-kyoiku.ac.jp (Tomoki AONO)

24 years agoohh YESS! this is so COOL!
Luke Leighton [Thu, 3 Feb 2000 21:46:41 +0000 (21:46 +0000)]
ohh YESS!  this is so COOL!

implemented get_md4pwd(), instead of in terms of get_smbpwd_entry(),
in terms of _samr_xxx() api calls.

it does this:

_samr_connect
_samr_open_domain
_samr_lookup_user
_samr_open_user
_samr_query_userinfo(info level 0x12, just added, to get password hash :-)
_samr_close
_samr_close
_samr_close

and what do you know?  it actually worked!

24 years agocreating _samr_set_userinfo info level 0x12.
Luke Leighton [Thu, 3 Feb 2000 21:09:07 +0000 (21:09 +0000)]
creating _samr_set_userinfo info level 0x12.
adding code to report security attack if api_samr_set_userinfo is called
with info level 0x12.

24 years agomake proto
Luke Leighton [Thu, 3 Feb 2000 20:07:16 +0000 (20:07 +0000)]
make proto

24 years agoignore libtool
Luke Leighton [Thu, 3 Feb 2000 20:03:50 +0000 (20:03 +0000)]
ignore libtool

24 years agopatch from elrond for make_dom_refs to UNICODE
Luke Leighton [Thu, 3 Feb 2000 20:03:08 +0000 (20:03 +0000)]
patch from elrond for make_dom_refs to UNICODE

24 years agoclean-up of sander's netlogon patch, it didn't compile.
Luke Leighton [Thu, 3 Feb 2000 20:01:31 +0000 (20:01 +0000)]
clean-up of sander's netlogon patch, it didn't compile.

24 years agopatch from ignacio to get --with-ldap compiling.
Luke Leighton [Thu, 3 Feb 2000 18:18:51 +0000 (18:18 +0000)]
patch from ignacio to get --with-ldap compiling.