aboutsummaryrefslogtreecommitdiff
path: root/tests/client/torture_algorithms.c
AgeCommit message (Collapse)AuthorFilesLines
2023-03-28Remove zlib from the default compression methods and fips methodskhalid1-6/+16
Signed-off-by: Khalid Mamdouh <khalidmamdou7@gmail.com> Reviewed-by: Jakub Jelen <jjelen@redhat.com>
2020-10-14tests: Test MAC algorithm mismatch when AEAD cipher is selectedJakub Jelen1-0/+57
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
2020-04-06kex: Add support for diffie-hellman-group14-sha256Anderson Toshiyuki Sasaki1-0/+13
Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-12-23tests: use OpenSSH-provided ciphersAris Adamantiadis1-14/+14
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-06-13tests/torture_algorithms: Skip some tests in FIPS modeAnderson Toshiyuki Sasaki1-0/+120
When running in FIPS mode, skip the tests using algorithms not allowed. Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-04-29tests: Avoid reading user configuration when running algorithm testsJakub Jelen1-0/+5
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-02-22Add tests and implementation for Encrypt-then-MAC modeDirkjan Bussink1-0/+216
This adds the OpenSSH HMACs that do encrypt then mac. This is a more secure mode than the original HMAC. Newer AEAD ciphers like chacha20 and AES-GCM are already encrypt-then-mac, but this also adds it for older legacy clients that don't support those ciphers yet. Signed-off-by: Dirkjan Bussink <d.bussink@gmail.com> Reviewed-by: Jon Simons <jon@jonsimons.org> Reviewed-by: Jakub Jelen <jjelen@redhat.com>
2019-02-07Allow building without Group Exchange supportJakub Jelen1-0/+4
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-01-24tests: Add dh-group-exchange algorithm testsAris Adamantiadis1-0/+26
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2019-01-09tests: Do not run SSHD with PAM when not neededJakub Jelen1-1/+1
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Daiki Ueno <dueno@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-12-19crypto: Disable blowfish support by defaultAndreas Schneider1-0/+4
Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Jakub Jelen <jjelen@redhat.com>
2018-11-23tests: Drop duplicate log level setupJakub Jelen1-3/+0
Already done in the setup phase. Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-11-21tests: Add tests for dh-group14, group16 and group18Aris Adamantiadis1-0/+27
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-10-09tests: Add aes-gcm ciphers testsJakub Jelen1-0/+20
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-07-02tests: Use assert_ssh_return_code() in torture_algorithmsAndreas Schneider1-6/+6
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2018-06-29tests: add algorithm tests for kex curve25519Tilo Eckert1-0/+26
Signed-off-by: Tilo Eckert <tilo.eckert@flam.de> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-06-28tests: send more packets of various sizesAris Adamantiadis1-1/+18
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-06-28tests: test for chacha20-poly1305@openssh.comAris Adamantiadis1-0/+13
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2018-05-07tests: We should only init and finalize libssh onceAndreas Schneider1-4/+4
This should fix a segfault with gcrypt. Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2017-12-21tests/client/algorithms: Respect global verbosity settingsJakub Jelen1-0/+3
Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2017-12-15tests: Do not test blowfish ciphers with OpenSSH 7.6 and newerJakub Jelen1-0/+4
2017-10-29torture_algorithms: deduplicate kex method passesJon Simons1-90/+49
Summary: Signed-off-by: Jon Simons <jon@jonsimons.org> Test Plan: * Re-ran the `torture_algorithms` test. Reviewers: asn Tags: #libssh Differential Revision: https://bugs.libssh.org/D8
2017-10-28Fix config.h includesAndreas Schneider1-0/+2
We need stdlib.h and string.h in priv.h for free() and memset(). Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2017-08-24ecdh: enable ecdh_sha2_nistp{384,521} kex methodsJon Simons1-2/+46
Summary: Based on Dirkjan's original patch series here: * https://www.libssh.org/archive/libssh/2015-08/0000029.html Here the changes are adapted for the current master branch, and expanded to include libgcrypt support. Co-Authored-By: Dirkjan Bussink <d.bussink@gmail.com> Signed-off-by: Jon Simons <jon@jonsimons.org> Reviewed-by: Andreas Schneider <asn@cryptomilk.org> Test Plan: * Ran pkd tests for libcrypto and libgcrypt builds. * Ran client torture_algorithms.c tests for libcrypto and libgcrypt builds. * Tested across multiple libgcrypts ("1.6.3" and "1.7.6-beta"). Reviewers: aris, asn Tags: #libssh Differential Revision: https://bugs.libssh.org/D7
2016-02-03tests: Switch to user bob in setupAndreas Schneider1-0/+12
This makes sure we can apply options correctly. Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2016-01-14tests: Migrate torture_algorithms to a cwrap testAndreas Schneider1-105/+220
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2015-09-07tests: Migrate to new cmocka APIAndreas Schneider1-32/+36
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2015-02-02tests: allow conditionnal execution on patternAris Adamantiadis1-2/+2
Option can be used to filter out irrelevant tests usage: ./torture_pki '*ed25519' Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2014-04-22Add tests for SHA2 HMAC algorithmsDirkjan Bussink1-25/+111
BUG: https://red.libssh.org/issues/91 Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2012-10-07tests: Don't run ecdh tests if not supported by crypto lib.Andreas Schneider1-2/+2
2011-09-23build: Fix zlib support.Andreas Schneider1-6/+6
2011-09-23torture_algorithm: follow verbosityAris Adamantiadis1-0/+2
2011-08-30tests: Enable ecdh_sha2_nistp256 test only with openssl.Andreas Schneider1-0/+4
2011-08-22tests: Fix torture test with zlib support.Andreas Schneider1-9/+33
2011-06-12Test for ecdh and dh-group1Aris Adamantiadis1-0/+43
2011-01-03tests: Fixed a build warning introduced before.Andreas Schneider1-3/+2
2011-01-03tests: Call init and finalize in client torture tests.Andreas Schneider1-1/+8
2010-12-28tests: Migrated torture_algorithms to cmockery.Andreas Schneider1-119/+114
2010-12-27test: Added openssh checks to the compression tests.Andreas Schneider1-10/+16
2010-10-04Implemented zlib@openssh.com compressionAris Adamantiadis1-1/+22
2010-06-03tests: Move client tests to a seperate directory.Andreas Schneider1-0/+144
Tests which require a running sshd should go to tests/client.