2008-05-26 19:13:21 +00:00
|
|
|
/* nessie_bc_test.h */
|
|
|
|
/*
|
|
|
|
This file is part of the Crypto-avr-lib/microcrypt-lib.
|
|
|
|
Copyright (C) 2008 Daniel Otte (daniel.otte@rub.de)
|
|
|
|
|
|
|
|
This program is free software: you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation, either version 3 of the License, or
|
|
|
|
(at your option) any later version.
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
2008-04-03 01:02:01 +00:00
|
|
|
#ifndef NESSIE_BC_TEST_H_
|
|
|
|
#define NESSIE_BC_TEST_H_
|
|
|
|
|
|
|
|
#include <stdint.h>
|
|
|
|
|
2008-04-07 02:21:24 +00:00
|
|
|
typedef void (*nessie_bc_gen_fpt)(uint8_t* key, uint16_t keysize_b, void* ctx);
|
2008-04-13 03:05:55 +00:00
|
|
|
typedef void (*nessie_bc_free_fpt)(void* ctx);
|
2008-04-07 02:21:24 +00:00
|
|
|
typedef void (*nessie_bc_enc_fpt)(void* buffer, void* ctx);
|
|
|
|
typedef void (*nessie_bc_dec_fpt)(void* buffer, void* ctx);
|
2008-04-05 17:57:46 +00:00
|
|
|
|
2008-04-07 02:21:24 +00:00
|
|
|
typedef struct nessie_bc_ctx_st{
|
|
|
|
uint16_t keysize_b;
|
2008-04-03 01:02:01 +00:00
|
|
|
uint16_t blocksize_B;
|
|
|
|
uint16_t ctx_size_B;
|
|
|
|
char* name;
|
2008-04-13 03:05:55 +00:00
|
|
|
nessie_bc_gen_fpt cipher_genctx;
|
|
|
|
nessie_bc_free_fpt cipher_free;
|
|
|
|
nessie_bc_enc_fpt cipher_enc;
|
|
|
|
nessie_bc_dec_fpt cipher_dec;
|
2008-04-07 02:21:24 +00:00
|
|
|
} nessie_bc_ctx_t;
|
2008-04-03 01:02:01 +00:00
|
|
|
|
|
|
|
|
2008-04-07 02:21:24 +00:00
|
|
|
extern nessie_bc_ctx_t nessie_bc_ctx;
|
2008-04-03 01:02:01 +00:00
|
|
|
|
2008-04-07 02:21:24 +00:00
|
|
|
void nessie_bc_run(void);
|
2008-04-13 03:05:55 +00:00
|
|
|
void nessie_bc_init(void);
|
|
|
|
|
2008-04-03 01:02:01 +00:00
|
|
|
|
|
|
|
#endif /*NESSIE_BC_TEST_H_*/
|