mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-29 20:59:47 +01:00
Implement ZAP and integrate it with PLAIN mechanism
This commit is contained in:
@@ -67,11 +67,23 @@ namespace zmq
|
||||
// The function takes ownership of the message.
|
||||
int push_msg (msg_t *msg_);
|
||||
|
||||
int zap_connect ();
|
||||
|
||||
// Fetches a message. Returns 0 if successful; -1 otherwise.
|
||||
// The caller is responsible for freeing the message when no
|
||||
// longer used.
|
||||
int pull_msg (msg_t *msg_);
|
||||
|
||||
// Receives message from ZAP socket.
|
||||
// Returns 0 on success; -1 otherwise.
|
||||
// The caller is responsible for freeing the message.
|
||||
int read_zap_msg (msg_t *msg_);
|
||||
|
||||
// Sends message to ZAP socket.
|
||||
// Returns 0 on success; -1 otherwise.
|
||||
// The function takes ownership of the message.
|
||||
int write_zap_msg (msg_t *msg_);
|
||||
|
||||
socket_base_t *get_socket ();
|
||||
|
||||
protected:
|
||||
@@ -109,6 +121,9 @@ namespace zmq
|
||||
// Pipe connecting the session to its socket.
|
||||
zmq::pipe_t *pipe;
|
||||
|
||||
// Pipe used to exchange messages with ZAP socket.
|
||||
zmq::pipe_t *zap_pipe;
|
||||
|
||||
// This set is added to with pipes we are disconnecting, but haven't yet completed
|
||||
std::set <pipe_t *> terminating_pipes;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user