1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-15 05:57:49 +03:00

36 Commits

Author SHA1 Message Date
Andrew Bartlett
ded3303352 r4682: A LDB-based secrets implementation in Samba4.
This uses LDB (a local secrets.ldb and the global samdb) to fill out
the secrets from an LSA perspective.

Some small changes to come, but the bulk of the work is now done.

A re-provision is required after this change.

Andrew Bartlett
2007-10-10 13:08:42 -05:00
Andrew Tridgell
b0f6e21481 r4054: got rid of Realloc(), replacing it with the type safe macro realloc_p() 2007-10-10 13:06:19 -05:00
Andrew Tridgell
80d15fa340 r4052: fixed a bunch of code to use the type safe _p allocation macros 2007-10-10 13:06:18 -05:00
Stefan Metzmacher
0614fa3b16 r3965: fix compiler warnings
metze
2007-10-10 13:06:08 -05:00
Stefan Metzmacher
dfb062c63c r3581: fix some signedness warnings with gcc-4.0
(there some callers to be fixed later)

metze
2007-10-10 13:05:35 -05:00
Andrew Tridgell
558de54ec6 r3494: got rid of include/rewrite.h, and split out the dynconfig.h header 2007-10-10 13:05:22 -05:00
Andrew Tridgell
7842b23d01 r3457: s_addr is a macro on solaris, so we can't use it in structure names. arrgh. 2007-10-10 13:05:15 -05:00
Andrew Tridgell
6b1f86aea8 r3449: more include file reduction
the ldb part isn't ideal, I will have to think of a better solution
2007-10-10 13:05:13 -05:00
Andrew Tridgell
2e25c71853 r3443: the next stage in the include files re-organisation.
I have created the include/system/ directory, which will contain the
wrappers for the system includes for logical subsystems. So far I have
created include/system/kerberos.h and include/system/network.h, which
contain all the system includes for kerberos code and networking code.
These are the included in subsystems that need kerberos or networking
respectively.

Note that this method avoids the mess of #ifdef HAVE_XXX_H in every C
file, instead each C module includes the include/system/XXX.h file for
the logical system support it needs, and the details are kept isolated
in include/system/

This patch also creates a "struct ipv4_addr" which replaces "struct
in_addr" in our code. That avoids every C file needing to import all
the system networking headers.
2007-10-10 13:05:11 -05:00
Andrew Tridgell
73ea8ee6c2 r3441: some include file cleanups and general housekeeping 2007-10-10 13:05:11 -05:00
Andrew Tridgell
7e942e7f1b r3360: improved the deletion of tmp files. smbd now puts all tmp files in var/locks/smbd.tmp/
and deletes that dir on startup.
2007-10-10 13:05:01 -05:00
Andrew Tridgell
ffa285bc78 r3357: removed the need to use TDB_CLEAR_IF_FIRST in Samba4.
We found a few months ago that TDB_CLEAR_IF_FIRST is extremely
inefficient for large numbers of connections, due to a fundamental
limitation in the way posix byte range locking is implemented. Rather
than the nasty workaround we had for Samba3, we now have a single
"cleanup tmp files" function that runs when smbd starts. That deletes
the tmp tdbs, so TDB_CLEAR_IF_FIRST is not needed at all.
2007-10-10 13:05:00 -05:00
Andrew Tridgell
7f2c771b0e r3278: - rewrote the client side rpc connection code to use lib/socket/
rather than doing everything itself. This greatly simplifies the
  code, although I really don't like the socket_recv() interface (it
  always allocates memory for you, which means an extra memcpy in this
  code)

- fixed several bugs in the socket_ipv4.c code, in particular client
  side code used a non-blocking connect but didn't handle EINPROGRESS,
  so it had no chance of working. Also fixed the error codes, using
  map_nt_error_from_unix()

- cleaned up and expanded map_nt_error_from_unix()

- changed interpret_addr2() to not take a mem_ctx. It makes absolutely
  no sense to allocate a fixed size 4 byte structure like this. Dozens
  of places in the code were also using interpret_addr2() incorrectly
  (precisely because the allocation made no sense)
2007-10-10 13:04:49 -05:00
Andrew Tridgell
247421ee64 r3004: removed some unused functions 2007-10-10 12:59:56 -05:00
Andrew Tridgell
2132d38f9c r2900: rusty pointed out to me that discard_const() can be done via a macro
on systems that have the intptr_t type, and for systems that don't
have it, they also almost certainly won't have -Wcast-qual, so we can use a
void* cast.
2007-10-10 12:59:46 -05:00
Andrew Tridgell
9a04664531 r2783: got rid of the unused remote architecture detection code 2007-10-10 12:59:32 -05:00
Andrew Tridgell
56ecda2178 r2634: use discard_const_p() in a few places 2007-10-10 12:59:14 -05:00
Andrew Tridgell
fec3288ad6 r2632: a new approach to handling const errors. We have had huge numbers of
const warnings for a long time, and no real way to approach a
solution. Some of them are unavoidable due to the way the C standard
works (for example, any function that provides strchr() like
functionality _must_ produce a const warning)

I will be converting a bunch of places that currently produce const
warnings to use the discard_const_p(). Some of these will be
unavoidable const problems, some of them will be ones we will fix up
over time. At least this change means we will no longer be swamped
with const warnings, and we will easily be able to see when new
problems emerge.
2007-10-10 12:59:14 -05:00
Andrew Bartlett
fd10c9dd53 r2514: Remove unused funcions, and add static.
Andrew Bartlett
2007-10-10 12:59:01 -05:00
Jim McDonough
d2553aac0a r1596: Fix up copyrights. 2007-10-10 12:57:43 -05:00
Andrew Bartlett
e8de8905b2 r1434: Merge this function in from Samba 3.0, but use a mem_ctx rather than
an fstring.

Andrew Bartlett
2007-10-10 12:56:55 -05:00
Stefan Metzmacher
4daf1bafc7 r1308: move smb_panic() to lib/fault.c
merge the backtrace stuff from 3.0

metze
2007-10-10 12:56:50 -05:00
Stefan Metzmacher
60f823f201 r1291: rename struct smbsrv_context to smbsrv_connection
because this is the connection state per transport layer (tcp)
connection

I also moved the substructs directly into smbsrv_connection,
because they don't need a struct name and we should allway pass the complete
smbsrv_connection struct into functions

metze
2007-10-10 12:56:49 -05:00
Stefan Metzmacher
0712f9f307 r1277: rename struct server_context to smbsrv_ontext
because I need server_context fot the generic server infastructure

metze
2007-10-10 12:56:48 -05:00
Andrew Bartlett
4a445fce7f r1163: Add const.
Andrew Bartlett
2007-10-10 12:56:42 -05:00
Andrew Bartlett
5d39d7497f r1123: Make all lp_ string functions return 'const char *'.
Fix other 'const' warnings in the torture code.

Andrew Bartlett
2007-10-10 12:56:38 -05:00
Stefan Metzmacher
57151e80eb r962: convert 'unsigned' and 'unsigned int' to uint_t
metze
2007-10-10 12:56:23 -05:00
Stefan Metzmacher
9f914e4af9 r961: convert 'uchar' to 'uint8_t'
metze
2007-10-10 12:56:23 -05:00
Stefan Metzmacher
18062d2ed9 r960: convert 'unsigned int' to uint_t in the most places
metze
2007-10-10 12:56:23 -05:00
Stefan Metzmacher
b5378803fd r943: change samba4 to use 'uint8_t' instead of 'unsigned char'
metze
2007-10-10 12:56:21 -05:00
Stefan Metzmacher
0e5517d937 r884: convert samba4 to use [u]int32_t instead of [u]int32
metze
2007-10-10 12:56:15 -05:00
Stefan Metzmacher
cbfa29549e remove unused NISPLUS/AUTOMOUNT stuff
metze
-
Andrew Tridgell
3f85f9b782 added a basic dcerpc endpoint mapper to Samba4. Currently only
implements the epm_Lookup() call, I'll add the other important calls
soon. I was rather pleased to find that epm_Lookup() worked first
time, which is particularly surprising given its complexity.

This required quite a bit of new infrastructure:

  * a generic way of handling dcerpc policy handles in the rpc server

  * added type checked varients of talloc. These are much less error
    prone. I'd like to move to using these for nearly all uses of
    talloc.

  * added more dcerpc fault handling code, and translation from
    NTSTATUS to a dcerpc fault code

  * added data_blob_talloc_zero() for allocating an initially zero
    blob

  * added a endpoint enumeration hook in the dcerpc endpoint server
    operations
-
Andrew Tridgell
c18c9b5585 signed DCERPC over TCP now works !
* moved ntlmssp code into libcli/auth/, and updated to latest ntlmssp
   code from samba3 (thanks Andrew! the new interface is great)

 * added signing/ntlmssp support in the dcerpc code

 * added a dcerpc_auth.c module for the various dcerpc auth mechanisms
-
Andrew Tridgell
8a82050fd6 * fixed byte order in epmapper parsing
* allow rpc transport to be specified on command line in smbtorture
-
Andrew Tridgell
b0510b5428 first public release of samba4 code -