Kurt Zeilenga
9826f704b5
Back out to simple sock_errno sock_errstr macros and use WSAGetErrorString
...
instead of WSAGetLastErrorString to preserve errno like semantics.
1999-08-29 23:33:35 +00:00
Howard Chu
3925d53ccd
Replaced sock_errno()/sock_errstr() macros with SOCK_ERR(num,str)
1999-08-29 23:09:27 +00:00
Kurt Zeilenga
32aa582abe
Make sock_errstr expect an error value instead of relying on current
...
errno.
1999-08-29 20:32:34 +00:00
Howard Chu
74543e6c68
Defined tcp_read and tcp_write. Use them in daemon.c
1999-08-29 04:01:16 +00:00
Howard Chu
801bac51c9
per Hallvard's advice: fixed definition of sock_errstr().
1999-08-29 02:54:58 +00:00
Howard Chu
d75975edf8
Use sock_errno() and sock_errstr() in socket debug messages.
...
Use a UDP socket connected to itself to allow signals to terminate the
select() in slapd_daemon_task().
1999-08-29 01:51:45 +00:00
Kurt Zeilenga
5c63fd55b5
Implement ldap_dn_normalize and friends. Should be used by clients
...
to validate input dn's BEFORE sending dn's to server.
Also fixed getfilter to use REG_EXTENDED|REG_NOSUB. (and fixed one
case where REG_BASIC was still used).
s/strdup/LDAP_STRDUP/
Added ldap_pvt_str2lower/upper
1999-08-25 06:44:08 +00:00
Hallvard Furuseth
2d6460f880
plug memory leak
1999-08-19 11:44:44 +00:00
Kurt Zeilenga
8ead8c5fd9
Clean up debug messages.
1999-08-19 00:40:18 +00:00
Hallvard Furuseth
6054463eeb
Minor cleanup:
...
Fix Statlog() formats, remove an implicit int, include <ctype.h> for isspace().
1999-08-07 05:36:48 +00:00
Kurt Zeilenga
9c3ed0310b
Add copyright notices.
1999-08-06 23:07:46 +00:00
Kurt Zeilenga
9ea7a42b99
Add copyright notice and a few comments here and there
1999-08-04 23:59:13 +00:00
Kurt Zeilenga
2b79ff2c48
Initial inet_aton() detection.
1999-08-03 20:02:44 +00:00
Kurt Zeilenga
df8f7cbb9b
s/exit(1)/exit(EXIT_FAILURE)/
...
s/exit(0)/exit(EXIT_SUCCESS)/
add <ac/stdlib.h> where needed and other minor header adjustments
1999-08-03 18:14:24 +00:00
Kurt Zeilenga
008bbf56db
Fix -USLAPD_RLOOKUPS
1999-07-27 18:49:32 +00:00
Kurt Zeilenga
d147e609d2
Implement TCP_NODELAY on both client and server side.
1999-07-22 21:49:35 +00:00
Kurt Zeilenga
f0c1fc37f5
Fix IP: typo in peername
1999-07-22 20:37:56 +00:00
Kurt Zeilenga
933908f72f
ACL CHANGES:
...
by <who> <access> changed to by <who>+ <access> (joined with AND)
added peername=<regex> sockname=<regex> url=<regex>
removed addr=<regex> (use peername instead).
replace dn_upcase with str2upper and str2lower. Use where needed.
1999-07-21 20:54:23 +00:00
Gary Williams
f4eb2feba5
use rd instead of i looking for listeners (line 848)
1999-07-20 21:55:06 +00:00
Julio Sánchez Fernández
504038ffac
Move the input data exhaustion loop to connection.c from daemon.c
1999-07-20 18:03:29 +00:00
Julio Sánchez Fernández
535cc34421
If we did gethostbyname, we need no further address manipulation.
1999-07-20 11:26:44 +00:00
Kurt Zeilenga
cb94e155ae
Don't call Debug inside a signal handler
1999-07-20 07:11:56 +00:00
Kurt Zeilenga
6847e329bc
Fix new URL startup code.
1999-07-19 20:48:19 +00:00
Kurt Zeilenga
170836751a
Namespace changes
...
added slap_ and ldbm_ to many structures
added typedefs to many structures
used typedefs
New main.c argument parsing with ldap url support (replacing -a address).
New sockaddr_in handling and support for multiple listeners.
1999-07-19 19:40:33 +00:00
Hallvard Furuseth
425bab2c47
Add comment thatPass socklen_t* instead of int* to getsockopt, accept, getpeername, recvfrom
1999-07-16 18:57:11 +00:00
Julio Sánchez Fernández
0053b27ce0
Look on connection_read() if it returns positive so it has a chance
...
to exhaust all protocol units received from the transport layer.
I think this is the necessary fix for the TLS-data-ready/
socket-not-ready issue, but I have not experimented that problem
yet, so I am unsure about its effectiveness.
Now, do we need something like that for connection_write? How would
we go about implementing it?
1999-07-16 18:53:30 +00:00
Julio Sánchez Fernández
6d75d0f8fb
connection_init now takes one more argument that indicates whether to
...
use TLS right away or not on that connection.
1999-07-14 19:44:18 +00:00
Julio Sánchez Fernández
c18d6e7ecf
Only bind on TLS port if explicitly requested with -T, otherwise all
...
kind of conflicts happen when running tests.
1999-07-14 13:39:30 +00:00
Julio Sánchez Fernández
5b7babdee4
Bind and listen on TLS port too
1999-07-14 13:16:13 +00:00
Kurt Zeilenga
2fda53f375
Add missing arguments to Debug() calls... and adapt nt_debug for general
...
use.
1999-06-21 22:36:13 +00:00
Kurt Zeilenga
13ac82621b
Limit the check to a 4 tries every timeout.
1999-06-19 03:23:49 +00:00
Kurt Zeilenga
2d720643be
experimental connections_timeout_idle() implementation.
1999-06-19 03:20:01 +00:00
Kurt Zeilenga
669b8f4047
ber_int_t, ber_tag_t, ber_socket_t, ber_len_t
...
added lber_types.h.nt, lber_types.h.in
removal of NULLxxx internal macros (in favor of NULL).
ch_free added to slapd,slurpd/ch_malloc.c
#define free ch_free (should be removed after s/free/ch_free/g) in proto-slap.h
ch_malloc and friends use ber_memalloc and friends
1999-06-18 23:53:05 +00:00
Gary Williams
1971837778
fix comments (remove // style), free(ptr) in slapd_daemon_task was causing heap failure
1999-06-18 21:31:53 +00:00
Kurt Zeilenga
b0aea66d1d
Recommit NT service changes (untested) with changes to resolve
...
compiling errors on other platforms. Will need to update NT projects.
1999-06-17 18:46:02 +00:00
Kurt Zeilenga
bbc568b21f
ldapconfig.h vs ldap_config.h changes
...
backout previous nt changes (actually, just don't include nt_svc.c)
1999-06-17 04:43:24 +00:00
Kurt Zeilenga
21e081dc5b
Separate autoconf generated values from "defaults".
...
ldap_defaults.h incorporates non-generated ldapconfig.h values.
ldap_config.h.in is new template for autoconf generated defaults
(namely directories and paths)
ldap_config.h.nt, NT template (must be manually copied)
s/<ldapconfig.h>/<ldap_defaults.h>/
s/DIRSEP/LDAP_DIRSEP/ & s/DEFAULT_/LDAP_/
1999-06-17 03:54:25 +00:00
Kurt Zeilenga
23c4b81819
Backout NT Service changes.... breaks Unix builds...
1999-06-17 00:51:12 +00:00
Gary Williams
4d13d4071a
add code to support slapd as NT service
1999-06-16 19:15:35 +00:00
Kurt Zeilenga
e2e1cb76cb
Remove check for inactive streams before connection_read/_write
...
calls. Such checks are ineffective it protecting connection_read/_write
from being called inactive streams. connection_read/_write have their
own protection against such (in connection_get()).
1999-06-14 20:28:30 +00:00
Kurt Zeilenga
3cfd58eed8
EXPERIMENTAL: move slapd_remove to connections_read/_write as they
...
acquire c_mutex.
1999-06-11 19:10:45 +00:00
Kurt Zeilenga
368628e9d5
Close inactive streams instead of asserting condition.
1999-06-10 22:06:05 +00:00
Kurt Zeilenga
571e8c098d
Add cheap EBADF loop protection.
1999-06-10 21:11:21 +00:00
Kurt Zeilenga
9c793f15f4
Fix typo in last commit.
1999-06-10 15:55:00 +00:00
Kurt Zeilenga
446ef413f6
Don't shutdown when select() returns EBADF.
1999-06-10 03:11:22 +00:00
Kurt Zeilenga
64bb1a99f4
Fix unprotected (and bad) FD_SET asserts.
1999-06-10 02:52:51 +00:00
Kurt Zeilenga
22e981eef3
Close hit socket.
1999-06-04 21:42:25 +00:00
Kurt Zeilenga
5b218b7671
Move WAKE_LISTENER call behind &connection_mutex to eliminate
...
race condition on file descriptor sets.
1999-06-04 01:05:29 +00:00
Kurt Zeilenga
1a7d72e629
setsockopt( SO_KEEPALIVE ) on the listen() socket. Will be
...
inherited on accept().
1999-05-24 22:20:34 +00:00
Kurt Zeilenga
42c5a40b78
Implement keep alives. Probably should be a configuration option.
1999-05-24 21:57:26 +00:00