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

725 Commits

Author SHA1 Message Date
Andrew Tridgell
23ba434b01 r2469: complete overhaul of the old-style RAW_SEARCH_ calls (the OS/2 and
original core level calls). The old code was completely wrong in many respects.

also fixed the EA_SIZE level in the server

extended the RAW-SEARCH test suite to test the new code properly
(This used to be commit 71480271ad84b57fcdde264a54bb2408cf783255)
2007-10-10 12:58:56 -05:00
Andrew Tridgell
635d5d8800 r2459: added STATUS_NO_MORE_FILES nt status code
(This used to be commit 3bf55c9e1129d8036a968c49ac2de7260e657f53)
2007-10-10 12:58:55 -05:00
Andrew Tridgell
992442cbf9 r2456: got rid of some outdated global macros
(This used to be commit ea7eac5e3fb8f0db8d412a95ef4dc7889a07bc73)
2007-10-10 12:58:55 -05:00
Andrew Tridgell
677d1bc487 r2434: separate "attrib" and "ex_attrib" elements for DOS attributes is pointless
(This used to be commit 5fcad57128e47d4d6c0f387d5563d9de2fc08351)
2007-10-10 12:58:52 -05:00
Andrew Tridgell
03cb4367d6 r2404: the first large lump of posix vfs stuff.
this is still very much a skeleton (with many limbs missing too!). I
am committing this early to get some feedback on the approach taken.
(This used to be commit 40d5cae5ebbfe328e193eadb685df6a370730299)
2007-10-10 12:58:48 -05:00
Andrew Tridgell
2432c783ca r2386: fixed some indentation
(This used to be commit 1de5aa5b1d6a9b4b3ed18935c562b0bf03a4d94e)
2007-10-10 12:58:47 -05:00
Stefan Metzmacher
ce694e7051 r2328: add the start of a new system and protocol
independent socket library.

this is not used, but compiled currently

there're maybe some api changes later...

metze
(This used to be commit de4447d7a57c614b80d0ac00dca900ea7e1c21ea)
2007-10-10 12:58:44 -05:00
Stefan Metzmacher
a560d554bd r2321: add complately untested LDAP server start
based on volker's patch

this is compiled by default but not started by default

metze
(This used to be commit 5387bc423d4dc669cbac6626f8dd3a5498a6519d)
2007-10-10 12:58:43 -05:00
Andrew Tridgell
3ddde3b74c r2242: some older versions of gcc don't properly handle the
PRINTF_ATTRIBUTE() format checking magic, so only enable it for gcc
versions >= 3.0
(This used to be commit 9c7100e3c770fca163d3788fc6b735457f74d7e9)
2007-10-10 12:58:34 -05:00
Andrew Tridgell
31c1c7846f r2159: converted samba4 over to UTF-16.
I had previously thought this was unnecessary, as windows doesn't use
standards compliant UTF-16, and for filesystem operations treats bytes
as UCS-2, but Bjoern Jacke has pointed out to me that this means we
don't correctly store extended UTF-16 characters as UTF-8 on
disk. This can be seen with (for example) the gothic characters with
codepoints above 64k.

This commit also adds a LOCAL-ICONV torture test that tests the first
1 million codepoints against the system iconv library, and tests 5
million random UTF-16LE buffers for identical error handling to the
system iconv library.

the lib/iconv.c changes need backporting to samba3
(This used to be commit 756f28ac95feaa84b42402723d5f7286865c78db)
2007-10-10 12:58:27 -05:00
Andrew Tridgell
600144050c r2039: got rid of the free() ptr in DATA_BLOB
I plan on replacing the concept by adding a generic destructor in all talloc ptrs, so you can do:

  talloc_set_destructor(ptr, my_destructor);

to setup a function that will be called on free.
(This used to be commit 957b260621c091830c01e9e8c370c199350342ec)
2007-10-10 12:58:19 -05:00
Stefan Metzmacher
45a69c44e7 r2005: fix compiler warnings
metze
(This used to be commit 71992c90cc35179ea8783d770c89b16618e1adc6)
2007-10-10 12:58:17 -05:00
Andrew Tridgell
b7e1ea20dc r1985: take advantage of the new talloc in a few more places
(This used to be commit 6ffdfd779936ce8c5ca49c5f444e8da2bbeee0a8)
2007-10-10 12:58:14 -05:00
Andrew Tridgell
b45f4ebbb8 r1984: this change is what you should read to understand the new talloc()
It simplifies our structure handling a lot, making the code shorter
and easier to understand. Look at the diff carefully and see if you
can understand it. If you're still confused then please ask.
(This used to be commit 03c341aca7f09cb1f0d33ec65e074e6a00caa30f)
2007-10-10 12:58:14 -05:00
Andrew Tridgell
b83ba93eae r1983: a completely new implementation of talloc
This version does the following:

  1) talloc_free(), talloc_realloc() and talloc_steal() lose their
     (redundent) first arguments

  2) you can use _any_ talloc pointer as a talloc context to allocate
     more memory. This allows you to create complex data structures
     where the top level structure is the logical parent of the next
     level down, and those are the parents of the level below
     that. Then destroy either the lot with a single talloc_free() or
     destroy any sub-part with a talloc_free() of that part

  3) you can name any pointer. Use talloc_named() which is just like
     talloc() but takes the printf style name argument as well as the
     parent context and the size.

The whole thing ends up being a very simple piece of code, although
some of the pointer walking gets hairy.

So far, I'm just using the new talloc() like the old one. The next
step is to actually take advantage of the new interface
properly. Expect some new commits soon that simplify some common
coding styles in samba4 by using the new talloc().
(This used to be commit e35bb094c52e550b3105dd1638d8d90de71d854f)
2007-10-10 12:58:14 -05:00
Stefan Metzmacher
d139dc808a r1912: move popt_common.h
metze
(This used to be commit ecf6be894fc47f9e00f46531e06ef20e11115c0f)
2007-10-10 12:58:10 -05:00
Stefan Metzmacher
bca24a19eb r1911: merge a few popt parameters from 3.0 move some to better places
and deal with users DOMAIN and lp_workgroup() of the local workstation

metze
(This used to be commit 1fc0100e44a8640cfc15effb99f5824cb7817da8)
2007-10-10 12:58:10 -05:00
Stefan Metzmacher
a154ed7291 r1903: hmm a better solution is to include popt.h where it is needed
metze
(This used to be commit 64d61ef4a5b44e76c90914ebaeaafac58228d78c)
2007-10-10 12:58:10 -05:00
Stefan Metzmacher
045bdb356f r1902: we need to include popt.h before popt_common.h
metze
(This used to be commit edde7497e9e06be0e51e886981725271a85bd9e5)
2007-10-10 12:58:09 -05:00
Andrew Tridgell
70f630d375 r1895: added a note about OPEN_BY_FILE_ID to the ntcreatex interface definition
(This used to be commit e50fc00671ace0085632f35ec99ad1125cd4d546)
2007-10-10 12:58:09 -05:00
Volker Lendecke
664f50e81c r1894: Convert // to /* */
(This used to be commit 5dc793b2b4b5c54df4aa3b0c98c248bdd671bbb1)
2007-10-10 12:58:09 -05:00
Stefan Metzmacher
f7c842707a r1877: since make proto catches all functions
the inlcude has to move to includes.h

metze
(This used to be commit 97fe38183b6a03c01f6ac2d28a958d632eb4ff8a)
2007-10-10 12:58:06 -05:00
Stefan Metzmacher
d3e7a22630 r1836: - as abartlet said to me, we need to contact the users domain pdcfor doing a
password change
- add start of libnet_SetPassword
- use KRB5 and LDAP instead of ADS as ADS isn't a protocol
- add start of lib_rpc_connect()

metze
(This used to be commit 05c40dca8ad1ab020aa75282da046f1dbce2a52a)
2007-10-10 12:58:00 -05:00
Andrew Bartlett
7b088a8f65 r1796: Enable server-side SPNEGO, now that I have fixed the server-side SMB
signing code to be able to cope.

Andrew Bartlett
(This used to be commit cb74d52b563730a50e33c92d868c45ee96a598e8)
2007-10-10 12:57:57 -05:00
Simo Sorce
28ea8b8785 r1785: remove unneeded dependencies on openldap client libraries
(This used to be commit 44083e317855f6d8a0b4a81002a3376e8775df28)
2007-10-10 12:57:56 -05:00
Simo Sorce
76abf79a5f r1760: name the struct
(This used to be commit 512c410860a5947c94187454d7220ad1df08a6c0)
2007-10-10 12:57:54 -05:00
Stefan Metzmacher
fa8d37adae r1756: merge volkers ldap client lib to samba4 for simo to start with the
ldap server code

it's not compiled in yet...

metze
(This used to be commit 48939adca1332ff90f9287311c0e9ff3e2e5917a)
2007-10-10 12:57:54 -05:00
Andrew Bartlett
ffcfb97fb3 r1745: More work on cleaning up SMB signing.
This removes the function pointer mess from the SMB signing code.

Andrew Bartlett
(This used to be commit 8830603e4bc821a11db87072a32a51b076a28e06)
2007-10-10 12:57:52 -05:00
Andrew Bartlett
ca72bdfecb r1735: Clean up SMB signing - we don't have more than one 'real' way to sign
a packet, so don't pretend we do...

Andrew Bartlett
(This used to be commit 68a6d5aeb35e8972182fffbb6cc506f89584b2d5)
2007-10-10 12:57:51 -05:00
Andrew Bartlett
d9ff454a87 r1729: Make the SMB signing code more generic (to share more between client and servers).
Andrew Bartlett
(This used to be commit b90b04e84bc8add235cf9ee7797a608ff48c4ca0)
2007-10-10 12:57:50 -05:00
Andrew Bartlett
6ffaf57fe7 r1686: Don't use a void* for the context inside the SMB signing code.
Andrew Bartlett
(This used to be commit 64fcd8ecebabdd09fed6b65e3c436bffc1da9de7)
2007-10-10 12:57:48 -05:00
Stefan Metzmacher
c5fbb6f23c r1654: rename cli_ -> smbcli_
rename CLI_ -> SMBCLI_

metze
(This used to be commit 8441750fd9427dd6fe477f27e603821b4026f038)
2007-10-10 12:57:47 -05:00
Andrew Tridgell
53781e9d37 r1633: fixed a couple of async oplock handling errors
(This used to be commit d7e2f39b90122088e94d4a8e8c7ffa7c91d7d664)
2007-10-10 12:57:45 -05:00
Andrew Tridgell
2d9adf1ea5 r1629: server_zone needs to be "int" not "int16_t" as it can hold values
larger than 35536 (the max value is actually 12*3600 == 43200)
(This used to be commit 78dcaddbb78574b7f489989df0b1f979677bb7d5)
2007-10-10 12:57:45 -05:00
Jim McDonough
112c2c831b r1596: Fix up copyrights.
(This used to be commit d2553aac0a75591026b9b1fcf46065e5b03ed19c)
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 96bf4da3edc4d64b0f58ef520269f3b385b8da02)
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 0bb50dcf1ccb9797000fcbea4d8a73f2d2a3db77)
2007-10-10 12:57:41 -05:00
Andrew Tridgell
bacee255dd r1523: declaring variables "in" and "out" in every C module is a bad idea!
I actually don't like this idea of sharing the request buffer
structure between client and server, and I'll see if I can convince
abartlet to revert it. It ties the two pieces of code far more
intimately than is justified, and will certainly lead to ugliness as
the client and server take different paths of development. I would far
prefer we just pass 2 arguments (pointer and length) to the signing
calls instead of 1 (the request).
(This used to be commit 70838a921185c091d0e774dd5fb0546693999e8f)
2007-10-10 12:57:39 -05:00
Andrew Bartlett
afb48b55ae r1522: Oops - I forgot this file in the prvevious commit.
This breaks the request structure out into a common part between the
client and server, which the signing code now uses.

Andrew Bartlett
(This used to be commit 33de58455a3674e8fc803fb043d26af4e2794c30)
2007-10-10 12:57:39 -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 35b83eb329482ac1b3bc67285854cc47844ff353)
2007-10-10 12:57:39 -05:00
Stefan Metzmacher
5779a7da9a r1499: combine struct user_struct and struct smbsrv_user
to a struct smbsrv_session that the same as cli_session for the client

we need a gensec_security pointer there
(spnego support will follow)

prefix some related functions with smbsrv_

metze
(This used to be commit f276378157bb9994c4c91ce46150a510de5c33f8)
2007-10-10 12:57:36 -05:00
Stefan Metzmacher
45a85bdd35 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
(This used to be commit bbe5e00715ca4013ff0dbc345aa97adc6b5c2458)
2007-10-10 12:57:35 -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 de5da669397db4ac87c6da08d3533ca3030da2b0)
2007-10-10 12:57:34 -05:00
Volker Lendecke
3a6f761eb0 r1470: Get the smb_trans2 structure out of the rap_cli_call struct.
Initial attempt at RAP server infrastructure. Look at rap_server.c for the
dummy functions that are supposed to implement the core functionality.

ipc_rap.c contains all the data shuffling. _rap_shareenum and _rap_serverenum2
in ipc_rap.c are (I think) regular enough to be auto-generated.

I did not test all the corner cases yet, but nevertheless I would like some
comments on the general style.

Volker

P.S: samba-3 smbclient now doesn't freak out anymore, although the results are
not entirely correct :-)
(This used to be commit 08140cc1a838b4eaa23c897b280a46c95b7ef3e0)
2007-10-10 12:57:33 -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 cea578d6f39a2ea4a24e7a0064c95193ab6f6df7)
2007-10-10 12:57:32 -05:00
Jelmer Vernooij
805ebe1084 r1455: More Gtk+ updates:
- Start working on 'gwsam'
 - Add GtkSelectDomainDialog and GtkSelectHostDialog
(This used to be commit bea47671aa791f3c4d22263f9444aea1a73f47f1)
2007-10-10 12:56:58 -05:00
Volker Lendecke
ec3a86254b r1454: Today is the day of broken builds, now I get my share ... :-)
Add a missing file.

Volker
(This used to be commit 2bc6147c118a61f7f37f3414cce3df44625ade65)
2007-10-10 12:56:58 -05:00
Jelmer Vernooij
e3fd2d0492 r1432: - Move the various Gtk-specific parts from the registry code into a directory gtk/
- Move common "Samba-Gtk" code into gtk/common/ ("Connect to RPC pipe"-dialog, etc)
- Add a new utility 'gwcrontab' that can currently list, delete and add 'atsvc' jobs. It still displays times and dates as integers though, will fix that later.

Some screenshots available at:
 http://samba.org/~jelmer/gwcrontab/
(This used to be commit d321cf20f1f0ff33603b013c26d370669f255868)
2007-10-10 12:56:55 -05:00
Stefan Metzmacher
4f0e5e0690 r1345: add extended security spnego support to the smb client
code

set lp_use_spnego = False, because I can't get it working yet
but I commit it so others can help me

metze
(This used to be commit 2445cceba9ab9bd928c8bc50927a39509e4526b0)
2007-10-10 12:56:51 -05:00
Stefan Metzmacher
854665fb1b r1343: formating
metze
(This used to be commit 442905394b5e2f74baa4d83b2f4ba5159f321dd2)
2007-10-10 12:56:51 -05:00