2
* seccure - Copyright 2009 B. Poettering
4
* This program is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU General Public License as
6
* published by the Free Software Foundation; either version 2 of the
7
* License, or (at your option) any later version.
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12
* General Public License for more details.
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
21
* SECCURE Elliptic Curve Crypto Utility for Reliable Encryption
23
* http://point-at-infinity.org/seccure/
26
* seccure implements a selection of asymmetric algorithms based on
27
* elliptic curve cryptography (ECC). See the manpage or the project's
28
* homepage for further details.
30
* This code links against the GNU gcrypt library "libgcrypt" (which
31
* is part of the GnuPG project). Use the included Makefile to build
34
* Report bugs to: seccure AT point-at-infinity.org
38
#ifndef INC_SERIALIZE_H
39
#define INC_SERIALIZE_H
44
#define COMPACT_DIGITS_COUNT 90
45
extern const char compact_digits[];
47
#define BASE36_DIGIT_COUNT 36
48
extern const char base36_digits[];
50
int get_serialization_len(const gcry_mpi_t x, enum disp_format df);
51
void serialize_mpi(char *outbuf, int outlen, enum disp_format df,
53
int deserialize_mpi(gcry_mpi_t *x, enum disp_format ds, const char *buf,
56
#endif /* INC_SERIALIZE_H */