libubox/tests
Zefir Kurtisi a0dbcf8b8f tests: add blob-buffer overflow test
The blob buffer has no limitation in place
to prevent buflen to exceed maximum size.

This commit adds a test to demonstrate how
a blob increases past the maximum allowd
size of 16MB. It continuously adds chunks
of 64KB and with the 255th one blob_add()
returns a valid attribute pointer but the
blob's buflen does not increase.

The test is used to demonstrate the
failure, which is fixed with a follow-up
commit.

Signed-off-by: Zefir Kurtisi <zefir.kurtisi@gmail.com>
[adjusted test case for cram usage]
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2021-04-29 15:34:21 +02:00
..
cram tests: add blob-buffer overflow test 2021-04-29 15:34:21 +02:00
fuzz tests: add fuzzer seed file for crash in blob_len 2020-05-26 09:48:07 +02:00
shunit2 tests: include json script shunit2 based testing 2020-01-12 19:17:17 +01:00
CMakeLists.txt tests: include json script shunit2 based testing 2020-01-12 19:17:17 +01:00
test-avl.c add cram based unit tests 2019-11-24 13:26:58 +01:00
test-b64.c tests: prefer dynamically allocated buffers 2020-01-20 16:54:10 +01:00
test-b64_decode.c base64: fix possible null pointer dereference 2019-11-24 13:26:58 +01:00
test-b64_encode.c base64: fix possible null pointer dereference 2019-11-24 13:26:58 +01:00
test-blob-buflen.c tests: add blob-buffer overflow test 2021-04-29 15:34:21 +02:00
test-blob-parse.c tests: prefer dynamically allocated buffers 2020-01-20 16:54:10 +01:00
test-blobmsg-parse.c tests: prefer dynamically allocated buffers 2020-01-20 16:54:10 +01:00
test-blobmsg-procd-instance.c tests: prefer dynamically allocated buffers 2020-01-20 16:54:10 +01:00
test-blobmsg-types.c libubox: tests: add more blobmsg/json test cases 2021-03-09 21:53:14 +01:00
test-blobmsg.c blobmsg_json: prefer snprintf usage 2020-01-20 16:54:10 +01:00
test-blobmsg_check_array.c tests: blobmsg: add test case 2020-02-27 21:56:20 +01:00
test-json-script.c add cram based unit tests 2019-11-24 13:26:58 +01:00
test-list.c tests: list: add test case for list_empty iterator 2020-05-21 13:43:00 +02:00
test-runqueue.c tests: runqueue: try to fix race on GitLab CI 2020-05-21 16:28:29 +02:00