From b6b909bbab9227c138865700f3381236b9bd4b8a Mon Sep 17 00:00:00 2001 From: Richard T Bonhomme Date: Sun, 30 Oct 2022 19:31:24 +0000 Subject: [PATCH] Introduce global option '--notext|--no-text' Global option '--notext|--no-text': Disable the output of human readable text into certificate files, when signing a request file. Closes: #624 Signed-off-by: Richard T Bonhomme --- easyrsa3/easyrsa | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/easyrsa3/easyrsa b/easyrsa3/easyrsa index 6160e71..ae73b33 100755 --- a/easyrsa3/easyrsa +++ b/easyrsa3/easyrsa @@ -473,6 +473,7 @@ General options: Certificate & Request options: (these impact cert/req field values) +--no-text : Create certificates without human readable text --days=# : sets the signing validity to the specified number of days Also applies to renewal period. For details, see: 'help days' --fix-offset=# : Generate certificate with fixed start and end dates. @@ -1792,6 +1793,7 @@ $(display_dn req "$req_in") easyrsa_openssl ca -utf8 -in "$req_in" -out "$crt_out_tmp" \ -extfile "$ext_tmp" -days "$EASYRSA_CERT_EXPIRE" -batch \ ${EASYRSA_PASSIN:+-passin "$EASYRSA_PASSIN"} \ + ${EASYRSA_NO_TEXT:+-notext} \ ${EASYRSA_FIX_OFFSET+ -startdate "$start_fixdate"} \ ${EASYRSA_FIX_OFFSET+ -enddate "$end_fixdate"} \ || die "signing failed (openssl output above may have more detail)" @@ -5010,6 +5012,10 @@ while :; do --passout) export EASYRSA_PASSOUT="$val" ;; + --notext|--no-text) + empty_ok=1 + export EASYRSA_NO_TEXT=1 + ;; --subca-len) number_only=1 export EASYRSA_SUBCA_LEN="$val"