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

336 Commits

Author SHA1 Message Date
Jelmer Vernooij
b73441b04d r9616: Finish ldb_map module (still needs a lot of testing though...)
Add initial mapping table for ldb_samba3. Contains most attributes.
2007-10-10 13:34:35 -05:00
Jelmer Vernooij
e0a0d3f092 r9595: Add ldb map module 2007-10-10 13:34:33 -05:00
Jelmer Vernooij
b8c5290063 r9591: - Remove empty file
- Fix a couple of typo's
- Fix build of lib/samba3/secrets.c for systems that don't have /usr/include/tdb.h...
2007-10-10 13:34:33 -05:00
Simo Sorce
0a26ee0432 r9451: some fixes now core.schema and cosine.schema are also read properly 2007-10-10 13:34:16 -05:00
Simo Sorce
fc373fd463 r9447: Add a new tool to convert openLdap schema files into an ldif
My first test with nis.schema seem to confirm it works properly

Use a command line like:
oLschema2ldif -I tests/schema/nis.schema -O nis_schema.ldif -b "dc=sambadom,dc=samba,dc=org"
to see how it works.

SSS
2007-10-10 13:34:16 -05:00
Simo Sorce
10e4ebcc42 r9446: clean up old test file 2007-10-10 13:34:15 -05:00
Jelmer Vernooij
a66eeadecd r9438: Add initial files for ldb_map 2007-10-10 13:34:14 -05:00
Simo Sorce
d2055849fb r9394: avoid to use BOOL in ldb 2007-10-10 13:33:33 -05:00
Simo Sorce
796d0ea2fc r9393: Fix ldb standalone build 2007-10-10 13:33:33 -05:00
Simo Sorce
31c69d0655 r9392: Fix ldb_dn_compose to make build farm happy
Add ldb_dn_string_compose so that you can build a dn starting from a
struct ldb_dn base and a set of parameters to be composed in a format
string with the same syntax of printf
2007-10-10 13:33:33 -05:00
Simo Sorce
692e35b779 r9391: Convert all the code to use struct ldb_dn to ohandle ldap like distinguished names
Provide more functions to handle DNs in this form
2007-10-10 13:33:32 -05:00
Andrew Tridgell
136ecf5cb2 r9387: regedit uses "New Key #nn" for newly created keys, which conflicts with the stricter
DN rules in ldb. Escape the DN components to cope.

Simo, sorry for making a change in ldb_dn.c while you have changes
pending. Please feel free to revert these and switch reg_backend_ldb.c
to use the new dn construction code.
2007-10-10 13:33:31 -05:00
Stefan Metzmacher
2a107472c3 r9318: fix searches with scope ONE and SUB,
the problem was that ldb_dn_compare_base() just looked at if
both dn's mtach some how, and the following happens:

basedn: CN=bar,DC=foo,DC=com
dn: DC=foo,DC=com

and dn: DC=foo,DC=com was return as result of a sub and base search

and also the ONE search with
basedn: DC=foo,DC=com

returned this

dn: CN=bla,CN=bar,DC=foo,DC=com

metze
2007-10-10 13:33:23 -05:00
Jelmer Vernooij
ce0935112b r8966: Simplify the makefile generation system a bit.
Autogenerate list of binaries (rather then having them hardcoded in build/smb_build/makefile.pm)
Add INSTALLDIR keyword to .mk files
2007-10-10 13:31:00 -05:00
Simo Sorce
d844d45d87 r8917: Better support for extended ldap search operations
Try to follow the RFC where possible and adapt to
  openLdap and AD way of handling this structure
2007-10-10 13:30:57 -05:00
Rafal Szczesniak
bc638cc3d6 r8810: Fix missing headers. Still doesn't fix the build but getting closer there.
rafal
2007-10-10 13:30:07 -05:00
Simo Sorce
1d40461362 r8779: Add rdn module to makefile and headers
Search by distinguishedName as if searching by dn
2007-10-10 13:30:04 -05:00
Andrew Bartlett
0cc58f5c3c r8740: Extend the rdn_name module to handle adding the rdn as an attribute. ie:
dn: cn=foo,ou=bar
objectClass: person

implies

dn: cn=foo,ou=bar
objectClass: person
cn: foo
(as well as a pile more default attributes)

We also correct the case in the attirbute to match that in the DN
(win2k3 behaviour) and I have a testsuite (in ejs) to prove it.

This module also found a bug in our provision.ldif, so and reduces
code complexity in the samdb module.

Andrew Bartlett
2007-10-10 13:30:00 -05:00
Andrew Tridgell
7b37923b72 r8736: this fixes the ldb speed (raises BENCH-WINS from 15 ops/sec to over 4000)
simo, we need to be careful to cope with this sort of direct dn query efficiently
2007-10-10 13:30:00 -05:00
Andrew Bartlett
8054abc76e r8669: The objectguid module belongs in Samba's ldb module collection, not in
ldb, as it can't build without the NDR and GUID code.

Also make it properly use the NDR encoding for the GUID (I forgot last
time, and used a string), as well as set the dependencies on the
module correctly.

Andrew Bartlett
2007-10-10 13:29:52 -05:00
Andrew Tridgell
756796ad2e r8668: fixed a segv during upgrade of a very old ldb.
Thanks to volker for finding this one too. Keep them coming!
2007-10-10 13:29:52 -05:00
Andrew Bartlett
ed1f2e029c r8667: Further simply the provision script, by removing the 'name' attribute.
This is now calculated on the fly for every add and modify.

Andrew Bartlett
2007-10-10 13:29:52 -05:00
Andrew Tridgell
d2c29a5a51 r8659: return ldif formatted attributes in the ejs ldb search call, so sids show up as strings
not binary blobs
2007-10-10 13:29:50 -05:00
Andrew Bartlett
940ed9827f r8650: Use the timestamps and a new objectguid module rather than placing
boilerplate attributes in every entry in provision.ldif.

The next step will be to use templates.

Andrew Bartlett
2007-10-10 13:29:50 -05:00
Andrew Tridgell
4e090c66df r8625: move the ldb_wrap logic into the ldb code. This logic is meant to
avoid the horrors of posix locking, but it was preventing us having an
ldb open twice with different options. Now each ldb open of the same
file shares the same underlying tdb, but uses a different ldb
structure
2007-10-10 13:29:45 -05:00
Andrew Tridgell
64b6586b57 r8601: fixed null termination in ltdb connect error 2007-10-10 13:29:43 -05:00
Andrew Tridgell
326f0ad6fb r8600: fixed null termination on some error messages in ldb 2007-10-10 13:29:43 -05:00
Simo Sorce
a9e8cd0bad r8585: add to ldb and ldap comparison functionality
better pares filters
Approx is currently only a stub need to dig more info to
understand what it really means and how it works exactly
2007-10-10 13:29:41 -05:00
Simo Sorce
24a65b5ba6 r8529: Matching against the wrong union 2007-10-10 13:29:35 -05:00
Andrew Tridgell
a58ea6b385 r8520: fixed a pile of warnings from the build farm gcc -Wall output on
S390. This is an attempt to avoid the panic we're seeing in the
automatic builds.

The main fixes are:

 - assumptions that sizeof(size_t) == sizeof(int), mostly in printf formats

 - use of NULL format statements to perform dn searches.

 - assumption that sizeof() returns an int
2007-10-10 13:29:34 -05:00
Andrew Tridgell
19d789e825 r8517: fixed a crash bug in ldb_dn_compare_base() 2007-10-10 13:29:34 -05:00
Simo Sorce
76d496c308 r8515: ldb_dn_cmp now uses ldb_dn_compare so that the DNs are compared
on a content level not ona form level, his means that the 2 DNs:
a) cn= user, dc=this, dc = is,dc=test
b) cn=user,dc=this,dc=is,dc=test
are now identical even if the string form differ (spaces)
2007-10-10 13:29:33 -05:00
Andrew Tridgell
6b20bcbeeb r8490: make the ldb tests more portable 2007-10-10 13:23:09 -05:00
Andrew Tridgell
9f29cccbc1 r8485: - be friendly to shells other than bash
- don't use /tmp in test paths, as that opens us to symlink attacks
2007-10-10 13:23:08 -05:00
Tim Potter
bcfb3a45e4 r8414: Some C++ friendlyness fixes - 'not' is apparently a keyword in C++. 2007-10-10 13:23:00 -05:00
Love Hörnquist Åstrand
56fd21c806 r8394: Make sure the argument to ctype is*(3) macros are unsigned char as
required by ISO C99.
2007-10-10 13:20:14 -05:00
Simo Sorce
ed804262dc r8377: forgot an ldif test 2007-10-10 13:20:14 -05:00
Simo Sorce
4eb5863042 r8373: New wildcard matching code.
This code applies correct ldap standard wildcard matching code
removes WILDCARD matching from tdb @ATTRIBUTES, that's now handled independently
adds some more tests for wildcard matching
fixes dn comparison code in ldb_match
2007-10-10 13:20:13 -05:00
Andrew Tridgell
ef804e8f36 r8364: fixed a valgrind bug spotted by simo 2007-10-10 13:20:12 -05:00
Andrew Tridgell
4b11c00421 r8342: allow ldb_ldif_read_string() to continue in the string, so you can
read multiple records
2007-10-10 13:20:08 -05:00
Stefan Metzmacher
93c1d18021 r8228: fix compiler warnings
metze
2007-10-10 13:19:22 -05:00
Stefan Metzmacher
e6c39241bf r8224: - add objectGUID ldif_handler
- fix some compiler warnings

metze
2007-10-10 13:19:21 -05:00
Stefan Metzmacher
5fcaa21d67 r8146: fix compiler warning
metze
2007-10-10 13:19:12 -05:00
Simo Sorce
2e328e6c2f r8084: do not leak memory on errors 2007-10-10 13:19:07 -05:00
Simo Sorce
b1a61cd5d0 r8083: check attribute type is valid (only ascii alphanum chars and '-' char)
fail if not
2007-10-10 13:19:06 -05:00
Simo Sorce
624a73148d r8082: large rewite of ldb_dn.c
- we do not support multpiple attribute components anymore, makes code a lot easier
  they will be readded later if we found out they are really used, so far my tests
  show w2k3 do not handle them as well

- fix escaping issues, move component value to be in an ldb_val structure
  still need to handle binary values case

- make cononicalize functions leak less memory by giving a specific memory context

- fix tests scripts so that test-ldap can start
- make test not delete databases on completion so that I can inspect them
2007-10-10 13:19:06 -05:00
Andrew Tridgell
c03753faa4 r8071: reduce the size of the default ldb tests. We run on some pretty low powered machines
in the farm, and don't want to chew too much cpu needlessly.
2007-10-10 13:19:05 -05:00
Andrew Tridgell
60863b6faf r8043: increase shell compatibility of ldb tests 2007-10-10 13:19:02 -05:00
Andrew Tridgell
912fa269d2 r8041: remove a mis-spelled debug message :-) 2007-10-10 13:19:01 -05:00
Andrew Tridgell
f3e3b2ccd9 r8039: allow ldb test suite to be run outside of the ldb directory 2007-10-10 13:19:01 -05:00