From 614ebd7f4c808b475c7df2a8da2417265e793b98 Mon Sep 17 00:00:00 2001 From: Paul Selkirk Date: Tue, 12 Feb 2019 16:24:42 -0500 Subject: Add CLI functions to manage the keywrap core, with new auto-zeroise functionality. --- projects/hsm/mgmt-misc.c | 31 ------------------------------- 1 file changed, 31 deletions(-) (limited to 'projects/hsm/mgmt-misc.c') diff --git a/projects/hsm/mgmt-misc.c b/projects/hsm/mgmt-misc.c index 72ee1f2..86f1be8 100644 --- a/projects/hsm/mgmt-misc.c +++ b/projects/hsm/mgmt-misc.c @@ -155,39 +155,8 @@ static int cmd_reboot(struct cli_def *cli, const char *command, char *argv[], in return CLI_OK; } -static int cmd_keywrap_core(struct cli_def *cli, const char *command, char *argv[], int argc) -{ - command = command; - - if (argc == 1) { - int onoff = -1; - if (strcmp(argv[0], "on") == 0) - onoff = 1; - else if (strcmp(argv[0], "off") == 0) - onoff = 0; - if (onoff >= 0) { - int ret = hal_aes_use_keywrap_core(onoff); - if (ret) - cli_print(cli, "keywrap core enabled"); - else if (onoff) - cli_print(cli, "keywrap core not found"); - else - cli_print(cli, "keywrap core disabled"); - return CLI_OK; - } - } - - cli_print(cli, "Syntax: keywrap core "); - return CLI_ERROR; -} - void configure_cli_misc(struct cli_def *cli) { - struct cli_command *c_keywrap = cli_register_command(cli, NULL, "keywrap", NULL, 0, 0, NULL); - - /* keywrap core */ - cli_register_command(cli, c_keywrap, "core", cmd_keywrap_core, 0, 0, "Toggle use of the keywrap core"); - #ifdef DO_PROFILING struct cli_command *c_profile = cli_register_command(cli, NULL, "profile", NULL, 0, 0, NULL); -- cgit v1.2.3