diff --git a/libwebsockets-api-doc.html b/libwebsockets-api-doc.html index eae14036..80ccd376 100644 --- a/libwebsockets-api-doc.html +++ b/libwebsockets-api-doc.html @@ -219,6 +219,25 @@ context. After calling this, any further use of the context is undefined.
+

lws_set_extension_option -

+int +lws_set_extension_option +(struct lws * wsi, +const char * ext_name, +const char * opt_name, +const char * opt_val) +

Arguments

+
+
wsi +
websocket connection +
ext_name +
name of ext, like "permessage-deflate" +
opt_name +
name of option, like "rx_buf_size" +
opt_val +
value to set option to +
+

lws_return_http_status - Return simple http status

int lws_return_http_status @@ -324,6 +343,22 @@ using globals statics in the user code.
Callback reason index
+

lws_callback_all_protocol_vhost - Callback all connections using the given protocol with the given reason

+int +lws_callback_all_protocol_vhost +(struct lws_vhost * vh, +const struct lws_protocols * protocol, +int reason) +

Arguments

+
+
vh +
Vhost whose connections will get callbacks +
protocol +
Which protocol to match +
reason +
Callback reason index +
+

lws_get_socket_fd - returns the socket file descriptor

int lws_get_socket_fd @@ -396,12 +431,10 @@ has been created.

lws_set_proxy - Setups proxy to lws_context.

int lws_set_proxy -(struct lws_context * context, +(struct lws_vhost * vhost, const char * proxy)

Arguments

-
context -
pointer to struct lws_context you want set proxy to
proxy
pointer to c string containing proxy in format address:port
@@ -543,8 +576,10 @@ and the leading / on the path is consequently lost LWS_EXTERN int lws_cgi (struct lws * wsi, -char *const * exec_array, -int timeout_secs) +const char *const * exec_array, +int script_uri_path_len, +int timeout_secs, +const struct lws_protocol_vhost_options * mp_cgienv)

Arguments

wsi @@ -553,6 +588,16 @@ and the leading / on the path is consequently lost
array of "exec-name" "arg1" ... "argn" NULL

+

lws_cgi_write_split_stdout_headers -

+LWS_EXTERN int +lws_cgi_write_split_stdout_headers +(struct lws * wsi) +

Arguments

+
+
wsi +
connection to own the process +
+

lws_cgi_kill -

LWS_EXTERN int lws_cgi_kill @@ -800,6 +845,25 @@ Many protocols won't care becuse their packets are always small.
Websocket connection instance to get callback for
+

lws_callback_on_writable_all_protocol_vhost - Request a callback for all connections using the given protocol when it becomes possible to write to each socket without blocking in turn.

+int +lws_callback_on_writable_all_protocol_vhost +(const struct lws_vhost * vhost, +const struct lws_protocols * protocol) +

Arguments

+
+
vhost +
Only consider connections on this lws_vhost +
protocol +
Protocol whose connections will get callbacks +
+

Description

+
+

+This calls back connections with the same protocol ON THE SAME +VHOST ONLY. +

+

lws_callback_on_writable_all_protocol - Request a callback for all connections using the given protocol when it becomes possible to write to each socket without blocking in turn.

int lws_callback_on_writable_all_protocol @@ -812,6 +876,12 @@ Many protocols won't care becuse their packets are always small.
protocol
Protocol whose connections will get callbacks +

Description

+
+

+This calls back any connection using the same protocol on ANY +VHOST. +


lws_http_transaction_completed - wait for new http transaction or close

int LWS_WARN_UNUSED_RESULT @@ -1615,104 +1685,149 @@ header.     unsigned int fd_limit_per_thread;
    unsigned int timeout_secs;
    const char * ecdh_curve;
+    const char * vhost_name;
+    const char *const * plugin_dirs;
+    const struct lws_protocol_vhost_options * pvo;
+    int keepalive_timeout;
+    const char * log_filepath;
+    const struct lws_http_mount * mounts;
+    const char * server_string;
};

Members

port -
Port to listen on... you can use CONTEXT_PORT_NO_LISTEN to +
VHOST: Port to listen on... you can use CONTEXT_PORT_NO_LISTEN to suppress listening on any port, that's what you want if you are not running a websocket server at all but just using it as a client
iface -
NULL to bind the listen socket to all interfaces, or the +
VHOST: NULL to bind the listen socket to all interfaces, or the interface name, eg, "eth2" +If options specifies LWS_SERVER_OPTION_UNIX_SOCK, this member is +the pathname of a UNIX domain socket. you can use the UNIX domain +sockets in abstract namespace, by prepending an @ symbole to the +socket name.
protocols -
Array of structures listing supported protocols and a protocol- +
VHOST: Array of structures listing supported protocols and a protocol- specific callback for each one. The list is ended with an entry that has a NULL callback pointer. It's not const because we write the owning_server member
extensions -
NULL or array of lws_extension structs listing the +
VHOST: NULL or array of lws_extension structs listing the extensions this context supports. If you configured with --without-extensions, you should give NULL here.
token_limits -
NULL or struct lws_token_limits pointer which is initialized +
CONTEXT: NULL or struct lws_token_limits pointer which is initialized with a token length limit for each possible WSI_TOKEN_***
ssl_cert_filepath -
If libwebsockets was compiled to use ssl, and you want +
VHOST: If libwebsockets was compiled to use ssl, and you want to listen using SSL, set to the filepath to fetch the server cert from, otherwise NULL for unencrypted
ssl_private_key_filepath -
filepath to private key if wanting SSL mode; +
VHOST: filepath to private key if wanting SSL mode; if this is set to NULL but sll_cert_filepath is set, the OPENSSL_CONTEXT_REQUIRES_PRIVATE_KEY callback is called to allow setting of the private key directly via openSSL library calls
ssl_ca_filepath -
CA certificate filepath or NULL +
VHOST: CA certificate filepath or NULL
ssl_cipher_list -
List of valid ciphers to use (eg, +
VHOST: List of valid ciphers to use (eg, "RC4-MD5:RC4-SHA:AES128-SHA:AES256-SHA:HIGH:!DSS:!aNULL" or you can leave it as NULL to get "DEFAULT"
http_proxy_address -
If non-NULL, attempts to proxy via the given address. +
VHOST: If non-NULL, attempts to proxy via the given address. If proxy auth is required, use format "username:passwordserver:port"
http_proxy_port -
If http_proxy_address was non-NULL, uses this port at +
VHOST: If http_proxy_address was non-NULL, uses this port at the address
gid -
group id to change to after setting listen socket, or -1. +
CONTEXT: group id to change to after setting listen socket, or -1.
uid -
user id to change to after setting listen socket, or -1. +
CONTEXT: user id to change to after setting listen socket, or -1.
options -
0, or LWS_SERVER_OPTION_... bitfields +
VHOST + CONTEXT: 0, or LWS_SERVER_OPTION_... bitfields
user -
optional user pointer that can be recovered via the context +
CONTEXT: optional user pointer that can be recovered via the context pointer using lws_context_user
ka_time -
0 for no keepalive, otherwise apply this keepalive timeout to +
CONTEXT: 0 for no keepalive, otherwise apply this keepalive timeout to all libwebsocket sockets, client or server
ka_probes -
if ka_time was nonzero, after the timeout expires how many +
CONTEXT: if ka_time was nonzero, after the timeout expires how many times to try to get a response from the peer before giving up and killing the connection
ka_interval -
if ka_time was nonzero, how long to wait before each ka_probes +
CONTEXT: if ka_time was nonzero, how long to wait before each ka_probes attempt
provided_client_ssl_ctx -
If non-null, swap out libwebsockets ssl +
CONTEXT: If non-null, swap out libwebsockets ssl implementation for the one provided by provided_ssl_ctx. Libwebsockets no longer is responsible for freeing the context if this option is selected.
provided_client_ssl_ctx -
If non-null, swap out libwebsockets ssl +
CONTEXT: If non-null, swap out libwebsockets ssl implementation for the one provided by provided_ssl_ctx. Libwebsockets no longer is responsible for freeing the context if this option is selected.
max_http_header_data -
The max amount of header payload that can be handled +
CONTEXT: The max amount of header payload that can be handled in an http request (unrecognized header payload is dropped)
max_http_header_pool -
The max number of connections with http headers that +
CONTEXT: The max number of connections with http headers that can be processed simultaneously (the corresponding memory is allocated for the lifetime of the context). If the pool is busy new incoming connections must wait for accept until one becomes free.
count_threads -
how many contexts to create in an array, 0 = 1 +
CONTEXT: how many contexts to create in an array, 0 = 1
fd_limit_per_thread -
nonzero means restrict each service thread to this +
CONTEXT: nonzero means restrict each service thread to this many fds, 0 means the default which is divide the process fd limit by the number of threads.
timeout_secs -
various processes involving network roundtrips in the +
VHOST: various processes involving network roundtrips in the library are protected from hanging forever by timeouts. If nonzero, this member lets you set the timeout used in seconds. Otherwise a default timeout is used.
ecdh_curve -
if NULL, defaults to initializing server with "prime256v1" +
VHOST: if NULL, defaults to initializing server with "prime256v1" +
vhost_name +
VHOST: name of vhost, must match external DNS name used to +access the site, like "warmcat.com" as it's used to match +
plugin_dirs +
CONTEXT: NULL, or NULL-terminated array of directories to +scan for lws protocol plugins at context creation time +
pvo +
VHOST: pointer to optional linked list of per-vhost +options made accessible to protocols +
keepalive_timeout +
VHOST: (default = 0 = 60s) seconds to allow remote +client to hold on to an idle HTTP/1.1 connection +
log_filepath +
VHOST: filepath to append logs to... this is opened before +any dropping of initial privileges +
mounts +
VHOST: optional linked list of mounts for this vhost +
server_string +
CONTEXT: string used in HTTP headers to identify server +software, if NULL, "libwebsockets".
+

Description

+
+

+This is also used to create vhosts.... if LWS_SERVER_OPTION_EXPLICIT_VHOSTS +is not given, then for backwards compatibility one vhost is created at +context-creation time using the info from this struct. +

+If LWS_SERVER_OPTION_EXPLICIT_VHOSTS is given, then no vhosts are created +at the same time as the context, they are expected to be created afterwards. +

+

Host

+
+header and / or SNI name for SSL. +

struct lws_client_connect_info - parameters to connect with when using lws_client_connect_via_info()

struct lws_client_connect_info {
@@ -1728,6 +1843,10 @@ Otherwise a default timeout is used.     void * userdata;
    const struct lws_extension * client_exts;
    const char * method;
+    struct lws * parent_wsi;
+    const char * uri_replace_from;
+    const char * uri_replace_to;
+    struct lws_vhost * vhost;
};

Members

@@ -1756,6 +1875,17 @@ Otherwise a default timeout is used.
method
if non-NULL, do this http method instead of ws[s] upgrade. use "GET" to be a simple http client connection +
parent_wsi +
if another wsi is responsible for this connection, give it here. +this is used to make sure if the parent closes so do any +child connections first. +
uri_replace_from +
if non-NULL, when this string is found in URIs in +text/html content-encoding, it's replaced with uri_replace_to +
uri_replace_to +
see above +
vhost +
vhost to bind to (used to determine related SSL_CTX)

lws_close_reason - Set reason and aux data to send with Close packet If you are going to return nonzero from the callback requesting the connection to close, you can optionally call this to set the reason the peer will be told if possible.

diff --git a/release-checklist b/release-checklist index 8cdcac09..3d9079df 100644 --- a/release-checklist +++ b/release-checklist @@ -82,11 +82,16 @@ Release Checklist - Bump version to 1.6.4 - MINOR fix xyz -6) signed tag +6) update api docs + + $ cmake .. + $ cp doc/* .. + +7) signed tag git tag -s vX.Y[.Z] -7) git +8) git a) push