Commit Graph

217 Commits

Author SHA1 Message Date
Kurt Zeilenga
4863d98084 Remove configure's wait3 test as we don't care about the rusage.
Rewrite all child waits to use wait4 (for consistency only).
1999-01-23 04:03:43 +00:00
Kurt Zeilenga
637c0a8301 Use strtok_r() instead of strtok(). Remove strtok mutex! 1999-01-22 04:46:54 +00:00
Kurt Zeilenga
0f17fac37d Implement NEXTID chunking. Obtain IDs in chunks of size
SLAPD_NEXTID_CHUNK.  Code protects NEXTID file to ensure
its equal to or greater than nextid.  Updated on close
to actual nextid.  next_id_save() could be called periodically
if desired.  Default chunk size is 32.  Define to 1 to disable
chunking.
1999-01-22 02:26:19 +00:00
Kurt Zeilenga
5389e40ba5 initialize nextid with NOID not -1. 1999-01-22 01:53:39 +00:00
Kurt Zeilenga
2318ea0fd6 Don't return nextid on failed add operations for safety. 1999-01-22 01:51:53 +00:00
Kurt Zeilenga
5bfb3ac221 nextid cleanup in preparation to disable next_id_return(). 1999-01-22 01:40:39 +00:00
Kurt Zeilenga
ecdf9a354d Entry must be locked before adding it to the cache.
This removes a race condition upon the entry.
1999-01-22 00:27:50 +00:00
Kurt Zeilenga
6edeeeffd4 During cleanup always unlock root_mutex if rootlock is true
(don't make it conditional on p == NULL)
1999-01-21 22:20:03 +00:00
Kurt Spanier
68a8798594 Definition of slapd pid and args files as slapd.conf general parameters;
introduction of pid/agrs parameters to the test-suite slapd.conf files;
creation of sub-directory test/var for storage of pid/args files during test;
update of the slapd and slapd.conf man pages.
(The change reduces dependency on ldapconfig.h, since SLAPD_PIDEXT
 and SLAPD_ARGSEXT are deleted from the code.)
1999-01-21 15:53:54 +00:00
Kurt Zeilenga
127ec9c46c Fix c_cdn typo. Ouch. 1999-01-21 02:25:09 +00:00
Kurt Zeilenga
09421a74db Add c_protocol to slap_conn to track protocol version used by client.
Is initialized to 0 (unknown) and then set to 2 or 3 on bind.  Should
also be 0->3 if a special (or any) operation occurs before the bind.
1999-01-21 02:21:39 +00:00
Kurt Zeilenga
b3d383bbf5 *** empty log message *** 1999-01-21 01:12:35 +00:00
Kurt Zeilenga
19a17982c6 suffixes need to be stored in normalized uppercase format 1999-01-20 05:43:33 +00:00
Kurt Zeilenga
f9b416ea7c ndn & strcasecmp cleanup 1999-01-20 03:05:35 +00:00
Kurt Zeilenga
0503205c93 suffixAlias will return a normalized uppercase DN if input is normalized
and uppercase.  (aliased_dn are stored in normalized uppercase format).
1999-01-19 19:29:11 +00:00
Kurt Zeilenga
0daa8c1f06 Recode suffixAlias to implement simple check to see if part to aliased
is at a DNSEPARATOR.  Moved DNSEPARATOR macro from dn.c to slap.h
1999-01-19 19:26:09 +00:00
Kurt Zeilenga
029069d84a Removed o_suffix and o_suffixalias as they were 1) leaked and 2) unused
(suffixAliasing only maps input dn's, not output dn).
1999-01-19 18:54:19 +00:00
Kurt Zeilenga
3efaabe560 Don't allow suffixAliases were alias and aliased dn our the same. 1999-01-19 18:39:20 +00:00
Kurt Zeilenga
47d0c970d4 use dn_normalize_case(). 1999-01-19 18:25:21 +00:00
Kurt Zeilenga
a837feacc2 uppercase that ndn. 1999-01-19 18:18:53 +00:00
Kurt Zeilenga
48bdf4258c Need to uppercase e_ndn. 1999-01-19 18:17:29 +00:00
Kurt Zeilenga
8c501c28a2 Need to upper case the new_ndn. 1999-01-19 18:16:12 +00:00
Kurt Zeilenga
0e142b42f3 Update support for dn vs ndn. Build new dn from e->e_dn not frontend
provided dn (which is normalized and uppercased).   This preserved
the trailing portion of the dn.
1999-01-19 18:13:30 +00:00
Kurt Zeilenga
e2a15115b0 Update slap_conn to maintain client provided dn and bound dn.
Update slap_op to maintain dn and ndn (derived from conn->c_dn).
Update ldbm_back_bind to return actual bound dn (including rootdn)
	for use in slapd_conn.  Other backends use client dn.
Modify other codes to use ndn (normalized uppercase dn) most everywhere.
Aliasing, Suffixing and modrdn could use more work.
Applied suffixing to compare and modrdn.
1999-01-19 05:10:50 +00:00
Kurt Zeilenga
01a759971e Free that unclobberred dn. 1999-01-18 20:49:07 +00:00
Kurt Zeilenga
802325542b Don't clobber dn. 1999-01-18 20:34:17 +00:00
Kurt Zeilenga
c9242a123f e_ndn = dn_normalize_case( e_dn ) 1999-01-18 20:00:58 +00:00
Kurt Zeilenga
2805b25682 Store rootdn in normalized uppercase format. 1999-01-18 19:47:12 +00:00
Kurt Zeilenga
15fb73a473 ITS#44 fix. denied connections should not be added to connections. 1999-01-18 18:40:12 +00:00
Kurt Zeilenga
8009e591ce Protect return of the locked entry.
Note: we probably can replace the dn2entry_r with dn2id as only the id
is needed unless we're holding the lock for filtercandidates or something
1999-01-18 17:41:12 +00:00
Kurt Zeilenga
818bc57319 Minor cleanup of trace output. 1999-01-18 17:33:36 +00:00
Kurt Zeilenga
77b2e2cb25 Use Entry's e_ndn instead of recomputing it. 1999-01-17 20:12:00 +00:00
Kurt Zeilenga
931a8b1cd8 Add 'should not be world readable' comment. 1999-01-16 01:51:02 +00:00
Kurt Zeilenga
55cd5ee75f Add reference to slapd.conf(5) and recommendation to avoid cleartext passwords. 1999-01-16 01:48:26 +00:00
Bart Hartgers
3a5a86d44c Fixed a small typo... 1999-01-15 19:57:32 +00:00
Kurt Zeilenga
3e3f0b8871 Could have no entry to return... check entry pointer before trying to
return cache entry.
1999-01-15 18:04:52 +00:00
Kurt Zeilenga
163bac5f04 Install slapd.conf with mode of 600. 1999-01-15 02:48:00 +00:00
Kurt Zeilenga
b7beec1663 Initial version of the experimental 'back-perl'
John's still working on the 'perl-test' (the perl backend test module).
1999-01-14 06:33:09 +00:00
Kurt Zeilenga
28a671d10d Revamp build system yet again to move all external libraries to
end of link.    Basic order is:
	$LDFLAGS internal-libs external-libs $LIBS $LTHREAD_LIBS

LTHREAD_LIBS is last as -lpthread (or equiv) must be last on many systems.
LIBS is next to last as some user might have put -lpthread (or equiv)
in $LIBS.
1999-01-14 01:31:43 +00:00
Kurt Zeilenga
b39fdc0bcd Add normalized dn to Entry structure as field e_ndn. Entry
creation codes to provide this field.  Update cache_entrydn_cmp
to strcasecmp() the e_ndn instead of e_dn.  Note: strcasecmp()
is still used as e_ndn isn't in uppercase.  Maybe it should
be.  Did not update other codes to use e_ndn.  Hence, there
are lots of dn_normalize() calls that could be eliminated.
(The case determination of e_ndn should be made first).
1999-01-13 01:17:22 +00:00
Kurt Zeilenga
6f88096e72 Report status of failed pthread_create() 1999-01-12 23:57:21 +00:00
Kurt Zeilenga
6bd6a7cf27 Report exit status of pthread_create() 1999-01-12 23:52:50 +00:00
Kurt Zeilenga
318531a437 Use pthread_detach() to detach connection threads instead of
creating them detached.  This hopefully will reduce problems on
draft4 pthread implementations related to creating detached
threads (which is _np under draft4) on some platforms without
causing problems with other thread implementations.
1999-01-11 19:04:34 +00:00
Kurt Zeilenga
82b94e2258 Change SLAPD shutdown to do a cond wait on active threads instead
of a busy wait and allow the pthread_yield within the loop to be
removed.  This was the only pthread_yield which was necessary
when usng non-preemptive threads.  As such, the configure.in
sched_yield/pthread_yield missing error can be removed from
configure.in.  If explicit yield function is missing, just provide
a no-op replacement.
Moved declaration of various slapd globals from main.c to init.c
so they can be shared with ldbm tools.
1999-01-11 18:36:40 +00:00
Kurt Zeilenga
334768c1bb Update build environment to fix VPATH support.
make depend, make tests, and make install all work when build directory
  is not the $srcdir.
Also modified library handling such that -lpthread more likely to be last.
WARNING: new orderring requires use of LDFLAGS to set global loader options
  such as -L/usr/local/lib.  If you put this in LIBS, some libraries
  may not be found a link time.
Likely broke Kerberos/LDAPD support.  Don't have those in my testbed.
1999-01-10 02:25:41 +00:00
Kurt Zeilenga
d0516836b5 rename 'struct op' to 'struct slap_op'
rename 'struct conn' to 'struct slap_conn'
rename op_function to slap_op_func for functions add/delete/free
This change is need to avoid clashing with perl internals.
1999-01-10 02:16:48 +00:00
Kurt Zeilenga
e05e9dd955 Cleanup slapd search op deallocation. 1999-01-08 21:48:09 +00:00
Kurt Zeilenga
1d7704b28e Fix tmp file removal. 1999-01-08 19:51:15 +00:00
Kurt Zeilenga
de8c07c62c Updated SLAPD args/pid file codes to use DEFAULT_RUNDIR and DEFAULT_DIRSEP.
Removed old defines.
1999-01-07 18:16:40 +00:00
Kurt Zeilenga
dd351c3a17 Apply fix suggested by Ben Collins <bmc@visi.net>
pass STRING_UNKNOWN if !client_name
	pass STRING_UNKNOWN if !client_addr
1999-01-07 05:47:25 +00:00