jabberd2
2.7.0
|
#include "sx.h"
Go to the source code of this file.
Functions | |
static void | _sx_compress_notify_compress (sx_t s, void *arg) |
this plugin implements the XEP-0138: Stream Compression More... | |
static int | _sx_compress_process (sx_t s, sx_plugin_t p, nad_t nad) |
static void | _sx_compress_features (sx_t s, sx_plugin_t p, nad_t nad) |
static int | _sx_compress_wio (sx_t s, sx_plugin_t p, sx_buf_t buf) |
static int | _sx_compress_rio (sx_t s, sx_plugin_t p, sx_buf_t buf) |
static void | _sx_compress_new (sx_t s, sx_plugin_t p) |
static void | _sx_compress_free (sx_t s, sx_plugin_t p) |
cleanup More... | |
int | sx_compress_init (sx_env_t env, sx_plugin_t p, va_list args) |
args: none More... | |
int | sx_compress_client_compress (sx_plugin_t p, sx_t s, const char *pemfile) |
|
static |
this plugin implements the XEP-0138: Stream Compression
Definition at line 25 of file compress.c.
References _sx_debug, _sx_reset(), _sx_st::flags, SX_COMPRESS_WRAPPER, sx_server_init(), and ZONE.
Referenced by _sx_compress_process().
|
static |
Definition at line 35 of file compress.c.
References _sx_buffer_new(), _sx_compress_notify_compress(), _sx_debug, _sx_event, _sx_gen_error, _sx_reset(), event_ERROR, _sx_st::flags, jqueue_push(), NAD_ENAME, NAD_ENAME_L, NAD_ENS, nad_free(), NAD_NURI, NAD_NURI_L, _sx_st::ns, _sx_st::req_from, _sx_st::req_to, _sx_st::req_version, sx_client_init(), SX_COMPRESS_OFFER, SX_COMPRESS_WRAPPER, SX_ERR_COMPRESS_FAILURE, _sx_st::type, type_CLIENT, type_SERVER, uri_COMPRESS, _sx_st::want_write, _sx_st::wbufq, and ZONE.
Referenced by sx_compress_init().
|
static |
Definition at line 119 of file compress.c.
References _sx_debug, _sx_st::flags, nad_add_namespace(), nad_append_cdata(), nad_append_elem(), _sx_st::ssf, SX_COMPRESS_OFFER, SX_COMPRESS_WRAPPER, SX_SSL_STARTTLS_REQUIRE, SX_WEBSOCKET_WRAPPER, uri_COMPRESS_FEATURE, and ZONE.
Referenced by sx_compress_init().
|
static |
Definition at line 135 of file compress.c.
References _sx_buffer_alloc_margin(), _sx_buffer_clear(), _sx_debug, _sx_event, _sx_gen_error, _sx_buf_st::data, event_ERROR, _sx_st::flags, _sx_plugin_st::index, _sx_buf_st::len, _sx_st::plugin_data, stream_err_INTERNAL_SERVER_ERROR, sx_close(), SX_COMPRESS_WRAPPER, SX_ERR_COMPRESS, sx_error(), and ZONE.
Referenced by sx_compress_init().
|
static |
Definition at line 196 of file compress.c.
References _sx_buffer_alloc_margin(), _sx_buffer_clear(), _sx_debug, _sx_event, _sx_gen_error, _sx_buf_st::data, event_ERROR, _sx_st::flags, _sx_plugin_st::index, _sx_buf_st::len, _sx_st::plugin_data, stream_err_INVALID_XML, sx_close(), SX_COMPRESS_WRAPPER, SX_ERR_COMPRESS, sx_error(), and ZONE.
Referenced by sx_compress_init().
|
static |
Definition at line 266 of file compress.c.
References _sx_buffer_new(), _sx_chain_io_plugin(), _sx_debug, _sx_st::flags, _sx_plugin_st::index, _sx_st::plugin_data, SX_COMPRESS_WRAPPER, _sx_st::tag, and ZONE.
Referenced by sx_compress_init().
|
static |
cleanup
Definition at line 301 of file compress.c.
References _sx_buffer_free(), _sx_plugin_st::index, log_debug, _sx_st::plugin_data, _sx_st::type, type_NONE, and ZONE.
Referenced by sx_compress_init().
int sx_compress_init | ( | sx_env_t | env, |
sx_plugin_t | p, | ||
va_list | args | ||
) |
args: none
Definition at line 328 of file compress.c.
References _sx_compress_features(), _sx_compress_free(), _sx_compress_new(), _sx_compress_process(), _sx_compress_rio(), _sx_compress_wio(), _sx_debug, _sx_plugin_st::client, _sx_plugin_st::features, _sx_plugin_st::free, _sx_plugin_st::process, _sx_plugin_st::rio, _sx_plugin_st::server, _sx_plugin_st::wio, and ZONE.
Referenced by JABBER_MAIN().
int sx_compress_client_compress | ( | sx_plugin_t | p, |
sx_t | s, | ||
const char * | pemfile | ||
) |
Definition at line 343 of file compress.c.
References _sx_buffer_new(), _sx_debug, _sx_event, event_WANT_WRITE, _sx_st::flags, jqueue_push(), _sx_st::state, state_STREAM, SX_COMPRESS_WRAPPER, _sx_st::type, type_CLIENT, uri_COMPRESS, _sx_st::want_write, _sx_st::wbufq, and ZONE.