@@ -21,16 +21,16 @@ NOTE: Global options MUST be provided before the command.
2121Global options:
2222
2323--version : Prints EasyRSA version and build information
24- --verbose|-v : Enable verbose output
2524--batch|-b : Set automatic (no-prompts when possible) mode
2625--silent|-s : Disable all warnings, notices and information
2726--silent-ssl|-S : Silence SSL output (Requires batch mode)
27+ --verbose|-v : Enable verbose output
2828
29- --nopass|no-pass : Do not use passwords
29+ --nopass : Do not use passwords
3030 Can NOT be used with --passin or --passout
3131--passin=ARG : Set -passin ARG for openssl (eg: pass:xEasyRSAy)
3232--passout=ARG : Set -passout ARG for openssl (eg: pass:xEasyRSAy)
33- --rawca|raw-ca : Build CA with password via RAW SSL input
33+ --rawca : Build CA with password via RAW SSL input
3434
3535--pki=DIR : Declare the PKI directory
3636 (Default PKI directory is sub-directory 'pki')
@@ -39,14 +39,14 @@ Global options:
3939 (Default vars file is in the current working PKI)
4040
4141--umask=ARG : Define a UMASK (Default 077)
42- --no-umask : Do not use a UMASK, fall back to file system default.
42+ --noumask : Do not use a UMASK, fall back to file system default.
4343--ssl-cnf=FILE : Define a specific OpenSSL config file for Easy-RSA to use
4444 (Default config file is in the EasyRSA PKI directory)
4545--force-safe-ssl: Always generate a safe SSL config file
4646 (Default: Generate Safe SSL config once per instance)
4747--force-vars : Ignore known errors in 'vars' file
48- --no-lockfile : Disable lock-file (Useful for read-only PKI)
49- --no-inline : Disable inline file creation
48+ --nolockfile : Disable lock-file (Useful for read-only PKI)
49+ --noinline : Disable inline file creation
5050--tmp-dir=DIR : Declare the temporary directory
5151 (Default temporary directory is the EasyRSA PKI directory)
5252--keep-tmp=NAME : Keep the original temporary session by name: NAME
@@ -56,15 +56,15 @@ Global options:
5656Certificate & Request options: (these impact cert/req field values)
5757
5858--text : Create certificate requests with human readable text
59- --notext|no-text : Create certificates without human readable text
59+ --notext : Create certificates without human readable text
6060--days=# : Sets the signing validity to the specified number of days
6161 Applies to other commands. For details, see: 'help days'
6262--startdate=DATE: Sets the SSL option '-startdate' (Format '[YY]YYMMDDhhmmssZ')
6363--enddate=DATE : Sets the SSL option '-enddate' (Format '[YY]YYMMDDhhmmssZ')
6464
6565--digest=ALG : Digest to use in the requests & certificates
6666--keysize=# : Size in bits of keypair to generate (RSA Only)
67- --use- algo=ALG : Crypto alg to use: choose rsa (default), ec or ed
67+ --algo=ALG : Crypto algorithm to use: choose rsa (default), ec or ed
6868--curve=NAME : For elliptic curve, sets the named curve
6969 (Default: algo ec: secp384r1, algo ed: ed25519)
7070 (--use-algo and --curve can be used to configure 'init-pki')
@@ -838,22 +838,17 @@ easyrsa_random() {
838838 die "easyrsa_random failed"
839839} # => easyrsa_random()
840840
841- # Set clobber on|off
841+ # Set noclobber on|off
842842set_no_clobber() {
843+ verbose "set_no_clobber; $1"
843844 case "$1" in
844845 on)
845- if [ "$easyrsa_host_os" = win ]; then
846- set -o noclobber && return
847- else
848- set -C && return
849- fi
846+ set -o noclobber && return
847+ set -C && return
850848 ;;
851849 off)
852- if [ "$easyrsa_host_os" = win ]; then
853- set +o noclobber && return
854- else
855- set +C && return
856- fi
850+ set +o noclobber && return
851+ set +C && return
857852 ;;
858853 *)
859854 : # drop to error
@@ -937,14 +932,14 @@ easyrsa_mktemp() {
937932 [ -d "$secured_session" ] || die "\
938933easyrsa_mktemp - Temporary session undefined (--tmp-dir)"
939934
935+ # Force noclobber
936+ set_no_clobber on
937+
940938 # Create shotfile
941939 for high in 0 1; do
942940 for low in 0 1 2 3 4 5 6 7 8 9; do
943941 shotfile="${secured_session}/temp.${high}${low}"
944942
945- # Force noclobber
946- set_no_clobber on
947-
948943 # atomic:
949944 printf "" 2>/dev/null 1>"$shotfile" || continue
950945
@@ -6782,6 +6777,7 @@ detect_host
67826777# Allow selective use of 'set -e'
67836778if [ "$EASYRSA_SET_ERREXIT" ]; then
67846779 set -e || die "Cannot set -e"
6780+ print " # ENABLED: shell option errexit"
67856781fi
67866782
67876783# Protect variables from alteration by sourcing vars file
@@ -6824,11 +6820,11 @@ while :; do
68246820 --pki-dir|--pki)
68256821 export EASYRSA_PKI="$val"
68266822 ;;
6827- --no-lockfile)
6823+ --nolockfile|-- no-lockfile)
68286824 empty_ok=1
68296825 export EASYRSA_NO_LOCKFILE=1
68306826 ;;
6831- --no-inline)
6827+ --noinline|-- no-inline)
68326828 empty_ok=1
68336829 export EASYRSA_NO_INLINE=1
68346830 ;;
@@ -6838,7 +6834,7 @@ while :; do
68386834 --umask)
68396835 export EASYRSA_UMASK="$val"
68406836 ;;
6841- --no-umask)
6837+ --noumask|-- no-umask)
68426838 empty_ok=1
68436839 export EASYRSA_NO_UMASK=1
68446840 ;;
@@ -6848,7 +6844,7 @@ while :; do
68486844 --keep-tmp)
68496845 export EASYRSA_KEEP_TEMP="$val"
68506846 ;;
6851- --use-algo)
6847+ --algo|-- use-algo)
68526848 export EASYRSA_ALGO="$val"
68536849 ;;
68546850 --keysize)
@@ -6916,7 +6912,7 @@ while :; do
69166912 empty_ok=1
69176913 export EASYRSA_SILENT=1
69186914 ;;
6919- --sbatch|--silent-batch)
6915+ --sb|-- sbatch|--silent-batch)
69206916 empty_ok=1
69216917 export EASYRSA_SILENT=1
69226918 export EASYRSA_BATCH=1
0 commit comments