Mention that SHA2 is vulnerable to length extension attacks.

This commit is contained in:
Frank Denis 2014-06-30 20:30:49 -07:00
parent b555ed6cf0
commit 46181575fa
3 changed files with 21 additions and 0 deletions

View File

@ -1,6 +1,13 @@
#ifndef crypto_hash_H
#define crypto_hash_H
/*
* WARNING: Unless you absolutely need to use SHA512 for interoperatibility,
* purposes, you might want to consider crypto_generichash() instead.
* Unlike SHA512, crypto_generichash() is not vulnerable to length
* extension attacks.
*/
#include <stddef.h>
#include "crypto_hash_sha512.h"

View File

@ -1,6 +1,13 @@
#ifndef crypto_hash_sha256_H
#define crypto_hash_sha256_H
/*
* WARNING: Unless you absolutely need to use SHA256 for interoperatibility,
* purposes, you might want to consider crypto_generichash() instead.
* Unlike SHA256, crypto_generichash() is not vulnerable to length
* extension attacks.
*/
#include <stddef.h>
#include <stdint.h>
#include <stdlib.h>

View File

@ -1,6 +1,13 @@
#ifndef crypto_hash_sha512_H
#define crypto_hash_sha512_H
/*
* WARNING: Unless you absolutely need to use SHA512 for interoperatibility,
* purposes, you might want to consider crypto_generichash() instead.
* Unlike SHA512, crypto_generichash() is not vulnerable to length
* extension attacks.
*/
#include <stddef.h>
#include <stdint.h>
#include <stdlib.h>