blob: a8ca1e24230c5200483b304120e1a0c41c0a6367 [file] [log] [blame]
Vadim Bendeburyc00055c2015-05-29 22:50:18 -07001/*
2 * Copyright 2015 The Chromium OS Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file.
5 */
6
7#ifndef __TPM2_RSAKEYSIEVE_FP_H
8#define __TPM2_RSAKEYSIEVE_FP_H
9
10LIB_EXPORT CRYPT_RESULT _cpri__GenerateKeyRSA(
Vadim Bendeburyf788ffb2015-06-05 12:57:27 -070011 TPM2B *n, // OUT: The public modulus
12 TPM2B *p, // OUT: One of the prime factors of n
13 UINT16 keySizeInBits, // IN: Size of the public modulus in bits
14 UINT32 e, // IN: The public exponent
15 TPM_ALG_ID
16 hashAlg, // IN: hash algorithm to use in the key generation process
17 TPM2B *seed, // IN: the seed to use
18 const char *label, // IN: A label for the generation process.
19 TPM2B *extra, // IN: Party 1 data for the KDF
20 UINT32 *counter // IN/OUT: Counter value to allow KDF iteration to be
21 // propagated across multiple routines
22#ifdef RSA_DEBUG
23 ,
24 UINT16 primes, // IN: number of primes to test
25 UINT16 fieldSize // IN: the field size to use
26#endif
27 );
Vadim Bendeburyc00055c2015-05-29 22:50:18 -070028
Vadim Bendeburyf788ffb2015-06-05 12:57:27 -070029#endif // __TPM2_RSAKEYSIEVE_FP_H