blob: 63031116d4135a343e1c8bd344be9ddc7425f122 [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(
11 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 hashAlg, // IN: hash algorithm to use in the key
16 // 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
21 // iteration to be propagated across
22 // multiple routines
23#ifdef RSA_DEBUG //%
24 ,UINT16 primes, // IN: number of primes to test
25 UINT16 fieldSize // IN: the field size to use
26#endif //%
27 );
28
29#endif // __TPM2_RSAKEYSIEVE_FP_H