Botan  2.1.0
Crypto and TLS for C++11
package.h
Go to the documentation of this file.
1 /*
2 * Rivest's Package Tranform
3 * (C) 2009 Jack Lloyd
4 *
5 * Botan is released under the Simplified BSD License (see license.txt)
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 (aont_package takes ownership)
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 uint8_t input[], size_t input_len,
28  uint8_t output[]);
29 
30 /**
31 * Rivest's Package Tranform (Inversion)
32 * @param cipher the block cipher to use (aont_package takes ownership)
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 uint8_t input[], size_t input_len,
40  uint8_t output[]);
41 
42 }
43 
44 #endif
void aont_package(RandomNumberGenerator &rng, BlockCipher *cipher, const uint8_t input[], size_t input_len, uint8_t output[])
Definition: package.cpp:16
Definition: alg_id.cpp:13
void aont_unpackage(BlockCipher *cipher, const uint8_t input[], size_t input_len, uint8_t output[])
Definition: package.cpp:69