Commit graph

2159 commits

Author SHA1 Message Date
Andy Green
2e11efa84b file_ops: add compression flags and convert open flags to pointer
ihttps://libwebsockets.org/pipermail/libwebsockets/2017-February/003127.html
2017-02-12 18:15:15 +08:00
Andy Green
21faff3deb file_ops: use wrappers for names 2017-02-12 18:11:11 +08:00
Andy Green
0b3e9e62cb client redirect: make sure there is a leading / on path 2017-02-10 11:00:38 +08:00
Andy Green
807313b157 appveyor: make zip artifact 2017-02-10 07:37:35 +08:00
Andy Green
31c5130802 client: fix redirects and allow ssl / non-ssl redirects 2017-02-09 15:25:01 +08:00
Andy Green
5e25dc07c8 chunked http client: support in test-client and document
This improves the test client to

 - dump http content if INFO log level enabled
 - handle chunked content correctly
 - document lws_http_client_read()
2017-02-09 09:17:23 +08:00
Andy Green
c8b20910ec lwsl_visible 2017-02-09 09:11:17 +08:00
Johnny
388f6c97fb test client: some compilers dont accept void * as const char *
This fixes a conversion error from a void pointer to a string.
2017-02-08 07:02:00 +08:00
Andy Green
73f5e58682 gcc-format-strings: LWS_PLAT_OPTEE 2017-02-07 00:51:25 +08:00
Andy Green
9395eb62ce LWS_PLAT_OPTEE: Convert to use TEE_Malloc
OPTEE TAs should allocate via TEE_Malloc
2017-02-07 00:51:25 +08:00
Andy Green
066f4156d6 coverity 175437: forgot to add name to array for new USER log level 2017-02-07 00:51:25 +08:00
Andy Green
cde0371a83 coverity 175438: server status plugin: off-by-one if you generate 32KB of content 2017-02-07 00:51:25 +08:00
Andy Green
af9ddec2f7 coverity 175435: seems bogus 2017-02-07 00:51:25 +08:00
Andy Green
a17992b638 coverity 175436: dead cruft 2017-02-07 00:51:25 +08:00
Andy Green
fdb25fcd6e gcc format strings: http2 2017-02-07 00:51:25 +08:00
andSpace
7df395695b LWS_FALLBACK_GETHOSTBYNAME
Adapted by AG to not use-after-free and have LWS_FALLBACK_GETHOSTBYNAME
2017-02-05 22:30:27 +08:00
Andy Green
ce37ee9624 gcc- format strings: debug and extra plugins 2017-02-05 22:30:27 +08:00
Martin Milata
be1f0a3a92 Subject: gcc format strings: Make GCC check format strings, fix found problems 2017-02-05 21:32:30 +08:00
Martin Milata
e96b69887f docs: Correct string 2017-02-05 21:31:16 +08:00
Sven Hoffmann
b5ebd599b2 post processing: fix problem where hex cant straddle block correctly 2017-02-05 21:25:39 +08:00
Andy Green
24e77a04ab remove dump getaddrinfo result 2017-02-03 20:55:56 +08:00
Andy Green
ad945976f7 client: decruft extensions
https://github.com/warmcat/libwebsockets/issues/770
2017-02-03 10:39:37 +08:00
Andy Green
c2208640dd logging: cleanup and introduce LLL_USER 2017-01-31 10:50:15 +08:00
Andy Green
71bb400805 http_proxy: deal with redundant protocol leader
https://github.com/warmcat/libwebsockets/issues/764
2017-01-26 07:27:11 +08:00
Denis Osvald
76985f256d wsi remove unused 'upgraded' boolean field
It was introduced in 7df53c5550
but was never used...

Signed-off-by: Denis Osvald <denis.osvald@sartura.hr>
2017-01-23 20:04:06 +08:00
Andy Green
716aaeeb8b context new option LWS_SERVER_OPTION_JUST_USE_RAW_ORIGIN
https://github.com/warmcat/libwebsockets/issues/757
2017-01-23 19:52:27 +08:00
Denis Osvald
cc806bb77e ssl pass real wsi to verify cert cb
Signed-off-by: Denis Osvald <denis.osvald@sartura.hr>
2017-01-23 19:35:00 +08:00
Denis Osvald
bcce73201f ssl expose public wsi->ssl getter
Signed-off-by: Denis Osvald <denis.osvald@sartura.hr>
2017-01-23 19:34:46 +08:00
Andy Green
1bc025cfa7 windows: reduce C99isms to something MS compiler can understand 2017-01-18 07:20:09 +08:00
Andy Green
51c96d8c2a plat-optee and boringssl adaptations 2017-01-17 07:01:02 +08:00
Andy Green
e680fb9193 win32 fixes
https://github.com/warmcat/libwebsockets/issues/750
2017-01-17 06:51:11 +08:00
Tobias
3f55e5e964 ignore leading spaces when checking for a suitable subprotocol
My Browsers send as Subprotocols e.g. chat, superchat, mySubprotocol (with spaces after the ,). Libwebsockets now checked if ' mySubprotocol' was equal to 'mySubprotocol' which failed. With this fix the leading space is ignored and uses 'mySubprotocol' for comparision.
2017-01-17 06:22:58 +08:00
Namowen
b837f93dcf ssl: add LWS_CALLBACK_OPENSSL_PERFORM_SERVER_CERT_VERIFICATION 2017-01-10 09:31:23 +08:00
Andy Green
9e562fcf1b ssl: wolfssl doesn't have clear options
https://github.com/warmcat/libwebsockets/issues/741
2017-01-10 09:14:44 +08:00
Hai Vu
8b7704f1b3 ssl-correct-option-clear-availability-version
https://github.com/warmcat/libwebsockets/issues/744
2017-01-10 09:10:49 +08:00
Andy Green
a7bf178606 ssl: correct version detection 2017-01-07 11:29:32 +08:00
Andy Green
1e22719f5e polarssl: turn off missing tlsext 2017-01-07 10:24:16 +08:00
Andy Green
c001a15973 openssl: deal with missing OPENSSL_NO_TLSEXT on ancient versions 2017-01-06 09:49:28 +08:00
Andy Green
d79d8b792d cmake: boringssl helper 2017-01-04 20:23:10 +08:00
Andy Green
b3c2427cfd client: MORE_SERVICE is not an error 2017-01-04 19:59:38 +08:00
Andy Green
a0c4a0e253 cgi: 5s grace to send buffered if chunked 2017-01-03 08:18:37 +08:00
Denis Osvald
9b129c137a server: check listen(2) return value
The `listen` call can fail with EADDRINUSE after bind() succeeds, for
example because another process called listen on that port in the
meantime, or under some circumstances with IPv6-mapped-IPv4. This was
causing EINVAL on accept, with an infinite loop in case of libuv.

A reproducible example was to run nc -l -p 5555 ( OpenBSD netcat (Debian
patchlevel 1)) before starting test-server

Signed-off-by: Denis Osvald <denis.osvald@sartura.hr>
2017-01-03 01:56:20 +08:00
Andy Green
58a26ebf45 lejp-conf: add timeout-secs 2017-01-02 19:57:54 +08:00
Andy Green
714f66f5b7 windows: remove preprocessor business for [v]snprintf
https://github.com/warmcat/libwebsockets/issues/731
2016-12-28 15:23:34 +08:00
namowen
85f0c283dd lws_plat_service_tsi: accessing context before checking for NULL
https://github.com/warmcat/libwebsockets/issues/730
2016-12-24 07:57:34 +08:00
Andy Green
a14be2664c test server: add -P secs to allow pingpong test 2016-12-24 07:37:40 +08:00
Andy Green
dd0dfaecb7 ESP8266: LWS_POSIX fixes for basic auth and deprecated context 2016-12-22 11:32:34 +08:00
Alan Conway
f3ad9540fa ssl-server: Add CONTEXT_PORT_NO_LISTEN_SERVER
Special port setting to disable listening for a server using socket adoption.
This contrasts with CONTEXT_PORT_NO_LISTEN which does the same for a client.

In particular, server-side SSL is not disabled by CONTEXT_PORT_NO_LISTEN_SERVER
as it is by CONTEXT_PORT_NO_LISTEN.
2016-12-21 09:32:44 +08:00
Alan Conway
63627e7e86 ssl: improved error reporting for SSL_accept.
The return value from SSL_get_error() is an integer switch value, not an error
code that can be interpreted by ERR_error_string()

Report the error code name, plus errno information if available for
SSL_ERROR_SYSCALL as per man page for SSL_get_error().
2016-12-21 09:32:25 +08:00
Alan Conway
acdf0c7066 server: expose lws_adopt_socket_vhost() as public API
Allows a socket to be adopted and associated with an existing vhost.
Also added corresponding  lws_adopt_socket_vhost_readbuf()
2016-12-21 09:32:16 +08:00