import-req: Check input file exists

Signed-off-by: Richard T Bonhomme <tincantech@protonmail.com>
This commit is contained in:
Richard T Bonhomme 2023-05-01 19:58:40 +01:00
parent 15299444a4
commit b8455ad392
No known key found for this signature in database
GPG Key ID: 2D767DB92FB6C246

View File

@ -3266,6 +3266,11 @@ import_req() {
Unable to import: incorrect command syntax.
Run easyrsa without commands for usage and command help."
# Request file must exist
[ -e "$in_req" ] || die "\
No request found for the input: '$2'
Expected to find the request at: $in_req"
verify_file req "$in_req" || die "\
The input file does not appear to be a certificate request. Aborting import.
File Path: $in_req"