OpenDNSSEC-signer
1.4.1
Main Page
Data Structures
Files
File List
Globals
signer
src
signer
keys.h
Go to the documentation of this file.
1
/*
2
* $Id: keys.h 6215 2012-03-20 13:30:51Z matthijs $
3
*
4
* Copyright (c) 2009 NLNet Labs. All rights reserved.
5
*
6
* Redistribution and use in source and binary forms, with or without
7
* modification, are permitted provided that the following conditions
8
* are met:
9
* 1. Redistributions of source code must retain the above copyright
10
* notice, this list of conditions and the following disclaimer.
11
* 2. Redistributions in binary form must reproduce the above copyright
12
* notice, this list of conditions and the following disclaimer in the
13
* documentation and/or other materials provided with the distribution.
14
*
15
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
18
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
19
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
20
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
21
* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
23
* IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
24
* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
25
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
*
27
*/
28
34
#ifndef SIGNER_KEYS_H
35
#define SIGNER_KEYS_H
36
37
#include "
shared/allocator.h
"
38
#include "
shared/status.h
"
39
40
#ifdef HAVE_SYS_TYPES_H
41
# include <sys/types.h>
42
#endif
43
#ifdef HAVE_UNISTD_H
44
# include <unistd.h>
45
#endif
46
#include <ldns/ldns.h>
47
#include <libhsm.h>
48
#include <libhsmdns.h>
49
50
55
typedef
struct
key_struct
key_type
;
56
struct
key_struct
{
57
ldns_rr*
dnskey
;
58
hsm_key_t*
hsmkey
;
59
hsm_sign_params_t*
params
;
60
const
char
*
locator
;
61
uint8_t
algorithm
;
62
uint32_t
flags
;
63
int
publish
;
64
int
ksk
;
65
int
zsk
;
66
};
67
72
typedef
struct
keylist_struct
keylist_type
;
73
struct
keylist_struct
{
74
void
*
sc
;
75
key_type
*
keys
;
76
size_t
count
;
77
};
78
85
keylist_type
*
keylist_create
(
void
* sc);
86
94
key_type
*
keylist_lookup_by_locator
(
keylist_type
* kl,
const
char
* locator);
95
103
key_type
*
keylist_lookup_by_dnskey
(
keylist_type
* kl, ldns_rr* dnskey);
104
117
key_type
*
keylist_push
(
keylist_type
* kl,
const
char
* locator,
118
uint8_t algorithm, uint32_t flags,
int
publish,
int
ksk,
int
zsk);
119
126
void
keylist_print
(FILE* fd,
keylist_type
* kl);
127
134
void
keylist_log
(
keylist_type
* kl,
const
char
* name);
135
141
void
keylist_cleanup
(
keylist_type
* kl);
142
150
key_type
*
key_recover2
(FILE* fd,
keylist_type
* kl);
151
159
void
keylist_backup
(FILE* fd,
keylist_type
* kl,
const
char
* version);
160
161
#endif
/* SIGNER_KEYS_H */
Generated on Wed Jul 17 2013 07:14:23 for OpenDNSSEC-signer by
1.8.4