1
0
mirror of https://github.com/samba-team/samba.git synced 2025-11-29 16:23:52 +03:00
Commit Graph

244 Commits

Author SHA1 Message Date
Stefan Metzmacher
a934da4dcf r20762: load the default dn's after the rootdse module is initialized,
so that following module can access the default dn's.

metze
2007-10-10 14:40:47 -05:00
Stefan Metzmacher
c8f5aad40a r20760: also handle the case where no private data is attached to the module
metze
2007-10-10 14:40:46 -05:00
Stefan Metzmacher
2e79863d54 r20729: add a version number to struct dsdb_extended_replicated_objects
metze
2007-10-10 14:40:33 -05:00
Stefan Metzmacher
4380cc9ed6 r20728: the DSDB_CONTROL_REPLICATED_OBJECT_OID control isn't used anymore
because we now use DSDB_EXTENDED_REPLICATED_OBJECTS_OID extended operation

metze
2007-10-10 14:40:32 -05:00
Stefan Metzmacher
262e42123d r20727: implement basic merging of replicated objects when it already exist
in the ldb

metze
2007-10-10 14:40:32 -05:00
Stefan Metzmacher
0ecb07e052 r20726: - only add the rdn attribute and it's meta_data when the 'name' attribute is there
- add the values for objectGUID and whenChanged inside the ldb module,
  so that the ldb module has only replicated attributes as input

metze
2007-10-10 14:40:32 -05:00
Stefan Metzmacher
fbb1f85e32 r20716: add a dsdb_cache ldb module which will load the dsdb_schema and other things
on startup into memory structures in future.

metze
2007-10-10 14:40:31 -05:00
Stefan Metzmacher
cd654f20e1 r20713: sort the cursors in replUpToDateVector by source_dsa_invocation_id,
w2k3 seems to do the same.

It's later useful, when we would have a large array
be could use a binary search

metze
2007-10-10 14:40:30 -05:00
Stefan Metzmacher
665d8f9626 r20710: update or create the "repsFrom" values after applying replicated objects
metze
2007-10-10 14:40:30 -05:00
Stefan Metzmacher
a31e017e53 r20709: pass a repsFromTo1 struct down as it contains all needed info for the source dsa
and the highwater mark vector

metze
2007-10-10 14:40:29 -05:00
Stefan Metzmacher
c9e7a58f6a r20705: store the "replUpToDateVector" attribute in DSDB_EXTENDED_REPLICATED_OBJECTS
metze
2007-10-10 14:40:28 -05:00
Stefan Metzmacher
da4ff0e7cc r20681: implement the DSDB_EXTENDED_REPLICATED_OBJECTS operation.
the merging of existing objects is not implemented yet...

there are a few ifdef REPLMD_FULL_ASYNC because we need to workarouns
ldb's async infrastructure (which don't handle full async sub requests nicely)

metze
2007-10-10 14:40:21 -05:00
Stefan Metzmacher
88051a82c4 r20679: make the init_handle stuff a bit easier and get rid of really ugly talloc_get_type()
usage

simo: if you change more modules, please include also this change

metze
2007-10-10 14:40:20 -05:00
Andrew Bartlett
5aa2195ec2 r20622: Add in a hack to avoid permitting searches on the value of protected
attributes.

Andrew Bartlett
2007-10-10 14:37:16 -05:00
Stefan Metzmacher
0ed53c6d0f r20599: - forward extended operations in the partitions module
- by default the operations goes to all partitions
- but some wellkown ones will go to just one partition
  (DSDB_EXTENDED_REPLICATED_OBJECTS_OID for now)

I'll soon change the partitions module so that it'll attach a
DSDB_CONTROL_PARTITION_CONTEXT_OID control to give
the repl_meta_data or other partition specific modules a chance to
to know for which partition it should work.

metze
2007-10-10 14:37:12 -05:00
Stefan Metzmacher
ef3b325db0 r20587: prepare the DSDB_EXTENDED_REPLICATED_OBJECTS_OID handling
metze
2007-10-10 14:37:08 -05:00
Stefan Metzmacher
a4d5e0126c r20580: pass the DSDB_CONTROL_REPLICATED_OBJECT_OID with the ldb_add request
when applying replicated objects.

the samldb module ignores such requests now...
and the repl_meta_data module has different functions
for the replicated and originating cases...

metze
2007-10-10 14:37:06 -05:00
Stefan Metzmacher
46df7ff6e5 r20529: very, very ugly...
But this is currently needed to make regpatch linking in
the dsdb/schema/schema_*.o object files.

the problem is that the linker doesn't find any references to public symbols
in this files and removes them from the link list.

gnu ld has a --whole-archive option, but it seems to be not portable...

I think the solution with prelinking using 'ld -r' to create one object file
for a subsystem instead of using 'ar -rcs' to create an archive for a subsystem...

jelmer: any ideas about this problem?

metze
2007-10-10 14:36:49 -05:00
Stefan Metzmacher
045ddfe1ec r20522: make a copy of the objectguid ldb module because:
- I'll add handling of replication meta data to it
  for orginating changes
- I'll pass replication meta data via a ldb control
  for applying replicated changes
- It will also update the replUpToDateVector attribute in
  in root object of the partition
- It will handle deleted records by adding the isDeleted=TRUE attribute
  and move them to the CN=Deleted Objects container of the partition
- I make a copy to play with the code without breaking
  the LDAP backend setup

metze
2007-10-10 14:36:47 -05:00
Andrew Bartlett
600c7f1a68 r20492: Add in instructions/sample LDIF to setup Fedora DS as a backend.
Add a new module entrypoint to handle the new, interesting and
different mappings required for Fedora DS.

Andrew Bartlett
2007-10-10 14:35:59 -05:00
Andrew Bartlett
2959b4ba8b r20460: Simplfy the handling of password hashes in the samba3sam module.
Andrew Bartlett
2007-10-10 14:35:51 -05:00
Andrew Bartlett
14e2c877a8 r20455: Apply some of the patches from Martin Kuehl <kuehl@univention.de> to
better handle the Samba3 backend.

I've refactored the password format patch to use the routines in
lib/samba3/smbpasswd.c, which has required me to move this into a
seperate subsystem, due to recursive dependencies.

Andrew Bartlett
2007-10-10 14:35:49 -05:00
Andrew Bartlett
2eb9e6445c r20315: Implement the server side of DsGetDomainControllerInfo. This is a
supprisingly complex call...

It turns out that the in/out parameter 'level' is not in/out, but set
seperatly by the server-side code from r->req.req1.level.

This commit also breaks out some common code from samldb into samdb.

Andrew Bartlett
2007-10-10 14:29:38 -05:00
Stefan Metzmacher
b97b8f5dcb r20184: change ldb_attrib_handler into ldb_schema_attribute, which has a pointer
to a ldb_schema_syntax struct.

the default attribute handler is now registered dynamicly as "*"
attribute, instead of having its own code path.

ldb_schema_attribute's can be added to the ldb_schema given a
ldb_schema_syntax struct or the syntax name

we may also need to introduce a ldb_schema_matching_rule,
and add a pointer to a default ldb_schema_matching_rule
in the ldb_schema_syntax.

metze
2007-10-10 14:29:19 -05:00
Simo Sorce
4f07542143 r20034: Start using ldb_search_exp_fmt() 2007-10-10 14:28:51 -05:00
Simo Sorce
3a662a2d98 r19869: fix memleaks 2007-10-10 14:28:28 -05:00
Simo Sorce
3929c086d5 r19832: better prototypes for the linearization functions:
- ldb_dn_get_linearized
  returns a const string

- ldb_dn_alloc_linearized
  allocs astring with the linearized dn
2007-10-10 14:28:22 -05:00
Simo Sorce
a580c871d3 r19831: Big ldb_dn optimization and interfaces enhancement patch
This patch changes a lot of the code in ldb_dn.c, and also
removes and add a number of manipulation functions around.

The aim is to avoid validating a dn if not necessary as the
validation code is necessarily slow. This is mainly to speed up
internal operations where input is not user generated and so we
can assume the DNs need no validation. The code is designed to
keep the data as a string if possible.

The code is not yet 100% perfect, but pass all the tests so far.
A memleak is certainly present, I'll work on that next.

Simo.
2007-10-10 14:28:22 -05:00
Andrew Bartlett
c4bf9cc09b r19757: Don't do the strrchr twice. Pointed out by Martin Kuhl.
Andrew Bartlett
2007-10-10 14:28:19 -05:00
Andrew Bartlett
9890af534d r19732: The 'res' from ldb_search is only valid if the call returns LDB_SUCCESS.
This seems to show up (as an abort() from talloc) particularly under
ldb_ildap.

Andrew Bartlett
2007-10-10 14:28:15 -05:00
Andrew Bartlett
186766e309 r19731: Modify the ldb_map infrustructure to always map from requested
attributes to backend (remote) attributes.

We can't do a reverse mapping safely where the remote attribute may be
a source for multiple local attributes.  (We end up with the wrong
attributes returned).

In doing this, I've modified the samba3sam.js test to be more
realistic, and fixed some failures in the handling of primaryGroupID.

I've added a new (private) helper function ldb_msg_remove_element() to
avoid a double lookup of the element name.

I've also re-formatted many of the function headers, to fit into
standard editor widths.

Andrew Bartlett
2007-10-10 14:28:15 -05:00
Stefan Metzmacher
62aa73f3d5 r19726: when a client explicit asks for the 'netlogon' attriubute on LDAP
the result entry is skipped!

metze
2007-10-10 14:28:14 -05:00
Simo Sorce
889fb983ba r19531: Make struct ldb_dn opaque and local to ldb_dn.c 2007-10-10 14:24:44 -05:00
Andrew Bartlett
379da475e2 r19522: Remove gensec and credentials dependency from the rootdse module (less
dependency loops).

This moves the evaluation of the SASL mechansim list to display in the
rootDSE to the ldap server.

Andrew Bartlett
2007-10-10 14:24:44 -05:00
Jelmer Vernooij
7a01235067 r19507: Merge my DSO fixes branch. Building Samba's libraries as shared libraries
works again now, by specifying --enable-dso to configure.
2007-10-10 14:24:41 -05:00
Simo Sorce
0fa5d4bc22 r19489: Change ldb_msg_add_value and ldb_msg_add_empty to take a foruth argument.
This is a pointer to an element pointer. If it is not null it will be
filled with the pointer of the manipulated element.
Will avoid double searches on the elements list in some cases.
2007-10-10 14:24:38 -05:00
Simo Sorce
d2073c1f7e r19337: never alloc on module unless you mean to attach a context to
it to keep the data around as long as the module lives
2007-10-10 14:21:12 -05:00
Simo Sorce
524ec78086 r19333: commit module changes I made some time ago before I loose them 2007-10-10 14:21:11 -05:00
Simo Sorce
3e0e2787c1 r19332: ldb_parse_tree leaks 2007-10-10 14:21:11 -05:00
Simo Sorce
f163f422e3 r19330: Fix memleaks 2007-10-10 14:21:10 -05:00
Andrew Tridgell
3f48bcb058 r19329: fixed a leak in the password hash module 2007-10-10 14:21:10 -05:00
Andrew Tridgell
f57535b9c2 r19328: another leak plugged .... 2007-10-10 14:21:10 -05:00
Andrew Bartlett
1d4d2271c9 r19321: Merge from release branch:
Always set the krb5key from the ntPwdHash, even if we don't have the
cleartext password in sambaPassword.  This fixes kerberos after a
vampire.

Andrew Bartlett
2007-10-10 14:21:08 -05:00
Simo Sorce
e3b7e91299 r19313: Don't mess with hierarchies!!
There is a reason why we use them :-)
2007-10-10 14:21:07 -05:00
Andrew Bartlett
3310032399 r19308: Merge samsync fixes from SAMBA_4_0_RELEASE
Andrew Bartlett
2007-10-10 14:21:06 -05:00
Simo Sorce
6fad80bb09 r19299: Fix possible memleaks 2007-10-10 14:21:04 -05:00
Stefan Metzmacher
ed195999c0 r18945: fix compiler warnings and end-of-non-void function bugs
metze
2007-10-10 14:20:23 -05:00
Simo Sorce
ca8827d8f9 r18908: Store the schema structure into an opaque pointer so that it can be reused by multiple connections 2007-10-10 14:20:19 -05:00
Andrew Bartlett
72858f8594 r18781: Move the usnCreated and usnChanged handling around again.
This moves these attributes from objectguid into an optional backend
(objectguid), used by ltdb.  For OpenLDAP, the entryUUID module
converts entryCSN into usnChanged.

This also changes the sequence number API, and uses 'time based'
sequence numbers, when an LDAP or similar backend is detected.

To assist this, we also store the last modified time in the TDB,
whenever we change a value.

Andrew Bartlett
2007-10-10 14:19:11 -05:00
Andrew Bartlett
81d9a692c1 r18504: Handle mappings for RENAME and KEEP attributes better. We don't need
to mess with the values in these cases.

Where we do convert the values, try and convert substrings.  This
isn't going to be perfect, but we should try rather than segfault.

This also avoids using the wrong arm of the union for the attribute
name

The change in the entryUUID module is to correct the case of
sAMAccountName, due to the case sensitive ldap.js test.

Andrew Bartlett
2007-10-10 14:18:40 -05:00