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

4581 commits

Author SHA1 Message Date
makejian
2b0c5f1653 mbedtls/ssl: free cert chain when mbedtls_client_preload_filepath enabled
Signed-off-by: makejian <makejian@xiaomi.com>
2025-03-03 07:43:17 +00:00
Martin Quinson
81633bef2a PkgConfig: include libsystemd if needed by lib 2025-02-28 17:23:39 +00:00
Andy Green
ab9df9cfc3 tag 4.3.5 2025-02-28 06:41:45 +00:00
Andy Green
2ce0be3284 async dns: allow up to 8 x 128-char CNAMEs from 4
https://github.com/warmcat/libwebsockets/issues/3329

Extra ~600 bytes stack needed might be a struggle for RTOS, trimmed from 10
recommended in issue.
2025-02-27 07:41:53 +00:00
Glen Mabey
6414a1b63c Subject: docs: fix typo 2025-02-26 06:38:48 +00:00
Andy Green
e7fbdac391 lws_mux_mark_immortal: remove noisy log 2025-02-25 19:38:02 +00:00
Mark Adler
bd57dbc241 win32port: zlib: upstream bugfix patch on inftrees.c
From 6a043145ca6e9c55184013841a67b2fef87e44c0 Mon Sep 17 00:00:00 2001
Subject: [PATCH] Remove offset pointer optimization in inftrees.c.

inftrees.c was subtracting an offset from a pointer to an array,
in order to provide a pointer that allowed indexing starting at
the offset. This is not compliant with the C standard, for which
the behavior of a pointer decremented before its allocated memory
is undefined. Per the recommendation of a security audit of the
zlib code by Trail of Bits and TrustInSoft, in support of the
Mozilla Foundation, this tiny optimization was removed, in order
to avoid the possibility of undefined behavior.
2025-02-24 12:52:53 +00:00
Andy Green
df9f518e97 dos2unix: win32port/zlib/inftrees.c 2025-02-24 12:52:43 +00:00
Andy Green
5d1947474e lws_tls_openssl_asn1time_to_unix: fix 13 char asn1 epoch
Also align to struct tm's year epoch of 1900

https://github.com/warmcat/libwebsockets/issues/3341
2025-02-24 12:52:33 +00:00
Andy Green
7333fcc9cd coverity 472861: http2: deal with zero length data without overflow 2025-01-19 16:59:34 +00:00
Andy Green
ff0e0f3c35 coverity 472860: ops-h2: let coverity see all err enums covered
x
2025-01-19 16:59:25 +00:00
Andy Green
b81b24d10e coverity 472863: cookies: length check order wrong 2025-01-19 16:59:17 +00:00
Andy Green
5a34404b1a coverity 872858: hash gen overflow false positive
Help it ignore that we use the MS 7 bits in the next part of the operation
and discard it in the first part.
2025-01-19 16:58:57 +00:00
Andy Green
fce734f279 coverity 472862: cookiejar overflow 2025-01-19 16:58:46 +00:00
Davidovory03
e5506ade69 mbedtls: translate error codes for caller
https://github.com/warmcat/libwebsockets/issues/3315
2025-01-19 16:57:24 +00:00
Albert Ribes
c6e9792188 lejp: E implies float
Since eg, 1e-3 is a float without needing a decimal point, let's just
    generally take it that anything with the exponent token is a float, ie, 1e3
    is also a float despite it can be expressed as an integer.

    This seems right also because E is itself not valid in an integer.

    https://github.com/warmcat/libwebsockets/issues/3308
2025-01-10 14:14:49 +00:00
Andy Green
dc65edd519 spa: use sized local info rather than incoming
We allow a default 0 length in the incoming const info to mean a default
size (of 512).  We implement it by copying the incoming const info to a
copy in the spa that we can adapt, which is all good.

But in two cases after we dumbly use the incoming const info directly
instead of the adapted copy.

https://github.com/warmcat/libwebsockets/issues/3294
2024-12-13 09:23:07 +00:00
level 6
12e52ae293 test-server-extpoll: remove LWS_WITH_EXTERNAL_POLL redefine 2024-12-06 07:43:59 +00:00
Orgad Shaneh
c4b1e34a50 clean: var unused when no logs 2024-11-16 09:08:31 +00:00
Lucas
a71a62f51b mbedtls: fix issue about memory leak
https://github.com/warmcat/libwebsockets/issues/3177
2024-11-08 07:58:59 +00:00
Orgad Shaneh
5102a5c8d6 tls-sessions: Pass correct type for printf %u 2024-10-06 08:11:58 +01:00
Orgad Shaneh
8ad16af9a3 win: simplify error logging in windows-sockets.c 2024-10-03 05:27:54 +01:00
Orgad Shaneh
0ee1984c5c win: change uid_t and gid_t from int to unsigned int
Like they are on Linux.
2024-10-03 05:25:29 +01:00
Orgad Shaneh
dcf9dcaf2a unix-file: Fix signed/unsigned implicit conversion 2024-10-03 05:21:50 +01:00
Orgad Shaneh
a544db3020 win32: zlib: Fix buffer overflow on inflate (CVE-2022-37434) 2024-10-03 05:14:30 +01:00
Andy Green
a1ee5a2c50 mbedtls: provide declaration if ge 3.5
https://github.com/warmcat/libwebsockets/issues/3169
2024-09-29 11:50:41 +01:00
Andy Green
e24114fed9 win: file: use INVALID_HANDLE_VALUE directly
c571d22dba (commitcomment-142753910)
2024-09-25 12:24:35 +01:00
Andy Green
0981808868 doc: session tickets
https://github.com/warmcat/libwebsockets/issues/3226
2024-09-25 12:18:06 +01:00
Andy Green
bad1866c8a wolfssl: have docs follow switch change
https://github.com/warmcat/libwebsockets/issues/3116
2024-09-25 10:35:53 +01:00
Andy Green
d1722af79b check func munging
https://github.com/warmcat/libwebsockets/issues/3181
2024-09-25 09:44:18 +01:00
Andy Green
f7aeadeb0e win: trigger context destroy if pt destroying itself
https://github.com/warmcat/libwebsockets/issues/3182

This follows the flow for *nix
2024-09-25 09:37:03 +01:00
Andy Green
8fc7596fec event: blow error if runtime context options want eventlib we dont have
https://github.com/warmcat/libwebsockets/issues/3186
2024-09-25 09:03:36 +01:00
Andy Green
2ca5d8605b ws: increase sanity check for spins needed to consume buffer to 100
https://github.com/warmcat/libwebsockets/issues/3184
2024-09-25 08:53:41 +01:00
Andy Green
b05e95ec87 pipe: only pt destroy pipe close should close pipe fds
https://github.com/warmcat/libwebsockets/issues/2873
2024-09-25 08:38:44 +01:00
Andy Green
82c97d4022 lws_extension_callback_pm_deflate: make visible
https://github.com/warmcat/libwebsockets/issues/3178
2024-09-25 07:46:35 +01:00
Andy Green
86819f05af win32: upscale timeout_ms to 64-bit int
This may help with this:

https://github.com/warmcat/libwebsockets/issues/3201
2024-09-25 07:11:29 +01:00
Andy Green
51c47daea3 without-server: adapt loops to not touch listen_list
https://github.com/warmcat/libwebsockets/issues/3203
2024-09-25 07:03:54 +01:00
Andy Green
3976131e35 unix-sockets: extra care around short for some toolchains
https://github.com/warmcat/libwebsockets/issues/3163
2024-09-25 06:38:09 +01:00
Andy Green
57a0c16aeb openbsd: disable HIGH_RELIABLITY socket option
https://github.com/warmcat/libwebsockets/issues/3204
2024-09-25 06:32:13 +01:00
Andy Green
154bf55441 openssl: allow custom SSL_CTX with GLOBAL_INIT unset 2024-09-23 13:10:30 +01:00
Andy Green
8c8a2a5be3 lws_map: remove typedef for some toolchains
This backports a change that has been in main for a while
2024-09-23 11:06:36 +01:00
ribes96
7467274d4d cgi: setenv: remove equals from arg
https://github.com/warmcat/libwebsockets/issues/3222
2024-09-23 10:39:23 +01:00
James Darpinian
b462ccd7dd ACME: fixes
Increase polling time and poll the "order" endpoint instead of the "finalize" endpoint. These changes are required for ACME to work with Let's Encrypt as of 2024.
2024-06-24 14:58:35 +01:00
zzblydia
ca375a4cab client hs: fix segmentation fault
https://github.com/warmcat/libwebsockets/pull/3171
2024-06-24 09:09:00 +01:00
streltsovdd
c571d22dba windows: fix check of result of CreateFileW 2024-06-04 06:06:51 +01:00
Seo Suchan
c90a77f124 mbedtls: fix compile on mbedtls ge 3.6 2024-05-07 13:48:09 +01:00
payne.ye
bd8f69e438 smp: extend client to work with tsi
and take care of zombie sul previously left on connect failure path
2024-04-12 06:25:21 +01:00
p-luke
eac4489237 netlink: when binding the per-context socket, let the kernel choose the unicast address.
When using multiple client contextes in a single application, rops_pt_init_destroy_netlink() fails binding the second socket and on - only the first one succeeds. The failure is made obvious by this log:
  W: rops_pt_init_destroy_netlink: netlink bind failed

So, let's fix this by doing what netlink(7) man page suggests:
  If the application sets nl_pid before calling bind(2), then it is up to the
  application to make sure that nl_pid is unique. If the application sets it
  to 0, the kernel takes care of assigning it. The kernel assigns the process
  ID to the first netlink socket the process opens and assigns a unique nl_pid
  to every netlink socket that the process subsequently creates.
2024-03-20 07:29:48 +00:00
Andy Green
0a132164c2 h2: cleanly return if fd is -1 on custom close 2024-03-08 06:44:22 +00:00
Liu DongMiao
6901c32a9d raw-skt: don't read more than rx_buffer_size
When other roles like ws reading data, they follow `rx_buffer_size`, then fallback to context's `pt_serv_buf_size`.
However, `raw-skt` don't follow `rx_buffer_size`, always use 0, then fallback to `pt_serv_buf_size`.

This PR make `raw-skt` don't read more than `rx_buffer_size` data.
2024-03-07 09:50:47 +00:00