1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-30 00:00:16 +01:00
libwebsockets/minimal-examples/api-tests
Andy Green dcaa0013b4 lecp: add CBOR stream parser LECP like JSON LEJP
This provides very memory-efficient CBOR stream parsing
and writing.

The parser  converts pieces of CBOR into callbacks that define
the structure and collate string and blobs into buffer chunks
for extensible and easy access.

It is fragementation-safe and does not need all the CBOR in
the same place at one time, chunks of CBOR are parsed and
discarded as provided.

It does not allocate and just needs a few hundred bytes of
stack for even huge CBOR objects.  Huge strings and blobs
are handled without needing memory to hold them atomically.

Includes ./minimal-examples/api-tests/api-test-lecp that
unit tests it against 82 official example CBORs and
26 additional test vectors from COSE (just checking the CBOR
parsing).

The writing apis allow printf style semantics with a variety
of CBOR-aware %-formats.  The apis write into a context that
manages output buffer usage, if the output buffer fills,
then the apis return with an AGAIN code that lets you issue
and reset the output buffer and repeat the api all to issue
more output.  The subsequent calls can occur much later or
from a different function context, so this is perfect for
WRITEABLE-mediated output from the network parts of lws.

See ./READMEs/README.cbor-lecp.md
2021-08-21 17:44:40 +01:00
..
api-test-async-dns client: DNS failure should retry while waiting for connect timeout 2021-03-11 06:58:59 +00:00
api-test-dhcpc dhcp: clean 2021-02-17 11:39:15 +00:00
api-test-fts type comparisons: fixes 2021-01-05 10:56:38 +00:00
api-test-gencrypto cmake: latest cmake shows dep warnings for scripts < 2.8.12 2020-12-06 19:44:54 +00:00
api-test-jose tls: mbedtls-3 2021-07-13 13:22:50 +01:00
api-test-lecp lecp: add CBOR stream parser LECP like JSON LEJP 2021-08-21 17:44:40 +01:00
api-test-lejp cmake: latest cmake shows dep warnings for scripts < 2.8.12 2020-12-06 19:44:54 +00:00
api-test-lws_cache http: cookies: support cookie jar in and out 2021-08-21 17:44:40 +01:00
api-test-lws_dsh dsh: api-test: dont use lws_dsh_describe in Release 2021-04-05 10:55:04 +01:00
api-test-lws_map lws_map 2021-08-21 17:44:40 +01:00
api-test-lws_sequencer cpd: pass up lws_ss_request_tx ret 2021-08-16 08:07:32 +01:00
api-test-lws_smd Wextra 2021-07-04 10:29:54 +01:00
api-test-lws_struct-json Fault injection 2021-04-05 10:55:04 +01:00
api-test-lws_struct_sqlite cmake: latest cmake shows dep warnings for scripts < 2.8.12 2020-12-06 19:44:54 +00:00
api-test-lws_tokenize wilcard: change api to use length for check 2021-06-07 14:57:57 +01:00
api-test-lwsac cmake: latest cmake shows dep warnings for scripts < 2.8.12 2020-12-06 19:44:54 +00:00
api-test-secure-streams cpd: pass up lws_ss_request_tx ret 2021-08-16 08:07:32 +01:00
api-test-smtp_client cmake: latest cmake shows dep warnings for scripts < 2.8.12 2020-12-06 19:44:54 +00:00
README.md smtp: make abstract 2019-05-04 08:28:31 +01:00

These are buildable test apps that run in CI to confirm correct api operation.

name tests
api-test-lwsac LWS Allocated Chunks api
api-test-lws_struct-json Selftests for lws_struct JSON serialization and deserialization
api-test-lws_tokenize Generic secure string tokenizer api
api-test-fts LWS Full-text Search api
api-test-gencrypto LWS Generic Crypto apis
api-test-jose LWS JOSE apis
api-test-smtp_client SMTP client for sending emails