summaryrefslogtreecommitdiff
path: root/source4/ldap_server/ldap_server.h
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-06-19 09:31:34 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:18:30 -0500
commitc7496c6cdb7bdcdd483868c21457350f567ec054 (patch)
tree5584e0aaf51f9504bc5754d79a147b39af766de2 /source4/ldap_server/ldap_server.h
parent68853a1c7be11ffaaef4ad2e3f78a97f0b401b68 (diff)
downloadsamba-c7496c6cdb7bdcdd483868c21457350f567ec054.tar.gz
samba-c7496c6cdb7bdcdd483868c21457350f567ec054.tar.bz2
samba-c7496c6cdb7bdcdd483868c21457350f567ec054.zip
r7747: - simplified the ldap server buffer handling
- got rid of the special cases for sasl buffers - added a tls_socket_pending() call to determine how much data is waiting on a tls connection - removed the attempt at async handling of ldap calls. The buffers/sockets are all async, but the calls themselves are sync. (This used to be commit 73cb4aad229d08e17e22d5792580bd43a61b142a)
Diffstat (limited to 'source4/ldap_server/ldap_server.h')
-rw-r--r--source4/ldap_server/ldap_server.h60
1 files changed, 17 insertions, 43 deletions
diff --git a/source4/ldap_server/ldap_server.h b/source4/ldap_server/ldap_server.h
index 2427c2b698..32b2cffe99 100644
--- a/source4/ldap_server/ldap_server.h
+++ b/source4/ldap_server/ldap_server.h
@@ -21,62 +21,36 @@
#include "libcli/ldap/ldap.h"
-struct rw_buffer {
- uint8_t *data;
- size_t ofs, length;
-};
+struct ldapsrv_connection {
+ struct stream_connection *connection;
+ struct gensec_security *gensec;
+ struct auth_session_info *session_info;
+ struct ldapsrv_service *service;
+ struct tls_context *tls;
-enum ldapsrv_call_state {
- LDAPSRV_CALL_STATE_NEW = 0,
- LDAPSRV_CALL_STATE_BUSY,
- LDAPSRV_CALL_STATE_ASYNC,
- LDAPSRV_CALL_STATE_ABORT,
- LDAPSRV_CALL_STATE_COMPLETE
-};
+ /* partially received request */
+ DATA_BLOB partial;
-enum ldapsrv_reply_state {
- LDAPSRV_REPLY_STATE_NEW = 0,
- LDAPSRV_REPLY_STATE_SEND
-};
+ /* are we using gensec wrapping? */
+ BOOL enable_wrap;
-struct ldapsrv_connection;
+ /* reply send queue */
+ struct ldapsrv_send {
+ struct ldapsrv_send *next, *prev;
+ DATA_BLOB data;
+ } *send_queue;
+};
struct ldapsrv_call {
- struct ldapsrv_call *prev,*next;
- enum ldapsrv_call_state state;
-
struct ldapsrv_connection *conn;
-
struct ldap_message *request;
-
struct ldapsrv_reply {
- struct ldapsrv_reply *prev,*next;
- enum ldapsrv_reply_state state;
+ struct ldapsrv_reply *prev, *next;
struct ldap_message *msg;
} *replies;
};
struct ldapsrv_service;
-
-struct ldapsrv_connection {
- struct stream_connection *connection;
-
- struct gensec_security *gensec;
- struct auth_session_info *session_info;
-
- struct rw_buffer sasl_in_buffer;
- struct rw_buffer sasl_out_buffer;
-
- struct rw_buffer in_buffer;
- struct rw_buffer out_buffer;
-
- struct ldapsrv_call *calls;
-
- struct ldapsrv_service *service;
-
- struct tls_context *tls;
-};
-
struct ldapsrv_partition;
struct ldapsrv_partition_ops {