diff options
author | Noriko Hosoi <nhosoi@redhat.com> | 2008-05-16 16:46:49 +0000 |
---|---|---|
committer | Noriko Hosoi <nhosoi@redhat.com> | 2008-05-16 16:46:49 +0000 |
commit | f4cadfcc40326a6ce29cb4b2aafee568fc15bb05 (patch) | |
tree | 6b53ba554b92ed780d769960146da2a038c99baa /ldap/servers/slapd/slap.h | |
parent | c6f0c0228924cf4984b0de6ce3e8e965a9c2d3ce (diff) | |
download | ds-f4cadfcc40326a6ce29cb4b2aafee568fc15bb05.tar.gz ds-f4cadfcc40326a6ce29cb4b2aafee568fc15bb05.tar.xz ds-f4cadfcc40326a6ce29cb4b2aafee568fc15bb05.zip |
Resolves: #436390
Summary: LDAPI: support auto-bind
Description:
1) Debugged the basic code of slapd_get_socket_peer, which is used for Solaris9
and HP-UX. The recvmsg call returns an error immediately if no data is waiting
to be received since the socket is set PR_SockOpt_Nonblocking (O_NONBLOCK). To
make slapd_get_socket_peer more robust, we have to retry recvmsg if it returns
EAGAIN. But set a retry count not to hang there.
2) Introduced c_local_valid in the Connection handle to tell the autobind
code that the uid/gid pair is valid or not.
3) Stops the automagic/unconditional auto-bind (the code used to be in
daemon.c).
4) Auto-bind is effective only when the client passes the SASL/EXTERNAL request.
Diffstat (limited to 'ldap/servers/slapd/slap.h')
-rw-r--r-- | ldap/servers/slapd/slap.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ldap/servers/slapd/slap.h b/ldap/servers/slapd/slap.h index 0b3305e3..982b9be8 100644 --- a/ldap/servers/slapd/slap.h +++ b/ldap/servers/slapd/slap.h @@ -1247,9 +1247,10 @@ typedef struct conn { int c_enable_sasl_io; /* Flag to tell us to enable SASL I/O on the next read */ int c_sasl_io; /* Flag to tell us to enable SASL I/O on the next read */ int c_sasl_ssf; /* flag to tell us the SASL SSF */ - int c_unix_local; /* flag true for LDAPI */ - uid_t c_local_uid; /* uid of connecting process */ - gid_t c_local_gid; /* gid of connecting process */ + int c_unix_local; /* flag true for LDAPI */ + int c_local_valid; /* flag true if the uid/gid are valid */ + uid_t c_local_uid; /* uid of connecting process */ + gid_t c_local_gid; /* gid of connecting process */ } Connection; #define CONN_FLAG_SSL 1 /* Is this connection an SSL connection or not ? * Used to direct I/O code when SSL is handled differently |