Commit Graph
11 Commits
Author SHA1 Message Date
Evgeny 73f707ef9b crypto: migrate ECDH(secp256r1) to X25519, drop TinyCrypt
- SC_PUBKEY_SIZE: 64 -> 32 bytes, SC_PUBKEY_ENC_SIZE: 72 -> 40
- sc_set_peer_public_key uses EVP_PKEY_derive with X25519
- sc_generate_keypair via EVP_PKEY_keygen(EVP_PKEY_X25519)
- sc_compute_public_key_from_private via EVP_PKEY_new_raw_private_key
- sc_validate_key: check non-zero (X25519 has no invalid keys)
- sc_obfuscate_pubkey: XOR now 32 bytes
- Remove all TinyCrypt code (~860 lines), always use OpenSSL
- Remove TinyCrypt from build system, drop test_crypto/test_ecc_encrypt
- Update all test keys (128 hex -> 64 hex)
- Fix bbr_integration.c split-line pubkeys
2026-06-17 21:28:07 +03:00
Evgeny 98f886b8a8 test fix, log update 2026-03-25 22:49:57 +03:00
jeka aa5171bcd1 route improvements 2026-03-12 02:57:38 +03:00
jeka 78dfdde400 Fix Windows test failures: proper WSAPoll error handling and FD_SETSIZE check 2026-02-16 10:33:43 +03:00
Evgeny f5faa7c834 Fix Windows build: add default_CSPRNG and improve build.sh error handling
- Add Windows implementation of default_CSPRNG() using CryptGenRandom
- Add fallback stub for platforms without CSPRNG support
- Fix build.sh to properly detect build failures (use PIPESTATUS)
- Show proper error message instead of "Build completed successfully" on failure
2026-02-15 04:34:05 +03:00
Evgeny 4d486c7017 Fix test files for Windows cross-platform compatibility
- Create test_utils.h with cross-platform utility functions:
  * test_mkdtemp() - Windows uses GetTempPath + _mkdir, Linux uses mkdtemp
  * test_unlink() - Windows _unlink, Linux unlink
  * test_rmdir() - Windows _rmdir, Linux rmdir

- Update all test files to use test_utils.h
- Replace arpa/inet.h and netinet/in.h with platform_compat.h
- Replace unistd.h with conditional includes
- Replace mkdtemp(), unlink(), rmdir() with test_* versions

- Tests now build on both Linux and Windows
- Note: Some integration tests may fail on Linux due to test environment
2026-02-15 04:09:24 +03:00
Evgeny 8334b97521 Backup before adding NAT IP:port tracking to ETCP handshake 2026-02-14 11:02:20 +03:00
Evgeny 4c12bace8e Replace printf with DEBUG_ macros in test_config_debug.c and test_debug_categories.c 2026-01-26 18:36:12 +03:00
Evgeny 3ddfb79338 Backup before replacing all printf with DEBUG_ macros in tests 2026-01-26 17:52:50 +03:00
Evgeny 1bafe6a681 Backup before fixing etcp_connections list addition 2026-01-26 17:40:51 +03:00
Evgeny d74f76a5a0 Fix: Resolved double free in timeout_heap_pop() and test_etcp_simple_traffic bind conflict
- Fixed incorrect init_connections() call in test_etcp_simple_traffic.c (was calling server_instance instead of client_instance)
- Fixed double free in timeout_heap_pop() when handling deleted elements
- Enhanced NULL pointer safety in uasync_print_resources() by removing complex heap manipulation
- Added debug logging to timeout_heap_pop() for better error tracking

Test results: test_etcp_simple_traffic now passes without double free errors
2026-01-25 10:47:02 +03:00