certbotbot
Reference documentation for a modular Bash project
Loading...
Searching...
No Matches
Functions | Variables
config.bash File Reference

Parses literal configuration and resolves selected-lineage settings. More...

Functions

int certbotbot_no_env_requested (String arg)
 Detects the presence-only flag before importing any application data.
 
int certbotbot_disable_application_environment ()
 Excludes all producer-owned environment settings under –no-env.
 
int certbotbot_extra_args_resolve (String kind, String json)
 Decodes one bounded JSON string-array into safe provider argv tokens.
 
int certbotbot_extra_args_config (String arg)
 Resolves independent CLI-over-environment provider argv collections.
 
int certbotbot_error (String message)
 Reports a non-sensitive configuration error.
 
int certbotbot_read_env_file (String file)
 Reads the accepted literal KEY=VALUE grammar.
 
int certbotbot_config_resolve (String arg)
 Resolves each supported key using CLI, environment, file and defaults.
 

Variables

AssociativeArray CERTBOTBOT_FILE_VALUES
 Associative literal values parsed from the selected configuration.
 
IndexedArray CERTBOTBOT_DESIRED_NAMES
 Complete operator-explicit desired lineage list (ADR-059).
 
IndexedArray CERTBOTBOT_AWS_ARGS
 Bounded AWS CLI global argument vector, defaulting empty.
 
IndexedArray CERTBOTBOT_GPG_ARGS
 Bounded authenticated encryption tuning arguments, defaulting empty.
 
IndexedArray CERTBOTBOT_CERTBOT_ARGS
 Complete ordered Certbot vector used on issuance and renewal.
 
IndexedArray CERTBOTBOT_CERTBOT_GLOBAL_ARGS
 Safe global Certbot arguments shared across allowed subcommands.
 
IndexedArray CERTBOTBOT_CERTBOT_CHALLENGE_ARGS
 Certbot dns-route53 options used only for selected issue and renew.
 

Detailed Description

Parses literal configuration and resolves selected-lineage settings.

Configuration is never sourced or evaluated. Values are captured by literal assignment and overlaid according to the public MVP configuration contract. Invalid configuration fails before any cloud operation is attempted. Legacy S3_KEY remains literal. S3_KEY_TEMPLATE and S3_KEY are mutually exclusive at one precedence tier; a higher-tier selection masks the other source's lower-tier alternative. Backup-key template configuration selects naming only, not publication or deletion. DATED_BACKUP_ENABLED independently opts into a guarded second S3 publication after success. BACKUP_RETENTION_COUNT is a separate default-zero destructive opt-in; it requires a verified current and dated backup publication (ADR-034). Additional SAN input follows ADR-029: repeated –san values select the entire CLI collection; exported ADDITIONAL_SANS replaces the literal file list, and file/default values are consulted only when higher sources are absent. Individual names are validated by certbotbot_identity_resolve.

Function Documentation

◆ certbotbot_config_resolve()

int certbotbot_config_resolve ( String  arg)

Resolves each supported key using CLI, environment, file and defaults.

A repeated –san NAME or –san=NAME is a collection-valued CLI setting. With no CLI –san, ADDITIONAL_SANS is a literal comma-delimited environment or .env list; an exported empty value deliberately masks the file list. The result is CERTBOTBOT_ADDITIONAL_SANS, an indexed Bash array. No list data is evaluated, interpolated or treated as shell code. The input cap is 99 extras, reserving the 100th name for the required primary identity.

Parameters
argCommand-line arguments including one DNS identity.
STDIN
Nothing is read from STDIN.
STDOUT
Nothing is written to STDOUT.
STDERR
Static validation diagnostics.
Return values
0Effective settings were resolved.
64Invalid settings or arguments.

◆ certbotbot_disable_application_environment()

int certbotbot_disable_application_environment ( )

Excludes all producer-owned environment settings under –no-env.

Deliberately retains OS environment and external AWS credentials.

◆ certbotbot_error()

int certbotbot_error ( String  message)

Reports a non-sensitive configuration error.

Parameters
messageStatic diagnostic without user-supplied values.
STDIN
Nothing is read from STDIN.
STDOUT
Nothing is written to STDOUT.
STDERR
One diagnostic.
Return values
64Invalid configuration.

◆ certbotbot_extra_args_config()

int certbotbot_extra_args_config ( String  arg)

Resolves independent CLI-over-environment provider argv collections.

Parameters
argThree optional CLI JSON values and three presence flags.
Return values
0All selected provider collections have passed validation.
64/69Invalid collection or required decoder unavailable.

◆ certbotbot_extra_args_resolve()

int certbotbot_extra_args_resolve ( String  kind,
String  json 
)

Decodes one bounded JSON string-array into safe provider argv tokens.

Parameters
kindAWS, GPG, or CERTBOT.
jsonEntire JSON argv array; no shell evaluation.
Return values
0Validated provider argument vector.
64Malformed, unsupported, or unsafe argument collection.
69Missing optional decoder required for nonempty input.

◆ certbotbot_no_env_requested()

int certbotbot_no_env_requested ( String  arg)

Detects the presence-only flag before importing any application data.

Skips option values and everything following the option terminator.

Parameters
argCLI tokens, optionally starting with 'register'.
Return values
0The explicit –no-env token was supplied.
1No valid standalone no-env token was found.

◆ certbotbot_read_env_file()

int certbotbot_read_env_file ( String  file)

Reads the accepted literal KEY=VALUE grammar.

Parameters
fileExisting configuration file path.
STDIN
Nothing is read from STDIN.
STDOUT
Nothing is written to STDOUT.
STDERR
Static diagnostics on invalid input.
Return values
0All entries were parsed.
64Input was invalid.

Variable Documentation

◆ CERTBOTBOT_AWS_ARGS

CERTBOTBOT_AWS_ARGS

Bounded AWS CLI global argument vector, defaulting empty.

Bash variable: read-write indexed_array

◆ CERTBOTBOT_CERTBOT_ARGS

CERTBOTBOT_CERTBOT_ARGS

Complete ordered Certbot vector used on issuance and renewal.

Bash variable: read-write indexed_array

◆ CERTBOTBOT_CERTBOT_CHALLENGE_ARGS

CERTBOTBOT_CERTBOT_CHALLENGE_ARGS

Certbot dns-route53 options used only for selected issue and renew.

Bash variable: read-write indexed_array

◆ CERTBOTBOT_CERTBOT_GLOBAL_ARGS

CERTBOTBOT_CERTBOT_GLOBAL_ARGS

Safe global Certbot arguments shared across allowed subcommands.

Bash variable: read-write indexed_array

◆ CERTBOTBOT_DESIRED_NAMES

CERTBOTBOT_DESIRED_NAMES

Complete operator-explicit desired lineage list (ADR-059).

Bash variable: read-write indexed_array

◆ CERTBOTBOT_FILE_VALUES

CERTBOTBOT_FILE_VALUES

Associative literal values parsed from the selected configuration.

Bash variable: read-write associative_array

◆ CERTBOTBOT_GPG_ARGS

CERTBOTBOT_GPG_ARGS

Bounded authenticated encryption tuning arguments, defaulting empty.

Bash variable: read-write indexed_array