aboutsummaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)AuthorFilesLines
2022-12-02Implementation of the MGM mode for magma/kuznyechikigrkir1-1/+1
first implemented in ossl_patched branch uses dynamic NIDs Signed-off-by: Sergei Ianovich <sergei.ianovich@ya.ru>
2022-08-11Add magma-ecb mode. Fixes #410Mark Fedorov1-1/+1
2021-12-20Output provider infoVitaly Chikunov1-0/+2
Output something in `openssl list -providers` so it's merrier. Signed-off-by: Vitaly Chikunov <vt@altlinux.org>
2021-10-11Making a gost provider - Add the macsRichard Levitte1-25/+185
We add the macs for the provider as wrappers around the EVP_MD implementations designed for ENGINEs. This is not the most elegant, but it does the job. When an algorithm has an OID, it's included in the OSSL_ALGORITHM name as an alias. This is the way to avoid having to register the OIDs in OpenSSL proper.
2021-10-11Making a gost provider - Add the digestsRichard Levitte1-109/+262
We add the digests for the provider as wrappers around the routines designed for ENGINEs. This is not the most elegant, but it does the job. When an algorithm has an OID, it's included in the OSSL_ALGORITHM name as an aliase. This is the way to avoid having to register the OIDs in OpenSSL proper. test/01-digest.t is modified to test the provider as well.
2021-10-11Making a gost provider - Add the ciphersRichard Levitte1-143/+207
We add the ciphers for the provider as wrappers around the routines designed for ENGINEs. This is not the most elegant, but it does the job. When an algorithm has an OID, it's included in the OSSL_ALGORITHM name as an aliase. This is the way to avoid having to register the OIDs in OpenSSL proper. test/03-encrypt.t is modified to test the provider as well.
2021-10-11Making a gost provider - Refactor the testing foundationRichard Levitte8-0/+78
This makes space for provider tests. As a beginning, test/00-provider.t is added. It corresponds to test/00-engine.t. All other test/*.t are currently skipped unless the engine is tested. They will be re-enabled as support for each algorithm type is added in the provider code.
2021-08-11[test] VKO unit tests for curves with cofactors: extreme rangesBilly Brumley1-5/+26
2021-05-02Make test programs less hard-codedRichard Levitte1-0/+7
The following programs had a hard coded load of the gost engine. This changes them to rely more on the testing environment, and to load engines through configuration files. This affects: test_ciphers.c, test_context.c, test_derive.c, test_digest.c, test_params.c, test_sign.c, test_tls.c
2021-02-16Remove the use of test/run_tests in favor of 'prove'Richard Levitte2-52/+67
'prove' is a well developed TAP harness program, there's no real need to write one's own. We do need to set certain paths properly for the appropriate 'openssl' program to be run. We do that with a 'prove' plugin (WrapOpenSSL.pm) that simply amends the appropriate system environment variables, given a number of cmake generated environment variables that indicate where OpenSSL files reside.
2021-02-06Adjust printing options as we print pubkey onlyDmitry Belyavskiy1-2/+2
2020-11-28Tests updated to support GOST2001DHDmitry Belyavskiy1-1/+1
2020-06-13Avoid some warningsDmitry Belyavskiy1-1/+1
2020-06-08GOST key agreement cofactor fix (#265)Billy Brumley1-4/+20
* GOST key agreement cofactor fix
2020-05-11Allow skipping perl testsDmitry Belyavskiy1-0/+2
2020-05-09magma-ctr-acpkm + magma-ctr-acpkm-omacDmitry Belyavskiy1-1/+1
2020-05-07[test] ECC: KATs for the curves in RFC4357 and RFC7836Billy Brumley1-26/+191
* Tests that gost-engine correctly computes the public key from the private key. (Twice -- Alice and Bob.) * Tests that gost-engine correctly computes the derived shared key. (Twice -- Alice and Bob, should be identical.)
2020-05-04Make engine test happierDmitry Belyavskiy1-1/+1
2019-08-28Merge pull request #166 from levitte/cleanup-testsDmitry Belyavskiy6-26/+0
Cleanup tests
2019-08-28test/*.t: Don't check OPENSSL_ENGINESRichard Levitte6-26/+0
It's set correctly when these tests are started with ctest, and otherwise, we leave it to the user to decide. Either way, we set it to a bogus value when it isn't previously set...
2019-08-27test/run_tests: when ctest is verbose, make TAP::Harness verbose tooRichard Levitte1-1/+3
2019-08-25test/run_tests: extend support for more operating systemsRichard Levitte1-0/+11
Not all systems recognise LD_LIBRARY_PATH, and we therefore need to set other environment variables. Currently set: - LD_LIBRARY_PATH (Linux and ELF HP-UX) - DYLD_LIBRARY_PATH (MacOS X) - LIBPATH (AIX, OS/2) More can be added as the need arises. Fixes #146
2019-08-24test/run_tests: Always set paths when OPENSSL_ROOT_DIR is definedRichard Levitte1-3/+31
When the environment variable OPENSSL_ROOT_DIR is defined, we need to ensure that PATH and LD_LIBRARY_PATH are properly affected. This is a little bit complicated, since OPENSSL_ROOT_DIR could point at an OpenSSL build directory as well as an OpenSSL installation tree. Fortunately, it's easy to detect the difference; if it's a build tree, there's a sub-directory 'apps'. For installation trees, it's further complicated by OpenSSL's 'multilib' target attribute, which exists for platforms that support directory separated libraries for differing bitness (typically 32-bit and 64-bit libraries). We trust pkg-config to give us the answer. Binaries are easier, they live in $OPENSL_ROOT_DIR/bin. Fixes #146
2019-02-16Migrate test framework to Test2Alexander Bokovoy5-70/+83
At least Fedora 30 will have no Test::More anymore. Test::More is deprecated, as well as Test::Stream and Test2 is a recommended replacement. Luckily, gost-engine's use of Test::More is limited to functions which are compatible with implementations in Test2, so only module import and test plan announcement need to change. Also, on Fedora 29 perl 5.28 is very picky on undefined variables.
2019-01-26run_tests: pass OPENSSL_ROOT_DIR into perl testsVitaly Chikunov1-0/+4
If OPENSSL_ROOT_DIR is specified pass it to the perl tests, and set its value as LD_LIBRARY_PATH, if unset. This allows to run tests for custom openssl build without manually setting proper env.
2018-09-06Make Travis more happyDmitry Belyavskiy1-1/+1
2018-07-26Add kuznyechik_ctracpkmVitaly Chikunov1-1/+1
2018-07-25test: Make perl tests report success or failureGleb Fotengauer-Malinovskiy1-1/+1
Co-authored-by: Mikhail Gordeev <obirvalger@altlinux.org>
2018-07-25Fix perl tests and library nameGleb Fotengauer-Malinovskiy1-1/+1
2018-06-27modernize ci:Ilya Shipitsin1-1/+5
(*) convert 'openssl ciphers | grep ...' into Test:More syntax (*) enable some tests on travis-ci (04 is yet broken)
2018-06-26fixed ciphersIlya Shipitsin1-1/+1
2018-06-26allow OPENSSL_ENGINES to be specified explicitlyIlya Shipitsin5-10/+20
2018-06-25Hopefully merge tests from object_db branchDmitry Belyavskiy7-0/+575