Commit Graph

89 Commits

Author SHA1 Message Date
dmiller 10f0b683a6 New tests for addrset, addrset_matches_all() 2026-08-28 04:03:22 +00:00
dmiller fe777b1d7c Addrset: add ability to test for entire address space exclusion 2026-08-28 04:03:18 +00:00
dmiller d5645bf76d ncat-test.pl: make reading stderr easier 2026-07-31 20:57:28 +00:00
dmiller b3620f74c3 Check return from OpenSSL allocation functions. Fixes #2721 2026-06-18 23:26:06 +00:00
dmiller 538764bb6a OpenSSL 4.0 compatibility. Fixes #3375 2026-06-16 13:58:41 +00:00
dmiller bfb569d8ec Fix memory leaks in Ncat test programs 2026-04-02 19:14:13 +00:00
dmiller 8ce9f04570 Use cross-platform-safe quoting for perl commands 2026-03-10 20:23:17 +00:00
dmiller edc7c4b492 ncat-test.pl: Also test that server is still running 2026-03-10 20:23:16 +00:00
dmiller fd8957052a Alter sleeps for slower Windows reconnect behavior 2026-03-10 20:23:16 +00:00
dmiller 2f9c3065fa Fix tests on Windows under MSYS2 2026-03-10 20:23:15 +00:00
dmiller ceccf5b237 ncat-test.pl: indicate timedout reads directly 2026-03-10 18:32:52 +00:00
dmiller 62206c623a ncat-test.pl: regen cert correctly 2026-03-10 18:32:51 +00:00
dmiller c5a05402d0 Consolidate Ncat EOF tests and add -k option where needed 2024-11-25 22:09:11 +00:00
dmiller 179786b2ce Add UDP SSL (DTLS) to Ncat tests 2024-11-25 22:09:09 +00:00
dmiller 498e92539f Use usleep in ncat-test.pl. Use 3-arg open 2024-11-18 17:11:43 +00:00
nnposter a1ba7b7672 Prevent unintentional filename expansion 2024-08-24 21:38:13 +00:00
dmiller d2280e0911 Ncat can proxy IPv6 to IPv4 and back. Update tests. 2022-09-22 01:35:20 +00:00
dmiller bf14c06d4c Some useful print statements for testing 2022-09-22 01:35:20 +00:00
dmiller aa0500e9a4 Generate cert for Ncat tests automatically 2022-09-22 01:35:19 +00:00
dmiller 2f9fde995c Remove xfail from some tests that were fixed in r36651 2022-09-21 19:17:22 +00:00
dmiller 478c5d4f19 Avoid a duplicate -l option in test 2022-09-21 19:17:21 +00:00
dmiller d6bea8dcde Build based on OpenSSL version, not API level. Fixes #2516 2022-09-06 22:39:34 +00:00
dmiller 140dd72415 Fix build with OpenSSL 3.0
Updated all OpenSSL code to OpenSSL 3.0 API with no deprecated functions. Some
NSE functions were changed:
* openssl.rc4_options and openssl.rc4 were removed in favor of openssl.encrypt
* openssl.bignum_pseudo_rand is now an alias for openssl.bignum_rand
* openssl.bignum_is_prime and openssl.bignum_is_safe_prime will now ignore the
  nchecks parameter, using a secure default instead.
2022-08-25 14:51:59 +00:00
dmiller 05faa0287a Fix addrset matching with overlapping CIDR specs. Fixes #2257 2021-03-01 18:42:00 +00:00
nnposter 9e8852a7c7 Rectify undefined behavior of out-of-range shift op
Fixes #1717, closes #1718
2019-09-03 21:56:31 +00:00
nnposter 25db5fbb0d Increases ncat temporary RSA key size to 2048 bits
This resolves a compatibility issue with OpenSSL library configured with
security level 2, as seen on current Debian or Kali. Closes #1310, closes #1409
2018-12-20 02:04:02 +00:00
dmiller 824f9dcb2f Rearrange declarations to put all addrset functions in nbase.h, hide struct addrset internals. 2018-11-01 04:35:00 +00:00
dmiller 689ea0e05d Spelling corrections. Fixes #1160 2018-03-26 14:59:41 +00:00
dmiller 7aeb2ada62 Avoid false FAIL due to ncat not starting quickly enough 2017-10-03 22:43:38 +00:00
dmiller ae59c8dafd Fix syntax error in ncat-test.pl 2017-10-03 22:43:37 +00:00
dmiller 09db4e48bf Fix paths and escape {} when running tests under Cygwin 2017-10-02 20:02:39 +00:00
dmiller 8488dae884 Expect failure with --sctp if no sctp support is available. 2017-10-02 16:55:18 +00:00
dmiller bf54157855 Fix some timing-related test failures 2017-07-29 05:55:28 +00:00
dmiller 4629f6d836 Ncat supports DNS failover, including fallback to IPv4 from IPv6 2017-03-16 21:54:26 +00:00
dmiller b7e213b5cb Fix compatibility with LibreSSL; new checks skipped initialization code 2017-02-07 20:10:02 +00:00
dmiller 9b86dadb58 Remove deprecated calls from OpenSSL 1.1 API. Closes #630 2017-01-11 15:38:08 +00:00
vincent aedd25c3a2 Add compatibility with OpenSSL 1.1.0 pre5 and previous versions
Add some checks to know which OpenSSL version is used, to be sure
the code follows the syntax of the version used (including 1.1.0).
2016-08-01 09:34:56 +00:00
abhishek d04046ae48 Adds test for -z option in ncat, closes #444 2016-07-19 10:08:02 +00:00
vincent 3287c1159b Replace deprecated RSA_generate_key by RSA_generate_key_ex
This applies the changes made in PR #451 on Github
2016-07-13 10:17:30 +00:00
dmiller e7cd3a7f1e Fix ncat tests
google.com can resolve to a different set of addresses each time you
resolve it, which makes the addrset tests fail. Use scanme.nmap.org
instead, since (at least for now) that has only one address assigned.
2014-08-02 04:38:02 +00:00
david d5d8cd3033 Add tests for 0-length POSTs.
The non-chunked one fails for me.
FAIL HTTP POST Content-Length: 0
     Read timeout at ./ncat-test.pl line 2087.
2014-03-07 05:54:48 +00:00
dmiller 1575c63d7d Spellcheck for Ncat, Nping source files 2014-02-20 21:22:22 +00:00
henri 21b7e3818d [Ncat] Added support for socks5 and corresponding regression tests.
[Marek Lucaszuk, Petr Stodulka]
2014-02-09 14:10:04 +00:00
dmiller 46eb0fed75 Be more compatible with SysV sh
Although $((arithmetic expansion)) is POSIX-specified, some systems have
non-POSIX System V shell, which can't handle it. This patch replaces
$((something)) with $(expr something) to fix compatibility. This
actually slows things down considerably, since a subshell must be
launched for each increment operation, but the tests aren't that
critical. Bug report: http://seclists.org/nmap-dev/2013/q4/198
2013-12-03 19:11:12 +00:00
david 5657e7e00b Make test-environment.lua a bit more straightforward. 2013-10-04 22:42:13 +00:00
d33tah ad2b15b88f Make ncat-test.pl work on both Windows and *nix without modification;
feel free to revert it if you believe it needs some discussion first.
(I find it useful when working from both VM and Linux on a shared
directory)
2013-09-03 01:01:38 +00:00
d33tah 695be03e60 Fix a copy-paste mistake in Ncat test suite. 2013-08-30 10:23:22 +00:00
david f43781f3d9 XFAIL Unix domain socket tests on Windows. 2013-08-16 17:09:06 +00:00
david b01285b8f3 Automatically XFAIL SCTP tests on Windows. 2013-08-16 17:09:03 +00:00
david a6dafe881c Put test filehandles into binary mode. 2013-08-16 17:08:55 +00:00