summaryrefslogtreecommitdiffstats
path: root/test/afalgtest.c
AgeCommit message (Collapse)Author
2018-12-06Following the license change, modify the boilerplates in test/Richard Levitte
Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7767)
2018-02-07Revert "Modify test/afalgtest to fail if the afalg engine couldn't be loaded"Richard Levitte
It turns out that even if you successfully build the engine, it might not load properly, so we cannot make the test program fail for it. See the message in commit 25b9d11c002e5c71840c2a6733c5009d78f2c9db This reverts commit 227a1e3f45bf06fdb00f2bdfb922f6f0d1f1d1de. Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5276)
2018-02-07Modify test/afalgtest to fail if the afalg engine couldn't be loadedRichard Levitte
If you know that there's no afalg engine, don't run this test. test/recipes/30-test_afalg.t checks this correctly. Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/5270)
2017-12-08fix --strict-warningsJitendraLulla
Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4717)
2017-12-08extending afalg with aes-cbc-192/256, afalgtest.c also updated accordingly. ↵JitendraLulla
comments from matt, Stephen considered fix indentation, remove printf from afalgtest.c Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4717)
2017-10-31afalg: Fix kernel version checkBaptiste Jonglez
The check should reject kernel versions < 4.1.0, not <= 4.1.0. The issue was spotted on OpenSUSE 42.1 Leap, since its linux/version.h header advertises 4.1.0. CLA: trivial Fixes: 7f458a48 ("ALG: Add AFALG engine") Signed-off-by: Baptiste Jonglez <git@bitsofnetworks.org> Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/4617)
2017-07-27Update the test framework so that the need for test_main is removed. EverythingPauli
that needed test_main now works using the same infrastructure as tests that used register_tests. This meant: * renaming register_tests to setup_tests and giving it a success/failure return. * renaming the init_test function to setup_test_framework. * renaming the finish_test function to pulldown_test_framework. * adding a user provided global_init function that runs before the test frame work is initialised. It returns a failure indication that stops the stest. * adding helper functions that permit tests to access their command line args. * spliting the BIO initialisation and finalisation out from the test setup and teardown. * hiding some of the now test internal functions. * fix the comments in testutil.h Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3953)
2017-04-16[squash]Build works with/out NO_ENGINE and NO_AFALGRich Salz
Reviewed-by: Andy Polyakov <appro@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3229)
2017-04-16Convert afalgtestRich Salz
Reviewed-by: Andy Polyakov <appro@openssl.org> (Merged from https://github.com/openssl/openssl/pull/3229)
2016-06-13Handle inability to create AFALG socketMatt Caswell
Some Linux platforms have a suitably recent kernel to support AFALG, but apparently you still can't actually create an afalg socket. This extends the afalg_chk_platform() function to additionally check whether we can create an AFALG socket. We also amend the afalgtest to not report a failure to load the engine as a test failure. A failure to load is almost certainly due to platform environmental issues, and not an OpenSSL problem. RT 4434 Reviewed-by: Andy Polyakov <appro@openssl.org>
2016-05-17Copyright consolidation 02/10Rich Salz
Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-04-14Fix AFALG kernel and headers mismatch problemMatt Caswell
During Configure we attempt to check the kernel version of this platform to see whether we can compile the AFALG engine. If the kernel version looks recent enough then we enable AFALG. However when we compile e_afalg.c we check the version of the linux headers. If there is a mismatch between the linux headers and the currently running kernel then we don't compile the AFLAG engine and continue. This was causing a link error. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-14Disable afalg when engine is disabled.Emilia Kasper
Also make it possible to disable afalg separately. we still need to update config again Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-10No need to call EVP_CIPHER_CTX_init after EVP_CIPHER_CTX_newMatt Caswell
The afalgtest was unnecessarily initing an EVP_CIPHER_CTX. It is not needed and is deprecated. Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-07Fix some clang warningsMatt Caswell
The af_alg engine and associated test were creating warnings when compiled with clang. This fixes it. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-07Fix minor errors in the afalg testMatt Caswell
The new afalg test should have a copyright date of 2016. Also an incorrect buffer was being sent to EVP_CipherFinal_ex when decrypting. Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-03-07Adding afalg testclucey
Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org>