Howard Chu
f1457a8ce8
Additional fix for ITS#4673
2006-09-14 22:38:45 +00:00
Pierangelo Masarati
524a7bc27a
by now, don't bail out if monitoring cannot be set up
2006-09-14 22:26:37 +00:00
Howard Chu
7fd2e65386
Fix invalid attributes in translucent_modify
2006-09-14 21:11:26 +00:00
Pierangelo Masarati
5bb325054e
fix back-ldap monitoring
2006-09-14 19:56:34 +00:00
Pierangelo Masarati
40cabdc0bc
handle errors
2006-09-14 19:55:52 +00:00
Pierangelo Masarati
67f3fd8078
monitor __ALL__ thread parameters
2006-09-14 18:55:02 +00:00
Pierangelo Masarati
107036a946
fix (temporarily) uninit'ed var
2006-09-14 14:58:00 +00:00
Howard Chu
242274d038
Remove obsolete SLAP_FILTER_DN definitions
2006-09-14 09:29:29 +00:00
Pierangelo Masarati
028a8af7df
comment monitoring by now
2006-09-14 09:06:17 +00:00
Howard Chu
e260fd1c2e
MSVC compatiblity
2006-09-14 08:06:08 +00:00
Howard Chu
3f4e196beb
Portability cleanups
2006-09-14 07:29:46 +00:00
Howard Chu
57c329a3af
ITS#4606 errno is not per-thread on WIN32, always use WSAGet/SetLastError
...
(with notable exceptions: ignore tests for EINTR which winsock never sets)
2006-09-14 06:35:34 +00:00
Howard Chu
8c939e1905
ITS#4565 catch errors from slap_sasl_init / backend_init
2006-09-14 04:52:08 +00:00
Pierangelo Masarati
a87da913cd
further cleanup
2006-09-14 01:07:18 +00:00
Pierangelo Masarati
6e18cdb5fd
add basic monitoring support to back-ldap/slapo-chain (slapo-chain needs work)
2006-09-14 01:05:48 +00:00
Pierangelo Masarati
b890f60e36
minor cleanup
2006-09-14 01:05:02 +00:00
Pierangelo Masarati
1f257bf5ed
URIs need to be between double quotes
2006-09-14 01:02:28 +00:00
Howard Chu
8e9651a598
Tweak ordered index check in check_vals
2006-09-14 00:31:18 +00:00
Howard Chu
18aac0e55e
Cleanup prev commit
2006-09-14 00:14:27 +00:00
Howard Chu
543ae473c5
Forgot the OC delete handler
2006-09-14 00:09:46 +00:00
Howard Chu
9f054b648b
Support dynamic add/delete of attributeTypes and objectClasses
2006-09-14 00:06:04 +00:00
Howard Chu
8e928dbb0b
Use register_at / register_oc
2006-09-13 13:38:24 +00:00
Howard Chu
e04275ca04
Use register_at / register_oc
2006-09-13 13:26:56 +00:00
Howard Chu
ef271979a8
Use register_at / register_oc helpers
2006-09-13 13:05:19 +00:00
Howard Chu
5342ce61dd
Add register_at / register_oc helpers.
2006-09-13 12:48:45 +00:00
Howard Chu
2bfe79fe88
Add BackendInfo.bi_extra for backend custom APIs
...
Use bi_extra for back-monitor entry points. Backends should never
directly reference each other's symbols.
2006-09-13 11:38:51 +00:00
Howard Chu
dd74acbf74
Fix ITS#4672, clear errno before calling STRTOL
2006-09-13 05:34:38 +00:00
Howard Chu
eaf976d56c
Fix typo from 1.667
2006-09-13 05:32:42 +00:00
Pierangelo Masarati
6300e449d8
leave monitor calls in place, hide contents; in the long run, enable monitor and build as static by default
2006-09-12 07:53:19 +00:00
Howard Chu
7cd64d384b
Use #ifdef SLAPD_MONITOR for monitor APIs
2006-09-12 02:59:28 +00:00
Pierangelo Masarati
55b5685425
ldap_back_dobind_int() may need to free a connection
2006-09-11 22:45:19 +00:00
Howard Chu
3e50687bf7
In connection_next, sockets may not be contiguous on Unix if syslog etc are
...
active. Just search to the end of the table, tracking the max isn't worth
the lock overhead.
2006-09-11 21:19:38 +00:00
Pierangelo Masarati
1ab4c624ed
rearrange error handling
2006-09-11 21:04:25 +00:00
Pierangelo Masarati
8eb455e7b2
add sb_version to slap_bindconf;
...
rework slap_client_connect() and slap_discover_feature() accordingly
2006-09-11 00:52:43 +00:00
Pierangelo Masarati
5c9eb73df7
make sure we got the right control...
2006-09-11 00:06:03 +00:00
Howard Chu
c6ed29dc3c
Fix uninit'd *cb (Coverity scan)
2006-09-09 22:15:45 +00:00
Pierangelo Masarati
0e13519191
ld may legitimately be NULL if another operation freed it because of a failure while binding
2006-09-09 17:01:28 +00:00
Pierangelo Masarati
c826725b7a
don't bother about unregistering stuff during shutdown
2006-09-09 16:25:32 +00:00
Pierangelo Masarati
8eab487020
further improve monitoring setup and cleanup
2006-09-09 16:24:35 +00:00
Pierangelo Masarati
2dac2e27b5
- use STRLENOF, looks cleaner
...
- in case a value is incorrectly empty (technically, it's null because
that's how it's returned by the stringification function), make enough
room to add the error string "(null)"
- in case a value is legitimately empty (see above), use it accordingly;
for example, a filter "(entryDN=)" is valid, so it should be possible
to stringify it like that.
2006-09-09 16:23:02 +00:00
Pierangelo Masarati
fdddeb1d8f
minor cleanup
2006-09-09 16:20:11 +00:00
Pierangelo Masarati
4bbffd1d98
more cleanup; add the frontend to the set of monitored databases; handle exceptional cases a bit more smoothly
2006-09-09 02:35:58 +00:00
Pierangelo Masarati
67dd808730
fix entry unlock in case of unhandled scope (ITS#4668)
2006-09-09 00:10:43 +00:00
Pierangelo Masarati
ad4ba42524
support "subordinate" scope
2006-09-09 00:00:44 +00:00
Howard Chu
f82ee25ec1
ITS#4667 in connection_closing, release c_mutex to allow waiters
...
to clear out.
2006-09-08 23:31:53 +00:00
Howard Chu
da6a4bcd3e
ITS#4667 fix assert in connection_next() for PENDING connections
2006-09-08 23:30:31 +00:00
Pierangelo Masarati
4350ce5189
cleanup names
2006-09-08 22:10:49 +00:00
Pierangelo Masarati
0e385af975
- need to be able to set new subsystems when appending entire entries;
...
- in case we appended an entry to a yet unknown parent, we don't know
the full DN, so unregistering needs to be possible based on the
available data;
- complete unregister calls so that not-yet-registered stuff can be
removed from limbo
2006-09-08 22:02:32 +00:00
Pierangelo Masarati
16043971ef
some overlay (rwm?) might set those values
2006-09-08 21:19:47 +00:00
Pierangelo Masarati
a9c4b54f1b
really really minor cleanup
2006-09-08 21:19:05 +00:00
Pierangelo Masarati
edd99f13f4
defer handling of loglevel listing, to let modules register custom subsystems (ITS#4666). Note: in case of any error in between, logging could not occur
2006-09-08 20:49:00 +00:00
Pierangelo Masarati
d5bb38f7e5
complain if "-T" is not the first option
2006-09-08 18:25:34 +00:00
Pierangelo Masarati
c3f9d68027
re-enable "-d '?'" as a means to list what loglevels are available (ITS#4666)
2006-09-08 18:10:53 +00:00
Pierangelo Masarati
b60990780f
custom monitoring can be enabled/disabled via config
2006-09-06 23:08:57 +00:00
Pierangelo Masarati
4d55aeb57c
cleanup subsystems monitoring OID handling
2006-09-06 16:06:49 +00:00
Pierangelo Masarati
df730d8538
check return values (failing when filter invalid)
2006-09-06 15:12:36 +00:00
Pierangelo Masarati
103485bf99
fix use with back-hdb
2006-09-06 15:11:54 +00:00
Pierangelo Masarati
1fc5e8e057
cleanup monitoring resources
2006-09-06 12:07:03 +00:00
Pierangelo Masarati
127ac65c44
implement support for unregistering registered stuff
2006-09-06 12:06:42 +00:00
Pierangelo Masarati
829685e218
improve previous commit
2006-09-06 12:05:38 +00:00
Pierangelo Masarati
6ce47650c9
- objectClass is now AUXILIARY (modifies existing object...)
...
- moved directory path publication from back-monitor/database.c
- added cleanup handler
- minor cleanup
2006-09-06 09:10:46 +00:00
Pierangelo Masarati
1f201f2cb4
remove dependencies on back-{b,h}db
2006-09-06 09:09:03 +00:00
Pierangelo Masarati
70624690c3
add attr_normalize*() helper (please holler if I missed any obvious alternative)
2006-09-06 09:06:50 +00:00
Howard Chu
9c2c30f541
Return current entry/IDL cache counts
2006-09-06 03:37:13 +00:00
Pierangelo Masarati
c67913ce1c
don't get mad if monitor database is not configured
2006-09-06 02:14:32 +00:00
Pierangelo Masarati
ae1481ba62
minor cleanup; plug couple of one-time leaks
2006-09-06 02:06:45 +00:00
Pierangelo Masarati
55f24ce8f6
- setup framework for monitoring of back-bdb/back-hdb stuff in their
...
database entry in cn=monitor
- improve support for custom attribute/callback registration
in back-monitor
- design API for registered antry/attr/callback removal in back-monitor
HEADS UP: now back-bdb requires back-monitor to be present, either static
or dynamically loaded __before__ back-bdb/back-hdb is initialized.
This works for sure if both back-bdb & back-monitor are static or dynamic
(provided back-monitor.la is loaded before back_bdb.la); it is not clear
what happens if back-bdb is static and back-monitor is dynamic. In case,
either make back-bdb monitoring conditional, or hardwire back-monitor
much like back-config and back-ldif.
2006-09-06 01:54:54 +00:00
Pierangelo Masarati
e1b83c881c
better handling of randomness
2006-09-04 08:40:40 +00:00
Pierangelo Masarati
3b3070d223
cleanup handling of sleeps
2006-09-04 08:36:16 +00:00
Pierangelo Masarati
84d6a04c91
improve timeout support (ITS#4157, ITS#4663)
2006-09-04 08:26:09 +00:00
Pierangelo Masarati
150a4f106c
improve timeout support (ITS#4157, ITS#4663); manpage cleanup
2006-09-04 08:24:05 +00:00
Pierangelo Masarati
35f8b9c9f5
release authz resources at shutdown
2006-09-04 07:20:59 +00:00
Pierangelo Masarati
0d2e2772d5
move req2op selection into a helper
2006-09-04 07:17:34 +00:00
Pierangelo Masarati
8129f7e2f2
fix arg format; better trace logging...
2006-09-03 11:14:37 +00:00
Pierangelo Masarati
906ff0d51a
don't abandon binds in progress; rather unbind (ITS#4663).
...
Better logging for tracing
2006-09-03 11:04:27 +00:00
Pierangelo Masarati
00c2498543
back-ldap should only touch the connection timestamp when activity actually occurred (i.e. ldap_result() returned a positive value), otherwise if "the network cable is removed after the connection is established" ldap_result() keeps returning 0 forever...
2006-09-03 11:02:15 +00:00
Pierangelo Masarati
3a83c813df
use preallocated entries? (otherwise bdb_add and others leak...)
2006-09-03 10:58:13 +00:00
Pierangelo Masarati
d95b88da21
plug slapo-ppolicy related leaks (ITS#4665)
2006-09-03 10:53:38 +00:00
Pierangelo Masarati
7c64c28ad5
plug leaks in search filter (and cleanup code; ITS#4664)
2006-09-03 10:45:07 +00:00
Pierangelo Masarati
faa13725e6
remove unnecessary assertion; add test for pending ops
2006-09-01 10:41:54 +00:00
Pierangelo Masarati
cb3248f173
cleanup
2006-09-01 10:01:36 +00:00
Pierangelo Masarati
9e8725a3cc
add an assertion to track ITS#4659; minor cleanup
2006-09-01 10:00:50 +00:00
Pierangelo Masarati
f797bc49a7
minor cleanup
2006-08-31 17:34:01 +00:00
Pierangelo Masarati
8a71ac3740
don't leak identity
2006-08-31 16:21:54 +00:00
Pierangelo Masarati
417ad40596
destroy socket set (man page for epoll_create(2) states that close(2) must be called on the returned filedes)
2006-08-31 13:51:25 +00:00
Pierangelo Masarati
420ed24c79
pick declaration of ch_strdup()
2006-08-30 22:45:26 +00:00
Pierangelo Masarati
afdae4272a
don't run useless (and likely to fail) checks, if possible
2006-08-30 21:05:05 +00:00
Pierangelo Masarati
e172835b55
fix pre-allocated entry/attribute handling
2006-08-29 17:09:08 +00:00
Pierangelo Masarati
c57782ad66
fix pre-allocated entry/attribute handling
2006-08-29 16:07:39 +00:00
Kurt Zeilenga
7c5baf493a
more cleanup
2006-08-29 07:28:22 +00:00
Howard Chu
c9562fa8fb
Hide config schema if !LDAP_DEVEL
2006-08-29 02:02:12 +00:00
Howard Chu
78172aa0cf
Entry/Attribute struct caching, to minimize malloc fragmentation
...
Note: this breaks LDAP_COMP_MATCH and SLAP_ZONE_MALLOC. But they
were probably broken already anyway.
2006-08-29 01:43:23 +00:00
Howard Chu
8ae4cbe643
Must use ch_strdup, not strdup
2006-08-29 01:36:52 +00:00
Howard Chu
f4da18e7e4
TLS ctx is already cleaned up
2006-08-29 01:34:55 +00:00
Howard Chu
cf47d33459
Only set c_sasl_bindop on actual SASL binds
2006-08-29 01:19:34 +00:00
Pierangelo Masarati
7cffbbad26
append global access rules also when be != NULL in backend_startup() (ITS#4654)
2006-08-28 13:31:16 +00:00
Pierangelo Masarati
5d3121902f
Add single-password constraint; NOTE from ppolicy.c:
...
/* FIXME: there's no easy way to ensure
* that add does not cause multiple
* userPassword values; one way (that
* would be consistent with the single
* password constraint) would be to turn
* add into replace); another would be
* to disallow add.
*
* Let's check at least that a single value
* is being added
*/
2006-08-28 12:44:39 +00:00
Quanah Gibson-Mount
761b0a239d
ITS#4358, thanks to Kevine Zerbib
2006-08-28 01:07:25 +00:00
Quanah Gibson-Mount
80073aefa3
Fix comment style.
2006-08-28 01:05:32 +00:00
Quanah Gibson-Mount
3ee11b1c2a
Fix delete type modifys where no value is given to be deleted. (ITS#2612)
...
Thanks to Alister Winfield for the patch.
2006-08-28 01:01:32 +00:00
Quanah Gibson-Mount
88ce76f24e
fix e_private value, goes along with memory leak fix to accesslog.c
2006-08-26 23:20:00 +00:00
Pierangelo Masarati
b898d35647
reduce code duplication
2006-08-26 17:55:56 +00:00
Pierangelo Masarati
9da24acb53
disable X-ORDERED 'VALUES' naming attributes by now
2006-08-26 17:28:07 +00:00
Pierangelo Masarati
828d55be4d
invalidate idle connection if a candidate target does not respond for the duration of time limit...
2006-08-26 15:24:49 +00:00
Kurt Zeilenga
d35d3b2026
Use LINE_MAX instead of BUFSIZ. Per POSIX, LINE_MAX should be at least 2K.
...
For ITS#4651
2006-08-25 20:05:14 +00:00
Howard Chu
ca262ee8e6
Fix test045, test048 use acl-bind credentials on retry if they were set.
2006-08-25 02:16:57 +00:00
Kurt Zeilenga
d3e288dffe
s/managedit/relax/
...
#unifdef -DSLAP_RELAX
2006-08-22 23:31:46 +00:00
Kurt Zeilenga
3d667a4705
remove dontusecopy ifdefs
2006-08-22 20:57:33 +00:00
Kurt Zeilenga
49708e1bd5
Basic donUseCopy implementation
2006-08-22 20:29:14 +00:00
Kurt Zeilenga
a1eb25c595
Initial dontUseCopy implementation
...
Needs to be extended to compare
2006-08-22 20:24:36 +00:00
Kurt Zeilenga
97fa3f1efd
More LDAP_DEVEL cleanup
...
Rename ManageDIT to Relax
2006-08-22 00:45:16 +00:00
Howard Chu
ae5c3db555
More config leaks
2006-08-21 04:25:54 +00:00
Howard Chu
282c00c349
Plug config leak
2006-08-21 04:11:29 +00:00
Howard Chu
d7be822a2a
Fix prev commit
2006-08-19 06:27:11 +00:00
Kurt Zeilenga
9695d292ef
LDAP_DEVEL cleanup
2006-08-19 05:47:05 +00:00
Howard Chu
69fa2d9f93
Move ber_sockbuf_free() to slapd_remove() to avoid using AC_SOCKET_INVALID
2006-08-18 23:54:24 +00:00
Pierangelo Masarati
e4d24ecce8
don't leave dangling conns in the AVL tree
2006-08-18 17:11:41 +00:00
Pierangelo Masarati
5b317f5b85
the conn may not be bound yet even if the bound DN is set...
2006-08-18 15:22:26 +00:00
Pierangelo Masarati
f5c308bdb6
more thread monitoring reworking; connection_pool_max may change via back-config
2006-08-18 10:26:03 +00:00
Pierangelo Masarati
2947c098ce
oi_list might be null if overlay initialization failed for any reason
2006-08-18 10:12:21 +00:00
Kurt Zeilenga
3e89a4ff82
LDAP_DEVEL cleanup
2006-08-18 06:29:46 +00:00
Howard Chu
ad1f0a3239
Fix null pointer reference (coverity scan) and freed pointer reference
2006-08-18 01:37:21 +00:00
Howard Chu
2e3e7ed14f
Fix prev commit
2006-08-18 01:17:44 +00:00
Pierangelo Masarati
9c52a2c4ff
give slapd a chance to play callback cleanup handlers when a search operation is abandoned (ITS#4645)
2006-08-17 19:47:25 +00:00
Kurt Zeilenga
73ec336a89
Add note about setting effectiveness.
2006-08-17 19:33:48 +00:00
Pierangelo Masarati
ea3ffdd135
don't core if out value is NULL (log error instead; in partial fulfilment of ITS#4644)
2006-08-17 17:37:46 +00:00
Pierangelo Masarati
a05a8972b2
fix previous commit
2006-08-17 16:32:11 +00:00
Pierangelo Masarati
9327af55ca
add tasklist monitoring; review runqueue monitoring
2006-08-17 16:10:47 +00:00
Pierangelo Masarati
c458df6441
add bverb_to_mask() API
2006-08-17 16:10:17 +00:00
Howard Chu
098153c5bb
Move socket close into slapd_remove, don't close until after socket
...
is removed from daemon control.
2006-08-17 00:44:38 +00:00
Howard Chu
ccd1273cfe
TS#4622 deletes in psearch didn't always propagate
2006-08-15 21:41:14 +00:00
Kurt Zeilenga
d9720d50dd
Some LDAP_DEVEL cleanup
2006-08-15 19:36:54 +00:00
Howard Chu
44d3972dd7
ITS#4622 if any present list was sent, must send refreshPresent
2006-08-15 12:37:59 +00:00
Howard Chu
55aa8af4be
ITS#4622 make sure queued psearch responses get played after refresh
...
phase completes. Ignore empty sessionlog
2006-08-15 09:28:25 +00:00
Howard Chu
789c76b4ce
Delete curcsn arg to slap_get_commit_csn, redundant with op->o_csn
2006-08-15 09:25:42 +00:00
Howard Chu
7036e2bb89
Delete curcsn arg to slap_get_commit_csn, redundant with op->o_csn
2006-08-15 08:51:49 +00:00
Howard Chu
4629002ec4
Additional shutdown check
2006-08-15 00:04:29 +00:00
Howard Chu
651bc9e40e
Don't purge log entries if a shutdown was requested
2006-08-15 00:02:57 +00:00
Kurt Zeilenga
4ba9bc1c2d
Use LDAP_OTHER to indicate internal error
2006-08-12 21:46:29 +00:00
Howard Chu
11a0ea514a
Tone down default ppolicy msg
2006-08-07 23:33:03 +00:00
Howard Chu
9f75c6a43d
ITS#4634 always init pp->ad
2006-08-07 22:40:51 +00:00
Pierangelo Masarati
bd8e1bb522
make log messages more esplicative
2006-08-05 16:34:19 +00:00
Pierangelo Masarati
b1faecd35c
process callbacks first; they are supposed to remove modifications they successfully handled, so that regular modify function can complain if any unhandled modification remains
2006-08-05 15:51:13 +00:00
Pierangelo Masarati
bbdc0bcd00
fix logging
2006-08-05 12:33:53 +00:00
Pierangelo Masarati
cc84163f30
factor connection code out of syncrepl
2006-08-04 19:20:59 +00:00
Pierangelo Masarati
4f395ab4ff
fix uri rewriting
2006-08-03 01:15:41 +00:00
Quanah Gibson-Mount
da1e743491
Minor typo fix (maintaned -> maintained)
2006-08-01 01:27:02 +00:00
Howard Chu
b915969d29
ITS#4589 slap_get_commit_csn occasionally returns a curcsn that points
...
to already-freed memory. That bug still needs to be tracked down. This
patch deletes curcsn and just uses op->o_csn, which did not exist when
this code was originally written.
2006-07-28 02:40:38 +00:00
Howard Chu
5757065736
ITS#4622
...
syncrepl: don't save contextCSN on incoming context entry
syncprov: delete contextCSN on checkpoint if ctxcsn is empty
2006-07-27 10:44:22 +00:00
Howard Chu
acea44af02
ITS#4622 additional fix
2006-07-26 21:36:44 +00:00