mirror of https://github.com/samply/bridgehead.git
Replace | openssl rsautl -sign with | sha1sum | openssl pkeyutl -sign
This commit is contained in:
parent
3a8df378a6
commit
3180d0fd76
|
@ -6,7 +6,7 @@ if [ "$ENABLE_DATASHIELD" == true ]; then
|
||||||
echo "The ENABLE_EXPORTER variable is either not set or not set to 'true'."
|
echo "The ENABLE_EXPORTER variable is either not set or not set to 'true'."
|
||||||
fi
|
fi
|
||||||
OAUTH2_CALLBACK=/oauth2/callback
|
OAUTH2_CALLBACK=/oauth2/callback
|
||||||
OAUTH2_PROXY_SECRET="$(echo \"This is a salt string to generate one consistent encryption key for the oauth2_proxy. It is not required to be secret.\" | openssl rsautl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 32)"
|
OAUTH2_PROXY_SECRET="$(echo \"This is a salt string to generate one consistent encryption key for the oauth2_proxy. It is not required to be secret.\" | sha1sum | openssl pkeyutl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 32)"
|
||||||
add_private_oidc_redirect_url "${OAUTH2_CALLBACK}"
|
add_private_oidc_redirect_url "${OAUTH2_CALLBACK}"
|
||||||
|
|
||||||
log INFO "DataSHIELD setup detected -- will start DataSHIELD services."
|
log INFO "DataSHIELD setup detected -- will start DataSHIELD services."
|
||||||
|
|
|
@ -3,6 +3,6 @@
|
||||||
if [ "$ENABLE_EXPORTER" == true ]; then
|
if [ "$ENABLE_EXPORTER" == true ]; then
|
||||||
log INFO "Exporter setup detected -- will start Exporter service."
|
log INFO "Exporter setup detected -- will start Exporter service."
|
||||||
OVERRIDE+=" -f ./$PROJECT/modules/exporter-compose.yml"
|
OVERRIDE+=" -f ./$PROJECT/modules/exporter-compose.yml"
|
||||||
EXPORTER_DB_PASSWORD="$(echo \"This is a salt string to generate one consistent password for the exporter. It is not required to be secret.\" | openssl rsautl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 30)"
|
EXPORTER_DB_PASSWORD="$(echo \"This is a salt string to generate one consistent password for the exporter. It is not required to be secret.\" | sha1sum | openssl pkeyutl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 30)"
|
||||||
EXPORTER_API_KEY="$(echo \"This is a salt string to generate one consistent API KEY for the exporter. It is not required to be secret.\" | openssl rsautl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 64)"
|
EXPORTER_API_KEY="$(echo \"This is a salt string to generate one consistent API KEY for the exporter. It is not required to be secret.\" | sha1sum | openssl pkeyutl -sign -inkey /etc/bridgehead/pki/${SITE_ID}.priv.pem | base64 | head -c 64)"
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -343,7 +343,7 @@ generate_password(){
|
||||||
generate_simple_password(){
|
generate_simple_password(){
|
||||||
local seed_text="$1"
|
local seed_text="$1"
|
||||||
local combined_text="This is a salt string to generate one consistent password for ${seed_text}. It is not required to be secret."
|
local combined_text="This is a salt string to generate one consistent password for ${seed_text}. It is not required to be secret."
|
||||||
echo "${combined_text}" | openssl rsautl -sign -inkey "/etc/bridgehead/pki/${SITE_ID}.priv.pem" 2> /dev/null | base64 | head -c 26 | sed 's/[+\/]/A/g'
|
echo "${combined_text}" | sha1sum | openssl pkeyutl -sign -inkey "/etc/bridgehead/pki/${SITE_ID}.priv.pem" 2> /dev/null | base64 | head -c 26 | sed 's/[+\/]/A/g'
|
||||||
}
|
}
|
||||||
|
|
||||||
docker_jq() {
|
docker_jq() {
|
||||||
|
|
Loading…
Reference in New Issue