From 5ddb8fac3757a1a43445628d5df3ad216bc8cefe Mon Sep 17 00:00:00 2001 From: asterix Date: Tue, 5 Oct 2010 09:30:12 +0000 Subject: [PATCH] Some fix to compile run test check. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4405 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/sec/kdf/pbkdf1_test.c | 51 ++++++++++++++++++++++++++++++++---- 1 file changed, 46 insertions(+), 5 deletions(-) diff --git a/bertos/sec/kdf/pbkdf1_test.c b/bertos/sec/kdf/pbkdf1_test.c index 1e0f727d..6cbe7fbb 100644 --- a/bertos/sec/kdf/pbkdf1_test.c +++ b/bertos/sec/kdf/pbkdf1_test.c @@ -1,10 +1,51 @@ -#include -#include +/** + * \file + * + * + * \brief PBKDF1 testsuite + * \author Giovanni Bajo + * + */ + +#include "pbkdf1.h" + #include #include + +#include + #include #include -#include + +#include int PBKDF1_testSetup(void) { @@ -22,12 +63,12 @@ int PBKDF1_testRun(void) Kdf *kdf = PBKDF1_stackinit(SHA1_stackinit()); uint8_t res[16]; - + PBKDF1_set_iterations(kdf, 1000); kdf_begin(kdf, "password", 8, (const uint8_t*)"\x78\x57\x8E\x5A\x5D\x63\xCB\x06", 8); kdf_read(kdf, res, 16); ASSERT(memcmp(res, "\xDC\x19\x84\x7E\x05\xC6\x4D\x2F\xAF\x10\xEB\xFB\x4A\x3D\x2A\x20", 16) == 0); - + return 0; } -- 2.25.1