1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00
Commit Graph

932 Commits

Author SHA1 Message Date
Stefan Metzmacher
d544f8a6de r19123: - pass LDFLAGS from configure to Makefile
which should fix the build on Tru64 in the build farm.

Thanks to Bjoern Jacke for finding this!

metze
(This used to be commit 165722a16c)
2007-10-10 14:20:37 -05:00
Andrew Tridgell
31e50ccae7 r19114: fixed another checker warning and a possible error on allocation
failure
(This used to be commit bc02f7ef96)
2007-10-10 14:20:36 -05:00
Andrew Tridgell
f1f807e66b r19113: fixed another checker warning.
(This used to be commit d12550af01)
2007-10-10 14:20:35 -05:00
Andrew Tridgell
36246a191c r19112: fixed a checker warning.
In case you haven't noticed, lots of our packages now run the IBM
checker in the build farm on 'snab'
(This used to be commit b39a79f17c)
2007-10-10 14:20:35 -05:00
Volker Lendecke
06ac3dbd9a r19079: talloc_array can fail
(This used to be commit 441ad8a45c)
2007-10-10 14:20:34 -05:00
Volker Lendecke
ecd970abb6 r19076: ldb_dn_copy_partial can fail
(This used to be commit 78aa689a74)
2007-10-10 14:20:33 -05:00
Volker Lendecke
c56585e5fe r19075: Fix a potential NULL dereference
(This used to be commit 84ae80b39b)
2007-10-10 14:20:33 -05:00
Volker Lendecke
9bbc8736e7 r19074: Merge from 3_0: Fix a potential NULL dereference.
Volker
(This used to be commit af72af684b)
2007-10-10 14:20:33 -05:00
Simo Sorce
118dae99de r19069: The sequence number is a 64 bit unsigned integer
Well spotted Volker
(This used to be commit f4239ef598)
2007-10-10 14:20:33 -05:00
Volker Lendecke
19df909135 r19068: Fix a potential NULL dereference
(This used to be commit 2dff8ee8cc)
2007-10-10 14:20:33 -05:00
Andrew Tridgell
bf86ece6cb r19009: ensure that data values from ldap libs are null terminated, to allow
ldb_msg_find_attr_as_string() to work correctly.

Thanks to Jim Myers for spotting this!
(This used to be commit b2076c1a7e)
2007-10-10 14:20:28 -05:00
Andrew Bartlett
c2a2c2456d r18978: Fix bug found by:
http://www.ee.oulu.fi/research/ouspg/protos/testing/c06/ldapv3/

The issue here is that if the UTF8 conversion fails, because this
isn't actually UTF8 data, then we need to do a binary compare instead.

Andrew Bartlett
(This used to be commit a113e47784)
2007-10-10 14:20:26 -05:00
Andrew Tridgell
4c3b07b654 r18942: add a ldb_set_create_perms() function in ldb. I didn't call it
ldb_set_umask() (which is what we had discussed) as it doesn't
actually set the umask (in effect it sets the inverse of the umask -
the perms to be used for the file)
(This used to be commit 7e2ec87590)
2007-10-10 14:20:22 -05:00
Andrew Tridgell
4e7c9367a7 r18939: don't rely on the umask being right in ldb creation. Both Samba3 and
Samba4 smbd force the umask to 0, which meant we ended up with ldb
being world writable.

This isn't really an ideal fix, as it means ldb no longer honors umask
(as it should do, like all good libraries).

Unfortunately the 'proper' fix is too complex for now

this also merges a tiny code style fix from s4 to s3
(This used to be commit 1a42f38dfd)
2007-10-10 14:20:22 -05:00
Andrew Tridgell
26ece8f697 r18910: Change ldb_msg_add_string() to not actually add an attribute if the
string is zero length. This allows callers to not have to worry about
creating an invalid ldap attribute.

See extensive discussion on samba-technical list :-)
(This used to be commit 7a1db8c2a4)
2007-10-10 14:20:20 -05:00
Stefan Metzmacher
95340f8afb r18903: merge from samba3:
define HAVE_LDB_LDAP and HAVE_LDB_SQLITE3

metze
(This used to be commit 4e2f5ba490)
2007-10-10 14:20:19 -05:00
Volker Lendecke
1b8d6b3e7d r18894: Merge const fixes from 3_0
(This used to be commit 4ce447223c)
2007-10-10 14:20:19 -05:00
Simo Sorce
5e1e97a20d r18882: make style consistent
(This used to be commit a141ee9473)
2007-10-10 14:20:18 -05:00
Simo Sorce
df83913eb1 r18881: remove wrong check and statement.
to manipulate rootDSE we use ldb_dn_new() as base and that has 0 elements.
(This used to be commit 3e131177da)
2007-10-10 14:20:18 -05:00
Volker Lendecke
51f27dc3f1 r18851: Some C++ warnings
(This used to be commit 69f05f288c)
2007-10-10 14:20:16 -05:00
Andrew Tridgell
088c24e4e6 r18840: make these compatible with g++ warnings
(This used to be commit bcfa93954f)
2007-10-10 14:20:15 -05:00
Andrew Tridgell
45ca27699c r18834: get the log context code right
(This used to be commit b6bb5d7b77)
2007-10-10 14:19:16 -05:00
Andrew Tridgell
0b5e01c19b r18832: fixed standalone build
(This used to be commit 1ebc098b67)
2007-10-10 14:19:15 -05:00
Andrew Tridgell
58619eebc1 r18831: minor build changes for samba3. The logging changes will be removed
when the tdb api is updated
(This used to be commit 6ace943fac)
2007-10-10 14:19:15 -05:00
Andrew Tridgell
6c86ed60fc r18830: ensure backends aren't added twice (needed for samba3)
(This used to be commit 54b864b491)
2007-10-10 14:19:15 -05:00
Andrew Bartlett
77db3973c4 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
(This used to be commit 72858f8594)
2007-10-10 14:19:11 -05:00
Simo Sorce
8d1b32083e r18777: add helper functions to create an ldb_request structure
(This used to be commit bcbe82873f)
2007-10-10 14:19:11 -05:00
Andrew Bartlett
df98ee6558 r18770: Avoid crashes and fix up other issues in the client-side paged_searches module.
In particular, we must query the remote server to find out if paged
searches are supported, not the local ldb.

This patch also removes the ue of bool, and returns it to LDB error codes.

Andrew Bartlett
(This used to be commit d36d05858b)
2007-10-10 14:19:10 -05:00
Andrew Tridgell
1188fa1a18 r18602: updated web page for new ldb build method
(This used to be commit 36c35262f2)
2007-10-10 14:18:55 -05:00
Andrew Tridgell
ee528dc0f2 r18596: removed superfluous semicolon
(This used to be commit 4f3628dea6)
2007-10-10 14:18:54 -05:00
Simo Sorce
9dd6cac44a r18591: Better defaults for share creation
Fix logic error in paged_results
(This used to be commit 34ce1f8e1b)
2007-10-10 14:18:53 -05:00
Andrew Tridgell
182ab7107c r18539: 'make distclean' should delete config.cache
(This used to be commit 5a8becb1be)
2007-10-10 14:18:43 -05:00
Andrew Tridgell
1d7a878c8b r18538: we need a pipe here, not a logical OR
also fix cn name for this record, and ensure tests/tmp is created
(This used to be commit 588c91f06b)
2007-10-10 14:18:43 -05:00
Andrew Tridgell
0e9147029f r18536: fixed the loading of external binary files from ldif into ldb
(This used to be commit fbe13ed83e)
2007-10-10 14:18:43 -05:00
Andrew Tridgell
fafa8c3e47 r18535: move the AC_CANONICAL_HOST and host specific flag tests into
libreplace. This should fix the standalone build of tdb on HPUX, where
we need to blacklist mmap.

Unfortunately this requires that we have a copy of config.guess and
config.sub in each of our project subdirectories. I tried to find a
way to use something like AC_CONFIG_AUX_DIR($libreplacedir) and just
put config.{guess,sub} in the lib/replace/ directory, but I couldn't
figure out how to do that in a way that kept autoconf happy for each
of our separate builds. Any autoconf guru out there see a way to do
this?
(This used to be commit 823cd3ab35)
2007-10-10 14:18:42 -05:00
Jelmer Vernooij
e9c465621e r18515: Remove calls to "time" for now as some sh implementations don't have it,
causing this test to fail.
(This used to be commit fc3f41a4ab)
2007-10-10 14:18:40 -05:00
Andrew Bartlett
595c141a69 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
(This used to be commit 81d9a692c1)
2007-10-10 14:18:40 -05:00
Andrew Bartlett
1e4f5a096c r18495: More work on the LDAP backend (which now passes a lot of our tests!)
This adds a list of attributes that are in our wildcard seaches, but
the remote server requires to be explicitly listed.  This also cleans
up the handling of wildcards in ldb_map to be more consistant.

Also fix the partitions module to rebase the search, if on the GC
port, we do a subtree search.  (Otherwise backends can rightly
complain that the search is not in their scope).

Andrew Bartlett
(This used to be commit bc58792b71)
2007-10-10 14:18:38 -05:00
Stefan Metzmacher
d08fb7b1cc r18485: include libreplace.m4 in the aclocal.m4 files
and use the macros in configure.ac

metze
(This used to be commit 95d33e4d71)
2007-10-10 14:18:36 -05:00
Andrew Tridgell
05cdd9ccaf r18439: 2nd try at a talloc_move() api. This type with the ** ptr interface
exposed.

Unfortunately this generates a large number of type punning
warnings. We'll have to find some magic to hide those.
(This used to be commit 254cbf09de)
2007-10-10 14:18:29 -05:00
Andrew Tridgell
24fe49a3d1 r18438: I should have examined these uses of talloc_move() more
carefully. Most of them are OK, but a couple were not.
(This used to be commit b0de283882)
2007-10-10 14:18:29 -05:00
Andrew Tridgell
12e7682e7b r18437: added a 'make valgrindtest' target for ldb
(This used to be commit 4c33c6bb97)
2007-10-10 14:18:29 -05:00
Andrew Tridgell
7f63cebd33 r18436: converted ldb to use talloc_move() instead of talloc_steal() when
appropriate.

Note that I also removed the error checks that were being done on the
result of talloc_steal(). They are pointless as talloc_steal() doesn't
have any failure modes that wouldn't cause a segv anyway, and they
tend to clutter the code
(This used to be commit c0d9e7d473)
2007-10-10 14:18:29 -05:00
Andrew Bartlett
33c4fea4cd r18410: Reduce noise in the ldb_ildap backend. We regularly search for things
that don't exist, and this is not a cause for panic.

Andrew Bartlett
(This used to be commit c89e416d28)
2007-10-10 14:18:25 -05:00
Andrew Tridgell
81e4403e79 r18347: run slapd in the foreground so timelimit can kill it
(This used to be commit 8cc456e6dc)
2007-10-10 14:18:14 -05:00
Andrew Tridgell
d939ff7bee r18346: make sure we kill off the slapd process
(This used to be commit 0e1d4be23a)
2007-10-10 14:18:13 -05:00
Andrew Tridgell
f658414c5f r18327: 'struct token' is defined on some hosts
(This used to be commit b2bba4e726)
2007-10-10 14:18:09 -05:00
Andrew Tridgell
9adf2883ef r18321: fixed some warnings on AIX
(This used to be commit 449fab2c26)
2007-10-10 14:18:08 -05:00
Simo Sorce
fb15300c60 r18317: Make sure we actually have a valid reply or fail
(This used to be commit 41cb3a9258)
2007-10-10 14:18:07 -05:00
Andrew Tridgell
e91cee468e r18309: FreeBSD 6.1 has a symbol ldap_new_connection() in the system ldap
library. Even though we don't like to that library, it gets loaded via
nss-ldap, which means nss-ldap calls into the samba ldap lib with the
wrong parameters, and crashes.

We really need to use a completely different namespace in libcli/ldap/
(This used to be commit c440e0eed9)
2007-10-10 14:18:06 -05:00
Andrew Tridgell
30ee8beb93 r18301: I discovered how to load the warnings from a build farm build into
emacs compile mode (hint, paste to a file, and compile as "cat
filename").

This allowed me to fix nearly all the warnings for a IA_64 SuSE build
very quickly.
(This used to be commit eba6c84eff)
2007-10-10 14:18:04 -05:00
Andrew Tridgell
27126bae7e r18286: ldb now needs install-sh too
(This used to be commit ce5b1b8c09)
2007-10-10 14:18:01 -05:00
Andrew Tridgell
e6b457d550 r18283: libreplace.m4 needs to be early in configure.ac in other packages too
(This used to be commit 03f9c67c06)
2007-10-10 14:18:01 -05:00
Simo Sorce
a865dcf02f r18272: Couldn't resist to change this.
What we want to do here is to just make sure res is freed.
Well let's just do so explicitly, the steal cofused me
initially while reading the code. This way it is clear
what we want to do.

Simo.
(This used to be commit 30a26a501f)
2007-10-10 14:17:59 -05:00
Andrew Bartlett
f140bd7e38 r18245: Ensure we don't keep the rootdse record around (steal it onto the
correct memory context).

Andrew Bartlett
(This used to be commit b4f234e507)
2007-10-10 14:17:54 -05:00
Andrew Tridgell
89a39c7acb r18244: more portable shell scripting
(This used to be commit 3200031276)
2007-10-10 14:17:54 -05:00
Stefan Metzmacher
a46e12d0e0 r18213: don't list LIBREPLACE depdendecies explicit and
always at it as first private dependencies

metze
(This used to be commit 135d096776)
2007-10-10 14:17:50 -05:00
Jelmer Vernooij
873749f218 r18168: Use {NULL} rather than POPT_TABLEEND, which is not always available.
(This used to be commit 8b622c5ded)
2007-10-10 14:17:45 -05:00
Jelmer Vernooij
f057742ef3 r18166: Fix build with external popt.
(This used to be commit b34310029a)
2007-10-10 14:17:45 -05:00
Jelmer Vernooij
7276648944 r18161: Fix LDB build after popt changes.
(This used to be commit 849fa93540)
2007-10-10 14:17:44 -05:00
Stefan Metzmacher
6aa376ef15 r18153: html/ isn't needed
metze
(This used to be commit 39dc57a502)
2007-10-10 14:17:43 -05:00
Stefan Metzmacher
6150443532 r18152: move our AC macros into lib/replace/libreplace_macros.m4
and include them from there

metze
(This used to be commit 38f9e90a12)
2007-10-10 14:17:43 -05:00
Stefan Metzmacher
6513e415b8 r18150: fix make *clean
metze
(This used to be commit e354cd0fae)
2007-10-10 14:17:42 -05:00
Andrew Tridgell
ed356c7989 r18143: the 'showflags' convention from Samba is useful for the other packages
(This used to be commit a4d1f1d222)
2007-10-10 14:17:40 -05:00
Andrew Tridgell
eaf584cd97 r18133: ad2oLschema needs ctype.h on some systems
(This used to be commit efe60c8a4b)
2007-10-10 14:17:37 -05:00
Andrew Tridgell
014f70008f r18130: the move to system/ in libreplace broke some things ... should be
happier now
(This used to be commit 18542f184f)
2007-10-10 14:17:37 -05:00
Andrew Tridgell
a983b06d37 r18129: moved the system includes into libreplace - this gives much more
isolation of our portability environment from the main code, and also
simplifies the includes system (no separate #ifdef _SAMBA_BUILD for
tdb. ldb etc now)
(This used to be commit 77d1a468e0)
2007-10-10 14:17:36 -05:00
Jelmer Vernooij
ca720634dd r18123: Fix manual file build.
(This used to be commit e84b6c70a1)
2007-10-10 14:17:35 -05:00
Jelmer Vernooij
a59706f721 r18121: Simplify m4 code, hopefully fix Samba4 build problems.
(This used to be commit 1adf65b4d7)
2007-10-10 14:17:35 -05:00
Andrew Tridgell
b7477fb388 r18117: first steps in making samba4 use libreplace
(This used to be commit c079cedb08)
2007-10-10 14:17:34 -05:00
Andrew Tridgell
6d2dd5a238 r18115: comparison_fn_t is defined in libreplace now
(This used to be commit e9ee8b1053)
2007-10-10 14:17:34 -05:00
Andrew Tridgell
58316b88e5 r18112: really make use of libreplace in ldb
(This used to be commit 2057159c75)
2007-10-10 14:17:18 -05:00
Andrew Tridgell
ea086c1cc8 r18109: move ldb to use the same build methods
(This used to be commit 28dcbb512f)
2007-10-10 14:17:18 -05:00
Stefan Metzmacher
99b2e8fdc9 r18098: use m4_include() instead of sinclude()
this breaks ./autogen.sh in lib/ldb/, but the ldb build is broken
anyway

metze
(This used to be commit 816fa197a7)
2007-10-10 14:17:16 -05:00
Stefan Metzmacher
14b0bc5d07 r18091: sometimes autoconf picks up some old stuff:
- remove configure and config.h.in
- cleanup after autoconf and autoheader are done

metze
(This used to be commit ce94fb008d)
2007-10-10 14:17:15 -05:00
Jelmer Vernooij
7a4206aa52 r18036: Add missing file
(This used to be commit 9ad8075d70)
2007-10-10 14:17:06 -05:00
Jelmer Vernooij
38fdde5d9b r18031: Merge my replace fixes:
* libreplace can now build stand-alone
 * add stub testsuite for libreplace
 * make talloc/tdb/ldb use libreplace
(This used to be commit fe7ca4b145)
2007-10-10 14:17:05 -05:00
Andrew Bartlett
173d17ab2f r18022: Increment number of records converted, and print number of records skipped.
Andrew Bartlett
(This used to be commit 6c11501ec3)
2007-10-10 14:17:03 -05:00
Volker Lendecke
515067a02e r18018: Fix the build on OpenBSD. No license problem this time, I've written strnlen
from scratch.

Volker
(This used to be commit 2a7cdf52e4)
2007-10-10 14:17:03 -05:00
Andrew Tridgell
0bb1c2da0e r17992: reverted r17842
This needs more consideration, as the patch removed the copyright
notice and license from the timegm.c code.

Volker, when you get a minute can you let me know what problem this
patch fixed so I can find a different approach?
(This used to be commit 5b9b9dd530)
2007-10-10 14:17:02 -05:00
Andrew Tridgell
f2c0831697 r17978: make the ldap backend test for ldb work both with and without modules
(so it works on both redhat and debian, for example)
(This used to be commit 71264bb785)
2007-10-10 14:16:59 -05:00
Stefan Metzmacher
071582898c r17960: try to use gmake if present on IRIX
metze
(This used to be commit 18b4ae591a)
2007-10-10 14:16:57 -05:00
Simo Sorce
bc2e3aa3f3 r17868: remove duplicated attributes from list
(This used to be commit fab0e66281)
2007-10-10 14:16:49 -05:00
Simo Sorce
d0ef5aad17 r17859: Fix some return values
(This used to be commit 5b4fc48c49)
2007-10-10 14:16:49 -05:00
Volker Lendecke
03dd0d5fc8 r17844: The AIX compiler thinks { } is a syntax error
(This used to be commit 4189736e09)
2007-10-10 14:16:48 -05:00
Volker Lendecke
6e9097045f r17842: After talking to Simo, apply the next attempt to resolve the strnlen
problem. Timegm is the same. Simo says this is just a workaround, but it helps
for now. Feel free to revert.

Volker
(This used to be commit fd166ca0c0)
2007-10-10 14:16:47 -05:00
Simo Sorce
88b04ab6e6 r17830: Set the default_basedn (hey, it comes from the "default" naming contex :-)
once at connection time, after modules have been loaded.

Introduce a function to retrieve the value where needed.
(This used to be commit 0caf6a44e0)
2007-10-10 14:16:46 -05:00
Andrew Tridgell
60898ca0b7 r17828: set the auto_baseDN opaque even on failure to fetch rootDSE. That
ensures we never try twice
(This used to be commit 946901e5dd)
2007-10-10 14:16:46 -05:00
Andrew Tridgell
fb36e279e7 r17822: the ildap ldb backend doesn't need the auto rootDSE logic any more
(This used to be commit c670837cc0)
2007-10-10 14:16:45 -05:00
Andrew Tridgell
a2ca0b5e3c r17821: changed ldb_search() and the ldbsearch command line utility to
automatically work out the basedn when basedn==NULL. The basedn is
fetched from the rootDSE defaultNamingContext value (if there is one)

This means we don't have to have the defaultNamingContext logic in
lots of places. It makes a lot of sense to me to have basedn==NULL
mean "use the default, as given by the database"

Note that explicitly specifing a basedn of '' is not the same thing,
and will not trigger this code

The baseDN is cached in a ldb opaque, so we only have to fetch it once
(This used to be commit 5d1b66b68f)
2007-10-10 14:16:44 -05:00
Andrew Tridgell
6a4794452f r17820: simplify the code flow a little
(This used to be commit 221272e393)
2007-10-10 14:16:44 -05:00
Stefan Metzmacher
eb6f27eccc r17778: fix compiler warnings
metze
(This used to be commit 4f753f9ebc)
2007-10-10 14:16:40 -05:00
Stefan Metzmacher
47479df22e r17775: use an enum to get rid of compiler warnings
metze
(This used to be commit c66cf31afd)
2007-10-10 14:16:40 -05:00
Andrew Tridgell
66337169f1 r17771: add a comment explaing the odd cast
(This used to be commit 47e695ed88)
2007-10-10 14:16:39 -05:00
Andrew Tridgell
a524e8cdde r17770: don't force -L/usr/lib, it breaks us4
(This used to be commit 348aff8c83)
2007-10-10 14:16:39 -05:00
Andrew Tridgell
2d4ecdb3e1 r17769: only look for dlopen in -ldl if not found in libc. Needed for us4
(This used to be commit 0b254f3bde)
2007-10-10 14:16:39 -05:00
Andrew Tridgell
b075bb842d r17765: fix handling of old solaris /bin/sh in ldb build/test
(This used to be commit f41d3ed4b3)
2007-10-10 14:16:38 -05:00
Andrew Tridgell
18f93fce20 r17764: more portable setenv() replacement
(This used to be commit 5c00b6d083)
2007-10-10 14:16:38 -05:00
Andrew Tridgell
47fb506da2 r17762: HPUX needs setenv
(This used to be commit 535c96f1e7)
2007-10-10 14:16:38 -05:00
Stefan Metzmacher
48c7cfcb74 r17756: I don't know why but this only works with the standalone
ldb build...I'll test more tomorrow.

metze
(This used to be commit aeee1b4655)
2007-10-10 14:16:37 -05:00