Commit Graph

870 Commits

Author SHA1 Message Date
dtucker@openbsd.org 0423043c5e upstream: Allow SLEEPTIME to be overridden.
OpenBSD-Regress-ID: 1596ab168729954be3d219933b2d01cc93687e76
2019-07-20 22:12:24 +10:00
dtucker@openbsd.org d466b6a5cf upstream: Move sleep time into a variable so that we can increase
it for platforms or configurations that are much slower then usual.

OpenBSD-Regress-ID: 88586cabc800062c260d0b876bdcd4ca3f58a872
2019-07-20 22:11:00 +10:00
djm@openbsd.org b4a7c9d2b5 upstream: add regression tests for scp for out-of-destination path file
creation by Harry Sintonen via Jakub Jelen in bz3007

OpenBSD-Regress-ID: 01ae5fbc6ce400b2df5a84dc3152a9e31f354c07
2019-07-19 13:53:27 +10:00
Darren Tucker 65333f7454 Show when skipping valgrind for a test. 2019-07-19 13:16:11 +10:00
Darren Tucker fccb7eb343 Enable connect-privsep test with valgrind.
connect-privsep seems to work OK with valgrind now so don't skip
valgrind on it.
2019-07-19 10:41:56 +10:00
Darren Tucker d742301726 Show valgrind results and error counts. 2019-07-19 07:43:07 +10:00
Darren Tucker a192021fed Fail tests if Valgrind enabled and reports errors.
Also dump the failing valgrind report to stdout (not the cleanest
solution, but better than nothing).
2019-07-18 11:09:38 +10:00
Darren Tucker d1c491ecb9 Allow low-priv tests to write to pipe dir.
When running regression tests with Valgrind and SUDO, the low-priv agent
tests need to be able to create pipes in the appropriate directory.
2019-07-18 10:17:54 +10:00
Darren Tucker 8a5bb3e781 Put valgrind vgdb files to a specific directory.
Valgrind by default puts vgdb files and pipes under /tmp, however it
is not always able to clean them up, which can cause test failures when
there's a pid/file collision.  Using a specific directory ensures that
we can clean up and start clean.
2019-07-17 21:24:55 +10:00
djm@openbsd.org f8829fe57f upstream: adapt to sshbuf_dtob64() change
OpenBSD-Regress-ID: 82374a83edf0955fd1477169eee3f5d6467405a6
2019-07-17 11:04:25 +10:00
dtucker@openbsd.org 1254fcbb2f upstream: Remove ssh1 files from CLEANFILES since ssh1 no longer
supported.

OpenBSD-Regress-ID: 5b9ae869dc669bac05939b4a2fdf44ee067acfa0
2019-07-17 11:04:25 +10:00
dtucker@openbsd.org 9dc81a5ada upstream: Update names of host key files in CLEANFILES to match
recent changes to the tests.

OpenBSD-Regress-ID: 28743052de3acf70b06f18333561497cd47c4ecf
2019-07-17 11:02:42 +10:00
djm@openbsd.org 477e2a3be8 upstream: unit tests for sshbuf_cmp() and sshbuf_find(); ok markus
OpenBSD-Regress-ID: b52d36bc3ab6dc158c1e59a9a4735f821cf9e1fd
2019-07-15 23:21:18 +10:00
Darren Tucker bc551dfebb Clear valgrind-out dir to prevent collisions. 2019-07-15 12:52:45 +10:00
Darren Tucker 5db9ba718e Allow agent tests to write to valgrind dir. 2019-07-15 12:02:27 +10:00
djm@openbsd.org 121e48fa53 upstream: unit tests for sshbuf_peek/poke bounds-checked random access
functions. ok markus@

OpenBSD-Regress-ID: 034c4284b1da6b12e25c762a6b958efacdafbaef
2019-07-15 09:39:42 +10:00
dtucker@openbsd.org e187b1d460 upstream: Add (recently added) rsa_oldfmt to CLEANFILES.
OpenBSD-Regress-ID: 405beda94e32aa6cc9c80969152fab91f7c54bd3
2019-07-05 15:08:14 +10:00
dtucker@openbsd.org 74b541bfab upstream: Adapt the PuTTY/Conch tests to new key names.
A recent regress change (2a9b3a2ce4 in
portable) broke the PuTTY and Twisted Conch interop tests, because the
key they want to use is now called ssh-rsa rather than rsa.  Adapt the
tests to the new file names.  bz#3020, patch from cjwatson at debian.org.

OpenBSD-Regress-ID: fd342a37db4d55aa4ec85316f73082c8eb96e64e
2019-07-05 15:07:55 +10:00
dtucker@openbsd.org de08335a4c upstream: Add a sleep to allow forwards to come up.
Currently when the multiplex client requests a forward it returns
once the request has been sent but not necessarily when the forward
is up.  This causes intermittent text failures due to this race,
so add some sleeps to mitigate this until we can fix it properly.

OpenBSD-Regress-ID: 384c7d209d2443d25ea941d7f677e932621fb253
2019-07-05 15:06:04 +10:00
Darren Tucker 4d24928472 Remove nc stderr redirection to resync w/OpenBSD. 2019-07-05 14:58:57 +10:00
Jitendra Sharma 58ceacdcba Update README doc to include missing test cases
Readme regress document is missing various individual tests,
which are supported currently. Update README to
include those test cases.
2019-06-27 20:54:14 +10:00
djm@openbsd.org 1dfadb9b57 upstream: adapt for key shielding API changes (const removal)
OpenBSD-Regress-ID: 298890bc52f0cd09dba76dc1022fabe89bc0ded6
2019-06-21 14:24:44 +10:00
djm@openbsd.org 99bcbbc77f upstream: check for convtime() refusing to accept times that
resolve to LONG_MAX Reported by Kirk Wolf bz2977; ok dtucker

OpenBSD-Regress-ID: 15c9fe87be1ec241d24707006a31123d3a3117e0
2019-06-19 12:21:40 +10:00
dtucker@openbsd.org e5cccb2410 upstream: Add unit tests for user@host and URI parsing.
OpenBSD-Regress-ID: 69d5b6f278e04ed32377046f7692c714c2d07a68
2019-06-19 12:21:40 +10:00
dtucker@openbsd.org 0bb7e38834 upstream: Add tests for sshd -T -C with Match.
OpenBSD-Regress-ID: d4c34916fe20d717692f10ef50b5ae5a271c12c7
2019-06-19 12:21:23 +10:00
Jakub Jelen 342d6e5158 Adjust softhsm2 path on Fedora Linux for regress
The SoftHSM lives in Fedora in /usr/lib64/pkcs11/libsofthsm2.so
2019-03-29 22:37:15 +11:00
Corinna Vinschen 786cd4c183 drop old Cygwin considerations
- Cygwin supports non-DOS characters in filenames
- Cygwin does not support Windows XP anymore

Signed-off-by: Corinna Vinschen <vinschen@redhat.com>
2019-03-28 09:23:46 +11:00
dtucker@openbsd.org 19a0f0529d upstream: The test sshd_config in in $OBJ.
OpenBSD-Regress-ID: 1e5d908a286d8e7de3a15a0020c8857f3a7c9172
2019-01-28 19:01:01 +11:00
dtucker@openbsd.org 8fe2544020 upstream: Remove leftover debugging.
OpenBSD-Regress-ID: 3d86c3d4867e46b35af3fd2ac8c96df0ffdcfeb9
2019-01-28 14:41:11 +11:00
dtucker@openbsd.org e30d32364d upstream: Enable ssh-dss for the agent test. Disable it for the
certificate test.

OpenBSD-Regress-ID: 388c1e03e1def539d350f139b37d69f12334668d
2019-01-28 11:34:22 +11:00
dtucker@openbsd.org ffdde469ed upstream: Count the number of key types instead of assuming there
are only two.

OpenBSD-Regress-ID: 0998702c41235782cf0beee396ec49b5056eaed9
2019-01-28 11:34:22 +11:00
dtucker@openbsd.org 2a9b3a2ce4 upstream: Generate all key supported key types and enable for keyscan
test.

OpenBSD-Regress-ID: 72f72ff49946c61bc949e1692dd9e3d71370891b
2019-01-27 17:40:42 +11:00
djm@openbsd.org 49d8c8e214 upstream: adapt to changes in KEX APIs and file removals
OpenBSD-Regress-ID: 54d6857e7c58999c7a6d40942ab0fed3529f43ca
2019-01-21 23:51:29 +11:00
djm@openbsd.org 35ecc53a83 upstream: adapt to changes in KEX API and file removals
OpenBSD-Regress-ID: 92cad022d3b0d11e08f3e0055d6a14b8f994c0d7
2019-01-21 23:41:21 +11:00
djm@openbsd.org 7d69aae64c upstream: adapt to bignum1 API removal and bignum2 API change
OpenBSD-Regress-ID: cea6ff270f3d560de86b355a87a2c95b55a5ca63
2019-01-21 23:38:30 +11:00
djm@openbsd.org beab553f0a upstream: remove hack to use non-system libcrypto
OpenBSD-Regress-ID: ce72487327eee4dfae1ab0212a1f33871fe0809f
2019-01-21 23:38:10 +11:00
Damien Miller ba58a529f4 make agent-pkcs11 search harder for softhsm2.so 2019-01-21 13:09:23 +11:00
djm@openbsd.org 3c0c657ed7 upstream: allow override of ssh-pkcs11-helper binary via
$TEST_SSH_SSHPKCS11HELPER from markus@

OpenBSD-Regress-ID: 7382a3d76746f5a792d106912a5819fd5e49e469
2019-01-21 11:51:54 +11:00
djm@openbsd.org 760ae37b45 upstream: adapt agent-pkcs11.sh test to softhsm2 and add support
for ECDSA keys

work by markus@, ok djm@

OpenBSD-Regress-ID: 1ebc2be0e88eff1b6d8be2f9c00cdc60723509fe
2019-01-21 11:51:54 +11:00
djm@openbsd.org b2ce8b31a1 upstream: add "extra:" target to run some extra tests that are not
enabled by default (currently includes agent-pkcs11.sh); from markus@

OpenBSD-Regress-ID: 9a969e1adcd117fea174d368dcb9c61eb50a2a3c
2019-01-21 11:51:54 +11:00
Damien Miller 9b655dc9c9 last bits of old packet API / active_state global 2019-01-20 14:55:27 +11:00
djm@openbsd.org 609644027d upstream: regress bits for banner processing refactor (this test was
depending on ssh returning a particular error message for banner parsing
failure)

reminded by bluhm@

OpenBSD-Regress-ID: f24fc303d40931157431df589b386abf5e1be575
2019-01-17 16:27:05 +11:00
djm@openbsd.org eb347d086c upstream: ssh_packet_set_state() now frees ssh->kex implicitly, so
don't do explicit kex_free() beforehand

OpenBSD-Regress-ID: f2f73bad47f62a2040ccba0a72cadcb12eda49cf
2018-12-27 14:39:53 +11:00
tedu@openbsd.org bb542f0cf6 upstream: remove unused and problematic sudo clean. ok espie
OpenBSD-Regress-ID: ca90c20a15a85b661e13e98b80c10e65cd662f7b
2018-12-27 14:39:53 +11:00
dtucker@openbsd.org 4da58d5873 upstream: Remove now-unneeded ifdef SIGINFO around handler since it is
now always used for SIGUSR1 even when SIGINFO is not defined.  This will make
things simpler in -portable.

OpenBSD-Regress-ID: 4ff0265b335820b0646d37beb93f036ded0dc43f
2018-11-23 14:42:07 +11:00
Darren Tucker deb51552c3 Resync with OpenBSD by pulling in an ifdef SIGINFO. 2018-11-23 11:34:21 +11:00
Damien Miller 42c5ec4b97 refactor libcrypto initialisation
Don't call OpenSSL_add_all_algorithms() unless OpenSSL actually
supports it.

Move all libcrypto initialisation to a single function, and call that
from seed_rng() that is called early in each tool's main().

Prompted by patch from Rosen Penev
2018-11-23 10:42:05 +11:00
dtucker@openbsd.org 5b60b6c020 upstream: Output info on SIGUSR1 as well as
SIGINFO to resync with portable.  (ID sync only).

OpenBSD-Regress-ID: 699d153e2de22dce51a1b270c40a98472d1a1b16
2018-11-22 21:01:01 +11:00
dtucker@openbsd.org e4ae345dc7 upstream: Append pid to temp files in /var/run and set a cleanup
trap for them. This allows multiple instances of tests to run without
colliding.

OpenBSD-Regress-ID: 57add105ecdfc54752d8003acdd99eb68c3e0b4c
2018-11-22 20:58:27 +11:00
dtucker@openbsd.org f72d0f52ef upstream: UsePrivilegeSeparation no is deprecated
test "yes" and "sandbox".

OpenBSD-Regress-ID: 80e685ed8990766527dc629b1affc09a75bfe2da
2018-11-22 16:24:20 +11:00
djm@openbsd.org 35d0e5fefc upstream: add some knobs:
UNITTEST_FAST?= no     # Skip slow tests (e.g. less intensive fuzzing).
UNITTEST_SLOW?= no     # Include slower tests (e.g. more intensive fuzzing).
UNITTEST_VERBOSE?= no  # Verbose test output (inc. per-test names).

useful if you want to run the tests as a smoke test to exercise the
functionality without waiting for all the fuzzers to run.

OpenBSD-Regress-ID: e04d82ebec86068198cd903acf1c67563c57315e
2018-11-22 16:14:31 +11:00
Darren Tucker c1941293d9 Resync Makefile.inc with upstream.
It's unused in -portable, but having it out of sync makes other syncs
fail to apply.
2018-11-22 16:02:46 +11:00
Damien Miller 4488ae1a69 really add source for authopt_fuzz this time 2018-09-15 19:36:55 +10:00
Damien Miller 9201784b4a remove accidentally checked-in authopt_fuzz binary 2018-09-15 19:35:40 +10:00
Damien Miller 6bc5a24ac8 fuzzer harness for authorized_keys option parsing 2018-09-14 15:17:08 +10:00
Damien Miller 0aa1f23084 allow SIGUSR1 as synonym for SIGINFO
Lets users on those unfortunate operating systems that lack SIGINFO
still be able to obtain progress information from unit tests :)
2018-09-14 10:31:47 +10:00
Damien Miller d64e785265 add compat header 2018-09-13 19:05:48 +10:00
djm@openbsd.org a3fd8074e2 upstream: missed a bit of openssl-1.0.x API in this unittest
OpenBSD-Regress-ID: a73a54d7f7381856a3f3a2d25947bee7a9a5dbc9
2018-09-13 19:04:10 +10:00
djm@openbsd.org 86e0a9f3d2 upstream: use only openssl-1.1.x API here too
OpenBSD-Regress-ID: ae877064597c349954b1b443769723563cecbc8f
2018-09-13 15:08:27 +10:00
Damien Miller 86112951d6 forgot to stage these test files in commit d70d061 2018-09-13 12:12:42 +10:00
djm@openbsd.org d70d061828 upstream: Include certs with multiple RSA signature variants in
test data Ensure that cert->signature_key is populated correctly

OpenBSD-Regress-ID: 56e68f70fe46cb3a193ca207385bdb301fd6603a
2018-09-12 16:51:36 +10:00
djm@openbsd.org f803b26829 upstream: test revocation by explicit hash and by fingerprint
OpenBSD-Regress-ID: 079c18a9ab9663f4af419327c759fc1e2bc78fd8
2018-09-12 16:51:14 +10:00
djm@openbsd.org 2de78bc7da upstream: s/sshkey_demote/sshkey_from_private/g
OpenBSD-Regress-ID: 782bde7407d94a87aa8d1db7c23750e09d4443c4
2018-09-12 16:51:14 +10:00
Damien Miller 9617816dbe document some more regress control env variables
Specifically SKIP_UNIT, USE_VALGRING and LTESTS. Sort the list of
environment variables.

Based on patch from Jakub Jelen
2018-08-27 13:08:01 +10:00
Damien Miller 71508e06fa shorten temporary SSH_REGRESS_TMP path
Previous path was exceeding max socket length on at least one platform (OSX)
2018-08-23 15:41:42 +10:00
Damien Miller 829fc28a9c Missing unistd.h for regress/mkdtemp.c 2018-08-20 15:57:29 +10:00
dtucker@openbsd.org 2f4766ceef upstream: The script that cooks up PuTTY format host keys does not
understand the new key format so convert back to old format to create the
PuTTY key and remove it once done.

OpenBSD-Regress-ID: 2a449a18846c3a144bc645135b551ba6177e38d3
2018-08-10 11:40:21 +10:00
Darren Tucker 149cab325a Include stdarg.h in mkdtemp for va_list. 2018-07-27 13:46:06 +10:00
Damien Miller c59aca8adb Create control sockets in clean temp directories
Adds a regress/mkdtemp tool and uses it to create empty temp
directories for tests needing control sockets.

Patch from Colin Watson via bz#2660; ok dtucker
2018-07-20 14:55:29 +10:00
djm@openbsd.org 2f131e1b34 upstream: memleak in unittest; found by valgrind
OpenBSD-Regress-ID: 168c23b0fb09fc3d0b438628990d3fd9260a8a5e
2018-07-16 13:12:28 +10:00
djm@openbsd.org 7449c178e9 upstream: make this use ssh_proxy rather than starting/stopping a
daemon for each testcase

OpenBSD-Regress-ID: 608b7655ea65b1ba8fff5a13ce9caa60ef0c8166
2018-07-13 12:14:38 +10:00
djm@openbsd.org dbab02f920 upstream: fix leaks in unit test; with this, all unit tests are
leak free (as far as valgrind can spot anyway)

OpenBSD-Regress-ID: b824d8b27998365379963440e5d18b95ca03aa17
2018-07-13 12:14:38 +10:00
Damien Miller 2f6accff50 Enable leak checks for unit tests with valgrind
Leave the leak checking on unconditionally when running with valgrind.
The unit tests are leak-free and I want them to stay that way.
2018-07-13 11:41:33 +10:00
Damien Miller e46cfbd9db increase timeout to match cfgmatch.sh
lets test pass under valgrind (on my workstation at least)
2018-07-13 11:41:33 +10:00
Damien Miller fccfa239de VALGRIND_CHECK_LEAKS logic was backwards :( 2018-07-11 10:19:56 +10:00
Damien Miller d20720d373 disable valgrind memleak checking by default
Add VALGRIND_CHECK_LEAKS knob to turn it back on.
2018-07-11 09:57:44 +10:00
Damien Miller 120a1ec74e Adapt portable to legacy buffer API removal 2018-07-10 19:39:52 +10:00
djm@openbsd.org 314908f451 upstream: deal with API rename: match_filter_list() =>
match_filter_blacklist()

OpenBSD-Regress-ID: 2da342be913efeb51806351af906fab01ba4367f
2018-07-04 23:52:50 +10:00
djm@openbsd.org 89f54cdf6b upstream: exercise new expansion behaviour of
PubkeyAcceptedKeyTypes and, by proxy, test kex_assemble_names()

ok markus@

OpenBSD-Regress-ID: 292978902e14d5729aa87e492dd166c842f72736
2018-07-04 23:52:50 +10:00
djm@openbsd.org 187633f24c upstream: add a comment that could have saved me 45 minutes of wild
goose chasing

OpenBSD-Regress-ID: d469b29ffadd3402c090e21b792d627d46fa5297
2018-07-04 23:52:50 +10:00
djm@openbsd.org 303af5803b upstream: some magic for RSA-SHA2 checks
OpenBSD-Regress-ID: e5a9b11368ff6d86e7b25ad10ebe43359b471cd4
2018-07-04 00:07:12 +10:00
dtucker@openbsd.org 1eee79a11c upstream: One ampersand is enough to backgroud an process. OpenBSD
doesn't seem to mind, but some platforms in -portable object to the second.

OpenBSD-Regress-ID: d6c3e404871764343761dc25c3bbe29c2621ff74
2018-07-03 00:45:40 +10:00
djm@openbsd.org 80e199d617 upstream: test PermitListen with bare port numbers
OpenBSD-Regress-ID: 4b50a02dfb0ccaca08247f3877c444126ba901b3
2018-06-19 13:03:03 +10:00
djm@openbsd.org 57379dbd01 upstream: test the correct configuration option name
OpenBSD-Regress-ID: 492279ea9f65657f97a970e0e7c7fd0b339fee23
2018-06-08 00:31:38 +10:00
djm@openbsd.org 4319f7a868 upstream: permitlisten/PermitListen unit test from Markus
OpenBSD-Regress-ID: ab12eb42f0e14926980441cf7c058a6d1d832ea5
2018-06-07 14:48:39 +10:00
djm@openbsd.org 392db2bc83 upstream: regress test for PermitOpen
OpenBSD-Regress-ID: ce8b5f28fc039f09bb297fc4a92319e65982ddaf
2018-06-07 04:28:25 +10:00
djm@openbsd.org a1dcafc41c upstream: Adapt to extra default verboisity from ssh-keygen when
searching for and hashing known_hosts entries in a single operation
(ssh-keygen -HF ...) Patch from Anton Kremenetsky

OpenBSD-Regress-ID: 519585a4de35c4611285bd6a7272766c229b19dd
2018-06-01 14:24:08 +10:00
djm@openbsd.org 76f314c75d upstream: Add TEST_SSH_FAIL_FATAL variable, to force all failures
to instantly abort the test. Useful in capturing clean logs for individual
failure cases.

OpenBSD-Regress-ID: feba18cf338c2328b9601bd4093cabdd9baa3af1
2018-06-01 14:24:08 +10:00
dtucker@openbsd.org 065c8c055d upstream: Clean up comment.
OpenBSD-Regress-ID: 6adb35f384d447e7dcb9f170d4f0d546d3973e10
2018-06-01 14:23:22 +10:00
Damien Miller 54268d589e fix key-options.sh on platforms without openpty(3)
Skip the pty tests if the platform lacks openpty(3) and has to chown(2)
the pty device explicitly. This typically requires root permissions that
this test lacks.

bz#2856 ok dtucker@
2018-05-11 14:04:40 +10:00
djm@openbsd.org 907da2f885 upstream: more typos spotted by Karsten Weiss using codespell
OpenBSD-Regress-ID: d906a2aea0663810a658b7d0bc61a1d2907d4d69
2018-04-10 10:17:56 +10:00
djm@openbsd.org 37e5f4a7ab upstream: make this a bit more portable-friendly
OpenBSD-Regress-ID: 62f7b9e055e8dfaab92b3825f158beeb4ca3f963
2018-04-10 10:17:56 +10:00
dtucker@openbsd.org 323f66ce93 upstream: Add test for username options parsing order, prompted by
bz#2849.

OpenBSD-Regress-ID: 6985cd32f38596882a3ac172ff8c510693b65283
2018-04-06 14:19:51 +10:00
Damien Miller 4b7d8acdbb Remove authinfo.sh test dependency on printenv
Some platforms lack printenv in the default $PATH.
Reported by Tom G. Christensen
2018-03-26 09:38:44 +11:00
Darren Tucker 393436024d Replace /dev/stdin with "-".
For some reason sftp -b doesn't work with /dev/stdin on Cygwin, as noted
and suggested by vinschen at redhat.com.
2018-03-25 09:40:46 +11:00
Darren Tucker b5974de1a1 Provide $OBJ to paths in PuTTY interop tests. 2018-03-23 13:21:14 +11:00
dtucker@openbsd.org dc31e79454 upstream: Tell puttygen to use /dev/urandom instead of /dev/random. On
OpenBSD they are both non-blocking, but on many other -portable platforms it
blocks, stalling tests.

OpenBSD-Regress-ID: 397d0d4c719c353f24d79f5b14775e0cfdf0e1cc
2018-03-23 11:05:39 +11:00
Darren Tucker c6cb2565c9 Save $? before case statement.
In some shells (FreeBSD 9, ash) the case statement resets $?, so save
for later testing.
2018-03-22 17:00:28 +11:00
djm@openbsd.org 4c4e7f783b upstream: rename recently-added "valid-before" key restriction to
"expiry-time" as the former is confusing wrt similar terminology in X.509;
pointed out by jsing@

OpenBSD-Regress-ID: ac8b41dbfd90cffd525d58350c327195b0937793
2018-03-14 18:55:47 +11:00
djm@openbsd.org 500396b204 upstream: check valid-before option in authorized_keys
OpenBSD-Regress-ID: 7e1e4a84f7f099a290e5a4cbf4196f90ff2d7e11
2018-03-14 18:55:47 +11:00
djm@openbsd.org a76b5d26c2 upstream: explicitly specify RSA/SHA-2 keytype here too
OpenBSD-Regress-ID: 74d7b24e8c72c27af6b481198344eb077e993a62
2018-03-14 18:55:47 +11:00
djm@openbsd.org 3a43297ce2 upstream: exlicitly include RSA/SHA-2 keytypes in
PubkeyAcceptedKeyTypes here

OpenBSD-Regress-ID: 954d19e0032a74e31697fb1dc7e7d3d1b2d65fe9
2018-03-14 18:55:47 +11:00
djm@openbsd.org 7e4fadd324 upstream: for the pty control tests, just check that the PTY path
points to something in /dev (rather than checking the device node itself);
makes life easier for portable, where systems with dynamic ptys can delete
nodes before we get around to testing their existence.

OpenBSD-Regress-ID: b1e455b821e62572bccd98102f8dd9d09bb94994
2018-03-04 12:47:42 +11:00
djm@openbsd.org de1920d743 upstream: unit tests for new authorized_keys options API
OpenBSD-Regress-ID: 820f9ec9c6301f6ca330ad4052d85f0e67d0bdc1
2018-03-03 14:39:25 +11:00
djm@openbsd.org dc3e92df17 upstream: fix testing of pty option, include positive test and
testing of restrict keyword

OpenBSD-Regress-ID: 4268f27c2706a0a95e725d9518c5bcbec9814c6d
2018-03-03 14:38:26 +11:00
djm@openbsd.org 3d1edd1ebb upstream: better testing for port-forwarding and restrict flags in
authorized_keys

OpenBSD-Regress-ID: ee771df8955f2735df54746872c6228aff381daa
2018-03-03 14:38:26 +11:00
Damien Miller a8dd6fe0aa space before tab in previous 2018-02-23 14:19:55 +11:00
dtucker@openbsd.org b5e9263c77 upstream: Replace fatal with exit in the case that we do not have
$SUDO set. Prevents test failures when neither sudo nor doas are configured.

OpenBSD-Regress-ID: 6a0464decc4f8ac7d6eded556a032b0fc521bc7b
2018-02-23 14:18:25 +11:00
djm@openbsd.org 73282b6118 upstream: unbreak interop test after SSHv1 purge; patch from Colin
Watson via bz#2823

OpenBSD-Regress-ID: 807d30a597756ed6612bdf46dfebca74f49cb31a
2018-02-23 14:07:23 +11:00
dtucker@openbsd.org f8985dde5f upstream: Skip sftp-chroot test when SUDO not set instead of
fatal().

OpenBSD-Regress-ID: cd4b5f1109b0dc09af4e5ea7d4968c43fbcbde88
2018-02-23 14:07:23 +11:00
dtucker@openbsd.org df88551c02 upstream: Replace fatal with exit in the case that we do not have
$SUDO set. Prevents test failures when neither sudo nor doas are configured.

OpenBSD-Regress-ID: 6a0464decc4f8ac7d6eded556a032b0fc521bc7b
2018-02-23 14:05:33 +11:00
djm@openbsd.org 3b252c20b1 upstream: some helpers to check verbose/quiet mode
OpenBSD-Regress-ID: e736aac39e563f5360a0935080a71d5fdcb976de
2018-02-23 14:05:07 +11:00
Darren Tucker affa6ba67f Remove execute bit from modpipe.c. 2018-02-15 22:33:21 +11:00
Darren Tucker 265d88d4e6 Remove remaining now-obsolete cvs $Ids. 2018-02-15 20:06:19 +11:00
Darren Tucker aee49b2a89 Set SO_REUSEADDR in regression test netcat.
Sometimes multiplex tests fail on Solaris with "netcat: local_listen:
Address already in use" which is likely due to previous invocations
leaving the port in TIME_WAIT.  Set SO_REUSEADDR (in addition to
SO_REUSEPORT which is alread set on platforms that support it).  ok djm@
2018-02-08 12:42:12 +11:00
Damien Miller 4f29309c4c unbreak fuzz harness 2018-01-03 19:50:43 +11:00
djm@openbsd.org f6b50bf84d upstream commit
another libssh casualty

OpenBSD-Regress-ID: 839b970560246de23e7c50215095fb527a5a83ec
2018-01-03 16:46:49 +11:00
djm@openbsd.org 5fb4fb5a01 upstream commit
missed one (unbreak after ssh/lib removal)

OpenBSD-Regress-ID: cfdd132143131769e2d2455e7892b5d55854c322
2018-01-03 16:46:49 +11:00
djm@openbsd.org e6c4134165 upstream commit
unbreak unit tests after removal of src/usr.bin/ssh/lib

OpenBSD-Regress-ID: 3a79760494147b20761cbd2bd5c20e86c63dc8f9
2018-01-03 16:46:49 +11:00
djm@openbsd.org c5a6cbdb79 upstream commit
explicitly test all key types and their certificate
counterparts

refactor a little

OpenBSD-Regress-ID: e9ecd5580821b9ef8b7106919c6980d8e45ca8c4
2017-12-19 16:19:18 +11:00
dtucker@openbsd.org f689adb7a3 upstream commit
use cmp in a loop instead of diff -N to compare
directories. The former works on more platforms for Portable.

OpenBSD-Regress-ID: c3aa72807f9c488e8829a26ae50fe5bcc5b57099
2017-12-19 16:19:18 +11:00
djm@openbsd.org@openbsd.org f2ad63c071 upstream commit
whitespace at EOL

OpenBSD-Regress-ID: f4b5df99b28c6f63478deb916c6ed0e794685f07
2017-10-31 09:08:52 +11:00
djm@openbsd.org@openbsd.org c6415b1f8f upstream commit
whitespace at EOL

OpenBSD-Regress-ID: 19b1394393deee4c8a2114a3b7d18189f27a15cd
2017-10-31 09:08:51 +11:00
millert@openbsd.org@openbsd.org e4d4ddbbba upstream commit
Use printenv to test whether an SSH_USER_AUTH is set
instead of using $SSH_USER_AUTH.  The latter won't work with csh which treats
unknown variables as an error when expanding them.  OK markus@

OpenBSD-Regress-ID: f601e878dd8b71aa40381573dde3a8f567e6f2d1
2017-10-31 09:08:51 +11:00
millert@openbsd.org@openbsd.org 116b1b4394 upstream commit
Add tests for URI parsing.  OK markus@

OpenBSD-Regress-ID: 5d1df19874f3b916d1a2256a905526e17a98bd3b
2017-10-31 09:08:51 +11:00
Damien Miller d27bff293c Fix missed RCSID merges 2017-10-20 13:22:00 +11:00
djm@openbsd.org d3b6aeb546 upstream commit
more RCSIDs

Upstream-Regress-ID: 1aecbe3f8224793f0ec56741a86d619830eb33be
2017-10-20 13:15:40 +11:00
djm@openbsd.org a66714508b upstream commit
exercise PermitOpen a little more thoroughly

Upstream-Regress-ID: f41592334e227a4c1f9a983044522de4502d5eac
2017-10-05 05:51:46 +11:00
dtucker@openbsd.org 609ecc8e57 upstream commit
UsePrivilegeSeparation is gone, stop trying to test it.

Upstream-Regress-ID: 796a5057cfd79456a20ea935cc53f6eb80ace191
2017-10-05 05:51:46 +11:00
markus@openbsd.org 6a9481258a upstream commit
test reverse dynamic forwarding with SOCKS

Upstream-Regress-ID: 95cf290470f7e5e2f691e4bc6ba19b91eced2f79
2017-09-26 16:56:15 +10:00
Damien Miller 1b9f321605 sync missing changes in dynamic-forward.sh 2017-09-26 16:55:55 +10:00
bluhm@openbsd.org 09eacf856e upstream commit
Print SKIPPED if sudo and doas configuration is missing.
Prevents that running the regression test with wrong environment is reported
as failure.  Keep the fatal there to avoid interfering with other setups for
portable ssh. OK dtucker@

Upstream-Regress-ID: f0dc60023caef496ded341ac5aade2a606fa234e
2017-09-18 14:13:02 +10:00
dtucker@openbsd.org cdede10899 upstream commit
Remove obsolete privsep=no fallback test.

Upstream-Regress-ID: 7d6e1baa1678ac6be50c2a1555662eb1047638df
2017-09-18 14:11:42 +10:00
dtucker@openbsd.org ec218c105d upstream commit
Remove non-privsep test since disabling privsep is now
deprecated.

Upstream-Regress-ID: 77ad3f3d8d52e87f514a80f285c6c1229b108ce8
2017-09-18 14:11:22 +10:00
dtucker@openbsd.org 239c57d5bc upstream commit
Don't call fatal from stop_sshd since it calls cleanup
which calls stop_sshd which will probably fail in the same way.  Instead,
just bail. Differentiate between sshd dying without cleanup and not shutting
down.

Upstream-Regress-ID: f97315f538618b349e2b0bea02d6b0c9196c6bc4
2017-09-18 14:11:22 +10:00
Damien Miller ec9d22cc25 Fuzzer harnesses for sig verify and pubkey parsing
These are some basic clang libfuzzer harnesses for signature
verification and public key parsing. Some assembly (metaphorical)
required.
2017-09-08 12:44:13 +10:00
djm@openbsd.org c9cdef3552 upstream commit
regress test for ExposeAuthInfo

Upstream-Regress-ID: 190e5b6866376f4061c411ab157ca4d4e7ae86fd
2017-06-24 17:29:55 +10:00
djm@openbsd.org 1de5e47a85 upstream commit
unbreak after sshv1 purge

Upstream-Regress-ID: 8ea01a92d5f571b9fba88c1463a4254a7552d51b
2017-06-08 13:11:11 +10:00
Damien Miller 6bdf70f01e clean up regress files and add a .gitignore 2017-05-09 18:41:54 -07:00
djm@openbsd.org d757a4b633 upstream commit
fix for new SSH_ERR_KEY_LENGTH error value

Upstream-Regress-ID: c38a6e6174d4c3feca3518df150d4fbae0dca8dc
2017-05-08 16:11:26 +10:00
djm@openbsd.org effaf526bf upstream commit
remove arcfour, blowfish and CAST here too

Upstream-Regress-ID: c613b3bcbef75df1fe84ca4dc2d3ef253dc5e920
2017-05-08 11:54:17 +10:00
djm@openbsd.org dd369320d2 upstream commit
eliminate explicit specification of protocol in tests and
loops over protocol. We only support SSHv2 now.

Upstream-Regress-ID: 0082838a9b8a382b7ee9cbf0c1b9db727784fadd
2017-05-01 11:59:42 +10:00
djm@openbsd.org 557f921aad upstream commit
remove SSHv1 support from unit tests

Upstream-Regress-ID: 395ca2aa48f1f7d23eefff6cb849ea733ca8bbfe
2017-05-01 10:07:19 +10:00
Darren Tucker 9504ea6b27 Merge integrity.sh rev 1.22.
Merge missing bits from Colin Watson's patch in bz#2658 which make integrity
tests more robust against timeouts.  ok djm@
2017-04-28 14:33:43 +10:00
Darren Tucker 06ec837a34 Id sync for integrity.sh rev 1.21 which pulls in some shell portability fixes 2017-04-28 14:30:03 +10:00
jsg@openbsd.org e0194b471e upstream commit
Change COMPILER_VERSION tests which limited additional
warnings to gcc4 to instead skip them on gcc3 as clang can handle
-Wpointer-sign and -Wold-style-definition.

Upstream-Regress-ID: e48d7dc13e48d9334b8195ef884dfbc51316012f
2017-04-28 13:28:49 +10:00
djm@openbsd.org 096fb65084 upstream commit
remove /usr/bin/time calls around tests, makes diffing test
runs harder. Based on patch from Mike Frysinger

Upstream-Regress-ID: 81c1083b14dcf473b23d2817882f40b346ebc95c
2017-03-21 09:09:59 +11:00
Damien Miller 9165abfea3 create test mux socket in /tmp
Creating the socket in $OBJ could blow past the (quite limited)
path limit for Unix domain sockets. As a bandaid for bz#2660,
reported by Colin Watson; ok dtucker@
2017-03-20 10:12:18 +11:00
Darren Tucker 2fbf91684d Include includes.h for compat bits. 2017-03-16 14:05:46 +11:00
Darren Tucker b55f634e96 Wrap stdint.h in #ifdef HAVE_STDINT_H 2017-03-16 13:45:17 +11:00