Commit 138f2043 authored by Dr. Stephen Henson's avatar Dr. Stephen Henson
Browse files

Camellia low level API algorithm blocking.

parent 7747c678
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -87,6 +87,11 @@ struct camellia_key_st

typedef struct camellia_key_st CAMELLIA_KEY;

#ifdef OPENSSL_FIPS
int private_Camellia_set_key(const unsigned char *userKey, const int bits,
	CAMELLIA_KEY *key);
#endif

int Camellia_set_key(const unsigned char *userKey, const int bits,
	CAMELLIA_KEY *key);

+13 −0
Original line number Diff line number Diff line
@@ -52,11 +52,24 @@
#include <openssl/opensslv.h>
#include <openssl/camellia.h>
#include "cmll_locl.h"
#include <openssl/crypto.h>
#ifdef OPENSSL_FIPS
#include <openssl/fips.h>
#endif

const char CAMELLIA_version[]="CAMELLIA" OPENSSL_VERSION_PTEXT;

int Camellia_set_key(const unsigned char *userKey, const int bits,
	CAMELLIA_KEY *key)
#ifdef OPENSSL_FIPS
	{
	if (FIPS_mode())
		FIPS_BAD_ABORT(CAMELLIA)
	private_Camellia_set_key(userKey, bits, key);
	}
int private_Camellia_set_key(const unsigned char *userKey, const int bits,
	CAMELLIA_KEY *key)
#endif
	{
	if (!userKey || !key)
		{
+1 −0
Original line number Diff line number Diff line
@@ -239,6 +239,7 @@ const EVP_CIPHER *EVP_##cname##_ecb(void) { return &cname##_ecb; }
#define CAST_set_key	private_CAST_set_key
#define RC5_32_set_key	private_RC5_32_set_key
#define BF_set_key	private_BF_set_key
#define Camellia_set_key private_Camellia_set_key
#define idea_set_encrypt_key private_idea_set_encrypt_key

#define MD5_Init	private_MD5_Init