380
|
1 /* LibTomCrypt, modular cryptographic library -- Tom St Denis |
|
2 * |
|
3 * LibTomCrypt is a library that provides various cryptographic |
|
4 * algorithms in a highly modular and flexible manner. |
|
5 * |
|
6 * The library is free for all purposes without any express |
|
7 * guarantee it works. |
|
8 * |
|
9 * Tom St Denis, [email protected], http://libtomcrypt.com |
|
10 */ |
|
11 |
|
12 /* Implements ECC over Z/pZ for curve y^2 = x^3 - 3x + b |
|
13 * |
|
14 * All curves taken from NIST recommendation paper of July 1999 |
|
15 * Available at http://csrc.nist.gov/cryptval/dss.htm |
|
16 */ |
|
17 #include "tomcrypt.h" |
|
18 |
|
19 /** |
|
20 @file ecc_decrypt_key.c |
|
21 ECC Crypto, Tom St Denis |
|
22 */ |
|
23 |
|
24 #ifdef MECC |
|
25 |
|
26 /** |
|
27 Decrypt an ECC encrypted key |
|
28 @param in The ciphertext |
|
29 @param inlen The length of the ciphertext (octets) |
|
30 @param out [out] The plaintext |
|
31 @param outlen [in/out] The max size and resulting size of the plaintext |
|
32 @param key The corresponding private ECC key |
|
33 @return CRYPT_OK if successful |
|
34 */ |
|
35 int ecc_decrypt_key(const unsigned char *in, unsigned long inlen, |
|
36 unsigned char *out, unsigned long *outlen, |
|
37 ecc_key *key) |
|
38 { |
Matt Johnston <matt@ucc.asn.au>
parents:
diff
|