Warning, file /include/nettle/arctwo.h was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035 #ifndef NETTLE_ARCTWO_H_INCLUDED
0036 #define NETTLE_ARCTWO_H_INCLUDED
0037
0038 #include "nettle-types.h"
0039
0040 #ifdef __cplusplus
0041 extern "C" {
0042 #endif
0043
0044
0045 #define arctwo_set_key nettle_arctwo_set_key
0046 #define arctwo_set_key_ekb nettle_arctwo_set_key_ekb
0047 #define arctwo_set_key_gutmann nettle_arctwo_set_key_gutmann
0048 #define arctwo40_set_key nettle_arctwo40_set_key
0049 #define arctwo64_set_key nettle_arctwo64_set_key
0050 #define arctwo128_set_key nettle_arctwo128_set_key
0051 #define arctwo128_set_key_gutmann nettle_arctwo128_set_key_gutmann
0052 #define arctwo_encrypt nettle_arctwo_encrypt
0053 #define arctwo_decrypt nettle_arctwo_decrypt
0054
0055 #define ARCTWO_BLOCK_SIZE 8
0056
0057
0058 #define ARCTWO_MIN_KEY_SIZE 1
0059 #define ARCTWO_MAX_KEY_SIZE 128
0060
0061 #define ARCTWO_KEY_SIZE 8
0062
0063 struct arctwo_ctx
0064 {
0065 uint16_t S[64];
0066 };
0067
0068
0069
0070 void
0071 arctwo_set_key_ekb (struct arctwo_ctx *ctx,
0072 size_t length, const uint8_t * key, unsigned ekb);
0073
0074
0075 void
0076 arctwo_set_key (struct arctwo_ctx *ctx, size_t length, const uint8_t *key);
0077 void
0078 arctwo40_set_key (struct arctwo_ctx *ctx, const uint8_t *key);
0079 void
0080 arctwo64_set_key (struct arctwo_ctx *ctx, const uint8_t *key);
0081 void
0082 arctwo128_set_key (struct arctwo_ctx *ctx, const uint8_t *key);
0083
0084
0085 void
0086 arctwo_set_key_gutmann (struct arctwo_ctx *ctx,
0087 size_t length, const uint8_t *key);
0088 void
0089 arctwo128_set_key_gutmann (struct arctwo_ctx *ctx,
0090 const uint8_t *key);
0091
0092 void
0093 arctwo_encrypt (struct arctwo_ctx *ctx,
0094 size_t length, uint8_t *dst, const uint8_t *src);
0095 void
0096 arctwo_decrypt (struct arctwo_ctx *ctx,
0097 size_t length, uint8_t *dst, const uint8_t *src);
0098
0099 #ifdef __cplusplus
0100 }
0101 #endif
0102
0103 #endif