mirror of
https://github.com/jmcorgan/fips.git
synced 2026-07-30 19:46:15 +00:00
fix unsupported bash for 3.2
This commit is contained in:
committed by
Johnathan Corgan
parent
be80342ef7
commit
841b376653
@@ -129,9 +129,20 @@ generate_config() {
|
|||||||
echo "$config" > "$output_file"
|
echo "$config" > "$output_file"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Associative arrays for resolved keys (populated in generate_topology)
|
# Key storage for bash 3.2 compatibility (using prefixed variables instead of associative arrays)
|
||||||
declare -A RESOLVED_NSEC
|
# Usage: set_key NSEC a "value" / get_key NSEC a
|
||||||
declare -A RESOLVED_NPUB
|
set_key() {
|
||||||
|
local prefix="$1"
|
||||||
|
local key="$2"
|
||||||
|
local value="$3"
|
||||||
|
eval "${prefix}_${key}=\"${value}\""
|
||||||
|
}
|
||||||
|
|
||||||
|
get_key() {
|
||||||
|
local prefix="$1"
|
||||||
|
local key="$2"
|
||||||
|
eval "echo \"\$${prefix}_${key}\""
|
||||||
|
}
|
||||||
|
|
||||||
generate_topology() {
|
generate_topology() {
|
||||||
local topology_name="$1"
|
local topology_name="$1"
|
||||||
|
|||||||
Reference in New Issue
Block a user