Andy Green | a35c86f | 2013-01-31 10:16:44 +0800 | [diff] [blame] | 1 | Changelog |
| 2 | --------- |
| 3 | |
Andy Green | 7900256 | 2013-11-09 11:04:35 +0800 | [diff] [blame] | 4 | (since v1.23) |
| 5 | |
kapejod | ce64fb0 | 2013-11-19 13:38:16 +0100 | [diff] [blame] | 6 | User api additions |
| 7 | ------------------ |
| 8 | |
| 9 | POST method is supported |
| 10 | |
| 11 | The protocol 0 / HTTP callback can now get two new kinds of callback, |
| 12 | LWS_CALLBACK_HTTP_BODY (in and len are a chunk of the body of the HTTP request) |
| 13 | and LWS_CALLBACK_HTTP_BODY_COMPLETION (the expected amount of body has arrived |
| 14 | and been passed to the user code already). These callbacks are used with the |
| 15 | post method (see the test server for details). |
| 16 | |
| 17 | The period between the HTTP header completion and the completion of the body |
| 18 | processing is protected by a 5s timeout. |
| 19 | |
| 20 | The chunks are stored in a malloc'd buffer of size protocols[0].rx_buffer_size. |
| 21 | |
| 22 | |
James Devine | 5b34c97 | 2013-12-14 11:41:29 +0800 | [diff] [blame] | 23 | New server option you can enable from user code |
| 24 | LWS_SERVER_OPTION_ALLOW_NON_SSL_ON_SSL_PORT allows non-SSL connections to |
| 25 | also be accepted on an SSL listening port. It's disabled unless you enable |
| 26 | it explicitly. |
| 27 | |
| 28 | |
Andy Green | 7a13279 | 2013-12-18 09:48:26 +0800 | [diff] [blame] | 29 | Two new callbacks are added in protocols[0] that are optional for allowing |
| 30 | limited thread access to libwebsockets, LWS_CALLBACK_LOCK_POLL and |
| 31 | LWS_CALLBACK_UNLOCK_POLL. |
| 32 | |
| 33 | If you use them, they protect internal and external poll list changes, but if |
| 34 | you want to use external thread access to libwebsocket_callback_on_writable() |
| 35 | you have to implement your locking here even if you don't use external |
| 36 | poll support. |
| 37 | |
| 38 | If you will use another thread for this, take a lot of care about managing |
| 39 | your list of live wsi by doing it from ESTABLISHED and CLOSED callbacks |
| 40 | (with your own locking). |
| 41 | |
| 42 | |
| 43 | |
Andy Green | 7900256 | 2013-11-09 11:04:35 +0800 | [diff] [blame] | 44 | User api changes |
| 45 | ---------------- |
| 46 | |
| 47 | Extra optional argument to libwebsockets_serve_http_file() allows injecion |
| 48 | of HTTP headers into the canned response. Eg, cookies may be added like |
| 49 | that without getting involved in having to send the header by hand. |
| 50 | |
| 51 | |
| 52 | |
Andy Green | 81877e6 | 2013-10-26 20:36:08 +0800 | [diff] [blame] | 53 | v1.23-chrome32-firefox24 |
| 54 | ======================== |
| 55 | |
| 56 | Android.mk | 29 + |
| 57 | CMakeLists.txt | 573 ++++++++---- |
| 58 | COPYING | 503 ----------- |
| 59 | INSTALL | 365 -------- |
| 60 | Makefile.am | 13 - |
| 61 | README.build | 371 ++------ |
| 62 | README.coding | 63 ++ |
| 63 | autogen.sh | 1578 --------------------------------- |
| 64 | changelog | 69 ++ |
| 65 | cmake/FindGit.cmake | 163 ++++ |
| 66 | cmake/FindOpenSSLbins.cmake | 15 +- |
| 67 | cmake/UseRPMTools.cmake | 176 ++++ |
| 68 | config.h.cmake | 25 +- |
| 69 | configure.ac | 226 ----- |
| 70 | cross-arm-linux-gnueabihf.cmake | 28 + |
| 71 | lib/Makefile.am | 89 -- |
| 72 | lib/base64-decode.c | 98 +- |
| 73 | lib/client-handshake.c | 123 ++- |
| 74 | lib/client-parser.c | 19 +- |
| 75 | lib/client.c | 145 ++- |
| 76 | lib/daemonize.c | 4 +- |
| 77 | lib/extension.c | 2 +- |
| 78 | lib/getifaddrs.h | 4 +- |
| 79 | lib/handshake.c | 76 +- |
| 80 | lib/libwebsockets.c | 491 ++++++---- |
| 81 | lib/libwebsockets.h | 164 ++-- |
| 82 | lib/output.c | 214 ++++- |
| 83 | lib/parsers.c | 102 +-- |
| 84 | lib/private-libwebsockets.h | 66 +- |
| 85 | lib/server-handshake.c | 5 +- |
| 86 | lib/server.c | 29 +- |
| 87 | lib/sha-1.c | 2 +- |
| 88 | libwebsockets-api-doc.html | 249 +++--- |
| 89 | libwebsockets.pc.in | 11 - |
| 90 | libwebsockets.spec | 14 +- |
| 91 | m4/ignore-me | 2 - |
| 92 | scripts/FindLibWebSockets.cmake | 33 + |
| 93 | scripts/kernel-doc | 1 + |
| 94 | test-server/Makefile.am | 131 --- |
| 95 | test-server/leaf.jpg | Bin 0 -> 2477518 bytes |
| 96 | test-server/test-client.c | 78 +- |
| 97 | test-server/test-echo.c | 33 +- |
| 98 | test-server/test-fraggle.c | 26 +- |
| 99 | test-server/test-ping.c | 15 +- |
| 100 | test-server/test-server.c | 197 +++- |
| 101 | test-server/test.html | 5 +- |
| 102 | win32port/win32helpers/gettimeofday.c | 74 +- |
| 103 | win32port/win32helpers/websock-w32.h | 6 +- |
| 104 | 48 files changed, 2493 insertions(+), 4212 deletions(-) |
| 105 | |
Andy Green | 54cb346 | 2013-02-14 22:23:54 +0800 | [diff] [blame] | 106 | |
| 107 | User api additions |
| 108 | ------------------ |
| 109 | |
| 110 | - You can now call libwebsocket_callback_on_writable() on http connectons, |
| 111 | and get a LWS_CALLBACK_HTTP_WRITEABLE callback, the same way you can |
| 112 | regulate writes with a websocket protocol connection. |
| 113 | |
Andy Green | 2672fb2 | 2013-02-22 09:54:35 +0800 | [diff] [blame] | 114 | - A new member in the context creation parameter struct "ssl_cipher_list" is |
| 115 | added, replacing CIPHERS_LIST_STRING. NULL means use the ssl library |
| 116 | default list of ciphers. |
| 117 | |
Andy Green | 58f214e | 2013-03-09 13:03:53 +0800 | [diff] [blame] | 118 | - Not really an api addition, but libwebsocket_service_fd() will now zero |
| 119 | the revents field of the pollfd it was called with if it handled the |
| 120 | descriptor. So you can tell if it is a non-lws fd by checking revents |
| 121 | after the service call... if it's still nonzero, the descriptor |
| 122 | belongs to you and you need to take care of it. |
| 123 | |
Andy Green | b55451c | 2013-03-16 12:32:27 +0800 | [diff] [blame] | 124 | - libwebsocket_rx_flow_allow_all_protocol(protocol) will unthrottle all |
| 125 | connections with the established protocol. It's designed to be |
| 126 | called from user server code when it sees it can accept more input |
| 127 | and may have throttled connections using the server rx flow apis |
| 128 | while it was unable to accept any other input The user server code |
| 129 | then does not have to try to track while connections it choked, this |
| 130 | will free up all of them in one call. |
| 131 | |
Andy Green | 0c9563b | 2013-06-10 22:54:40 +0800 | [diff] [blame] | 132 | - there's a new, optional callback LWS_CALLBACK_CLOSED_HTTP which gets |
| 133 | called when an HTTP protocol socket closes |
| 134 | |
Andy Green | 96d48fd | 2013-09-18 08:32:55 +0800 | [diff] [blame] | 135 | - for LWS_CALLBACK_FILTER_PROTOCOL_CONNECTION callback, the user_space alloc |
| 136 | has already been done before the callback happens. That means we can |
| 137 | use the user parameter to the callback to contain the user pointer, and |
| 138 | move the protocol name to the "in" parameter. The docs for this |
| 139 | callback are also updated to reflect how to check headers in there. |
| 140 | |
Andy Green | 5dc62ea | 2013-09-20 20:26:12 +0800 | [diff] [blame] | 141 | - libwebsocket_client_connect() is now properly nonblocking and async. See |
| 142 | README.coding and test-client.c for information on the callbacks you |
| 143 | can rely on controlling the async connection period with. |
| 144 | |
Andy Green | 81877e6 | 2013-10-26 20:36:08 +0800 | [diff] [blame] | 145 | - if your OS does not support the http_proxy environment variable convention |
| 146 | (eg, reportedly OSX), you can use a new api libwebsocket_set_proxy() |
| 147 | to set the proxy details inbetween context creation and the connection |
| 148 | action. For OSes that support http_proxy, that's used automatically. |
Andy Green | b55451c | 2013-03-16 12:32:27 +0800 | [diff] [blame] | 149 | |
Andy Green | 50097dd | 2013-02-15 22:36:30 +0800 | [diff] [blame] | 150 | User api changes |
| 151 | ---------------- |
| 152 | |
| 153 | - the external poll callbacks now get the socket descriptor coming from the |
| 154 | "in" parameter. The user parameter provides the user_space for the |
| 155 | wsi as it normally does on the other callbacks. |
Edwin van den Oetelaar | 8c8a8e1 | 2013-02-20 20:56:59 +0800 | [diff] [blame] | 156 | LWS_CALLBACK_FILTER_NETWORK_CONNECTION also has the socket descriptor |
| 157 | delivered by @in now instead of @user. |
Andy Green | 50097dd | 2013-02-15 22:36:30 +0800 | [diff] [blame] | 158 | |
Andy Green | fc7c5e4 | 2013-02-23 10:50:10 +0800 | [diff] [blame] | 159 | - libwebsocket_write() now returns -1 for error, or the amount of data |
| 160 | actually accepted for send. Under load, the OS may signal it is |
| 161 | ready to send new data on the socket, but have only a restricted |
| 162 | amount of memory to buffer the packet compared to usual. |
| 163 | |
Andy Green | 50097dd | 2013-02-15 22:36:30 +0800 | [diff] [blame] | 164 | |
Andy Green | dc914cf | 2013-02-18 16:54:26 +0800 | [diff] [blame] | 165 | User api removal |
| 166 | ---------------- |
| 167 | |
| 168 | - libwebsocket_ensure_user_space() is removed from the public api, if you |
| 169 | were using it to get user_space, you need to adapt your code to only |
| 170 | use user_space inside the user callback. |
| 171 | |
Andy Green | 2672fb2 | 2013-02-22 09:54:35 +0800 | [diff] [blame] | 172 | - CIPHERS_LIST_STRING is removed |
| 173 | |
Andy Green | 0097a99 | 2013-03-09 13:06:37 +0800 | [diff] [blame] | 174 | - autotools build has been removed. See README.build for info on how to |
| 175 | use CMake for your platform |
| 176 | |
Andy Green | 54cb346 | 2013-02-14 22:23:54 +0800 | [diff] [blame] | 177 | |
Andy Green | 53a4678 | 2013-02-14 11:23:49 +0800 | [diff] [blame] | 178 | v1.21-chrome26-firefox18 |
| 179 | ======================== |
| 180 | |
| 181 | - Fixes buffer overflow bug in max frame size handling if you used the |
| 182 | default protocol buffer size. If you declared rx_buffer_size in your |
| 183 | protocol, which is recommended anyway, your code was unaffected. |
| 184 | |
Andy Green | 182cb9a | 2013-02-13 11:54:08 +0800 | [diff] [blame] | 185 | v1.2-chrome26-firefox18 |
| 186 | ======================= |
| 187 | |
| 188 | Diffstat |
| 189 | -------- |
| 190 | |
| 191 | .gitignore | 16 +++ |
| 192 | CMakeLists.txt | 544 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 193 | LICENSE | 526 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 194 | Makefile.am | 1 + |
| 195 | README | 20 +++ |
| 196 | README.build | 258 ++++++++++++++++++++++++++++++++----- |
| 197 | README.coding | 52 ++++++++ |
| 198 | changelog | 136 ++++++++++++++++++++ |
| 199 | cmake/FindOpenSSLbins.cmake | 33 +++++ |
| 200 | config.h.cmake | 173 +++++++++++++++++++++++++ |
| 201 | configure.ac | 22 +++- |
| 202 | lib/Makefile.am | 20 ++- |
| 203 | lib/base64-decode.c | 2 +- |
| 204 | lib/client-handshake.c | 190 +++++++++++----------------- |
| 205 | lib/client-parser.c | 88 +++++++------ |
| 206 | lib/client.c | 384 ++++++++++++++++++++++++++++++------------------------- |
| 207 | lib/daemonize.c | 32 +++-- |
| 208 | lib/extension-deflate-frame.c | 58 +++++---- |
| 209 | lib/extension-deflate-stream.c | 19 ++- |
| 210 | lib/extension-deflate-stream.h | 4 +- |
| 211 | lib/extension.c | 11 +- |
| 212 | lib/getifaddrs.c | 315 +++++++++++++++++++++++----------------------- |
| 213 | lib/getifaddrs.h | 30 ++--- |
| 214 | lib/handshake.c | 124 +++++++++++------- |
| 215 | lib/libwebsockets.c | 736 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------------------------------------- |
| 216 | lib/libwebsockets.h | 237 ++++++++++++++++++++++------------ |
| 217 | lib/output.c | 192 +++++++++++----------------- |
| 218 | lib/parsers.c | 966 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---------------------------------------------------------------- |
| 219 | lib/private-libwebsockets.h | 225 +++++++++++++++++++++------------ |
| 220 | lib/server-handshake.c | 82 ++++++------ |
| 221 | lib/server.c | 96 +++++++------- |
| 222 | libwebsockets-api-doc.html | 189 ++++++++++++++++++---------- |
| 223 | libwebsockets.spec | 17 +-- |
| 224 | test-server/attack.sh | 148 ++++++++++++++++++++++ |
| 225 | test-server/test-client.c | 125 +++++++++--------- |
| 226 | test-server/test-echo.c | 31 +++-- |
| 227 | test-server/test-fraggle.c | 32 ++--- |
| 228 | test-server/test-ping.c | 52 ++++---- |
| 229 | test-server/test-server.c | 129 ++++++++++++------- |
| 230 | win32port/libwebsocketswin32/libwebsocketswin32.vcxproj | 279 ---------------------------------------- |
| 231 | win32port/libwebsocketswin32/libwebsocketswin32.vcxproj.filters | 23 +++- |
| 232 | 41 files changed, 4398 insertions(+), 2219 deletions(-) |
| 233 | |
Andy Green | 7b40545 | 2013-02-01 10:50:15 +0800 | [diff] [blame] | 234 | |
| 235 | User api additions |
| 236 | ------------------ |
| 237 | |
| 238 | - lws_get_library_version() returns a const char * with a string like |
| 239 | "1.1 9e7f737", representing the library version from configure.ac |
| 240 | and the git HEAD hash the library was built from |
| 241 | |
Andy Green | a47865f | 2013-02-10 09:39:47 +0800 | [diff] [blame] | 242 | - TCP Keepalive can now optionally be applied to all lws sockets, on Linux |
| 243 | also with controllable timeout, number of probes and probe interval. |
| 244 | (On BSD type OS, you can only use system default settings for the |
| 245 | timing and retries, although enabling it is supported by setting |
| 246 | ka_time to nonzero, the exact value has no meaning.) |
| 247 | This enables detection of idle connections which are logically okay, |
| 248 | but are in fact dead, due to network connectivity issues at the server, |
Andy Green | a690cd0 | 2013-02-09 12:25:31 +0800 | [diff] [blame] | 249 | client, or any intermediary. By default it's not enabled, but you |
| 250 | can enable it by setting a non-zero timeout (in seconds) at the new |
| 251 | ka_time member at context creation time. |
| 252 | |
Andy Green | a7109e6 | 2013-02-11 12:05:54 +0800 | [diff] [blame] | 253 | - Two new optional user callbacks added, LWS_CALLBACK_PROTOCOL_DESTROY which |
| 254 | is called one-time per protocol as the context is being destroyed, and |
| 255 | LWS_CALLBACK_PROTOCOL_INIT which is called when the context is created |
| 256 | and the protocols are added, again it's a one-time affair. |
| 257 | This lets you manage per-protocol allocations properly including |
| 258 | cleaning up after yourself when the server goes down. |
Andy Green | 7b40545 | 2013-02-01 10:50:15 +0800 | [diff] [blame] | 259 | |
Andy Green | ed33446 | 2013-02-07 21:14:33 +0800 | [diff] [blame] | 260 | User api changes |
| 261 | ---------------- |
| 262 | |
Andy Green | 1b26527 | 2013-02-09 14:01:09 +0800 | [diff] [blame] | 263 | - libwebsocket_create_context() has changed from taking a ton of parameters |
| 264 | to just taking a pointer to a struct containing the parameters. The |
| 265 | struct lws_context_creation_info is in libwebsockets.h, the members |
| 266 | are in the same order as when they were parameters to the call |
| 267 | previously. The test apps are all updated accordingly so you can |
| 268 | see example code there. |
| 269 | |
Andy Green | ed33446 | 2013-02-07 21:14:33 +0800 | [diff] [blame] | 270 | - Header tokens are now deleted after the websocket connection is |
Andy Green | 5449511 | 2013-02-06 21:10:16 +0900 | [diff] [blame] | 271 | established. Not just the header data is saved, but the pointer and |
| 272 | length array is also removed from (union) scope saving several hundred |
| 273 | bytes per connection once it is established |
| 274 | |
| 275 | - struct libwebsocket_protocols has a new member rx_buffer_size, this |
| 276 | controls rx buffer size per connection of that protocol now. Sources |
| 277 | for apps built against older versions of the library won't declare |
| 278 | this in their protocols, defaulting it to 0. Zero buffer is legal, |
| 279 | it causes a default buffer to be allocated (currently 4096) |
| 280 | |
| 281 | If you want to receive only atomic frames in your user callback, you |
| 282 | should set this to greater than your largest frame size. If a frame |
| 283 | comes that exceeds that, no error occurs but the callback happens as |
| 284 | soon as the buffer limit is reached, and again if it is reached again |
| 285 | or the frame completes. You can detect that has happened by seeing |
| 286 | there is still frame content pending using |
| 287 | libwebsockets_remaining_packet_payload() |
| 288 | |
| 289 | By correctly setting this, you can save a lot of memory when your |
| 290 | protocol has small frames (see the test server and client sources). |
| 291 | |
Andy Green | 16ab318 | 2013-02-10 18:02:31 +0800 | [diff] [blame] | 292 | - LWS_MAX_HEADER_LEN now defaults to 1024 and is the total amount of known |
| 293 | header payload lws can cope with, that includes the GET URL, origin |
| 294 | etc. Headers not understood by lws are ignored and their payload |
| 295 | not included in this. |
| 296 | |
Andy Green | 5449511 | 2013-02-06 21:10:16 +0900 | [diff] [blame] | 297 | |
| 298 | User api removals |
| 299 | ----------------- |
| 300 | |
Andy Green | 16ab318 | 2013-02-10 18:02:31 +0800 | [diff] [blame] | 301 | - The configuration-time option MAX_USER_RX_BUFFER has been replaced by a |
| 302 | buffer size chosen per-protocol. For compatibility, there's a default |
| 303 | of 4096 rx buffer, but user code should set the appropriate size for |
| 304 | the protocol frames. |
| 305 | |
| 306 | - LWS_INITIAL_HDR_ALLOC and LWS_ADDITIONAL_HDR_ALLOC are no longer needed |
| 307 | and have been removed. There's a new header management scheme that |
| 308 | handles them in a much more compact way. |
Andy Green | ed33446 | 2013-02-07 21:14:33 +0800 | [diff] [blame] | 309 | |
Andy Green | 70edd6f | 2013-02-12 10:15:25 +0800 | [diff] [blame] | 310 | - libwebsockets_hangup_on_client() is removed. If you want to close the |
| 311 | connection you must do so from the user callback and by returning |
| 312 | -1 from there. |
| 313 | |
Andy Green | 508946c | 2013-02-12 10:19:08 +0800 | [diff] [blame] | 314 | - libwebsocket_close_and_free_session() is now private to the library code |
| 315 | only and not exposed for user code. If you want to close the |
| 316 | connection, you must do so from the user callback by returning -1 |
| 317 | from there. |
| 318 | |
Andy Green | ed33446 | 2013-02-07 21:14:33 +0800 | [diff] [blame] | 319 | |
Andy Green | df60b0c | 2013-02-06 19:57:12 +0900 | [diff] [blame] | 320 | New features |
| 321 | ------------ |
| 322 | |
Andy Green | 9b09dc0 | 2013-02-08 12:48:36 +0800 | [diff] [blame] | 323 | - Cmake project file added, aimed initially at Windows support: this replaces |
Andy Green | 16ab318 | 2013-02-10 18:02:31 +0800 | [diff] [blame] | 324 | the visual studio project files that were in the tree until now. |
Andy Green | df60b0c | 2013-02-06 19:57:12 +0900 | [diff] [blame] | 325 | |
Andy Green | c3ef0d6 | 2013-02-12 10:50:49 +0800 | [diff] [blame] | 326 | - CyaSSL now supported in place of OpenSSL (--use-cyassl on configure) |
| 327 | |
Andy Green | 9b09dc0 | 2013-02-08 12:48:36 +0800 | [diff] [blame] | 328 | - PATH_MAX or MAX_PATH no longer needed |
Andy Green | df60b0c | 2013-02-06 19:57:12 +0900 | [diff] [blame] | 329 | |
Andy Green | 5449511 | 2013-02-06 21:10:16 +0900 | [diff] [blame] | 330 | - cutomizable frame rx buffer size by protocol |
| 331 | |
Andy Green | c3ef0d6 | 2013-02-12 10:50:49 +0800 | [diff] [blame] | 332 | - optional TCP keepalive so dead peers can be detected, can be enabled at |
| 333 | context-creation time |
| 334 | |
| 335 | - valgrind-clean: no SSL or CyaSSL: completely clean. With OpenSSL, 88 bytes |
| 336 | lost at OpenSSL library init and symptomless reports of uninitialized |
| 337 | memory usage... seems to be a known and ignored problem at OpenSSL |
| 338 | |
Andy Green | a3957ef | 2013-02-11 09:31:43 +0800 | [diff] [blame] | 339 | - By default debug is enabled and the library is built for -O0 -g to faclitate |
| 340 | that. Use --disable-debug configure option to build instead with -O4 |
| 341 | and no -g (debug info), obviously providing best performance and |
| 342 | reduced binary size. |
Andy Green | 7b40545 | 2013-02-01 10:50:15 +0800 | [diff] [blame] | 343 | |
Andy Green | 895d56d | 2013-02-11 09:32:53 +0800 | [diff] [blame] | 344 | - 1.0 introduced some code to try to not deflate small frames, however this |
| 345 | seems to break when confronted with a mixture of frames above and |
| 346 | below the threshold, so it's removed. Veto the compression extension |
| 347 | in your user callback if you will typically have very small frames. |
| 348 | |
Andy Green | 16ab318 | 2013-02-10 18:02:31 +0800 | [diff] [blame] | 349 | - There are many memory usage improvements, both a reduction in malloc/ |
| 350 | realloc and architectural changes. A websocket connection now |
| 351 | consumes only 296 bytes with SSL or 272 bytes without on x86_64, |
| 352 | during header processing an additional 1262 bytes is allocated in a |
| 353 | single malloc, but is freed when the websocket connection starts. |
| 354 | The RX frame buffer defined by the protocol in user |
| 355 | code is also allocated per connection, this represents the largest |
| 356 | frame you can receive atomically in that protocol. |
| 357 | |
Andy Green | c3ef0d6 | 2013-02-12 10:50:49 +0800 | [diff] [blame] | 358 | - On ARM9 build, just http+ws server no extensions or ssl, <12Kbytes .text |
| 359 | and 112 bytes per connection (+1328 only during header processing) |
| 360 | |
Andy Green | 895d56d | 2013-02-11 09:32:53 +0800 | [diff] [blame] | 361 | |
Andy Green | bd1132f | 2013-01-31 19:53:05 +0800 | [diff] [blame] | 362 | v1.1-chrome26-firefox18 |
Andy Green | a35c86f | 2013-01-31 10:16:44 +0800 | [diff] [blame] | 363 | ======================= |
| 364 | |
| 365 | Diffstat |
| 366 | -------- |
| 367 | |
| 368 | Makefile.am | 4 + |
| 369 | README-test-server | 291 --- |
| 370 | README.build | 239 ++ |
| 371 | README.coding | 138 ++ |
| 372 | README.rst | 72 - |
| 373 | README.test-apps | 272 +++ |
| 374 | configure.ac | 116 +- |
| 375 | lib/Makefile.am | 55 +- |
| 376 | lib/base64-decode.c | 5 +- |
| 377 | lib/client-handshake.c | 121 +- |
| 378 | lib/client-parser.c | 394 ++++ |
| 379 | lib/client.c | 807 +++++++ |
| 380 | lib/daemonize.c | 212 ++ |
| 381 | lib/extension-deflate-frame.c | 132 +- |
| 382 | lib/extension-deflate-stream.c | 12 +- |
| 383 | lib/extension-x-google-mux.c | 1223 ---------- |
| 384 | lib/extension-x-google-mux.h | 96 - |
| 385 | lib/extension.c | 8 - |
| 386 | lib/getifaddrs.c | 271 +++ |
| 387 | lib/getifaddrs.h | 76 + |
| 388 | lib/handshake.c | 582 +---- |
| 389 | lib/libwebsockets.c | 2493 ++++++--------------- |
| 390 | lib/libwebsockets.h | 115 +- |
| 391 | lib/md5.c | 217 -- |
| 392 | lib/minilex.c | 440 ++++ |
| 393 | lib/output.c | 628 ++++++ |
| 394 | lib/parsers.c | 2016 +++++------------ |
| 395 | lib/private-libwebsockets.h | 284 +-- |
| 396 | lib/server-handshake.c | 275 +++ |
| 397 | lib/server.c | 377 ++++ |
| 398 | libwebsockets-api-doc.html | 300 +-- |
| 399 | m4/ignore-me | 2 + |
| 400 | test-server/Makefile.am | 111 +- |
| 401 | test-server/libwebsockets.org-logo.png | Bin 0 -> 7029 bytes |
| 402 | test-server/test-client.c | 45 +- |
| 403 | test-server/test-echo.c | 330 +++ |
| 404 | test-server/test-fraggle.c | 20 +- |
| 405 | test-server/test-ping.c | 22 +- |
| 406 | test-server/test-server-extpoll.c | 554 ----- |
| 407 | test-server/test-server.c | 349 ++- |
| 408 | test-server/test.html | 3 +- |
| 409 | win32port/zlib/ZLib.vcxproj | 749 ++++--- |
| 410 | win32port/zlib/ZLib.vcxproj.filters | 188 +- |
| 411 | win32port/zlib/adler32.c | 348 ++- |
| 412 | win32port/zlib/compress.c | 160 +- |
| 413 | win32port/zlib/crc32.c | 867 ++++---- |
| 414 | win32port/zlib/crc32.h | 882 ++++---- |
| 415 | win32port/zlib/deflate.c | 3799 +++++++++++++++----------------- |
| 416 | win32port/zlib/deflate.h | 688 +++--- |
| 417 | win32port/zlib/gzclose.c | 50 +- |
| 418 | win32port/zlib/gzguts.h | 325 ++- |
| 419 | win32port/zlib/gzlib.c | 1157 +++++----- |
| 420 | win32port/zlib/gzread.c | 1242 ++++++----- |
| 421 | win32port/zlib/gzwrite.c | 1096 +++++---- |
| 422 | win32port/zlib/infback.c | 1272 ++++++----- |
| 423 | win32port/zlib/inffast.c | 680 +++--- |
| 424 | win32port/zlib/inffast.h | 22 +- |
| 425 | win32port/zlib/inffixed.h | 188 +- |
| 426 | win32port/zlib/inflate.c | 2976 +++++++++++++------------ |
| 427 | win32port/zlib/inflate.h | 244 +- |
| 428 | win32port/zlib/inftrees.c | 636 +++--- |
| 429 | win32port/zlib/inftrees.h | 124 +- |
| 430 | win32port/zlib/trees.c | 2468 +++++++++++---------- |
| 431 | win32port/zlib/trees.h | 256 +-- |
| 432 | win32port/zlib/uncompr.c | 118 +- |
| 433 | win32port/zlib/zconf.h | 934 ++++---- |
| 434 | win32port/zlib/zlib.h | 3357 ++++++++++++++-------------- |
| 435 | win32port/zlib/zutil.c | 642 +++--- |
| 436 | win32port/zlib/zutil.h | 526 ++--- |
| 437 | 69 files changed, 19556 insertions(+), 20145 deletions(-) |
| 438 | |
| 439 | user api changes |
| 440 | ---------------- |
| 441 | |
| 442 | - libwebsockets_serve_http_file() now takes a context as first argument |
| 443 | |
| 444 | - libwebsockets_get_peer_addresses() now takes a context and wsi as first |
| 445 | two arguments |
| 446 | |
| 447 | |
| 448 | user api additions |
| 449 | ------------------ |
| 450 | |
| 451 | - lwsl_...() logging apis, default to stderr but retargetable by user code; |
| 452 | may be used also by user code |
| 453 | |
| 454 | - lws_set_log_level() set which logging apis are able to emit (defaults to |
| 455 | notice, warn, err severities), optionally set the emit callback |
| 456 | |
| 457 | - lwsl_emit_syslog() helper callback emits to syslog |
| 458 | |
| 459 | - lws_daemonize() helper code that forks the app into a headless daemon |
| 460 | properly, maintains a lock file with pid in suitable for sysvinit etc to |
| 461 | control lifecycle |
| 462 | |
| 463 | - LWS_CALLBACK_HTTP_FILE_COMPLETION callback added since http file |
| 464 | transfer is now asynchronous (see test server code) |
| 465 | |
| 466 | - lws_frame_is_binary() from a wsi pointer, let you know if the received |
| 467 | data was sent in BINARY mode |
| 468 | |
| 469 | |
| 470 | user api removals |
| 471 | ----------------- |
| 472 | |
| 473 | - libwebsockets_fork_service_loop() - no longer supported (had intractable problems) |
| 474 | arrange your code to act from the user callback instead from same |
| 475 | process context as the service loop |
| 476 | |
| 477 | - libwebsockets_broadcast() - use libwebsocket_callback_on_writable[_all_protocol]() |
| 478 | instead from same process context as the service loop. See the test apps |
| 479 | for examples. |
| 480 | |
| 481 | - x-google-mux() removed until someone wants it |
| 482 | |
| 483 | - pre -v13 (ancient) protocol support removed |
| 484 | |
| 485 | |
| 486 | New features |
| 487 | ------------ |
| 488 | |
| 489 | - echo test server and client compatible with echo.websocket.org added |
| 490 | |
| 491 | - many new configure options (see README.build) to reduce footprint of the |
| 492 | library to what you actually need, eg, --without-client and |
| 493 | --without-server |
| 494 | |
| 495 | - http + websocket server can build to as little as 12K .text for ARM |
| 496 | |
| 497 | - no more MAX_CLIENTS limitation; adapts to support the max number of fds |
| 498 | allowed to the process by ulimit, defaults to 1024 on Fedora and |
| 499 | Ubuntu. Use ulimit to control this without needing to configure |
| 500 | the library. Code here is smaller and faster. |
| 501 | |
| 502 | - adaptive ratio of listen socket to connection socket service allows |
| 503 | good behaviour under Apache ab test load. Tested with thousands |
| 504 | of simultaneous connections |
| 505 | |
| 506 | - reduction in per-connection memory footprint by moving to a union to hold |
| 507 | mutually-exclusive state for the connection |
| 508 | |
| 509 | - robustness: Out of Memory taken care of for all allocation code now |
| 510 | |
| 511 | - internal getifaddrs option if your toolchain lacks it (some uclibc) |
| 512 | |
| 513 | - configurable memory limit for deflate operations |
| 514 | |
| 515 | - improvements in SSL code nonblocking operation, possible hang solved, |
| 516 | some SSL operations broken down into pollable states so there is |
| 517 | no library blocking, timeout coverage for SSL_connect |
| 518 | |
| 519 | - extpoll test server merged into single test server source |
| 520 | |
| 521 | - robustness: library should deal with all recoverable socket conditions |
| 522 | |
| 523 | - rx flowcontrol for backpressure notification fixed and implmeneted |
| 524 | correctly in the test server |
| 525 | |
| 526 | - optimal lexical parser added for header processing; all headers in a |
| 527 | single 276-byte state table |
| 528 | |
| 529 | - latency tracking api added (configure --with-latency) |
| 530 | |
| 531 | - Improved in-tree documentation, REAME.build, README.coding, |
| 532 | README.test-apps, changelog |
| 533 | |
| 534 | - Many small fixes |
| 535 | |
| 536 | |
| 537 | v1.0-chrome25-firefox17 (6cd1ea9b005933f) |