Add hashcat command lines
[pwdhash.git] / cencode.h
1 /**
2 * @file
3 * @author devolve <http://sourceforge.net/projects/libb64>
4 * @version 1.0
5 *
6 * @section LICENSE
7 *
8 * Public domain
9 *
10 * @section DESCRIPTION
11 *
12 * This is part of the libb64 project, and has been placed in the public domain.
13 * For details, see http://sourceforge.net/projects/libb64
14 *
15 * The cencode source provides support for base64 encoding data. It can be
16 * used in conjunction with the cdecode source. It's used by base64, which
17 * provides a higher-level interface to the functionality.
18 *
19 */
20
21 #ifndef BASE64_CENCODE_H
22 #define BASE64_CENCODE_H
23
24 typedef enum
25 {
26 step_A, step_B, step_C
27 } base64_encodestep;
28
29 typedef struct
30 {
31 base64_encodestep step;
32 char result;
33 int stepcount;
34 } base64_encodestate;
35
36 void base64_init_encodestate(base64_encodestate* state_in);
37
38 char base64_encode_value(char value_in);
39
40 int base64_encode_block(const char* plaintext_in, int length_in, char* code_out, base64_encodestate* state_in);
41
42 int base64_encode_blockend(char* code_out, base64_encodestate* state_in);
43
44 #endif /* BASE64_CENCODE_H */
45