The introduced SHA1_NOFINAL hasher was not sufficient for EAP-AKA,

as it requires to XOR the key into the hashers state.
A new SHA1 based keyed hash function, implemented as PRF, enables EAP-AKA
and the FIPS-PRF function to properly use the existing SHA1 implementation.
This commit is contained in:
Martin Willi
2008-03-19 14:02:52 +00:00
parent c912c3d382
commit cfede7f6e2
10 changed files with 188 additions and 114 deletions
+4 -2
View File
@@ -40,6 +40,8 @@ static void destroy(private_sha1_plugin_t *this)
{
lib->crypto->remove_hasher(lib->crypto,
(hasher_constructor_t)sha1_hasher_create);
lib->crypto->remove_prf(lib->crypto,
(prf_constructor_t)sha1_keyed_prf_create);
free(this);
}
@@ -54,8 +56,8 @@ plugin_t *plugin_create()
lib->crypto->add_hasher(lib->crypto, HASH_SHA1,
(hasher_constructor_t)sha1_hasher_create);
lib->crypto->add_hasher(lib->crypto, HASH_SHA1_NOFINAL,
(hasher_constructor_t)sha1_hasher_create);
lib->crypto->add_prf(lib->crypto, PRF_KEYED_SHA1,
(prf_constructor_t)sha1_keyed_prf_create);
return &this->public.plugin;
}