keystate_ds.c File Reference
`#include "config.h"`
`#include <sys/stat.h>`
`#include <getopt.h>`
`#include "cmdhandler.h"`
`#include "daemon/engine.h"`
`#include "enforcer/enforce_task.h"`
`#include "file.h"`
`#include "log.h"`
`#include "str.h"`
`#include "clientpipe.h"`
`#include "longgetopt.h"`
`#include "duration.h"`
`#include "db/key_data.h"`
`#include "db/zone_db.h"`
`#include "db/db_error.h"`
`#include "db/hsm_key.h"`
`#include "libhsm.h"`
`#include "libhsmdns.h"`
`#include "keystate/keystate_ds.h"`

Go to the source code of this file.

## Functions

int | change_keys_from_to (db_connection_t *dbconn, int sockfd, const char *zonename, const hsm_key_t *hsmkey, int keytag, key_data_ds_at_parent_t state_from, key_data_ds_at_parent_t state_to, engine_type *engine)
int | run_ds_cmd (cmdhandler_ctx_type *context, int argc, char *argv[], db_connection_t *dbconn, key_data_ds_at_parent_t state_from, key_data_ds_at_parent_t state_to, engine_type *engine)

## Function Documentation

## change_keys_from_to()

int change_keys_from_to | ( | db_connection_t * | dbconn,
|  | int | sockfd,
|  | const char * | zonename,
|  | const hsm_key_t * | hsmkey,
|  | int | keytag,
|  | key_data_ds_at_parent_t | state_from,
|  | key_data_ds_at_parent_t | state_to,
|  | engine_type * | engine
| ) |  |

Definition at line 346 of file keystate_ds.c.

References db_clause_list_free(), db_clause_list_new(), DB_CLAUSE_NOT_EQUAL, db_clause_set_type(), DB_OK, enforce_task_flush_zone(), key_data_ds_at_parent_clause(), KEY_DATA_DS_AT_PARENT_RETRACT, KEY_DATA_DS_AT_PARENT_RETRACTED, KEY_DATA_DS_AT_PARENT_SUBMIT, KEY_DATA_DS_AT_PARENT_SUBMITTED, key_data_free(), key_data_list_free(), key_data_list_get_by_clauses(), key_data_list_get_next(), key_data_list_new(), key_data_list_new_get_by_clauses(), key_data_role_clause(), KEY_DATA_ROLE_ZSK, key_data_set_ds_at_parent(), key_data_update(), zone_db::next_change, zone_db_ext_zonename_from_id(), zone_db_free(), zone_db_new_get_by_name(), zone_db_update(), and key_data::zone_id.

Referenced by run_ds_cmd().

## run_ds_cmd()

int run_ds_cmd | ( | cmdhandler_ctx_type * | context,
|  | int | argc,
|  | char * | argv[],
|  | db_connection_t * | dbconn,
|  | key_data_ds_at_parent_t | state_from,
|  | key_data_ds_at_parent_t | state_to,
|  | engine_type * | engine
| ) |  |

Definition at line 434 of file keystate_ds.c.

References change_keys_from_to(), hsm_key_free(), hsm_key_new_get_by_locator(), zone_db_free(), zone_db_get_by_name(), and zone_db_new().