Commit Graph

260 Commits

Author SHA1 Message Date
zugz (tox)
1157e4e68c
Separate run_auto_tests into a library 2022-01-25 14:25:36 -05:00
iphydf
4ce02c0af9
refactor: Deduplicate a bunch of code in TCP client/server.
Also generally a bit of cleanup and better layering.
2022-01-16 09:41:08 +00:00
iphydf
c7ecee7c15
cleanup: Remove old check Suite compat layer.
This doesn't do anything useful for us. It was there so we don't need to
rewrite the tests (which I just did). Finally this is now cleaned up.
2022-01-16 01:37:37 +00:00
iphydf
2671095f4a
cleanup: Merge crypto_core and crypto_core_mem.
The remaining memory functions are small and don't need their own file.
2022-01-15 01:34:14 +00:00
sudden6
e04b890817
add scripts to run the fuzzing process
This adds scripts and Dockerfiles to run the fuzzing process standalone
or with OSS-Fuzz/ClusterFuzzLite integrations.
2022-01-10 21:05:51 +01:00
sudden6
7dd8dbd897
intercept network, crypto and time
This fuzzing harness must be as deterministic as possible for the fuzzer
to detect additional coverage reliably.
2022-01-10 21:05:49 +01:00
sudden6
9eb88798a3
add fuzzing harnesses
Toxsave harness ported to libFuzzer interface.
New harness for bootstrap phase.
2022-01-10 20:57:00 +01:00
Robin Linden
f78c741790
Update MSVC auto test disables to match what somewhat reliably works 2022-01-10 02:27:13 +01:00
Robin Linden
d2ef514569
Disable building cracker with MSVC
It uses OpenMP features MSVC doesn't support.
2022-01-10 02:27:13 +01:00
iphydf
4746a8b3af
cleanup: Remove apidsl; remove crypto_memcmp.
* `crypto_memcmp` was replaced by more specific functions. We never want
  to compare arbitrary amounts of data this way. We use these functions
  to compare key material.
* apidsl has been bothering people, so now we un-bother them. You're
  welcome.
* Added the memlock/unlock functions from the New Group Chats branch.
* Remove some system dependencies in crypto_core_mem.c.
* Renamed UPPERCASE_NAMES to Snake_Camel_Case names.
2021-12-19 19:22:38 +00:00
sudden6
828312c2f9
perf: improve speed of cracker.c
- more inteligent secret key generation
- use OpenMP for multithreading
- leave old cracker, because it's simple
- update old cracker to new coding style
2021-12-17 20:11:18 +01:00
iphydf
d9ab91970d
cleanup: Remove apidsl for everything except the public API.
Apidsl is not powerful enough to express all the things we need and
doesn't know how `#include` works. The generated headers are more complex
than they should be.
2021-12-15 17:36:29 +00:00
Robin Linden
4348b96a5b
Release 0.2.13 2021-12-06 23:28:52 +01:00
iphydf
57b0651ffd
test: Add some unit tests for important internal DHT functions.
We definitely need more of this kind of test so refactorings don't
accidentally break things in ways that happen to still work in auto
tests.
2021-12-01 14:08:37 +00:00
Robin Linden
56992b099e
Add support for the conan C/C++ package manager
* Don't overwrite the CMAKE_MODULE_PATH
* Allow linking libsodium statically with MSVC
* Allow finding libsodium the normal way on MSVC
* Allow using pthreads4w for pthreads on MSVC
* Fall back to find_package if pkg_find_module fails
* Don't pass incompatible compile flags to MSVC
* Also try to find Opus and libvpx using their canonical names
* Support building using conan
* Allow pkg_use_module to take a list of libraries to look for
* Build for Windows on Appveyor using conan
2020-05-29 15:36:26 +02:00
Robin Linden
9be4dbb433
Release 0.2.12 2020-05-01 12:58:27 +02:00
iphydf
de3c21b5b7
Disable non-hermetic tests by default.
See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=955319.
2020-04-29 12:09:34 +00:00
iphydf
f3c6fc6771
Add execution trace option for debugging.
Use `cmake -DEXECUTION_TRACE=ON` to use it.
2020-04-27 23:10:27 +00:00
zoff99
cdafc6ff5e
Add new semi-private API functions to set per-packet-id custom handlers.
This is to prepare for ToxAV becoming independent of toxcore internal calls.
2020-04-16 12:28:13 +00:00
Robin Linden
7f9f8045cd
Fix things not being initialized if creating a TCP-only network 2020-04-13 22:43:51 +02:00
sudden6
6732e5ef2f
Add basic test adapter for AFL 2020-03-24 16:49:41 +01:00
Robin Linden
30b9369b01
Release 0.2.11 2020-03-22 21:12:04 +01:00
zugz (tox)
db07bda7f7
Add "member" invite response
This allows invitations to work in the case that the invitee is already
in the group, which can happen if the group becomes split. Such an
invitation is automatically accepted, leading to the peers becoming
connected in the group and sharing peer lists.
2020-03-18 00:00:00 +00:00
iphydf
28baf9632f
Remove testing/av_test.c.
It's a maintenance burden. Nobody uses this. It depends on an ancient
version of opencv that less and less systems actually have.
2020-03-02 21:07:55 +00:00
iphydf
0f7138c010
Upgrade bazel to 2.1.1.
Removed av_test, because it depends on an ancient opencv that starts to
really not exist on modern systems anymore.
2020-03-02 14:23:44 +00:00
Robin Lindén
7aab0d9952
Release 0.2.10 2019-05-30 15:36:12 +02:00
zugz (tox)
49e2406ffa
Expose api functions for enabling and disabling AV in AV groups
A group loaded from a savefile starts with AV disabled.
2019-02-10 00:00:00 +00:00
Robin Lindén
98b754e1f2
Release 0.2.9 2019-01-12 23:35:54 +01:00
zugz (tox)
0f8f82a3cf
Add cmake option for building additional tests
Closes #1262
2018-12-11 21:49:34 +01:00
iphydf
1eaa55d2d4
Include CTest in CMakeLists.txt to get valgrind support.
We can now run `ctest --output-on-failure -D ExperimentalMemCheck -j 50`
to run valgrind on all tests.
2018-10-17 19:25:33 +00:00
Leonid Bobrov
ed9beef61c
Support DragonFlyBSD and prune unused variables. 2018-10-16 22:01:00 +00:00
chrono
17a7bf3fd2
Add AUTOTEST Option to CMakeLists.txt 2018-10-07 22:09:54 +00:00
Robin Lindén
3f35a84968
Release 0.2.8 2018-10-07 23:21:24 +02:00
Maxim Biro
f5afc52655
Default to not defining MIN_LOGGER_LEVEL in CMake
That way CMake's behavior matches what autotools does -- letting
toxcore/logger.h handle the default case.
2018-10-07 15:15:58 -04:00
Maxim Biro
11e1f63f54
Fix logger level defaulting to TRACE in CMake 2018-10-07 15:15:44 -04:00
iphydf
bfd288c196
Revert "Improve cmake build for MSVC."
This reverts commit f87f8719d0.
2018-09-24 22:25:49 +00:00
Mick Sayson
f87f8719d0
Improve cmake build for MSVC. 2018-09-22 11:14:45 +00:00
Robin Lindén
18117581bd
Release 0.2.7 2018-08-30 22:43:11 +02:00
zugz (tox)
66ab386d6f
try ipv6 connections even after udp timeout
Also adds a test (auto_reconnect_test) which fails without this change.
2018-08-27 22:27:01 +02:00
iphydf
a1035cf814
Add some tests for ping_array.
No timeout test here yet, because we don't yet have the ability to
manipulate time at will, so we would have to actually sleep.
2018-08-26 17:32:19 +00:00
iphydf
2730c95699
Install the DHT_bootstrap binary on make install.
We didn't install it before, only `tox-bootstrapd`.
2018-08-23 21:33:54 +00:00
endoffile78
30960dcc7e
Add save file generator, save compatibility test, and generate a save file 2018-08-19 10:38:51 +00:00
Robin Lindén
31ea1aa06e
Release 0.2.6 2018-08-16 22:45:33 +02:00
iphydf
1de8b020cb
Remove all uses of the PAIR macro in toxav. 2018-08-12 11:38:23 +00:00
Robin Lindén
ffd71e895b
Release 0.2.5 2018-08-08 19:38:31 +02:00
hugbubby
051eb1d5a7
auto_test fixture and filenames
Renamed a poorly named test, fixed up a few printf statements,
substituted some unsigned integers with fixed size counterparts,
and implemmented the auto_run_test.h fixture for the lossy and
lossless packet tests.
2018-07-28 16:14:06 +00:00
hugbubby
c4d58403f9
More fixed_width ints and incorporating file_saving_test.c
The file_saving_test.c was not included in the cmake list
and thus was ignored by travis and "make check". I found this
out while introducing ck_assert_msg into the integration test.

Furthermore, removed some variable width integers from encryptsave_test.c,
and the SRunner utilization. Implemmented ck_assert_msg, reorganized some
loops, and removed some longs in file_transfer_test.c.
2018-07-23 15:10:22 +00:00
iphydf
f627a26a7b
Run Clang global static analysis on Travis.
This uses a single .cc file containing almost all the code in the
repository to perform whole program analysis.
2018-07-22 02:34:30 +00:00
iphydf
7245ac11ef
Avoid implementations in .h files or #including .c files.
Also, avoid the need for putting `_XOPEN_SOURCE` in every test file.
2018-07-21 20:44:26 +00:00
Robin Lindén
a672b3c56e
Release v0.2.4 2018-07-20 22:52:14 +02:00