Botan  1.10.9
package.h
Go to the documentation of this file.
1 /*
2 * Rivest's Package Tranform
3 * (C) 2009 Jack Lloyd
4 *
5 * Distributed under the terms of the Botan license
6 */
7 
8 #ifndef BOTAN_AONT_PACKAGE_TRANSFORM_H__
9 #define BOTAN_AONT_PACKAGE_TRANSFORM_H__
10 
11 #include <botan/block_cipher.h>
12 #include <botan/rng.h>
13 
14 namespace Botan {
15 
16 /**
17 * Rivest's Package Tranform
18 * @param rng the random number generator to use
19 * @param cipher the block cipher to use
20 * @param input the input data buffer
21 * @param input_len the length of the input data in bytes
22 * @param output the output data buffer (must be at least
23 * input_len + cipher->BLOCK_SIZE bytes long)
24 */
25 void BOTAN_DLL aont_package(RandomNumberGenerator& rng,
26  BlockCipher* cipher,
27  const byte input[], size_t input_len,
28  byte output[]);
29 
30 /**
31 * Rivest's Package Tranform (Inversion)
32 * @param cipher the block cipher to use
33 * @param input the input data buffer
34 * @param input_len the length of the input data in bytes
35 * @param output the output data buffer (must be at least
36 * input_len - cipher->BLOCK_SIZE bytes long)
37 */
38 void BOTAN_DLL aont_unpackage(BlockCipher* cipher,
39  const byte input[], size_t input_len,
40  byte output[]);
41 
42 }
43 
44 #endif
unsigned char byte
Definition: types.h:22
RandomNumberGenerator * rng
Definition: global_rng.cpp:165
void aont_package(RandomNumberGenerator &rng, BlockCipher *cipher, const byte input[], size_t input_len, byte output[])
Definition: package.cpp:17
void aont_unpackage(BlockCipher *cipher, const byte input[], size_t input_len, byte output[])
Definition: package.cpp:69