summaryrefslogtreecommitdiff
path: root/source4/lib/db_wrap.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r15853: started the process of removing the warnings now thatAndrew Tridgell1-2/+1
talloc_set_destructor() is type safe. The end result will be lots less use of void*, and less calls to talloc_get_type() (This used to be commit 6b4c085b862c0932b80b93e316396a53b993544c)
2007-10-10r15433: Add a todo.Andrew Bartlett1-0/+2
Andrew Bartlett (This used to be commit 437ce4123761b65edebc9b9432515a62348f360b)
2007-10-10r15362: Consider anything non-zero a failure, bnio not just -1Jelmer Vernooij1-1/+2
(This used to be commit c3626548f74ca4c930b9d8a82de9c79f6f5e5903)
2007-10-10r15295: Fix some dependenciesJelmer Vernooij1-5/+0
Move unistr-specific code to lib/charset/. Remove _m from some places where it's not needed. (This used to be commit 03224e112424968fc3f547c6159c7ccae2d1aa5b)
2007-10-10r14349: Kill proto.h!Jelmer Vernooij1-0/+1
Prototypes are now spread over multiple headers, usually one per subsystem. This change is required to allow proper header dependencies later on, without recompiling Samba each time the mtime of any source file changes. (This used to be commit 3da79bf909f801386a52e6013db399c384d0401c)
2007-10-10r13768: be less verbose...Stefan Metzmacher1-0/+3
metze (This used to be commit 18fe8a6fbb7b01c0c4d4318ca39ac0af9bab5e5f)
2007-10-10r13349: In the end I could not use ldb_caseless_cmpSimo Sorce1-1/+1
in attrib_handler.c functions remove it again Simo (This used to be commit 513ff499071e6cb5e608a82430718021f72997bd)
2007-10-10r13335: Fix the build and add an utf8 safe ldb_hadler_fold functionSimo Sorce1-2/+2
based on ldb_casefold (This used to be commit 6104f900863c688707809d42c5429a42d654d5fb)
2007-10-10r13333: revert previous commit I will use ldb_caseless_cmp in attrib_handlersSimo Sorce1-2/+7
to correctly support utf8 comparisons add an ldb_attr_Casefold function for attribute names and use it instead of casefold in the right places (This used to be commit 3b4eb2413bbce059dde69f35c03cdc3cc2ba85c5)
2007-10-10r13328: After the attribute name check cleanup it turned up ldb_caseless_cmp()Simo Sorce1-7/+2
was used just in one places and by mistake, as there we should have been using ldb_attr_cmp() Remove ldb_caseless_cmp() ... going on with the cleanup and utf8 compliance effort. Simo. (This used to be commit afda68d7bf655a9145648856d29e6e64b9f21aa3)
2007-10-10r13325: let samba register it's own utf8 aware functions in ldbSimo Sorce1-0/+12
(This used to be commit 12faf556833807d3f2aa4360c54e10583ac77fed)
2007-10-10r12227: I realised that I wasn't yet seeing authenticated LDAP for the ldbAndrew Bartlett1-0/+13
backend. The idea is that every time we open an LDB, we can provide a session_info and/or credentials. This would allow any ldb to be remote to LDAP. We should also support provisioning to a authenticated ldap server. (They are separate so we can say authenticate as foo for remote, but here we just want a token of SYSTEM). Andrew Bartlett (This used to be commit ae2f3a64ee0b07575624120db45299c65204210b)
2007-10-10r12178: Make ldb_ildap work against localhost again, by setting the eventAndrew Bartlett1-0/+4
context into the ldb opaque. I'm sure this was done before, and must have been lost by some other change. Andrew Bartlett (This used to be commit dddedf13717e860bda0dadd8a1dfc4f891e355b5)
2007-10-10r10409: allow smb.conf override of ldb synchronous transactions with ↵Andrew Tridgell1-0/+5
"ldb:nosync = yes/no" (This used to be commit 435cbcf78b70a82c2ec89fab21e4ff8af538f2f1)
2007-10-10r10253: a fairly large tdb cleanup and re-organise. Nearly all of this changeAndrew Tridgell1-1/+2
just involves splitting up the core tdb.c code into separate files on logical boundaries, but there are some minor functional changes as well: - move the 'struct tdb_context' into tdb_private.h, hiding it from users. This was done to allow the structure to change without breaking code that uses tdb. - added accessor functions tdb_fd(), tdb_name(), and tdb_log_fn() to access the elements of struct tdb_context that were used by external code but are no longer visible - simplied tdb_append() to use tdb_fetch()/tdb_store(), which is just as good due to the way tdb locks work - changed some of the types (such as tdb_off to tdb_off_t) to make syntax highlighting work better - removed the old optional spinlock code. It was a bad idea. - fixed a bug in tdb_reopen_all() that caused tdbtorture to sometimes fail or report nasty looking errors. This is the only real bug fixed in this commit. Jeremy/Jerry, you might like to pickup this change for Samba3, as that could definately affect smbd in Samba3. The aim of all of these changes is to make the tdb transactions/journaling code I am working on easier to write. I started to write it on top of the existing tdb.c code and it got very messy. Splitting up the code makes it much easier to follow. There are more cleanups we could do in tdb, such as using uint32_t instead of u32 (suggested by metze). I'll leave those for another day. (This used to be commit 4673cdd0d261614e707b72a7a348bb0e7dbb2482)
2007-10-10r9702: r9680@blu: tridge | 2005-08-27 18:45:08 +1000Andrew Tridgell1-6/+2
- fixed ncacn_ip_tcp to use the generic async name resolution methods, so NBT names now work (as requested several times by abartlet!) - changed resolve_name() to take an event_context, so it doesn't cause the whole process to block - cleaned up the talloc_find_parent_bytype() calls to go via a cleaner event_context_find() call (This used to be commit b3d491b210a8b889a25efcb273e70fefbd01b7f7)
2007-10-10r8625: move the ldb_wrap logic into the ldb code. This logic is meant toAndrew Tridgell1-36/+1
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 (This used to be commit 4e090c66dfa1d2764e4693578d3845be3b8893f6)
2007-10-10r8343: removed a debugging messageAndrew Tridgell1-2/+1
(This used to be commit c12325e25291a0083446519e0b37c7bcdc3d5433)
2007-10-10r7912: make private_path() recognise a non-relative filename, so we can haveAndrew Tridgell1-2/+10
sam database = sam.ldb and it will know to put it in the private dir, but if you use sam database = ldap://server it knows to use it as-is (This used to be commit c5bccbc366db144d3e1cb7b21f0e3284d841dd06)
2007-10-10r7860: switch our ldb storage format to use a NDR encoded objectSid. This isAndrew Tridgell1-0/+9
quite a large change as we had lots of code that assumed that objectSid was a string in S- format. metze and simo tried to convince me to use NDR format months ago, but I didn't listen, so its fair that I have the pain of fixing all the code now :-) This builds on the ldb_register_samba_handlers() and ldif handlers code I did earlier this week. There are still three parts of this conversion I have not finished: - the ltdb index records need to use the string form of the objectSid (to keep the DNs sane). Until that it done I have disabled indexing on objectSid, which is a big performance hit, but allows us to pass all our tests while I rejig the indexing system to use a externally supplied conversion function - I haven't yet put in place the code that allows client to use the "S-xxx-yyy" form for objectSid in ldap search expressions. w2k3 supports this, presumably by looking for the "S-" prefix to determine what type of objectSid form is being used by the client. I have been working on ways to handle this, but am not happy with them yet so they aren't part of this patch - I need to change pidl to generate push functions that take a "const void *" instead of a "void*" for the data pointer. That will fix the couple of new warnings this code generates. Luckily it many places the conversion to NDR formatted records actually simplified the code, as it means we no longer need as many calls to dom_sid_parse_talloc(). In some places it got more complex, but not many. (This used to be commit d40bc2fa8ddd43560315688eebdbe98bdd02756c)
2007-10-10r7779: use the parent event context in ldb_wrap_connect(). See the comment inAndrew Tridgell1-0/+10
the previous commit for the method. (This used to be commit b0ad505510b9df8e7f05fb646046114eb6b997ed)
2007-10-10r7711: update callers of ldb_connect() for new syntaxAndrew Tridgell1-4/+11
(This used to be commit f852661463624714ad8e7adc0547b2f07b8f9f6d)
2007-10-10r5585: LDB interfaces change:Simo Sorce1-16/+22
changes: - ldb_wrap disappears from code and become a private structure of db_wrap.c thanks to our move to talloc in ldb code, we do not need to expose it anymore - removal of ldb_close() function form the code thanks to our move to talloc in ldb code, we do not need it anymore use talloc_free() to close and free an ldb database - some minor updates to ldb modules code to cope with the change and fix some bugs I found out during the process (This used to be commit d58be9e74b786a11a57e89df36081d55730dfe0a)
2007-10-10r5307: removed db_wrap.h from includes.hAndrew Tridgell1-0/+1
(This used to be commit 826baec7b348814a7bbdcdbec8c8526514f25da1)
2007-10-10r5296: - only include the tdb headers where they are neededAndrew Tridgell1-0/+1
- removed the u32 hack in events.c as I think this was only needed as tdb.h defines u32. Metze, can you check that this hack is indeed no longer needed on your suse system? (This used to be commit 6f79432fe656164d4770dbce114a30dda5e7bf9a)
2007-10-10r5037: got rid of all of the TALLOC_DEPRECATED stuff. My apologies for theAndrew Tridgell1-2/+2
large commit. I thought this was worthwhile to get done for consistency. (This used to be commit ec32b22ed5ec224f6324f5e069d15e92e38e15c0)
2007-10-10r4475: fixed smbd to work with the small changes in the ldb API (the most ↵Andrew Tridgell1-0/+1
important change was in the ldb_msg_add_*() routines, which now use the msg as a context, and thus it needs to be a talloc ptr) (This used to be commit 1a4713bfd0e519f3eb7b3241121ff914a6eeef18)
2007-10-10r3783: - don't use make proto for ldb anymoreStefan Metzmacher1-0/+1
- split ldh.h out of samba's includes.h - make ldb_context and ldb_module private to the subsystem - use ltdb_ prefix for all ldb_tdb functions metze (This used to be commit f5ee40d6ce8224e280070975efc9911558fe675c)
2007-10-10r3463: separated out some more headers (asn_1.h, messages.h, dlinklist.h and ↵Andrew Tridgell1-0/+1
ioctl.h) (This used to be commit b97e395c814762024336c1cf4d7c25be8da5813a)
2007-10-10r3005: added talloc wrappers around tdb_open() and ldb_connect(), so that theAndrew Tridgell1-0/+170
caller doesn't have to worry about the constraint of only opening a database a single time in a process. These wrappers will ensure that only a single open is done, and will auto-close when the last instance is gone. When you are finished with a database pointer, use talloc_free() to close it. note that this code does not take account of the threads process model, and does not yet take account of symlinks or hard links to tdb files. (This used to be commit 04e1171996612ddb15f84134cadded68f0d173b2)