Commit graph

1880 commits

Author SHA1 Message Date
Sergey Kovalevich
02ad98dbd0 Subject: Fixed value of LIBWEBSOCKETS_LIBRARIES_STATIC 2017-05-30 09:05:48 +08:00
Andy Green
c36ac16ff5 LICENSE: clarify exceptions also apply to LGPL self-refernences
via Mike Atamas, Counsel for Epic Games
2017-05-19 09:28:53 +08:00
Andy Green
123572a921 windows: align choked trunc checking with unix 2017-04-18 15:18:56 +08:00
Gecko
d8b7e892fa Subject: Save copy of ah pointer even with WS client so that HTTP
error can be captured by calling lws_http_client_http_response.
2017-04-10 12:39:21 +08:00
Andy Green
1788dc5558 boilerplate: add back missing Lesser that cut-and-pasted itself around 2017-04-06 23:14:03 +08:00
Martin Milata
ea2596be2d Subject: ssl: fix OpenSSL client method detection 2017-04-06 23:13:56 +08:00
Andy Green
8553ecfb3a ssl: OpenSSL v1.1 deprecated TLSv1_2_client_method 2017-04-06 09:02:58 +08:00
Andy Green
61ef337671 pollout: handle request for pollout during pollout service 2017-04-05 08:31:33 +08:00
Andy Green
9494cc646a logs: reduce ah err to info 2017-04-02 13:03:51 +08:00
Andy Green
c304876941 service: always restrict rx to serve_buf_size 2017-03-28 08:53:02 +08:00
Andy Green
39a3a5854d pmd: handle case we are already on drain list
Provide internal helper for adding to list that takes care of the
case we are already on the list.

https://github.com/warmcat/libwebsockets/issues/847
2017-03-26 10:11:39 +08:00
Andy Green
584e7339c7 pmd: align client rx sm with server one 2017-03-25 08:50:32 +08:00
Andy Green
b22ef6775b docs 2017-03-20 19:37:47 +08:00
Andy Green
316b0293e9 ext: pmd: improve dealing with partial input usage with drain
https://github.com/warmcat/libwebsockets/issues/841
2017-03-20 19:35:26 +08:00
Michael Behrns-Miller [case-ubuntu]
9207bc51bb Subject: Buffer index protection in the case where client does not
receive content length from HTTP server
2017-03-03 05:42:47 +08:00
Whisperbyte
9892280467 docs: mac: add info from github 2017-03-01 18:00:00 +08:00
Silas Parker
a5f64f9f4d cosmetic fix trailing newline on log 2017-02-28 18:39:21 +08:00
Andy Green
a218d779b6 client: take care of rx close during pending partial same as server does
https://github.com/warmcat/libwebsockets/issues/816
2017-02-28 18:38:38 +08:00
Martin Milata
7ad81d6cdd gcc format strings: couple more 2017-02-22 07:14:06 +08:00
Yuchen Xie
7fb607720d Fix typo 2017-02-18 15:55:16 +08:00
Yongwen Zhuang
de22418879 Correct Cross compiling commandline 2017-02-15 18:18:01 +08:00
Andy Green
d317a96b27 v2.1.1 2017-02-15 18:03:12 +08:00
Silas Parker
e2fcf47f03 fix close packet index coding
https://github.com/warmcat/libwebsockets/issues/792
2017-02-14 23:25:15 +08:00
Andy Green
b95e7fe466 gcc format strings: http2 2017-02-05 22:46:39 +08:00
Andy Green
0b7ca30ed1 gcc- format strings: debug and extra plugins 2017-02-05 22:32:07 +08:00
Martin Milata
b03b17fd0b Subject: gcc format strings: Make GCC check format strings, fix found problems 2017-02-05 22:12:57 +08:00
Sven Hoffmann
a238984d1b post processing: fix problem where hex cant straddle block correctly 2017-02-05 22:12:33 +08:00
Tobias
109d66c365 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:28:27 +08:00
Andy Green
da6f03b423 ssl: wolfssl doesn't have clear options
https://github.com/warmcat/libwebsockets/issues/741
2017-01-10 09:16:49 +08:00
Hai Vu
c9d165bbcc ssl-correct-option-clear-availability-version
https://github.com/warmcat/libwebsockets/issues/744
2017-01-10 09:16:41 +08:00
Andy Green
8283659047 polarssl: turn off missing tlsext 2017-01-07 10:24:50 +08:00
Andy Green
c447e1f9f3 openssl: deal with missing OPENSSL_NO_TLSEXT on ancient versions 2017-01-07 10:24:42 +08:00
Denis Osvald
9706dd23a2 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 02:04:11 +08:00
namowen
837e7fdd14 lws_plat_service_tsi: accessing context before checking for NULL
https://github.com/warmcat/libwebsockets/issues/730
2016-12-24 08:03:04 +08:00
Namowen
d2cb05f1f6 echo: fix debug build
https://github.com/warmcat/libwebsockets/issues/716#issuecomment-267377856
2016-12-16 07:05:29 +08:00
Andy Green
d170ed0623 test-client: fix broken protocol names 2016-12-15 13:42:44 +08:00
Andy Green
39807c1d10 client ssl hostname check: trim any port on host header 2016-12-15 13:27:13 +08:00
Andy Green
6dce477aef ipv6-allow-binding-to-ipv6-address-in-iface
ipv4 and ipv6 binding to a named interface works OK.  ipv4 binding to an IP also
works, but we need some extra ipv6 magic to identify the ipv6 interface from an
ipv6 address.

This patch based on code from "user3546716" at
http://stackoverflow.com/questions/13504934/binding-sockets-to-ipv6-addresses

adds the necessary magic.

https://github.com/warmcat/libwebsockets/issues/717
2016-12-15 10:09:55 +08:00
Andy Green
cf8b922df5 client: if NULL protocol vhost same linked list entry
Lws maintains a linked-list of wsi that are on the same vhost protocol...
it walks it to perform ..._all_protocol() type apis.

Client connections also participate in this list, but in the case the
selected protocol is not given during negotation (a legal case where
the server default protocol is selected) we missed adding the new
ws negotiated client wsi to the list.

This patch makes sure we add the wsi to the vhost protocols[0] list
in that case.

https://github.com/warmcat/libwebsockets/issues/716
2016-12-15 08:38:35 +08:00
Andy Green
266819a1f5 client: avoid possible NULL deref on error path
https://github.com/warmcat/libwebsockets/issues/672
2016-12-12 20:38:32 +08:00
daren-qterics
e618359d4f ssl destroy: change ordering of ssl destroy to later than vhost destroy
https://github.com/warmcat/libwebsockets/issues/711
2016-12-10 09:13:08 +08:00
Andy Green
04fee5f75f clean: usused accidental global wsi
https://github.com/warmcat/libwebsockets/issues/708
2016-12-10 09:13:08 +08:00
Andy Green
384ee53a36 lwsgt: fix check against forgot password flow defeating existing pw check
https://github.com/warmcat/libwebsockets/issues/706

This fixes a problem where the check for the existing pw was
skipped when a logged-in user is changing his password.

It's not good but because the user has to be logged in, it only affected
the situation someone changes his password on his logged in session.
2016-12-10 09:13:08 +08:00
Bablooos
c01bbb2bbc Update CMakeLists.txt for BSD + libdl
Fixing build failure of libwebsockets-test-fraggle  on FreeBSD when LWS_WITH_PLUGINS.
Solution: FreeBSD has no libdl
2016-12-10 09:13:08 +08:00
Andy Green
d104d624ec ws-server: restrict returned Sec-Websocket-Protocol to the chosen name only
https://libwebsockets.org/pipermail/libwebsockets/2016-November/002948.html

Updated to fix a problem with no protocol

https://github.com/warmcat/libwebsockets/issues/705
2016-12-10 09:13:04 +08:00
Andy Green
60b3a027d9 generic-sessions: move auth level check to after mount protocol selection 2016-11-26 20:47:34 +08:00
Iblis Lin
c8bb24cf57 server: portable option for setsockopt
From linux ipv6(7) manual (section `Note`):

        SOL_IP, SOL_IPV6, SOL_ICMPV6 and other SOL_* socket options are
        nonportable variants of IPPROTO_*.  See also ip(7).

Ref: http://man7.org/linux/man-pages/man7/ipv6.7.html
2016-11-23 23:40:04 +08:00
sjames1958gm
0bef3a8b01 client stash: update path variable to larger size 2016-11-22 09:01:57 +08:00
Andy Green
c2cd260311 lws_socket_bind: use lws_sockfd_type 2016-11-16 09:00:45 +08:00
Andy Green
386bd4550b client: protect againt losing ah by lws_client_connect_2 2016-11-15 17:00:55 +08:00