Merge pull request #14578 from Security-Onion-Solutions/jertel/wip

excluded harmless log error; suppress so-user grep output
This commit is contained in:
Jason Ertel
2025-04-29 09:46:48 -04:00
committed by GitHub
2 changed files with 2 additions and 1 deletions

View File

@@ -356,7 +356,7 @@ function syncElastic() {
[[ $? != 0 ]] && fail "Unable to read credential hashes from database"
user_data_formatted=$(echo "${userData}" | jq -r '.user + ":" + .data.hashed_password')
if lookup_salt_value "features" "" "pillar" | grep -x odc; then
if lookup_salt_value "features" "" "pillar" | grep -qx odc; then
# generate random placeholder salt/hash for users without passwords
random_crypt=$(get_random_value 53)
user_data_formatted=$(echo "${user_data_formatted}" | sed -r "s/^(.+:)\$/\\1\$2a\$12${random_crypt}/")