1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00
Commit Graph

207 Commits

Author SHA1 Message Date
Andrew Tridgell
682a02d7d4 r1634: to get signing right for async requests we must send requests in
order. Fixed the linked list add to always add to the end for outgoing
requests.
(This used to be commit 81c450b434)
2007-10-10 12:57:45 -05:00
Andrew Tridgell
53781e9d37 r1633: fixed a couple of async oplock handling errors
(This used to be commit d7e2f39b90)
2007-10-10 12:57:45 -05:00
Andrew Tridgell
cfdd3e68be r1631: don't use req->transport after req has been destroyed
(This used to be commit 35f4ad4700)
2007-10-10 12:57:45 -05:00
Andrew Tridgell
94fb514376 r1630: - fixed the replacement timegm() function to work correctly for DST changes
- got rid of global_myname(), using lp_netbios_name() instead
(This used to be commit e8d4b39088)
2007-10-10 12:57:45 -05:00
Andrew Tridgell
f0ff2eccad r1627: make sure we initialise write_time in the deprecated function cli_ctemp()
(This used to be commit 48b5b740f1)
2007-10-10 12:57:44 -05:00
Andrew Tridgell
ae81794cf8 r1619: - add support for older systems to cli_list*()
- make cli_list_new() use the last_name continue method rather than
   the trans2 findnext continue flag, as the continue flag is broken on
   win2003 (win2003 sometimes misses up to 1/3 of all files in a directory)
(This used to be commit daa9648b3f)
2007-10-10 12:57:44 -05:00
Andrew Tridgell
27ce337277 r1618: fixed the receipt of multi-part replies to SMBtrans2
(This used to be commit bd4106a8e5)
2007-10-10 12:57:44 -05:00
Andrew Bartlett
188a8014ea 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
(This used to be commit 8a0f7bf5e2)
2007-10-10 12:57:44 -05:00
Andrew Bartlett
f1a215f5cb r1604: Samba4 avoids memcpy() as much as possible - we don't need to make a copy here.
Andrew Bartlett
(This used to be commit 9efc94eeaf)
2007-10-10 12:57:43 -05:00
Andrew Tridgell
2de2ead42d r1603: fixed in.size to not overstate the packet size by 4 bytes
my apologies to abartlett for thinking this was his bug!
(This used to be commit 6edbc55ddd)
2007-10-10 12:57:43 -05:00
Andrew Tridgell
b5061894dc r1602: make sure we honor the use_spnego flag
(This used to be commit de764d9004)
2007-10-10 12:57:43 -05:00
Andrew Tridgell
5ddf678e01 r1578: the first stage of the async client rewrite.
Up to now the client code has had an async API, and operated
asynchronously at the packet level, but was not truly async in that it
assumed that it could always write to the socket and when a partial
packet came in that it could block waiting for the rest of the packet.

This change makes the SMB client library full async, by adding a
separate outgoing packet queue, using non-blocking socket IO and
having a input buffer that can fill asynchonously until the full
packet has arrived.

The main complexity was in dealing with the events structure when
using the CIFS proxy backend. In that case the same events structure
needs to be used in both the client library and the main smbd server,
so that when the client library is waiting for a reply that the main
server keeps processing packets. This required some changes in the
events library code.

Next step is to make the generated rpc client code use these new
capabilities.
(This used to be commit 96bf4da3ed)
2007-10-10 12:57:42 -05:00
Stefan Metzmacher
d093b7e777 r1547: rename 'enum <bla>_level' -> 'enum smb_<bla>_level'
e.g. we now have 'union smb_mkdir' and 'enum smb_mkdir_level' in sync

we may should also rename 'RAW_MKDIR_*' -> 'SMB_MKDIR_*'

metze
(This used to be commit 0bb50dcf1c)
2007-10-10 12:57:41 -05:00
Andrew Bartlett
b3c46674a6 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
(This used to be commit 35b83eb329)
2007-10-10 12:57:39 -05:00
Andrew Bartlett
f607197054 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
(This used to be commit b97d3cb2ef)
2007-10-10 12:57:35 -05:00
Stefan Metzmacher
71d28b8265 r1497: add forward declaration for struct auth_session_info
(fix compiler warning)

metze
(This used to be commit 65147f5aa2)
2007-10-10 12:57:35 -05:00
Stefan Metzmacher
ad8d0190f1 r1494: fix debug message
metze
(This used to be commit 463982bf3f)
2007-10-10 12:57:35 -05:00
Andrew Bartlett
a92d87f1f7 r1476: Don't print messages about the CCACHE not being found - this is normal.
Andrew Bartlett
(This used to be commit 30d88580ef)
2007-10-10 12:57:34 -05:00
Andrew Bartlett
ed03516c91 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
(This used to be commit de5da66939)
2007-10-10 12:57:34 -05:00
Stefan Metzmacher
bff4e6963c r1469: fix a segfault and compiler warning,
introduced by the "compiler warning fix" in rev 1460...

metze
(This used to be commit ffb7ba35cd)
2007-10-10 12:57:33 -05:00
Stefan Metzmacher
e5173cfd3a r1467: disable gensec_krb5 by default till abartlet
add the kinit code

metze
(This used to be commit 9a876be76c)
2007-10-10 12:57:33 -05:00
Andrew Tridgell
7193ed3998 r1466: the name "oid" is taken by some silly system headers - avoid it in our code
(This used to be commit ea5659b051)
2007-10-10 12:57:33 -05:00
Stefan Metzmacher
39c3f22034 r1463: fix the krb5 build
metze
(This used to be commit fc8d00b8ab)
2007-10-10 12:57:32 -05:00
Andrew Bartlett
88002b851b 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
(This used to be commit cea578d6f3)
2007-10-10 12:57:32 -05:00
Andrew Bartlett
b62e6f1ec1 r1461: ntlm_check.c is a server-side peice of code, so it belongs in AUTH.
Andrew Bartlett
(This used to be commit 67ac960066)
2007-10-10 12:57:32 -05:00
Andrew Bartlett
e053c719ab r1460: Avoid a compile warning.
Andrew Bartlett
(This used to be commit 10a973da88)
2007-10-10 12:57:32 -05:00
Andrew Bartlett
df290b04df r1457: Add the GSSAPI layer to our gensec_krb5 code.
Andrew Bartlett
(This used to be commit 893a9a3865)
2007-10-10 12:56:58 -05:00
Jelmer Vernooij
fb8ae4518a r1451: More missing files...
(This used to be commit 7e9884799e)
2007-10-10 12:56:58 -05:00
Jelmer Vernooij
453e1e79fb r1450: Oops.. Missing files :-)
(This used to be commit eaa2940ba0)
2007-10-10 12:56:57 -05:00
Jelmer Vernooij
396a729686 r1449: Use the config system somewhat better in libcli/auth
(This used to be commit 69de0d95c5)
2007-10-10 12:56:57 -05:00
Andrew Bartlett
f9ddbad006 r1448: Indent this so proto doesn't pick it up.
Andrew Bartlett
(This used to be commit 1164be10af)
2007-10-10 12:56:57 -05:00
Andrew Bartlett
7980759352 r1447: Fix compile.
Andrew Bartlett
(This used to be commit b97ea8a63f)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
59a3aece81 r1446: Another funciton to avoid in proto.h
Andrew Bartlett
(This used to be commit 310a570936)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
f17eb8f2a9 r1445: Ensure get_auth_data_from_tkt doesn't get into proto.h
Andrew Bartlett
(This used to be commit 159c234589)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
bd38d43214 r1443: More changes towards Kerberos in Samba4's GENSEC.
The kerberos context is now tied in life to the GENSEC context.

Andrew Bartlett
(This used to be commit 64e99170c3)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
0f3f9090fa r1442: I was going to rename kerberos.c -> kerberos_kinit.c, but didn't.
Fix config.mk...

(oh, and this file is somehow marked as binary...)

Andrew Bartlett
(This used to be commit 3e9aa67e3f)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
b615397325 r1441: Indentation and comment fixes.
Andrew Bartlett
(This used to be commit 231e505dea)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
b0d94c8e7d r1440: GENSEC improvements:
- Infrustructure for kerberos
 - Don't segfault on un-implemented backend functions
 - Add comments.

Andrew Bartlett
(This used to be commit 1c31aa4271)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
43e7d4109f 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
(This used to be commit e48557158e)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
47fc62a097 r1438: Record the principal name we are sent in the SPENGO mechListMIC in a
seperate char *, not a DATA_BLOB.

This allows us to tell if we were sent a string here, or a real MIC.
(This used to be commit 06b997c826)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
b0d61c8b42 r1437: Intermediate commit of krb5 for GENSEC.
The session key in the client is wrong, we don't do signing/sealing
and we are sending raw Kerberos, not GSSAPI.

But it's a start, and if we continue to have to call Krb5 directly,
this will be the basis.

I also intend to provide an alternate implementation, using just
GSSAPI.

Andrew Bartlett
(This used to be commit eb0dd4a821)
2007-10-10 12:56:56 -05:00
Andrew Bartlett
74508c718b r1436: Move GENSEC across to config.mk
Andrew Bartlett
(This used to be commit 2de3a30823)
2007-10-10 12:56:55 -05:00
Stefan Metzmacher
efb010202f r1429: enable spnego in smbclient too.
metze
(This used to be commit ae2e6b5862)
2007-10-10 12:56:55 -05:00
Andrew Bartlett
102f5bc17d r1426: Fix some of my silly compile errors...
Andrew Bartlett
(This used to be commit c283837556)
2007-10-10 12:56:55 -05:00
Andrew Bartlett
82e59d11c3 r1423: Make sure to destory the mem_ctx.
Andrew Bartlett
(This used to be commit c5a1529d54)
2007-10-10 12:56:55 -05:00
Stefan Metzmacher
7caf17319a r1421: fix a uninitialized var (thanks valgrind:-)
add a view debug messages

metze
(This used to be commit 79953dccc1)
2007-10-10 12:56:54 -05:00
Stefan Metzmacher
7381ba30c4 r1420: be more strict reject if the context has the wrong type
metze
(This used to be commit db19d6047c)
2007-10-10 12:56:54 -05:00
Andrew Bartlett
bdb0b60861 r1418: Merge Samba 3.0's recent kerberos changes into Samba4. None of this
is used yet.

Andrew Bartlett
(This used to be commit 7596f311c9)
2007-10-10 12:56:54 -05:00
Stefan Metzmacher
2c87cb390d r1409: if we have no user name don't use extended security
the capabilities in the union smb_sesssetup should be used to decide
if we can use extented security

metze
(This used to be commit e3760fcc17)
2007-10-10 12:56:54 -05:00
Stefan Metzmacher
0fa2b94c56 r1406: I got spnego in the smb client working
so I set 'use spnego = True'

metze
(This used to be commit e06898f88c)
2007-10-10 12:56:54 -05:00