Commit Graph

218 Commits

Author SHA1 Message Date
Kurt Zeilenga
acbb5cf689 Happy new year! 2006-01-03 23:11:52 +00:00
Pierangelo Masarati
73acecaf0f cleanup 2005-12-13 15:53:10 +00:00
Howard Chu
d67a2f2044 Move lconn_tls_ctx to ldo_tls_ctx. Otherwise clients cannot set it after
ldap_initializ'ing an LD and before connecting on it. Really all of the
global TLS options belong in the ldapoptions struct, instead of static vars.
2005-11-05 12:49:43 +00:00
Howard Chu
e8b1b004d4 Fix ITS#3832 must mutex protect ld->ld_conns 2005-10-12 00:05:43 +00:00
Howard Chu
2ea5a66be2 ITS#2942 skip referrals that we've already chased 2005-10-09 10:01:38 +00:00
Hallvard Furuseth
f0091b101f Cast LDAP_BOOL value to LDAP_BOOLEANS; it could only use flags fitting in int. 2005-07-22 13:24:47 +00:00
Pierangelo Masarati
eb005a9872 allow to muck with referrals while chasing... 2005-05-28 14:29:08 +00:00
Kurt Zeilenga
dc0eacd40b Happy New Year! 2005-01-01 20:49:32 +00:00
Howard Chu
ae592801aa Add callbacks for client TLS connection establishment:
LDAP_OPT_X_TLS_CONNECT_CB and LDAP_OPT_X_TLS_CONNECT_ARG
with int (LDAP_TLS_CONNECT_CB) (LDAP *ld, SSL *ssl, SSL_CTX *ctx, void *arg)
To be called whenever the client library allocates a new SSL* handle.
2004-11-23 03:48:09 +00:00
Kurt Zeilenga
fb0571b5ad Poll code needs a bit more work. 2004-10-18 18:18:52 +00:00
Jong Hyuk Choi
331074b2d5 Patch for fast synchronous search result processing 2004-10-18 04:58:36 +00:00
Kurt Zeilenga
ecebe3d051 basic poll(2) implementation for connect(2) (needs work)
Need to deal with selectinfo...
2004-07-09 19:29:46 +00:00
Kurt Zeilenga
f0bd9b3a5b Mark areas needed poll(2) support with HAVE_POLL. 2004-07-09 17:50:22 +00:00
Kurt Zeilenga
3c598e89fb Happy new year 2004-01-01 19:15:16 +00:00
Kurt Zeilenga
4d29df5bd1 Add LDAP_DEPRECATED macro
Need to remove use of deprecated functions.
2003-12-14 02:47:42 +00:00
Kurt Zeilenga
159de0f135 Updated notices and acknowledgements 2003-11-26 07:16:36 +00:00
Luke Howard
bb6f9f4c53 Back out previous commit - files apart from test.c 2003-10-18 16:01:16 +00:00
Luke Howard
32a9ad1be8 ITS#2777 - fix previous commit 2003-10-18 15:59:58 +00:00
Kurt Zeilenga
4f003dbdaf mv ldap_int_get_controls to ldap_pvt_get_controls 2003-10-12 08:14:28 +00:00
Hallvard Furuseth
42de322f06 Make all debug output macros conditional on defined(LDAP_DEBUG). 2003-06-06 13:56:18 +00:00
Howard Chu
46e2b97757 ITS#2424 use two SASL contexts per session to conform to RFC 2222 2003-05-01 04:11:57 +00:00
Kurt Zeilenga
d7a326be26 Don't do (unsafe) DNS reverse lookups.
HEADS UP: May break some Kerberos deployments.
2003-04-22 01:17:23 +00:00
Kurt Zeilenga
978c94a223 ITS#2459 (partial) fix. Eliminate address parameter all together.
Need to look closely at the memcpy.  (It likely can be eliminated
as well.)
2003-04-21 17:06:37 +00:00
Howard Chu
1874658ae3 More memory context tweaks 2003-04-11 01:02:08 +00:00
Howard Chu
844cc97928 More for re-entrant LDAP* handles. Works much better. 2003-02-13 23:02:31 +00:00
Howard Chu
a6b3a92cc5 Added ld_req_mutex and ld_res_mutex to protect ld_requests and ld_responses
queues for multithreaded access to LDAP*'s. Also used to protect writes and
reads of ld_sb, respectively. Appears to work...
2003-02-13 10:43:16 +00:00
Pierangelo Masarati
e5a1418756 improve last commit 2003-02-04 19:27:56 +00:00
Kurt Zeilenga
6939c53170 Happy new year 2003-01-03 20:20:47 +00:00
Howard Chu
464292b50c Remove unneeded sasl_ssf param from ldap_int_sasl_open(),
it's set by ldap_int_sasl_external().
2002-12-18 03:09:52 +00:00
Kurt Zeilenga
9ba95dd027 ITS#2221: getaddrinfo(3) not thread-safe on some platforms (namely
due to res_() routines).  Change all res_() dependent routines to
share same mutex.
2002-12-03 01:15:03 +00:00
Howard Chu
ddfb4b775b Forced commit, undo previous accidental checkin. 2002-10-24 11:40:37 +00:00
Howard Chu
4396ad3316 ITS#2153, make sure sockbuf buffer is empty before returning (-2) from
try_read1msg. Blind fix, problem was not duplicated/tested.
2002-10-24 11:39:06 +00:00
Kurt Zeilenga
491e75548c ITS #2121 submitted by Dave Steck <dsteck@novell.com> with minor changes.
Patch to allow referrals to be read on synchronous non-search operations.
Treat referrals the same way as MatchDN or ErrorString values.
Store them in the ld structure and provide an option for ldap_get_option
to retrieve them
2002-10-02 19:14:02 +00:00
Kurt Zeilenga
a83cc88edd Move ldap_control_dup() to ldap_pvt.h 2002-09-04 02:14:12 +00:00
Howard Chu
456e6c73ab Fix ITS#1983, handle writing of large requests. Only one pending request is
allowed per LDAP* handle. It works, but needs review.
2002-08-29 12:12:36 +00:00
Howard Chu
353f627aa4 Eliminate SASL client session_callbacks. Since proc was always NULL they
never did anything anyway.
2002-06-06 01:44:38 +00:00
Howard Chu
2ca4b0ebfc ITS#1806, Cyrus 1 doesn't give back our callbacks pointer, must stash it
ourselves.
2002-05-06 23:56:35 +00:00
Pierangelo Masarati
4a8ab5dbf2 Mostly based on patches provided by Hallvard B. Furuseth
ITS#1677 - cast away const warnings
ITS#1678 - unsigned char args to ctype funcs
ITS#1682 - don't redefine ldap_debug
ITS#1683 - uninitialized vars
ITS#1703 - ldo_debug initialization
ITS#1705 - unsigned testing
ITS#1706 - socklen_t args
ITS#1719 - back-tcl update (other cleanups/fixes/improvements; yet untested)
ITS#1724 - integerNormalize/integerFilter/integerIndexer bugs
ITS#1725 - libdes not required

Implement back-null (/dev/null style backend)
Cleanup some misc warnings ("%lu" format, unused/uninitialized vars,
        ambiguous operator precedence)

Kurt, please regenerate configure
2002-04-08 09:43:22 +00:00
Kurt Zeilenga
111b464642 move ldap_int_put_filter to ldap_pvt_put_filter
and other cleanup
2002-03-30 00:42:40 +00:00
Howard Chu
a916535a27 Fix #include of sasl.h 2002-02-11 09:39:15 +00:00
Kurt Zeilenga
d23c559646 Don't use 'shtool mkln' as ln(1) replacement.
Allow both <sasl/sasl.h> and <sasl.h>
2002-02-11 08:28:51 +00:00
Kurt Zeilenga
b315d8af34 Update Cyrus SASL detection to always look for <sasl.h> regardless
of version and then try -lsasl2 and -lsasl.  Make SASL code
conditional on SASL_VERSION_MAJOR, not HAVE_CYRUS_SASL.
2002-02-10 17:51:19 +00:00
Howard Chu
8a4e92b259 Support for Cyrus SASLv2. Untested. 2002-02-10 14:27:23 +00:00
Kurt Zeilenga
c36352c173 Misc allocator cleanup 2002-01-05 19:38:54 +00:00
Kurt Zeilenga
0e2af54a3f Update copyright statements 2002-01-04 21:17:25 +00:00
Kurt Zeilenga
11175ed95e Some misc cleanup 2002-01-04 03:50:54 +00:00
Kurt Zeilenga
dedc7588c9 We'll need queue macros in -llber... 2002-01-03 00:49:52 +00:00
Kurt Zeilenga
73b2d62bcd Fix queue.h include 2002-01-03 00:39:09 +00:00
Howard Chu
cc60686c0d Renamed parse_numericoid to ldap_int_parse_numericoid since it is
no longer static. Moved declaration to ldap-int.h and removed extern
from getdn.c
2002-01-02 21:59:26 +00:00
Howard Chu
776ce133e9 More str2rdn tweaks 2001-12-30 09:42:58 +00:00
Kurt Zeilenga
bf5fc54473 Add ftest (filter test) to the mix, needs work.
Misc cleanup of other tests.
Add *.dsp files for tests
2001-12-28 03:39:05 +00:00
Kurt Zeilenga
883196d348 Clean up some symbol scoping 2001-12-24 06:36:44 +00:00
Kurt Zeilenga
c90b4fc878 Back out last change 2001-12-19 21:55:52 +00:00
Kurt Zeilenga
b3b17ca4e7 Remove srchpref and disptmpl stuff. 2001-12-19 21:46:34 +00:00
Howard Chu
e5eb270e6c from jon@symas.com - misc Windows cleanup 2001-12-17 22:42:55 +00:00
Kurt Zeilenga
abd9be4def Remove lint and misc MSVC updates 2001-12-09 02:34:45 +00:00
Howard Chu
0552b1c53f NT updates from jon@symas.com. 2001-12-07 04:03:25 +00:00
Pierangelo Masarati
fefc29786c skeleton of ldap_str2nd/dn2str; works with most of the simple cases, but there's much to do with unicode, I think 2001-10-18 19:00:07 +00:00
Kurt Zeilenga
75c7331743 Added the easy part of NLS support, behind an #ifdef. 2001-10-04 18:06:08 +00:00
Howard Chu
e80b5d4040 Clean up CLDAP stuff 2001-09-28 22:19:51 +00:00
Howard Chu
647b5f84ee Resurrection/rewrite of CLDAP (RFC1798 Connectionless LDAP).
Compile with -DLDAP_CONNECTIONLESS to use this code.
For slapd, use "-h cldap://" to listen on UDP.
For ldapsearch, use "-H cldap://" to query on UDP.
Client-side support is very minimal:
  no automatic timeout/retries
  no basedn wildcard expansion on results
  no support for specifying multiple servers at once.
2001-09-28 00:18:40 +00:00
Kurt Zeilenga
790a18cb86 chasing multi-level referrals core dumps (ITS#1346) bug fix
from Zachary Amsden <zach@mirapoint.com>.
2001-09-24 18:50:44 +00:00
Kurt Zeilenga
553d80cedd Blindly fix TLS/SASL external interaction. 2001-09-09 03:42:26 +00:00
Kurt Zeilenga
05960887bb Fix -H ldaps:// crashes due to rework of TLS code 2001-08-27 20:22:28 +00:00
Kurt Zeilenga
f61152ccbd Check for critical client controls. 2001-07-06 03:13:42 +00:00
Kurt Zeilenga
77f776dfd1 Another round of TLS updates to support secure referral chasing 2001-06-25 19:17:42 +00:00
Kurt Zeilenga
c4f5497ac6 move TLS ctx to lconn struct in prep for supporting TLS with referrals
need to rework cert check to use per lconn host name
2001-06-25 07:33:42 +00:00
Kurt Zeilenga
903940014c Sync with 2.x 2001-06-23 01:25:21 +00:00
Kurt Zeilenga
5f25c10980 new rebind proc
new SASL locking
2001-06-15 00:14:56 +00:00
Kurt Zeilenga
86acd7eb20 unifdef -ULDAP_UFN 2001-06-11 21:08:49 +00:00
Kurt Zeilenga
0a8b2f1381 Trim last of CLDAP cruft 2001-03-15 03:15:15 +00:00
Kurt Zeilenga
599a610164 Update SASL bufsize checks 2001-01-18 22:18:41 +00:00
Kurt Zeilenga
a0828d6135 Rework scope defaulting to only default scope for references.
Might break LDAPv2 partial results
2001-01-10 23:48:24 +00:00
Kurt Zeilenga
511a84bc31 First cut of SASL/EXTERNAL 2000-10-31 23:00:35 +00:00
Gary Williams
3e0cc38404 remove LDAP_Debug macro 2000-10-12 21:16:18 +00:00
Kurt Zeilenga
8e6062eb82 References with empty dn (ITS#817) 2000-10-11 04:23:23 +00:00
Ben Collins
b2866ff162 s/LDAP_PF_UNIX/LDAP_PF_LOCAL/ so that we actually declare ldap_connect_to_path(). Also fix the decleration to match the function 2000-09-15 02:55:54 +00:00
Kurt Zeilenga
102a88659b ITS#717 kbind fixes 2000-09-06 21:32:45 +00:00
Kurt Zeilenga
57ed8f6458 Fix port defaulting 2000-09-01 23:03:17 +00:00
Kurt Zeilenga
25a9f7427d Remove CLDAP cruft 2000-08-18 04:25:00 +00:00
Kurt Zeilenga
ecbb4e55b1 Expose ldap_create_control
Conform schema routines to ldap naming conventions
2000-07-22 17:29:54 +00:00
Kurt Zeilenga
6393523ffa Expose sasl flags to -lldap (so they can be quiet)
Fix interactive and automatic modes.  Quiet needs work.
2000-07-17 21:23:59 +00:00
Kurt Zeilenga
95eea5accc First cut SASL "interactive" and "quiet" modes (default is "automatic") 2000-07-17 00:56:29 +00:00
Kurt Zeilenga
d2b05a3858 Rework SASL command line arguments. Default is now to authenticate
using best available mechanism.  (authzid prompting to be disabled)
To use simple bind, -x is required (implied if -P 2) with -D/-[Ww]
To use simple "anonymous" bind, just -x will do.
2000-07-15 23:25:46 +00:00
Kurt Zeilenga
5fc22599e2 Update SASL code to reuse context through life of session.
Replace 'negotiated' with 'interactive' bind
Add hooks for SASL/EXTERNAL
Disable SASL security layers
Rework SASL command line and config file parameters
2000-07-13 22:54:38 +00:00
Kurt Zeilenga
5d552f6051 Minor cleanup 2000-06-26 01:26:53 +00:00
Kurt Zeilenga
49f4147385 Added -llber 'N' ber_printf format which inserts a NULL if
an internal flag set.  Used for SEQUENCE testing.  Flag must
be set using debugger.  Modified ber_printf to use new format
were needed for extensibility testing.

Added first cut -lldap support for extended responses.
Modified ldapsearch(1) to handle v3 search references when not
chasing.  Also added extended/unsolicited notification handling
and extended partial response handling.  Changes include a
number of LDIF enhancements.

Fixed getpassphrase() returns NULL bugs
2000-06-24 01:40:39 +00:00
Kurt Zeilenga
9ef1a740c2 Round one of LDAP_F() macro changes. In this round we rename
macros into our namespace and limit use to headers.  A subsequent
round will add macros to separately handle forward declarations
of variables from declaration of function prototypes.  The last
round will add additional macros for declaring actual variables and
functions.
2000-06-18 19:48:07 +00:00
Kurt Zeilenga
55dba4395f Update PF_INET6 and PF_UNIX detection, both default to auto 2000-06-09 23:09:51 +00:00
Kurt Zeilenga
77b235fba5 Apply Novell's IN_KERNEL support (ITS#576) 2000-06-08 17:11:57 +00:00
Kurt Zeilenga
22b8b60e49 Add VLV and SortList Control API and related (and other) I-Ds 2000-06-07 19:39:49 +00:00
Kurt Zeilenga
6ad1c45bd3 Use LDAP_VFREE and friends. Other misc code cleanup. 2000-06-07 05:17:29 +00:00
Kurt Zeilenga
1af849c720 DNSSRV use res_query, not res_search
Update configure and depend --enable-dnssrv upon finding res_query
Update back-dnssrv to better handle ManageDSAit control
2000-06-05 23:56:26 +00:00
Kurt Zeilenga
1aa4b07c98 Remove support for DNS DNs (not to be confused with X.500 DN using
domainComponents (DC)).
2000-06-05 20:07:02 +00:00
Kurt Zeilenga
c1117666b1 remove old STR_TRANSLATION feature. The use of this feature
was only of limited use with LDAPv2 (worked okay if no non-T.61
values existed) but downright dangerous in the face of LDAPv3.
Any translation must be schema aware and the BER isn't.
2000-06-05 19:22:19 +00:00
Kurt Zeilenga
7dc76e7139 move --enable-dns (LDAP_API_FEATURE_X_OPENLDAP_V2_DNS) to Attic 2000-06-05 07:19:09 +00:00
Kurt Zeilenga
2e0912622b ITS#537: lber io rewrite from Gambor Gombas.
Copyright 2000 Gábor Gombás. All rights reserved.
This is free software. You may redistribute and use it under the same
terms as OpenLDAP itself.
2000-06-01 20:59:21 +00:00
Kurt Zeilenga
a26cef7fc8 LDAPv3 referrals changes by Steve Sonntag @ Novell 2000-05-31 17:34:43 +00:00
Kurt Zeilenga
29d9fa20a2 Y2k copyright update 2000-05-13 02:36:07 +00:00
Howard Chu
b0faccce56 Added debuglevel parameter to ldap_int_initialize(). 2000-05-11 09:48:40 +00:00