Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-5]: src/sys/crypto/rijndael $NetBSD$



details:   https://anonhg.NetBSD.org/src/rev/9f58f496defc
branches:  netbsd-1-5
changeset: 489642:9f58f496defc
user:      itojun <itojun%NetBSD.org@localhost>
date:      Mon Oct 02 17:19:16 2000 +0000

description:
$NetBSD$

diffstat:

 sys/crypto/rijndael/rijndael-alg-fst.h |  34 ++++++++++++++++++++++++++++++++++
 sys/crypto/rijndael/rijndael.h         |   4 ++++
 sys/crypto/rijndael/rijndael_local.h   |  11 +++++++++++
 3 files changed, 49 insertions(+), 0 deletions(-)

diffs (61 lines):

diff -r 61a759c9bca7 -r 9f58f496defc sys/crypto/rijndael/rijndael-alg-fst.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/crypto/rijndael/rijndael-alg-fst.h    Mon Oct 02 17:19:16 2000 +0000
@@ -0,0 +1,34 @@
+/*     $NetBSD: rijndael-alg-fst.h,v 1.2.2.2 2000/10/02 17:19:16 itojun Exp $  */
+/*     $KAME: rijndael-alg-fst.h,v 1.4 2000/10/02 17:14:26 itojun Exp $        */
+
+/*
+ * rijndael-alg-fst.h   v2.3   April '2000
+ *
+ * Optimised ANSI C code
+ *
+ * #define INTERMEDIATE_VALUE_KAT to generate the Intermediate Value Known Answer Test.
+ */
+
+#ifndef __RIJNDAEL_ALG_FST_H
+#define __RIJNDAEL_ALG_FST_H
+
+#define RIJNDAEL_MAXKC                 (256/32)
+#define RIJNDAEL_MAXROUNDS             14
+
+int rijndaelKeySched(u_int8_t k[RIJNDAEL_MAXKC][4], u_int8_t rk[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS);
+
+int rijndaelKeyEncToDec(u_int8_t W[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS);
+
+int rijndaelEncrypt(u_int8_t a[16], u_int8_t b[16], u_int8_t rk[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS);
+
+#ifdef INTERMEDIATE_VALUE_KAT
+int rijndaelEncryptRound(u_int8_t a[4][4], u_int8_t rk[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS, int rounds);
+#endif /* INTERMEDIATE_VALUE_KAT */
+
+int rijndaelDecrypt(u_int8_t a[16], u_int8_t b[16], u_int8_t rk[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS);
+
+#ifdef INTERMEDIATE_VALUE_KAT
+int rijndaelDecryptRound(u_int8_t a[4][4], u_int8_t rk[RIJNDAEL_MAXROUNDS+1][4][4], int ROUNDS, int rounds);
+#endif /* INTERMEDIATE_VALUE_KAT */
+
+#endif /* __RIJNDAEL_ALG_FST_H */
diff -r 61a759c9bca7 -r 9f58f496defc sys/crypto/rijndael/rijndael.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/crypto/rijndael/rijndael.h    Mon Oct 02 17:19:16 2000 +0000
@@ -0,0 +1,4 @@
+/*     $NetBSD: rijndael.h,v 1.2.2.2 2000/10/02 17:19:16 itojun Exp $  */
+/*     $KAME: rijndael.h,v 1.2 2000/10/02 17:14:27 itojun Exp $        */
+
+#include <crypto/rijndael/rijndael-api-fst.h>
diff -r 61a759c9bca7 -r 9f58f496defc sys/crypto/rijndael/rijndael_local.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/crypto/rijndael/rijndael_local.h      Mon Oct 02 17:19:16 2000 +0000
@@ -0,0 +1,11 @@
+/*     $NetBSD: rijndael_local.h,v 1.2.2.2 2000/10/02 17:19:16 itojun Exp $    */
+/*     $KAME: rijndael_local.h,v 1.3 2000/10/02 17:14:27 itojun Exp $  */
+
+/* the file should not be used from outside */
+typedef u_int8_t               BYTE;
+typedef u_int8_t               word8;  
+typedef u_int16_t              word16; 
+typedef u_int32_t              word32;
+
+#define MAXKC          RIJNDAEL_MAXKC
+#define MAXROUNDS      RIJNDAEL_MAXROUNDS



Home | Main Index | Thread Index | Old Index