1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-07 20:23:50 +03:00
Commit Graph

124 Commits

Author SHA1 Message Date
Andrew Tridgell
fce7a4218b r2294: this fixes the NTLM2 sign+seal combination. I have now tested:
NTLM sign
 NTLM sign+seal
 NTLM2 sign
 NTLM2 sign+seal

and all of the above both with and without key exchange

the NTLM2 seal case is ugly and involves an extra data copy, which
some API changes in gensec or the ndr layer might avoid in future.
2007-10-10 12:58:40 -05:00
Andrew Bartlett
b80d849b6b r2290: Fix 'lsakey' for the server-side, it is static for
'authenticated' connections.

Fix kerberos session key issues - we need to call the
routine for extracting the session key, not just read the cache.

Andrew Bartlett
2007-10-10 12:58:40 -05:00
Andrew Bartlett
f5a381094d r2286: Fixes towards krb5 logins into Samba's CIFS server.
These fixes aim particularly at allowing PAC-less logins, as I don't
yet generate a PAC in the lorikeet-heimdal KDC.

This is for the benifit of a Kerbeors-enabled domain join, which seems
to be progressing quite well!

Andrew Bartlett
2007-10-10 12:58:39 -05:00
Andrew Bartlett
2c701f59a7 r2285: Remove more static data, fix spelling in a comment. 2007-10-10 12:58:39 -05:00
Andrew Bartlett
a1fe175eec r2284: Thanks to some great detective work by tridge, NTLM2 signing now works.
This means that 'require NTLMv2 session security' now works for RPC
pipe signing.  We don't yet have sealing, but it can't be much further.

This is almost all tridge's code, munged into a form that can work
with the GENSEC API.

This commit also includes more lsakey fixes - that key is used for all
DCE-RPC level authenticated connections, even over CIFS/ncacn_np.

No doubt I missed something, but I'm going to get some sleep :-)

Andrew Bartlett
2007-10-10 12:58:39 -05:00
Andrew Bartlett
e8d0246882 r2119: Noticed by jra:
Clean up use of unitilaised variable.

Andrew Bartlett
2007-10-10 12:58:26 -05:00
Andrew Bartlett
0237389ce7 r2099: Get rid of another private ARCFOUR implementation from the codebase.
Andrew Bartlett
2007-10-10 12:58:24 -05:00
Andrew Bartlett
e509451538 r2096: Enable use of NTLM2 for connections that do not got on to be NTLMSSP
signed or sealed.

This allows NTLM2 for SMB connections, and NTLMSSP over HTTP for example.

Andrew Bartlett
2007-10-10 12:58:24 -05:00
Günther Deschner
fe93f58dfe r2058: Merge heimdal krb5_locate_kdc-fix over from trunk/3_0 although
krb5_locate_kdc is (yet) an unused function in Samba4.

Guenther
2007-10-10 12:58:22 -05:00
Andrew Bartlett
2cbbf123d2 r2054: Fix compile warnings/build failures on non-gcc.
Andrew Bartlett
2007-10-10 12:58:21 -05:00
Andrew Bartlett
46864dd9d7 r2053: All RPC sessions 'want' a session key. Of course, the key they
currently get it bougs, but anyway...

Andrew Bartlett
2007-10-10 12:58:21 -05:00
Andrew Tridgell
e1575a72a1 r2042: missed a couple of places that should be talloc_free() 2007-10-10 12:58:19 -05:00
Andrew Bartlett
86f61568ea r2041: Fix NTLMSSP RPC sealing, client -> win2k3 server.
The bug (found by tridge) is that Win2k3 is being tighter about the
NTLMSSP flags.  If we don't negotiate sealing, we can't use it.

We now have a way to indicate to the GENSEC implementation mechanisms
what things we want for a connection.

Andrew Bartlett
2007-10-10 12:58:19 -05:00
Andrew Tridgell
a2ad77fb3a r2036: switched the spnego code to use talloc
now that talloc_free() doesn't need to take a context ptr, there is no
reason we can't use talloc everywhere that we currently use malloc().
2007-10-10 12:58:19 -05:00
Stefan Metzmacher
17268837d2 r2020: fix compiler warnings
metze
2007-10-10 12:58:18 -05:00
Volker Lendecke
7be7f25a57 r1886: Fix the build 2007-10-10 12:58:08 -05:00
Stefan Metzmacher
fe655d0474 r1794: fix the build MIT krb5
metze
2007-10-10 12:57:57 -05:00
Stefan Metzmacher
5a3a10c004 r1790: a few updates on krb5 PAC...
metze
2007-10-10 12:57:56 -05:00
Stefan Metzmacher
250485b69f r1784: a few minor changes and debug the decoded PAC_DATA
metze
2007-10-10 12:57:56 -05:00
Stefan Metzmacher
d8fe497097 r1770: here's the krb5 server code,
there're some cleanups needed and we need to verify the PAC correctly
and create the auth_session_info correctly...

metze
2007-10-10 12:57:55 -05:00
Andrew Bartlett
0949b72645 r1752: Fix compile bugs on C (rather than C++) tolerant compilers.
Andrew Bartlett
2007-10-10 12:57:53 -05:00
Stefan Metzmacher
b898589296 r1748: don't segfault if there's no ticket
metze
2007-10-10 12:57:53 -05:00
Stefan Metzmacher
68f3e53826 r1737: don't segfault when a mech don't have a session_info hook
metze
2007-10-10 12:57:51 -05:00
Andrew Bartlett
73ee549b8c r1731: Add server-side SPNEGO support to Samba (disabled, until SMB signing
is reworked).

Andrew Bartlett
2007-10-10 12:57:51 -05:00
Andrew Bartlett
c91d6b6f9b r1724: Add a new function to return the list of available OIDs.
(Used in our SPNEGO code).

Andrew Bartlett
2007-10-10 12:57:50 -05:00
Andrew Bartlett
0e4e3647e8 r1685: Add the ability to lookup RPC auth types for the RPC-MGMT torture test.
Andrew Bartlett
2007-10-10 12:57:48 -05:00
Andrew Tridgell
e8d4b39088 r1630: - fixed the replacement timegm() function to work correctly for DST changes
- got rid of global_myname(), using lp_netbios_name() instead
2007-10-10 12:57:45 -05:00
Andrew Bartlett
8a0f7bf5e2 r1605: GENSEC krb5 updates - fix a valgrind found uninitialised variable, and
allow tests for 'unwrapped' krb5, allowed by Win2k3.

SPENGO changes, trying to get the logic right (when and what
sub-mechanisms to wrap).

Andrew Bartlett
2007-10-10 12:57:44 -05:00
Andrew Bartlett
35b83eb329 r1521: Updates to our SMB signing code.
- This causes our client and server code to use the same core code,
  with the same debugs etc.
- In turn, this will allow the 'mandetory/fallback' signing algorithms
  to be shared, and only written once.

Updates to the SPNEGO code
- Don't wrap an empty token to the server, if we are actually already finished.

Andrew Bartlett
2007-10-10 12:57:39 -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
65147f5aa2 r1497: add forward declaration for struct auth_session_info
(fix compiler warning)

metze
2007-10-10 12:57:35 -05:00
Andrew Bartlett
30d88580ef r1476: Don't print messages about the CCACHE not being found - this is normal.
Andrew Bartlett
2007-10-10 12:57:34 -05:00
Andrew Bartlett
de5da66939 r1475: More kerberos work
- We can now connect to hosts that follow the SPNEGO RFC, and *do not*
give us their principal name in the mechListMIC.
 - The client code now remembers the hostname it connects to

- We now kinit for a user, if there is not valid ticket already

- Re-introduce clock skew compensation

TODO:
 - See if the username in the ccache matches the username specified
 - Use a private ccache, rather then the global one, for a 'new' kinit
 - Determine 'default' usernames.
  - The default for Krb5 is the one in the ccache, then $USER
  - For NTLMSSP, it's just $USER

Andrew Bartlett
2007-10-10 12:57:34 -05:00
Stefan Metzmacher
9a876be76c r1467: disable gensec_krb5 by default till abartlet
add the kinit code

metze
2007-10-10 12:57:33 -05:00
Andrew Tridgell
ea5659b051 r1466: the name "oid" is taken by some silly system headers - avoid it in our code 2007-10-10 12:57:33 -05:00
Stefan Metzmacher
fc8d00b8ab r1463: fix the krb5 build
metze
2007-10-10 12:57:32 -05:00
Andrew Bartlett
cea578d6f3 r1462: GENSEC Kerberos and SPENGO work:
- Spelling - it's SPNEGO, not SPENGO
 - SMB signing - Krb5 logins are now correctly signed
 - SPNEGO - Changes to always tell GENSEC about incoming packets, empty or not.

Andrew Bartlett
2007-10-10 12:57:32 -05:00
Andrew Bartlett
67ac960066 r1461: ntlm_check.c is a server-side peice of code, so it belongs in AUTH.
Andrew Bartlett
2007-10-10 12:57:32 -05:00
Andrew Bartlett
893a9a3865 r1457: Add the GSSAPI layer to our gensec_krb5 code.
Andrew Bartlett
2007-10-10 12:56:58 -05:00
Jelmer Vernooij
7e9884799e r1451: More missing files... 2007-10-10 12:56:58 -05:00
Jelmer Vernooij
eaa2940ba0 r1450: Oops.. Missing files :-) 2007-10-10 12:56:57 -05:00
Jelmer Vernooij
69de0d95c5 r1449: Use the config system somewhat better in libcli/auth 2007-10-10 12:56:57 -05:00
Andrew Bartlett
1164be10af r1448: Indent this so proto doesn't pick it up.
Andrew Bartlett
2007-10-10 12:56:57 -05:00
Andrew Bartlett
b97ea8a63f r1447: Fix compile.
Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
310a570936 r1446: Another funciton to avoid in proto.h
Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
159c234589 r1445: Ensure get_auth_data_from_tkt doesn't get into proto.h
Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
64e99170c3 r1443: More changes towards Kerberos in Samba4's GENSEC.
The kerberos context is now tied in life to the GENSEC context.

Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
231e505dea r1441: Indentation and comment fixes.
Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
1c31aa4271 r1440: GENSEC improvements:
- Infrustructure for kerberos
 - Don't segfault on un-implemented backend functions
 - Add comments.

Andrew Bartlett
2007-10-10 12:56:56 -05:00
Andrew Bartlett
e48557158e r1439: Once we are authenticated, always return NT_STATUS_OK. (Makes SPENGO
easier to code, as it may return an 'ok' with an empty blob).

Andrew Bartlett
2007-10-10 12:56:56 -05:00