r5902: A rather large change...
authorAndrew Bartlett <abartlet@samba.org>
Sat, 19 Mar 2005 08:34:43 +0000 (08:34 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:11:07 +0000 (13:11 -0500)
commitdf643022136a4b229aca817f5b57f7302a97f852
treee2a2b5b20b5b3c580fd899a4f39a7911ac5ea250
parent4037a7e80c3e5d9560b084d9925896d2a5a9518c
r5902: A rather large change...

I wanted to add a simple 'workstation' argument to the DCERPC
authenticated binding calls, but this patch kind of grew from there.

With SCHANNEL, the 'workstation' name (the netbios name of the client)
matters, as this is what ties the session between the NETLOGON ops and
the SCHANNEL bind.  This changes a lot of files, and these will again
be changed when jelmer does the credentials work.

I also correct some schannel IDL to distinguish between workstation
names and account names.  The distinction matters for domain trust
accounts.

Issues in handling this (issues with lifetime of talloc pointers)
caused me to change the 'creds_CredentialsState' and 'struct
dcerpc_binding' pointers to always be talloc()ed pointers.

In the schannel DB, we now store both the domain and computername, and
query on both.  This should ensure we fault correctly when the domain
is specified incorrectly in the SCHANNEL bind.

In the RPC-SCHANNEL test, I finally fixed a bug that vl pointed out,
where the comment claimed we re-used a connection, but in fact we made
a new connection.

This was achived by breaking apart some of the
dcerpc_secondary_connection() logic.

The addition of workstation handling was also propogated to NTLMSSP
and GENSEC, for completeness.

The RPC-SAMSYNC test has been cleaned up a little, using a loop over
usernames/passwords rather than manually expanded tests.  This will be
expanded further (the code in #if 0 in this patch) to use a newly
created user account for testing.

In making this test pass test_rpc.sh, I found a bug in the RPC-ECHO
server, caused by the removal of [ref] and the assoicated pointer from
the IDL.  This has been re-added, until the underlying pidl issues are
solved.
(This used to be commit 824289dcc20908ddec957a4a892a103eec2da9b9)
44 files changed:
source4/client/client.c
source4/gtk/tools/gepdump.c
source4/gtk/tools/gwcrontab.c
source4/gtk/tools/gwsam.c
source4/lib/com/dcom/main.c
source4/lib/registry/reg_backend_rpc.c
source4/libcli/auth/credentials.c
source4/libcli/auth/credentials.h
source4/libcli/auth/gensec.c
source4/libcli/auth/gensec.h
source4/libcli/auth/gensec_ntlmssp.c
source4/libcli/auth/ntlmssp.c
source4/libcli/auth/ntlmssp.h
source4/libcli/auth/schannel.c
source4/libcli/auth/schannel_state.c
source4/libnet/libnet_rpc.c
source4/librpc/idl/echo.idl
source4/librpc/idl/schannel.idl
source4/librpc/rpc/dcerpc_auth.c
source4/librpc/rpc/dcerpc_schannel.c
source4/librpc/rpc/dcerpc_smb.c
source4/librpc/rpc/dcerpc_util.c
source4/ntvfs/ipc/vfs_ipc.c
source4/rpc_server/dcerpc_server.c
source4/rpc_server/dcerpc_server.h
source4/rpc_server/dcerpc_sock.c
source4/rpc_server/epmapper/rpc_epmapper.c
source4/rpc_server/netlogon/dcerpc_netlogon.c
source4/rpc_server/remote/dcesrv_remote.c
source4/torture/libnet/userinfo.c
source4/torture/local/binding_string.c
source4/torture/rpc/bind.c
source4/torture/rpc/epmapper.c
source4/torture/rpc/mgmt.c
source4/torture/rpc/netlogon.c
source4/torture/rpc/samlogon.c
source4/torture/rpc/samsync.c
source4/torture/rpc/scanner.c
source4/torture/rpc/schannel.c
source4/torture/rpc/spoolss.c
source4/torture/rpc/testjoin.c
source4/torture/rpc/xplogin.c
source4/torture/torture.c
source4/utils/ntlm_auth.c