BBS: TELESC.NET.BR Assunto: src/ssh/kex/dh-gex-sha256.c src/ssh/ssh-internal.h ssh-trans.c src/ssh De: Deuc¨ Data: Mon, 23 Mar 2026 20:49:18 -0700 ----------------------------------------------------------- https://gitlab.synchro.net/main/sbbs/-/commit/a06e7e2cb45f81116329b146 Modified Files: src/ssh/kex/dh-gex-sha256.c src/ssh/ssh-internal.h ssh-trans.c src/ssh/test/dssh_test_internal.h test_transport.c Log Message: Expose version_tx, parse_bn_mpint, dh_value_valid for testing; add 12 tests Move DSSH_TESTABLE macro definition from ssh-trans.c to ssh-internal.h so all library source files can use it. Expose three static functions via DSSH_TESTABLE: - version_tx (ssh-trans.c): sends the SSH version identification line - parse_bn_mpint (dh-gex-sha256.c): parses an mpint from wire format - dh_value_valid (dh-gex-sha256.c): validates DH e/f in [1, p-1] Add test accessors dssh_test_set_sw_version/set_version_comment to bypass set_version validation for defense-in-depth testing. New tests: - version_tx TOOLONG with oversized version string - version_tx TOOLONG with oversized comment - parse_bn_mpint: valid, short header, truncated data - dh_value_valid: zero, negative, equal to p, greater than p, valid interior, boundary values (1 and p-1) Co-Authored-By: Claude Opus 4.6 (1M context)n --- mSynchronetn hgVertrauen n hHome of Synchronet n gh[vert/cvs/bbs].synchro.net ----------------------------------------------------------- [Voltar]