take care single quotes if they are in the WEBPASSWD

This commit is contained in:
m0duspwnens
2020-09-23 13:00:18 -04:00
parent b32bc8b542
commit 70f98e2eea

View File

@@ -1137,15 +1137,16 @@ manager_global() {
" airgap: False"\ >> "$global_pillar"
fi
WEBPASSWD1CLEAN=$(echo $WEBPASSWD1|sed -e "s/'/''/g")
# Check if TheHive is enabled. If so, add creds and other details
if [[ "$THEHIVE" == "1" ]]; then
printf '%s\n'\
" hiveuser: $WEBUSER"\
" hivepassword: '$WEBPASSWD1'"\
" hivepassword: '$WEBPASSWD1CLEAN'"\
" hivekey: $HIVEKEY"\
" hiveplaysecret: $HIVEPLAYSECRET"\
" cortexuser: $WEBUSER"\
" cortexpassword: '$WEBPASSWD1'"\
" cortexpassword: '$WEBPASSWD1CLEAN'"\
" cortexkey: $CORTEXKEY"\
" cortexorgname: SecurityOnion"\
" cortexorguser: soadmin"\