1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-28 17:47:29 +03:00

1602 Commits

Author SHA1 Message Date
Simo Sorce
6f18b19519 r12810: handle control options gracefully and don't segfault
(This used to be commit 300d48bc9daa13e1475c10eaa1ec0717c822a7f7)
2007-10-10 13:49:58 -05:00
Andrew Bartlett
f55ea8bb3d r12804: This patch reworks the Samba4 sockets layer to use a socket_address
structure that is more generic than just 'IP/port'.

It now passes make test, and has been reviewed and updated by
metze. (Thankyou *very* much).

This passes 'make test' as well as kerberos use (not currently in the
testsuite).

The original purpose of this patch was to have Samba able to pass a
socket address stucture from the BSD layer into the kerberos routines
and back again.   It also removes nbt_peer_addr, which was being used
for a similar purpose.

It is a large change, but worthwhile I feel.

Andrew Bartlett
(This used to be commit 88198c4881d8620a37086f80e4da5a5b71c5bbb2)
2007-10-10 13:49:57 -05:00
Jelmer Vernooij
5c8447773f r12801: Some more include/ cleanups (remove unused macros + move files
to specific dirs)
(This used to be commit 243cf760b077e155f5ac508aeebf819f7708a84e)
2007-10-10 13:49:57 -05:00
Stefan Metzmacher
8d15aee017 r12799: print out function and location too
metze
(This used to be commit a5ef3eef9cbedd273556068ba59c07ccb0060098)
2007-10-10 13:49:57 -05:00
Stefan Metzmacher
3c13509c06 r12798: print timestamps into the log file, this is not nice code,
but it works for now

metze
(This used to be commit ec7dbb5a98c112e86399ffcff14eb42c99d8e31d)
2007-10-10 13:49:56 -05:00
Stefan Metzmacher
39212a4960 r12790: fix compiler warning
metze
(This used to be commit c65ebc8b5574f9bd05270964dee9d4882e2d1828)
2007-10-10 13:49:55 -05:00
Andrew Tridgell
374da729dd r12785: make the iface_*() functions return strings which do not get
overwritten by another call (due to the implied static in
iface_ntoa()). This should save abartlet some pain
(This used to be commit 2244f298ace9f8832695cafd17c54324c11416f1)
2007-10-10 13:49:55 -05:00
Andrew Tridgell
dc0dde70d8 r12783: add a comment about matching more than 1 handler per message (andrew
thought this might be a bug)
(This used to be commit e1cd3f4b89e10c9a42f5939377df0eafb8c184a4)
2007-10-10 13:49:54 -05:00
Stefan Metzmacher
7fcf10609b r12777: use TEST_DATA_PREFIX if available
metze
(This used to be commit 7e702939faf70d0c02fa71b315043795bc4a1d84)
2007-10-10 13:49:53 -05:00
Stefan Metzmacher
887eae8516 r12774: - fix the build on OpenBSD
I'll try to remove TIME_T_MIN/TIME_T_MAX completly later,
but for now I try to build on all platfarms

metze
(This used to be commit d51244b6613dc07076da56937d09e4020c596475)
2007-10-10 13:49:53 -05:00
Simo Sorce
b589ac5d86 r12770: Remove the alloca.h header as it is not used in the code afaics
(This used to be commit d4454287cf14cfdf1ceeb090da40492314703fb9)
2007-10-10 13:49:52 -05:00
Stefan Metzmacher
74eb3f2af1 r12761: get the TIME_T_MIN and TIME_T_MAX right again, merging from samba3 was a bad idea...
as in samba4 we use TIME_T_MIN = 0 (maybe we should do this in samba3 too) because
negativ values mean error.

but still restrict TIME_T_MAX to INT32_MAX, to not overflow gmtime() on 64 bit systems,
is this behavior documented somewhere?

metze
(This used to be commit 333b1b8c4885c47a0d14d83896fce6740fa4d663)
2007-10-10 13:49:51 -05:00
Stefan Metzmacher
ddf0e3d046 r12754: - sync TIME_T_MAX calculation from samba3
- but limit TIME_T_MAX to INT32_MAX, otherwise 64 platfroms are broken
  because gmtime() will fail with INT64_MAX passed in!

I'm not sure if that's the best fix for this problem, but it works...

Should we port the INT32_MAX limitation to samba3?

Comments, please?

metze
(This used to be commit 396fa81be5b950aa2120cff19540a0236f79a685)
2007-10-10 13:49:50 -05:00
Simo Sorce
528470d4a7 r12748: Fix wrong handling of separation characters for RDNs
allow escaped separation chars as part of the attr value
of an RDN
(This used to be commit 7ba341d6c3745cd99c4c79933f9bd54f41e12a9c)
2007-10-10 13:49:49 -05:00
Andrew Bartlett
a8eec31354 r12746: An initial version of the kludge_acls module.
This should be replaced with real ACLs, which tridge is working on.
In the meantime, the rules are very simple:

- SYSTEM and Administrators can read all.

- Users and anonymous cannot read passwords, can read everything else

- list of 'password' attributes is hard-coded

Most of the difficult work in this was fighting with the C/js
interface to add a system_session() all, as it still doesn't get on
with me :-)

Andrew Bartlett
(This used to be commit be9d0cae8989429ef47a713d8f0a82f12966fc78)
2007-10-10 13:49:48 -05:00
Simo Sorce
b51fe793c7 r12745: Initial work to support a syntax to pass over controls via
command line to ldbsearch. Very rough work, no checks are
done on the input yet (will segfault if you make it wrong).
Controls are passed via the --controls switch an are comma
separated (no escaping yet).

General syntax is <ctrl_name>:<criticality>
<ctrl_name> is a string
<criticality> is 1 or 0

Current semi-parsed controls are:

server_sort
syntax: server_sort:1:0:attributename

	1st parm: criticality
	2nd parm: reversed
	3rd parm: attribute name to be used for sorting

todo:	still missing suport for multiple sorting
	  attributes and ordering rule
	no check on result code

paged_results
syntax: paged_results:1:100

	1st parm: criticality
	2nd parm: number of results to be returned

todo:	ldbsearch will return only the first batch
	  (missing code to cycle over conditionally)
	no check on result code

extended_dn
syntax: extended_dn:1:0

	1st parm: criticality
	2nd parm: type, see MS docs on meaning

Simo.
(This used to be commit 4c685ac0d1638a1d5392dfe733baf0db77e84858)
2007-10-10 13:49:48 -05:00
Simo Sorce
dbef4d76de r12743: Remove the ugly way we had to make a second stage init and introduce
a second_stage_init private function for modules that need a second stage init.

Simo.
(This used to be commit 5e8b365fa2d93801a5de1d9ea76ce9d5546bd248)
2007-10-10 13:49:48 -05:00
Simo Sorce
de296b6513 r12734: forgot to add qsort
(This used to be commit df1ccca3499015d68a6f9f86286d9f66b6c0476c)
2007-10-10 13:49:47 -05:00
Simo Sorce
c908d0b2aa r12733: Merge ldap/ldb controls into main tree
There's still lot of work to do but the patch is stable
enough to be pushed into the main samba4 tree.

Simo.
(This used to be commit 77125feaff252cab44d26593093a9c211c846ce8)
2007-10-10 13:49:47 -05:00
Andrew Bartlett
37bc6b5f81 r12728: Revive testparm.
It needs work to not dump defaults from loadparm.c, but otherwise it works.

Andrew Bartlett
(This used to be commit 1260fcf46579d708a406625f548add9be9fdc6fb)
2007-10-10 13:49:46 -05:00
Andrew Bartlett
28456784e9 r12717: Always compile the skel module, so we know when we break it.
Also fix up all the current issues with the skel module.

Andrew Bartlett
(This used to be commit d0a0a8de3fa73d8f06a801203e00b90ed8359b98)
2007-10-10 13:49:44 -05:00
Andrew Bartlett
5cea3edcef r12716: Tridge points out that the request argument to ldb_next_request must
be a valid talloc() pointer, as other modules may rely on this.

Andrew Bartlett
(This used to be commit 356c8c56090a7c4254609c0cc138c994b618fa55)
2007-10-10 13:49:44 -05:00
Andrew Bartlett
c5a6c7f61c r12710: Fix socket_wrapper: Make sure to fill in the socket family on the
returned address.

Andrew Bartlett
(This used to be commit 57b0aae0d4b52d9a9879c4606d2e4b3ef0d3d0d7)
2007-10-10 13:49:44 -05:00
Jelmer Vernooij
63d718e243 r12696: Reduce the size of include/structs.h
(This used to be commit 63917616016133c623fc6ff59454bc313ee7dd8f)
2007-10-10 13:49:40 -05:00
Jelmer Vernooij
78c50015bb r12694: Move some headers to the directory of the subsystem they belong to.
(This used to be commit c722f665c90103f3ed57621c460e32ad33e7a8a3)
2007-10-10 13:49:39 -05:00
Jelmer Vernooij
bc4aebfaec r12670: Make a couple of dependencies stricter
Re-introduce and use the OUTPUT_TYPE property for MODULEs to force
specific modules to always be included
(This used to be commit f9eede3d40098eddc3618ee48f9253cdddb94a6f)
2007-10-10 13:49:35 -05:00
Jelmer Vernooij
3b99d9c5bd r12658: Couple of fixes related to shared module builds.
(This used to be commit c297c93faf3b748de68679f5a4be50845ebe25fe)
2007-10-10 13:49:35 -05:00
Simo Sorce
93a3e9e2b6 r12643: don't fail make test
thanks Brad
(This used to be commit 2f213b9580cb9e84f1c44393cac521e5c1af817b)
2007-10-10 13:49:33 -05:00
Stefan Metzmacher
1d63dc5fe4 r12641: - remove some unused functions
- we already call usleep() directly in some places,
  so do it everywhere

metze
(This used to be commit 9eaf6e2c4d3dae3b6711e4aae3828222f5cab65e)
2007-10-10 13:49:33 -05:00
Stefan Metzmacher
d73156d2c4 r12638: fix the build on BSD systems
metze
(This used to be commit cd3cc29fdc2c0b9ffd82253857a7968e3324ea9b)
2007-10-10 13:49:11 -05:00
Andrew Tridgell
e4b7e8cdf1 r12633: expose talloc_vasprintf_append()
(This used to be commit 7a0e7074f6d3d38ce92f2b617549d5dbbaf968ef)
2007-10-10 13:49:10 -05:00
Andrew Bartlett
8d147a4dd3 r12632: Build fixes from Brad Hards <bradh@frogmouth.net>
Andrew Bartlett
(This used to be commit 44b107d3150135ee4381c1ba4eac23bfd9cb16b9)
2007-10-10 13:49:10 -05:00
Jelmer Vernooij
54613f5ae0 r12624: (hopefully) fix for BSD make after srcdir/builddir changes
(This used to be commit 261dc568f9b0e8641d3a28a03b440bddc5db668e)
2007-10-10 13:49:07 -05:00
Jelmer Vernooij
046a54f963 r12622: Move table.c prototypes to seperate header to prevent circular dependencies
with proto.h
(This used to be commit 9e0ba380374db028358158b9e4457dd930b5ab13)
2007-10-10 13:49:06 -05:00
Jelmer Vernooij
aa9f67163c r12620: Get rid of automatically generated lists of init functions of subsystems.
This allows Samba libraries to be used by other projects (and parts of
Samba to be built as shared libraries).
(This used to be commit 44f0aba715bfedc7e1ee3d07e9a101a91dbd84b3)
2007-10-10 13:49:06 -05:00
Stefan Metzmacher
eef64ba034 r12616: remove unused function, and we have iface_local() as replacement
metze
(This used to be commit 032d0a19eed485a9f0a11818b5296625f9489b2a)
2007-10-10 13:49:05 -05:00
Jelmer Vernooij
d4de4c2d21 r12608: Remove some unused #include lines.
(This used to be commit 70e7449318aa0e9d2639c76730a7d1683b2f4981)
2007-10-10 13:49:03 -05:00
Simo Sorce
a6d0d56459 r12605: docs patch from Brad Hards <bradh@frogmouth.net>
(This used to be commit 874f16e055ec30bf2ee52a33464b4810a8f8cd89)
2007-10-10 13:49:02 -05:00
Simo Sorce
0cf1feb114 r12604: fix make clean as Brad Hards <bradh@frogmouth.net> sugested
(This used to be commit 6198006ee466c6398f6a3da352d236034693ffb7)
2007-10-10 13:49:02 -05:00
Andrew Bartlett
a326d6dba9 r12601: Syncronise both copies of dlinklist.h.
Should we somehow link these, or just use the version in ldb?

Andrew Bartlett
(This used to be commit e98d14668e3fdee01b103adb5aec733790eee96d)
2007-10-10 13:49:01 -05:00
Andrew Bartlett
4ff20fcd31 r12600: Add a new module to sort the objectclass attribute on store. The
module is perhaps not the most efficient, but I think it is
reasonable.

This should restore operation of MMC against Samba4 (broken by the
templating fixes).

Andrew Bartlett
(This used to be commit 41948c4bdbfca1160a01a92994324f9e22422afe)
2007-10-10 13:49:01 -05:00
Andrew Bartlett
c82c9fe7bb r12599: This new LDB module (and associated changes) allows Samba4 to operate
using pre-calculated passwords for all kerberos key types.
(Previously we could only use these for the NT# type).

The module handles all of the hash/string2key tasks for all parts of
Samba, which was previously in the rpc_server/samr/samr_password.c
code.  We also update the msDS-KeyVersionNumber, and the password
history.  This new module can be called at provision time, which
ensures we start with a database that is consistent in this respect.

By ensuring that the krb5key attribute is the only one we need to
retrieve, this also simplifies the run-time KDC logic.  (Each value of
the multi-valued attribute is encoded as a 'Key' in ASN.1, using the
definition from Heimdal's HDB.  This simplfies the KDC code.).

It is hoped that this will speed up the KDC enough that it can again
operate under valgrind.
(This used to be commit e9022743210b59f19f370d772e532e0f08bfebd9)
2007-10-10 13:49:01 -05:00
Jelmer Vernooij
46aa296cc9 r12592: Remove some useless dependencies
(This used to be commit ca8db1a0cd77682ac2c6dc4718f5d753a4fcc4db)
2007-10-10 13:49:00 -05:00
Andrew Bartlett
a50b42dcb5 r12553: Steal the error string onto this context, so that the caller doesn't
have to think about exactly what the right context to hang it of is.

Andrew Bartlett
(This used to be commit b1c8adcfe16c72252b0312e65676edcdbe472f09)
2007-10-10 13:47:57 -05:00
Jelmer Vernooij
2cd5ca7d25 r12542: Move some more prototypes out to seperate headers
(This used to be commit 0aca5fd5130d980d07398f3291d294202aefe3c2)
2007-10-10 13:47:55 -05:00
Andrew Bartlett
451797744d r12540: Provide more information in the ldb error string.
Andrew Bartlett
(This used to be commit 31f65e510cdd46b1962cf06b3d51f152b1cecf37)
2007-10-10 13:47:54 -05:00
Andrew Bartlett
b1c80c3cfa r12534: Make the transaction code fill the error string on failure.
Andrew Bartlett
(This used to be commit 2f54d7f774434f2a8b89ae01e993c4a1d16ce861)
2007-10-10 13:47:53 -05:00
Andrew Tridgell
e4dbcc0d5d r12531: 'make quicktest' was taking 15 minutes on my system due to failing DNS
lookups in load_interfaces(). The reason was my eth0 interface was
down, and it was being interpreted as a DNS name.

This patch changes load_interfaces() to happening automatically when
interfaces are first needed instead of on the startup of every samba
binary. This means that (for example) ldbadd doesn't call
load_interfaces(), which means no slow DNS lookups.

I also reduced the number of static globals in interface.c to 1, and
changed from malloc to talloc

When you want to force a reload of the interfaces list, you now call
unload_interfaces(), which means the next call that needs the
interfaces list will reload it
(This used to be commit f79d90bd1364b970adb2981b2572e77066431f1e)
2007-10-10 13:47:52 -05:00
Jelmer Vernooij
0a3c167f6b r12528: Add seperate proto headers for ntvfs, tdr, smb_server and nbt_server.
(This used to be commit 87f665a1d5ba74289974bf9d8f9441c162e6f1b1)
2007-10-10 13:47:51 -05:00
Jelmer Vernooij
7285e102f0 r12523: Convert the registry subsystem to use a seperate prototype header
(note that this doesn't use the distinction between private
 and public prototypes yet)
(This used to be commit 60e11f575821c1762b25ad66441b6e69ad1167ef)
2007-10-10 13:47:51 -05:00