Skip to content
Snippets Groups Projects
Commit 8a767263 authored by Matt Johnston's avatar Matt Johnston
Browse files

Cleaning up various unused bits (des_*, rijndael, MDS for twofish)

--HG--
branch : libtomcrypt
extra : convert_revision : 1ef3379fdde1e2cca49289fd2a1cd1c5bac514d7
parent a3f18d83
No related merge requests found
......@@ -38,6 +38,7 @@
#define ECB_TEST rijndael_test
#define ECB_KS rijndael_keysize
#if 0
const struct _cipher_descriptor rijndael_desc =
{
"rijndael",
......@@ -45,6 +46,7 @@ const struct _cipher_descriptor rijndael_desc =
16, 32, 16, 10,
SETUP, ECB_ENC, ECB_DEC, ECB_TEST, ECB_KS
};
#endif
const struct _cipher_descriptor aes_desc =
{
......
......@@ -16,6 +16,7 @@
#define EN0 0
#define DE1 1
#if 0
const struct _cipher_descriptor des_desc =
{
"des",
......@@ -27,6 +28,7 @@ const struct _cipher_descriptor des_desc =
&des_test,
&des_keysize
};
#endif
const struct _cipher_descriptor des3_desc =
{
......@@ -1510,6 +1512,7 @@ static void desfunc(ulong32 *block, const ulong32 *keys)
}
#endif
#if 0
int des_setup(const unsigned char *key, int keylen, int num_rounds, symmetric_key *skey)
{
_ARGCHK(key != NULL);
......@@ -1528,6 +1531,7 @@ int des_setup(const unsigned char *key, int keylen, int num_rounds, symmetric_ke
return CRYPT_OK;
}
#endif
int des3_setup(const unsigned char *key, int keylen, int num_rounds, symmetric_key *skey)
{
......@@ -1553,6 +1557,7 @@ int des3_setup(const unsigned char *key, int keylen, int num_rounds, symmetric_k
return CRYPT_OK;
}
#if 0
void des_ecb_encrypt(const unsigned char *pt, unsigned char *ct, symmetric_key *key)
{
ulong32 work[2];
......@@ -1578,6 +1583,7 @@ void des_ecb_decrypt(const unsigned char *ct, unsigned char *pt, symmetric_key *
STORE32H(work[0],pt+0);
STORE32H(work[1],pt+4);
}
#endif
void des3_ecb_encrypt(const unsigned char *pt, unsigned char *ct, symmetric_key *key)
{
......@@ -1610,6 +1616,7 @@ void des3_ecb_decrypt(const unsigned char *ct, unsigned char *pt, symmetric_key
STORE32H(work[1],pt+4);
}
#if 0
int des_test(void)
{
#ifndef LTC_TEST
......@@ -1752,6 +1759,7 @@ int des_test(void)
return CRYPT_OK;
#endif
}
#endif
int des3_test(void)
{
......@@ -1789,6 +1797,7 @@ int des3_test(void)
#endif
}
#if 0
int des_keysize(int *desired_keysize)
{
_ARGCHK(desired_keysize != NULL);
......@@ -1798,6 +1807,7 @@ int des_keysize(int *desired_keysize)
*desired_keysize = 8;
return CRYPT_OK;
}
#endif
int des3_keysize(int *desired_keysize)
{
......
......@@ -38,12 +38,14 @@ const struct _cipher_descriptor twofish_desc =
#define RS_POLY 0x14D
/* The 4x4 MDS Linear Transform */
#if 0
static const unsigned char MDS[4][4] = {
{ 0x01, 0xEF, 0x5B, 0x5B },
{ 0x5B, 0xEF, 0xEF, 0x01 },
{ 0xEF, 0x5B, 0x01, 0xEF },
{ 0xEF, 0x01, 0xEF, 0x5B }
};
#endif
/* The 4x8 RS Linear Transform */
static const unsigned char RS[4][8] = {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment