]> git.saurik.com Git - apple/security.git/blob - OSX/libsecurity_cryptkit/lib/CurveParamDocs/tools.h
Security-57337.20.44.tar.gz
[apple/security.git] / OSX / libsecurity_cryptkit / lib / CurveParamDocs / tools.h
1 /**************************************************************
2 *
3 * tools.h
4 *
5 * Header file for tools.c.
6 *
7 * Updates:
8 * 30 Apr 99 REC Modified init_tools type to void.
9 * 3 Apr 98 REC Creation
10 *
11 *
12 * c. 1998 Perfectly Scientific, Inc.
13 * All Rights Reserved.
14 *
15 *
16 *************************************************************/
17
18 #define NUM_PRIMES 6542 /* PrimePi[2^16]. */
19 #define MILLER_RABIN_DEPTH (8)
20
21 void
22 init_tools(int shorts);
23
24 void
25 make_primes();
26
27 int
28 prime_literal(
29 unsigned int p
30 );
31
32 int
33 primeq(
34 unsigned int odd
35 );
36
37 void
38 make_primes();
39
40 int
41 prime_probable(giant p);
42
43 int
44 jacobi_symbol(giant a, giant n);
45
46 int
47 pseudoq(giant a, giant p);
48
49 int
50 pseudointq(int a, giant p);
51
52
53 void
54 powFp2(giant a, giant b, giant w2, giant n, giant p);
55
56 int
57 sqrtmod(giant p, giant x);
58
59 void
60 sqrtg(giant n);
61
62 int
63 cornacchia4(giant n, int d, giant u, giant v);
64
65