add des alias for des-cbc
This commit is contained in:
parent
2c3bd2fa7a
commit
a517fbf50c
3 changed files with 8 additions and 3 deletions
|
@ -18,7 +18,7 @@ void ft_des_usage
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
ft_putstr("des cipher usage:\n\n");
|
ft_putstr("des cipher usage:\n\n");
|
||||||
ft_putstr("ft_ssl des-{mode} [flags]\n\n");
|
ft_putstr("ft_ssl des|des-{mode} [flags]\n\n");
|
||||||
ft_putstr("flags:\n");
|
ft_putstr("flags:\n");
|
||||||
ft_putstr(" -a\t\tdecode/encode the input/output in base64\n");
|
ft_putstr(" -a\t\tdecode/encode the input/output in base64\n");
|
||||||
ft_putstr(" -e\t\tecrypt mode\n");
|
ft_putstr(" -e\t\tecrypt mode\n");
|
||||||
|
@ -30,6 +30,7 @@ void ft_des_usage
|
||||||
ft_putstr(" -s salt\tsalt in hex format\n");
|
ft_putstr(" -s salt\tsalt in hex format\n");
|
||||||
ft_putstr(" -v vector\tinitialization vector in hex format\n\n");
|
ft_putstr(" -v vector\tinitialization vector in hex format\n\n");
|
||||||
ft_putstr("where {mode} is one of:\n");
|
ft_putstr("where {mode} is one of:\n");
|
||||||
ft_putstr("ecb\ncbc\npcbc\n");
|
ft_putstr("ecb\ncbc\npcbc\n\n");
|
||||||
|
ft_putstr("des cipher is an alias for des-cbc.\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,7 +19,7 @@ void ft_ssl_usage(void)
|
||||||
ft_putstr("Message Digest commands:\n");
|
ft_putstr("Message Digest commands:\n");
|
||||||
ft_putstr("md5\nsha256\nsha224\n\n");
|
ft_putstr("md5\nsha256\nsha224\n\n");
|
||||||
ft_putstr("Cipher commands:\n");
|
ft_putstr("Cipher commands:\n");
|
||||||
ft_putstr("base64\ndes-ecb\ndes-cbc\ndes-pcbc\n\n");
|
ft_putstr("base64\ndes\ndes-ecb\ndes-cbc\ndes-pcbc\n\n");
|
||||||
ft_putstr("To get help for specific command:\n");
|
ft_putstr("To get help for specific command:\n");
|
||||||
ft_putstr("ft_ssl command -h\n\n");
|
ft_putstr("ft_ssl command -h\n\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -34,6 +34,10 @@ t_algorithm g_algorithms[] = {
|
||||||
"base64",
|
"base64",
|
||||||
ft_base64,
|
ft_base64,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"des",
|
||||||
|
ft_des_cbc,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"des-ecb",
|
"des-ecb",
|
||||||
ft_des_ecb,
|
ft_des_ecb,
|
||||||
|
|
Loading…
Reference in a new issue