OpenDNSSEC-signer 1.2.1
|
#include "signer/backup.h"
#include "signer/se_key.h"
#include "util/file.h"
#include "util/log.h"
#include "util/se_malloc.h"
Go to the source code of this file.
Functions | |
key_type * | key_create (const char *locator, uint8_t algorithm, uint32_t flags, int publish, int ksk, int zsk) |
key_type * | key_recover_from_backup (FILE *fd) |
void | key_cleanup (key_type *key) |
void | key_print (FILE *out, key_type *key) |
keylist_type * | keylist_create (void) |
int | keylist_add (keylist_type *kl, key_type *key) |
int | key_compare (key_type *a, key_type *b) |
int | keylist_delete (keylist_type *kl, key_type *key) |
key_type * | keylist_lookup (keylist_type *list, const char *locator) |
int | keylist_compare (keylist_type *a, keylist_type *b) |
void | keylist_cleanup (keylist_type *kl) |
void | keylist_print (FILE *out, keylist_type *kl) |
void key_cleanup | ( | key_type * | key | ) |
Clean up key.
Definition at line 128 of file se_key.c.
References key_struct::dnskey, key_struct::hsmkey, key_cleanup(), key_struct::locator, key_struct::next, key_struct::params, se_free(), and se_log_warning().
Referenced by key_cleanup(), and keylist_cleanup().
Compare two key references.
Definition at line 237 of file se_key.c.
References key_struct::locator, se_log_assert, and se_strcmp().
Referenced by keylist_compare(), and keylist_delete().
key_type* key_create | ( | const char * | locator, |
uint8_t | algorithm, | ||
uint32_t | flags, | ||
int | publish, | ||
int | ksk, | ||
int | zsk | ||
) |
Signing keys. Create a new key.
Definition at line 46 of file se_key.c.
References key_struct::algorithm, key_struct::dnskey, key_struct::flags, key_struct::hsmkey, key_struct::ksk, key_struct::locator, key_struct::next, key_struct::params, key_struct::publish, se_log_assert, se_malloc(), se_strdup(), and key_struct::zsk.
Referenced by parse_sc_keys().
void key_print | ( | FILE * | out, |
key_type * | key | ||
) |
Print key.
Definition at line 163 of file se_key.c.
References key_struct::algorithm, key_struct::flags, key_struct::ksk, key_struct::locator, key_struct::publish, se_log_assert, and key_struct::zsk.
Referenced by keylist_print().
key_type* key_recover_from_backup | ( | FILE * | fd | ) |
Recover a key from backup.
Definition at line 74 of file se_key.c.
References key_struct::algorithm, backup_read_check_str(), backup_read_int(), backup_read_str(), backup_read_uint32_t(), backup_read_uint8_t(), key_struct::dnskey, key_struct::flags, key_struct::hsmkey, key_struct::ksk, key_struct::locator, key_struct::next, key_struct::params, key_struct::publish, se_free(), se_log_assert, se_log_error(), se_malloc(), and key_struct::zsk.
int keylist_add | ( | keylist_type * | kl, |
key_type * | key | ||
) |
Add a key to the keylist.
Definition at line 210 of file se_key.c.
References keylist_struct::count, keylist_struct::first_key, key_struct::locator, key_struct::next, se_log_assert, and se_log_debug().
Referenced by parse_sc_keys().
void keylist_cleanup | ( | keylist_type * | kl | ) |
Clean up key list.
Definition at line 376 of file se_key.c.
References keylist_struct::first_key, key_cleanup(), se_free(), se_log_debug(), and se_log_warning().
Referenced by signconf_cleanup().
int keylist_compare | ( | keylist_type * | a, |
keylist_type * | b | ||
) |
Compare two key lists.
Definition at line 314 of file se_key.c.
References key_struct::algorithm, keylist_struct::count, keylist_struct::first_key, key_struct::flags, key_compare(), key_struct::ksk, key_struct::next, key_struct::publish, se_log_assert, se_log_warning(), and key_struct::zsk.
Referenced by signconf_compare().
keylist_type* keylist_create | ( | void | ) |
Create a new key list.
Definition at line 194 of file se_key.c.
References keylist_struct::count, keylist_struct::first_key, se_log_debug(), and se_malloc().
Referenced by parse_sc_keys(), and zone_recover_from_backup().
int keylist_delete | ( | keylist_type * | kl, |
key_type * | key | ||
) |
Delete a key from the keylist.
Definition at line 250 of file se_key.c.
References keylist_struct::count, keylist_struct::first_key, key_compare(), key_struct::locator, key_struct::next, se_log_assert, se_log_debug(), and se_log_error().
key_type* keylist_lookup | ( | keylist_type * | list, |
const char * | locator | ||
) |
Lookup a key in the key list by locator.
Definition at line 285 of file se_key.c.
References keylist_struct::count, keylist_struct::first_key, key_struct::locator, key_struct::next, and se_strcmp().
void keylist_print | ( | FILE * | out, |
keylist_type * | kl | ||
) |
Print key list.
Definition at line 395 of file se_key.c.
References keylist_struct::first_key, key_print(), key_struct::next, and se_log_assert.
Referenced by signconf_print().