allow choice of digest algorithm in certificate generation
[strongswan.git] / src / libstrongswan / credentials / builder.c
1 /*
2 * Copyright (C) 2008 Martin Willi
3 * Hochschule fuer Technik Rapperswil
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * for more details.
14 */
15
16 #include "builder.h"
17
18 ENUM(builder_part_names, BUILD_FROM_FILE, BUILD_END,
19 "BUILD_FROM_FILE",
20 "BUILD_FROM_FD",
21 "BUILD_AGENT_SOCKET",
22 "BUILD_BLOB_ASN1_DER",
23 "BUILD_BLOB_PEM",
24 "BUILD_BLOB_PGP",
25 "BUILD_BLOB_DNSKEY",
26 "BUILD_PASSPHRASE",
27 "BUILD_PASSPHRASE_CALLBACK",
28 "BUILD_KEY_SIZE",
29 "BUILD_SIGNING_KEY",
30 "BUILD_SIGNING_CERT",
31 "BUILD_PUBLIC_KEY",
32 "BUILD_SUBJECT",
33 "BUILD_SUBJECT_ALTNAME",
34 "BUILD_ISSUER",
35 "BUILD_ISSUER_ALTNAME",
36 "BUILD_NOT_BEFORE_TIME",
37 "BUILD_NOT_AFTER_TIME",
38 "BUILD_SERIAL",
39 "BUILD_DIGEST_ALG",
40 "BUILD_IETF_GROUP_ATTR",
41 "BUILD_CA_CERT",
42 "BUILD_CERT",
43 "BUILD_X509_FLAG",
44 "BUILD_SMARTCARD_KEYID",
45 "BUILD_SMARTCARD_PIN",
46 "BUILD_RSA_MODULUS",
47 "BUILD_RSA_PUB_EXP",
48 "BUILD_RSA_PRIV_EXP",
49 "BUILD_RSA_PRIME1",
50 "BUILD_RSA_PRIME2",
51 "BUILD_RSA_EXP1",
52 "BUILD_RSA_EXP2",
53 "BUILD_RSA_COEFF",
54 "BUILD_END",
55 );
56
57 /**
58 * See header.
59 */
60 void* builder_free(builder_t *this)
61 {
62 free(this);
63 return NULL;
64 }