1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-16 00:00:07 +01:00
Commit graph

2414 commits

Author SHA1 Message Date
Andy Green
4739c3234b COVA11294: check mpi_write_binary retcode 2019-07-13 13:28:54 -07:00
Andy Green
7bbf6ebc7e COVA11233: add additional deref checks 2019-07-13 13:28:54 -07:00
Andy Green
e3f895a71d COVA11626: pwsi is not allowed to be NULL 2019-07-13 13:28:54 -07:00
Andy Green
cd56a4b97f COVA12046: make it clear the strdup target cannot be NULL 2019-07-13 13:28:54 -07:00
Andy Green
e07d6986ab COVA10081: ensure m can never be negative 2019-07-13 13:28:54 -07:00
Andy Green
1929f3a6c0 COVA11597: buffer http_proxy env var before using 2019-07-13 13:28:54 -07:00
Andy Green
0709167759 COVA10653: check for zalloc fail 2019-07-13 13:28:54 -07:00
Andy Green
d14dcff076 COVA11197: source indentation confused 2019-07-13 13:28:54 -07:00
Andy Green
fbb33af4f1 COVA11781: source indentation confused 2019-07-13 13:28:54 -07:00
Andy Green
dec1007756 COVA10141: add additional deref checks 2019-07-13 13:28:54 -07:00
Andy Green
f323205c52 COVA10063: check malloc return 2019-07-13 13:28:54 -07:00
Andy Green
93df14454c COVA10821: check lws_change_pollfd 2019-07-13 13:28:54 -07:00
Andy Green
049c898aad COVA10417: help coverity see no problem
This isn't strange if coverity could understand the preprocessor options
2019-07-13 13:28:54 -07:00
Andy Green
f60db2fff9 openssl: rename internal api for describe error stack and make it destructive again 2019-07-13 13:28:44 -07:00
Andy Green
89fd3d822e openssl: explicitly clear error queue
https://libwebsockets.org/pipermail/libwebsockets/2019-July/008033.html
2019-07-10 20:34:24 +01:00
Andy Green
e76982a090 boringssl: deal with loss of EVP_PKEY_new_mac_key
Rewrite HMAC stuff to use HMAC_ apis instead of EVP

Bit trickly since modern OpenSSL has opaque HMAC_CTX and older
OpenSSL does not have any apis to allocate and free it.

Add another cmake check for the allocation api to decide
what to do.
2019-07-09 18:18:10 +01:00
Andy Green
896de50de2 boringssl: wrong tag constant 2019-07-09 18:18:10 +01:00
Andy Green
761e7528eb boringssl: adapt to missing AES modes 2019-07-09 18:18:10 +01:00
Andy Green
23fde179f0 boringssl: fix type changes 2019-07-09 18:18:10 +01:00
Hustweimin
17920cadf5 tls: openssl: use lws pem_to_der first for mem cert
https://github.com/warmcat/libwebsockets/issues/1620
2019-07-09 07:48:35 +01:00
Andy Green
79bb26b6bd HPACK: take sizing to 0 as clear existing
Apparently some peers set the HPACK size to zero and then try
to set HPACK dynamic elements.  Take it to mean keep the same
size but clear it down.
2019-07-08 11:40:10 +01:00
Andy Green
3b44a745c9 h2-tx-credit-disallow-overflow 2019-07-08 08:48:58 +01:00
Andy Green
55599fef71 h2: SETTINGS: allow 16M-1 peer max frame size
We only allow 8M-1 when we should allow 16M-1 without blowing a
PROTOCOL ERROR.
2019-07-07 12:19:54 +01:00
Andy Green
cbd58fa458 http: body: make sure to consume body before transaction complete
https://github.com/warmcat/libwebsockets/issues/1625

"dead bodies" that were sent but not processed by lws as server
will clog up and destroy transaction tracking if repeated POSTs
with keepalive are sent to nonexistant paths.

This patch introduces a DISCARD_BODY state that follows BODY
except the payload is not signalled to the protocol callback.
Calling transaction_completed() with pending body makes lws
enter DISCARD_BODY and retry transaction completed only after
the pending body is exhausted.
2019-07-05 07:31:38 +01:00
Andy Green
d727c89d79 cmake: miniz: add as option 2019-07-03 19:46:23 +01:00
Jackson Ming Hu
310bd7d5d4 esp32: use strerror instead of gai_strerror 2019-07-02 08:54:29 +01:00
Jackson Ming Hu
9e75e7b780 esp32: remove extra const
it will block the compilation on GCC 8.x
2019-07-02 08:54:29 +01:00
Jackson Ming Hu
4064daddf8 esp32: compiler complains about insert_wsi as macro 2019-07-02 08:54:29 +01:00
Andy Green
e4ec282987 coverity: 2019.03 fixes 2019-07-01 06:39:55 +01:00
Andy Green
75ef709ff7 buflist: ensure all use callers have nonzero len 2019-07-01 05:53:08 +01:00
Andy Green
a7e1bac4ac unit test sequencer 2019-06-29 21:08:36 +01:00
Ico Doornekamp
604a718e92 raw-skt: server: allow tls
AG: some additional fixes and add -s tls mode to
minimal-raw-vhost
2019-06-29 21:08:36 +01:00
Ilan Pegoraro
0123b4381f vhost: bind: make failure to bind optionally fatal
When creating a vhost and the port is already bound to another process
this flag would allow the user code to choose to have the
lws_create_vhost function to fail and return a null pointer.
2019-06-29 21:08:36 +01:00
Andy Green
0ada40ce92 abstract: allow completely generic instantiation and destruction 2019-06-26 14:33:34 +01:00
Andy Green
b3d6e28bc7 lws_sequencer 2019-06-25 12:10:18 +01:00
Jim Borden
477d50bf56 Add locking into the cancellation process
To avoid racing on the set and reset of interrupt_requested
2019-06-25 12:08:49 +01:00
Jim Borden
1979bd8cc9 Make the Windows pipe more responsive
Otherwise it often forgets to inform about event loop interrupts.  Add a flag to the per thread context, set it in the signal function, then check / reset it in the service method.
2019-06-25 12:08:39 +01:00
Andy Green
805c033b6b openssl: client certs: use info.client_ssl_private_key_password
https://github.com/warmcat/libwebsockets/issues/1599
2019-06-21 07:18:48 +01:00
Andy Green
a72b422be3 abstract: add abstract transport tokens
SMTP was improved to use the new abstract stuff a while ago,
but it was only implemented with raw socket abstract transport,
and a couple of 'api cheats' remained passing network information
for the peer connection through the supposedly abstract apis.

This patch adds a flexible generic token array to supply
abstract transport-specific information through the abstract apis,
removing the network information from the abstract connect() op.

The SMTP minimal example is modified to use this new method to
pass the network information.

The abstract transport struct was opaque, but there are real
uses to override it in user code, so this patch also makes it
part of the public abi.
2019-06-19 19:10:14 +01:00
Andy Green
5462529bcc coverity-2019-03 update 2019-06-19 12:50:50 +01:00
Andy Green
69fbc272f0 coverity: fixes 2019-06-08 10:29:08 +01:00
Andy Green
4692c1a7ee rtos: clean warnings where uint32_t is an unsigned long 2019-06-07 11:11:46 +01:00
Chen Xi
892cde2c71 rtos: add support for AMAZON_RTOS 2019-06-05 05:04:17 +01:00
Orgad Shaneh
10660466c1 openssl-server: Fix null dereference
Reported by GCC9.
2019-05-31 06:16:52 +08:00
Orgad Shaneh
19049d2f28 Change some struct members to unsigned char
Enables removal of superfluous casts, and fixes strict-aliasing warnings with
GCC 4.1.
2019-05-30 08:21:33 +08:00
Orgad Shaneh
93c35b9712 http: Initialize local variable
GCC 4.1 warns about potential access to uninitialized variable, although
this can't really happen.

Silence it by initializing the variable.
2019-05-30 06:06:41 +08:00
Orgad Shaneh
4a8123fc34 poll: Add newline at end of file
Fixes compiler warning with GCC 4.1.
2019-05-30 06:06:31 +08:00
Orgad Shaneh
71131adb9c tls: Fix yet another strict-aliasing issue on GCC 4.1 2019-05-30 06:03:47 +08:00
Orgad Shaneh
12fcba7b4c listen: Fix strict-aliasing warning on GCC 4.1 2019-05-30 05:51:48 +08:00
Andy Green
8b8849e8cc client: modernize socks5 fixing heap overflow
https://github.com/warmcat/libwebsockets/issues/1583
2019-05-22 15:54:46 +01:00