1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

167 Commits

Author SHA1 Message Date
Volker Lendecke
48df39c133 r1814: Fix the build.
Tridge, in rpc_epmapper.c there's a whole bunch of "return
NT_STATUS_NOT_IMPLEMENTED". You told me that's wrong, you should generate the
correct fault pdu. Or is epmapper special in that respect?

Volker
2007-10-10 12:57:58 -05:00
Andrew Tridgell
ecb7378bbc r1757: much simpler (and smaller, faster etc) way of doing relative pointers
in pidl. This mechanism should be much easier to extend to the
"retrospective subcontexts" that jelmer needs.

also produced more standards complient full-pointer offsets. This
keeps ethereal happy with decoding our epmapper frames.
2007-10-10 12:57:54 -05:00
Jelmer Vernooij
547f860285 r1703: - Lots of RPC updates, adding new pipes and protocols.
- More updates/fixes to the ethereal parser generator
2007-10-10 12:57:49 -05:00
Stefan Metzmacher
76cb9966bf r1546: fix the build the function name has changed to srvsvc_NetRemoteTOD
because I implemented the idl for it

metze
2007-10-10 12:57:41 -05:00
Andrew Tridgell
0c5a5632a8 r1519: show the ldb_errstring() value in the log for failed ldb calls 2007-10-10 12:57:38 -05:00
Stefan Metzmacher
0e1f5e66d3 r1514: close stuff from the server_connection not in the
close_connection fn of a specific service

metze
2007-10-10 12:57:37 -05:00
Stefan Metzmacher
d7dd5347dd r1513: change DEBUG level to 1
metze
2007-10-10 12:57:37 -05:00
Andrew Bartlett
b97d3cb2ef r1498: (merge from 3.0)
Rework our random number generation system.

On systems with /dev/urandom, this avoids a change to secrets.tdb for every fork().

For other systems, we now only re-seed after a fork, and on startup.
No need to do it per-operation.  This removes the 'need_reseed'
parameter from generate_random_buffer().

This also requires that we start the secrets subsystem, as that is
where the reseed value is stored, for systems without /dev/urandom.

In order to aviod identical streams in forked children, the random
state is re-initialised after the fork(), at the same point were we do
that to the tdbs.

Andrew Bartlett
2007-10-10 12:57:35 -05:00
Stefan Metzmacher
bbe5e00715 r1486: commit the start of the generic server infastructure
the idea is to have services as modules (smb, dcerpc, swat, ...)

the process_model don't know about the service it self anymore.

TODO:
- the smbsrv should use the smbsrv_send function
- the service subsystem init should be done like for other modules
- we need to have a generic socket subsystem, which handle stream, datagram,
  and virtuell other sockets( e.g. for the ntvfs_ipc module to connect to the dcerpc server
  , or for smb or dcerpc or whatever to connect to a server wide auth service)
- and other fixes...

NOTE: process model pthread seems to be broken( but also before this patch!)

metze
2007-10-10 12:57:35 -05:00
Stefan Metzmacher
80851e6778 r1335: NT_STATUS_INTERNAL_DB_CORRUPTION
should cause DEBUG(0,(...));

metze
2007-10-10 12:56:50 -05:00
Tim Potter
0edf17ac38 r1313: Split up OpenPrinterEx into functions to handle opening printers and print
servers.
2007-10-10 12:56:50 -05:00
Andrew Bartlett
07fd885fd4 r1294: A nice, large, commit...
This implements gensec for Samba's server side, and brings gensec up
to the standards of a full subsystem.

This means that use of the subsystem is by gensec_* functions, not
function pointers in structures (this is internal).  This causes
changes in all the existing gensec users.

Our RPC server no longer contains it's own generalised security
scheme, and now calls gensec directly.

Gensec has also taken over the role of auth/auth_ntlmssp.c

An important part of gensec, is the output of the 'session_info'
struct.  This is now reference counted, so that we can correctly free
it when a pipe is closed, no matter if it was inherited, or created by
per-pipe authentication.

The schannel code is reworked, to be in the same file for client and
server.

ntlm_auth is reworked to use gensec.

The major problem with this code is the way it relies on subsystem
auto-initialisation.  The primary reason for this commit now.is to
allow these problems to be looked at, and fixed.

There are problems with the new code:
- I've tested it with smbtorture, but currently don't have VMware and
  valgrind working (this I'll fix soon).
- The SPNEGO code is client-only at this point.
- We still do not do kerberos.

Andrew Bartlett
2007-10-10 12:56:49 -05:00
Tim Potter
cf4e9080d5 r1276: Return data for enumprinters level 2 and 5. 2007-10-10 12:56:48 -05:00
Tim Potter
60e48790dc r1271: Return spoolss enumprinters info level1 from spoolss.ldb - woot! 2007-10-10 12:56:47 -05:00
Tim Potter
1162e2fcff r1270: Start to break samdb into general bits so we can share code with other
similar dbs.
2007-10-10 12:56:47 -05:00
Tim Potter
de5984c956 r1268: varient -> variant 2007-10-10 12:56:46 -05:00
Tim Potter
6b24ee3864 r1266: Start to split out EnumPrinters into a separate fn for each info level. 2007-10-10 12:56:46 -05:00
Stefan Metzmacher
d3b80fd40a r1235: as the pidl code init all output data.
we should do it manualy too.

metze
2007-10-10 12:56:46 -05:00
Stefan Metzmacher
b8b4d0d5bf r1234: valgrind found this uninitialised var...
But I don't know how to fix this correct,
so maybe this needs to be fixed

(tridge: can you please look at this)

metze
2007-10-10 12:56:46 -05:00
Tim Potter
5d0013438e r1226: Return dummy information for two printers. Note that ndr_push_array()
can be used here - neat!
2007-10-10 12:56:45 -05:00
Tim Potter
e216c6a707 r1211: Some output from rpcclient -c enumprinters to remind me what a relative
string looks like.  I'm not sure relstrs can be shoehorned into the ndr
code as easily as adding a LIBNDR_STR flag.
2007-10-10 12:56:45 -05:00
Tim Potter
487211f1ae r1210: A skeleton spoolssdb, based on samdb. 2007-10-10 12:56:45 -05:00
Tim Potter
1c749a3a34 r1208: Return some dummy printer information for the EnumPrinters RPC.
rpcclient enumprinters prints this information OK.

Some minor cut&paste cleanups.
2007-10-10 12:56:45 -05:00
Tim Potter
e21f324937 r1205: Whoops - this should fix the build. 2007-10-10 12:56:45 -05:00
Tim Potter
a5e3a26fc9 r1204: decrpc -> dcerpc 2007-10-10 12:56:45 -05:00
Tim Potter
3e79a6219e r1201: Skeleton versions of OpenPrinterEx() and ClosePrinter() to get the hang
of things.
2007-10-10 12:56:44 -05:00
Tim Potter
261531ce0a r1188: Use generated pidl template for this file and return DCESRV_FAULT instead
of a bogus WERROR.
2007-10-10 12:56:44 -05:00
Tim Potter
ed9c4d7d70 r1185: Hey look an endpoint for the spoolss pipe!
Doesn't do much at the moment except compile.
2007-10-10 12:56:43 -05:00
Andrew Tridgell
9b397356ae r1168: fixed a little-endian/big-endian mixup in the rpc server code 2007-10-10 12:56:43 -05:00
Andrew Tridgell
0e557fe857 r1165: fixed handling of SMBtrans replies that should return STATUS_BUFFER_OVERFLOW when more data is present. 2007-10-10 12:56:42 -05:00
Andrew Tridgell
db9ea488b0 r1150: - fixed interactive sam logon in the rpc server
- added a torture test for interactive login in smbtorture

These changes allow winxp to perform an interactive login (a login on
the winxp console) against a Samba4 DC. Our netlogon server code is
still filling in many of the fields incorrectly, but it fills in
enough that winxp can login.
2007-10-10 12:56:41 -05:00
Andrew Tridgell
cb3d3b5e51 r1145: added server support for logon level 5 in sam logon 2007-10-10 12:56:40 -05:00
Andrew Tridgell
705205083a r1141: - consolidated the netr_SamInfo structures using a netr_SamBaseInfo
structure (andrew, this is the type of structure consolidation I think
  you were asking about. It's possible here in NDR as it isn't in the
  top level fn code)

- added validation level 6 in sam logon

With these changes I can successfully authentication smbclient to a
winxp server, with the winxp server using a Samba4 ADS DC for account
auth
2007-10-10 12:56:40 -05:00
Andrew Tridgell
4eac7340d8 r1139: added IDL and server code for netr_LogonSamLogonWithFlags() 2007-10-10 12:56:40 -05:00
Andrew Tridgell
a35459387d r1136: - added IDL for netr_LogonGetDomainInfo()
- added workstation to auth_session_info in rpc servers

- added session key fetch hook in crypto backends in dcesrv

- store and fetch seed as well as a session key in schannel ldb

- when a client uses schannel to setup a netlogon pipe connection we
  also need to setup the credentials from the schannel negotiation so
  credentials chaining works

- added server side netr_LogonGetDomainInfo() call
2007-10-10 12:56:39 -05:00
Andrew Bartlett
de97d9df22 r1080: Make sure to initialise all the returned elements in the SamLogon
reply also initialise the LM session key, when we have it (was failing
because the auth code was setting it's length wrong).

Andrew Bartlett
2007-10-10 12:56:37 -05:00
Stefan Metzmacher
ad3dd1789e r1078: the dxesrv_crypto_* implementations should now explicit set
the dce_conn->auth_state.session_info
( the ntlmssp one works fine, but the schannel one isn't implemented yet)

this is also set by the ntvfs_ipc backend on the endpoint connect.

metze
2007-10-10 12:56:37 -05:00
Stefan Metzmacher
6f8b51e290 r1066: fix compiler warning
metze
2007-10-10 12:56:36 -05:00
Andrew Bartlett
6c92563b79 r1061: The start of the SamLogon call for the NETLOGON pipe.
Changes:

- Check for a valid 'pipe_state' in netr_ServerAuthenticate3 before
  we dereference it

- removes the expansionroom[7] in the netr_SamInfo* structs to 7
individual elements.
- renames netr_SamInfo -> netr_SamInfo2
          netr_SamInfo2 -> netr_SamInfo3
  - Having the thing we always called an 'info3' being 'netr_SamInfo2'
    was just too confusing.

- Expand and fill in extra details about users from the SAM, into
  the server_info, for processing into the SamLogon reply.

- Add a dum_sid_dup() function to duplicate a struct dom_sid

The SamLogon code currently does not return supplementary groups, and is
only tested with Samba4 smbtorture.

Andrew Bartlett
2007-10-10 12:56:35 -05:00
Andrew Tridgell
5a90187c2c r1060: check for an invalid session key in samr_set_password() 2007-10-10 12:56:35 -05:00
Stefan Metzmacher
d62c0661f9 r1059: add dcesrv_crypto_schannel_session_info() dummy function.
every backend must implement all functions!

metze
2007-10-10 12:56:35 -05:00
Andrew Bartlett
3ccd96bd94 r1058: The start of work on the SamLogon call for NETLOGON.
This starts to store information about the user in the server_info
struct - like the account name, the full name etc.

Also, continue to make the names of the structure elements in the
logon reply more consistant with those in the SAMR pipe.

Andrew Bartlett
2007-10-10 12:56:35 -05:00
Andrew Tridgell
0cde043592 r1057: added rpc packet logging for packets that generate rpc faults. This
makes it much easier to develop the IDL for new requests, especially
for sealed pipes, where ethereal cannot easily extract the data.
2007-10-10 12:56:35 -05:00
Andrew Tridgell
536aa86aa9 r1056: fixed a comment on handling of the initial challenge in the ntlmssp rpc server backend 2007-10-10 12:56:35 -05:00
Andrew Tridgell
55e0b014fe r1048: - moved the schannel definitions into a separate schannel.idl
- added server side support for schannel type 23. This allows WinXP to establish a schannel connection
  to Samba4 as an ADS DC

- added client side support for schannel type 23, but disabled it as currently the client
  code has now way of getting the fully qualified domain name (which is needed)

- report dcerpc faults in the server code in the log
2007-10-10 12:56:34 -05:00
Andrew Tridgell
4daab1eaec r1046: initialise a structure element caught by valgrind 2007-10-10 12:56:34 -05:00
Andrew Tridgell
2ac79dfba0 r1030: added server side schannel support 2007-10-10 12:56:30 -05:00
Andrew Tridgell
ee6c17f373 r1029: cope wiith samdb_result_passwords() returning a null machine password 2007-10-10 12:56:30 -05:00
Andrew Bartlett
0d2ae66d3a r1028: More consistancy fixes, which should also fix the build.
Andrew Bartlett
2007-10-10 12:56:30 -05:00
Tim Potter
b7fe73613a r1026: Spelling. 2007-10-10 12:56:30 -05:00