use_existing_key command not found

[root@node71 tools]# pwd
/root/ob-loader-dumper-4.3.3.1-RELEASE/tools

[root@node71 tools]#
[root@node71 tools]# ./secure-gen -h
Usage: ./secure-gen [-n ][-i][-h]
Description:
-n: Specify a to-be-encrypted file of sensitive contents in plain-text, use -i to check out the format.
-i: Input sensitive contents in interactive mode.
-h: Display this message.

问题一:
./secure-gen -i 表示生成密钥?
./secure-gen -n <file_path> 表示使用密码?

问题二:
[root@node71 tools]# ./secure-gen -n ~/.loaddump/secure/
A pair of rsa keys already exist in /root/.loaddump/secure, would you like to use it? If not, a new pair will be generated and will overwrite the current keys (y/n): y
./secure-gen: line 74: use_existing_key: command not found

A pair of rsa keys already exist in /root/.loaddump/secure, would you like to use it? If not, a new pair will be generated and will overwrite the current keys (y/n): n
./secure-gen: line 74: use_existing_key: command not found

[root@node71 tools]#

此处提供两个临时解决方案,后续迭代会修复

1、可直接删除目录下生成的密钥文件,再重新生成,不会进入到此选项里,可规避此错误。

2、可自行修正脚本中的问题,在第73行处:

read -r -p "A pair of rsa keys already exist in $key_dir, would you like to use it? If not, a new pair will be generated and will overwrite the current keys (y/n): "

use_existing_key

本来是这样两行改成下面一行即可

read -r -p "A pair of rsa keys already exist in $key_dir, would you like to use it? If not, a new pair will be generated and will overwrite the current keys (y/n): " use_existing_key