enforcercommands.c
Go to the documentation of this file.
#include "config.h"
#include "file.h"
#include "str.h"
#include "locks.h"
#include "log.h"
#include "status.h"
#include "util.h"
#include "daemon/engine.h"
#include "cmdhandler.h"
#include "enforcercommands.h"
#include "db/db_connection.h"
/* commands to handle */
#include "policy/policy_resalt_cmd.h"
#include "policy/policy_list_cmd.h"
#include "daemon/help_cmd.h"
#include "daemon/time_leap_cmd.h"
#include "daemon/queue_cmd.h"
#include "daemon/verbosity_cmd.h"
#include "daemon/ctrl_cmd.h"
#include "enforcer/update_repositorylist_cmd.h"
#include "enforcer/repositorylist_cmd.h"
#include "enforcer/update_all_cmd.h"
#include "enforcer/update_conf_cmd.h"
#include "enforcer/enforce_cmd.h"
#include "policy/policy_import_cmd.h"
#include "policy/policy_export_cmd.h"
#include "policy/policy_purge_cmd.h"
#include "keystate/zone_list_cmd.h"
#include "keystate/zone_del_cmd.h"
#include "keystate/zone_add_cmd.h"
#include "keystate/keystate_ds_submit_cmd.h"
#include "keystate/keystate_ds_seen_cmd.h"
#include "keystate/keystate_ds_retract_cmd.h"
#include "keystate/keystate_ds_gone_cmd.h"
#include "keystate/keystate_export_cmd.h"
#include "keystate/keystate_import_cmd.h"
#include "keystate/keystate_list_cmd.h"
#include "keystate/key_purge_cmd.h"
#include "keystate/rollover_list_cmd.h"
#include "keystate/keystate_rollover_cmd.h"
#include "keystate/zonelist_import_cmd.h"
#include "keystate/zonelist_export_cmd.h"
#include "signconf/signconf_cmd.h"
#include "hsmkey/backup_hsmkeys_cmd.h"
#include "hsmkey/key_generate_cmd.h"
static char const * cmdh_str = "cmdhandler";
static struct cmd_func_block* enforcecommands[] = {
/* Thoughts has gone into the ordering of this list, it affects
* the output of the help command */
&update_conf_funcblock,
&update_repositorylist_funcblock,
&repositorylist_funcblock,
&update_all_funcblock,
&policy_list_funcblock,
&policy_export_funcblock,
&policy_import_funcblock,
&policy_purge_funcblock,
&resalt_funcblock,
&zone_list_funcblock,
&zone_add_funcblock,
&zone_del_funcblock,
&zonelist_export_funcblock,
&zonelist_import_funcblock,
&key_list_funcblock,
&key_export_funcblock,
&key_import_funcblock,
&key_ds_submit_funcblock,
&key_ds_seen_funcblock,
&key_ds_retract_funcblock,
&key_ds_gone_funcblock,
&key_generate_funcblock,
&key_purge_funcblock,
&key_rollover_funcblock,
&rollover_list_funcblock,
&backup_funcblock,
&enforce_funcblock,
&signconf_funcblock,
&queue_funcblock,
&time_leap_funcblock,
&flush_funcblock,
&ctrl_funcblock,
&verbosity_funcblock,
&help_funcblock,
NULL
};
struct cmd_func_block** enforcercommands = enforcecommands;
engine_type*
getglobalcontext(cmdhandler_ctx_type* context)
{
return (engine_type*) context->globalcontext;
}
db_connection_t*
getconnectioncontext(cmdhandler_ctx_type* context)
{
return (db_connection_t*) context->localcontext;
}
zone_list_funcblock
struct cmd_func_block zone_list_funcblock
Definition: zone_list_cmd.c:138
db_connection.h
keystate_ds_gone_cmd.h
verbosity_cmd.h
update_repositorylist_cmd.h
update_repositorylist_funcblock
struct cmd_func_block update_repositorylist_funcblock
Definition: update_repositorylist_cmd.c:142
signconf_cmd.h
zone_add_funcblock
struct cmd_func_block zone_add_funcblock
Definition: zone_add_cmd.c:411
enforce_funcblock
struct cmd_func_block enforce_funcblock
Definition: enforce_cmd.c:136
update_all_cmd.h
engine.h
key_ds_retract_funcblock
struct cmd_func_block key_ds_retract_funcblock
Definition: keystate_ds_retract_cmd.c:85
policy_import_funcblock
struct cmd_func_block policy_import_funcblock
Definition: policy_import_cmd.c:151
update_conf_funcblock
struct cmd_func_block update_conf_funcblock
Definition: update_conf_cmd.c:102
zone_add_cmd.h
repositorylist_cmd.h
key_purge_funcblock
struct cmd_func_block key_purge_funcblock
Definition: key_purge_cmd.c:142
enforcercommands
struct cmd_func_block ** enforcercommands
Definition: enforcercommands.c:99
verbosity_funcblock
struct cmd_func_block verbosity_funcblock
Definition: verbosity_cmd.c:116
policy_export_cmd.h
key_list_funcblock
struct cmd_func_block key_list_funcblock
Definition: keystate_list_cmd.c:434
key_ds_submit_funcblock
struct cmd_func_block key_ds_submit_funcblock
Definition: keystate_ds_submit_cmd.c:86
key_import_funcblock
struct cmd_func_block key_import_funcblock
Definition: keystate_import_cmd.c:588
help_funcblock
struct cmd_func_block help_funcblock
Definition: help_cmd.c:100
key_ds_gone_funcblock
struct cmd_func_block key_ds_gone_funcblock
Definition: keystate_ds_gone_cmd.c:87
zonelist_export_cmd.h
policy_list_cmd.h
zone_list_cmd.h
policy_list_funcblock
struct cmd_func_block policy_list_funcblock
Definition: policy_list_cmd.c:87
policy_import_cmd.h
repositorylist_funcblock
struct cmd_func_block repositorylist_funcblock
Definition: repositorylist_cmd.c:139
resalt_funcblock
struct cmd_func_block resalt_funcblock
Definition: policy_resalt_cmd.c:70
getglobalcontext
engine_type * getglobalcontext(cmdhandler_ctx_type *context)
Definition: enforcercommands.c:102
time_leap_cmd.h
policy_purge_funcblock
struct cmd_func_block policy_purge_funcblock
Definition: policy_purge_cmd.c:88
update_conf_cmd.h
key_generate_funcblock
struct cmd_func_block key_generate_funcblock
Definition: key_generate_cmd.c:161
zonelist_export_funcblock
struct cmd_func_block zonelist_export_funcblock
Definition: zonelist_export_cmd.c:90
getconnectioncontext
db_connection_t * getconnectioncontext(cmdhandler_ctx_type *context)
Definition: enforcercommands.c:108
key_export_funcblock
struct cmd_func_block key_export_funcblock
Definition: keystate_export_cmd.c:382
ctrl_funcblock
struct cmd_func_block ctrl_funcblock
Definition: ctrl_cmd.c:112
rollover_list_funcblock
struct cmd_func_block rollover_list_funcblock
Definition: rollover_list_cmd.c:215
time_leap_funcblock
struct cmd_func_block time_leap_funcblock
Definition: time_leap_cmd.c:209
keystate_export_cmd.h
update_all_funcblock
struct cmd_func_block update_all_funcblock
Definition: update_all_cmd.c:136
key_generate_cmd.h
key_purge_cmd.h
ctrl_cmd.h
keystate_import_cmd.h
signconf_funcblock
struct cmd_func_block signconf_funcblock
Definition: signconf_cmd.c:74
enforcercommands.h
backup_hsmkeys_cmd.h
policy_purge_cmd.h
zone_del_cmd.h
policy_resalt_cmd.h
zone_del_funcblock
struct cmd_func_block zone_del_funcblock
Definition: zone_del_cmd.c:314
keystate_rollover_cmd.h
key_rollover_funcblock
struct cmd_func_block key_rollover_funcblock
Definition: keystate_rollover_cmd.c:254
zonelist_import_funcblock
struct cmd_func_block zonelist_import_funcblock
Definition: zonelist_import_cmd.c:152
keystate_ds_seen_cmd.h
keystate_list_cmd.h
engine_struct
Definition: engine.h:47
zonelist_import_cmd.h
keystate_ds_submit_cmd.h
flush_funcblock
struct cmd_func_block flush_funcblock
Definition: queue_cmd.c:159
db_connection
Definition: db_connection.h:46
rollover_list_cmd.h
queue_cmd.h
keystate_ds_retract_cmd.h
enforce_cmd.h
key_ds_seen_funcblock
struct cmd_func_block key_ds_seen_funcblock
Definition: keystate_ds_seen_cmd.c:86
backup_funcblock
struct cmd_func_block backup_funcblock
Definition: backup_hsmkeys_cmd.c:259
queue_funcblock
struct cmd_func_block queue_funcblock
Definition: queue_cmd.c:124
policy_export_funcblock
struct cmd_func_block policy_export_funcblock
Definition: policy_export_cmd.c:151
help_cmd.h