mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 09:12:45 +01:00
Workaround for FleetDM PW Req
This commit is contained in:
@@ -53,8 +53,10 @@ if [[ $? -ne 0 ]]; then
|
|||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
TEMPPW=$FLEET_SA_PW!
|
||||||
|
|
||||||
# Create New User
|
# Create New User
|
||||||
CREATE_OUTPUT=$(docker exec so-fleet fleetctl user create --email $USER_EMAIL --name $USER_EMAIL --password $USER_PASS --global-role admin 2>&1)
|
CREATE_OUTPUT=$(docker exec so-fleet fleetctl user create --email $USER_EMAIL --name $USER_EMAIL --password $TEMPPW --global-role admin 2>&1)
|
||||||
|
|
||||||
if [[ $? -eq 0 ]]; then
|
if [[ $? -eq 0 ]]; then
|
||||||
echo "Successfully added user to Fleet"
|
echo "Successfully added user to Fleet"
|
||||||
@@ -64,6 +66,9 @@ else
|
|||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Reset New User Password to user supplied password
|
||||||
|
echo "$USER_PW" | so-fleet-user-update "$USER_EMAIL"
|
||||||
|
|
||||||
# Disable forced password reset
|
# Disable forced password reset
|
||||||
MYSQL_OUTPUT=$(docker exec so-mysql mysql -u root --password=$MYSQL_PW fleet -e \
|
MYSQL_OUTPUT=$(docker exec so-mysql mysql -u root --password=$MYSQL_PW fleet -e \
|
||||||
"UPDATE users SET admin_forced_password_reset = 0 WHERE email = '$USER_EMAIL'" 2>&1)
|
"UPDATE users SET admin_forced_password_reset = 0 WHERE email = '$USER_EMAIL'" 2>&1)
|
||||||
|
|||||||
@@ -1511,7 +1511,7 @@ generate_passwords(){
|
|||||||
PLAYBOOKADMINPASS=$(get_random_value)
|
PLAYBOOKADMINPASS=$(get_random_value)
|
||||||
PLAYBOOKAUTOMATIONPASS=$(get_random_value)
|
PLAYBOOKAUTOMATIONPASS=$(get_random_value)
|
||||||
FLEETPASS=$(get_random_value)
|
FLEETPASS=$(get_random_value)
|
||||||
FLEETSAPASS=$(get_random_value)
|
FLEETSAPASS="$(get_random_value)!"
|
||||||
FLEETJWT=$(get_random_value)
|
FLEETJWT=$(get_random_value)
|
||||||
GRAFANAPASS=$(get_random_value)
|
GRAFANAPASS=$(get_random_value)
|
||||||
SENSORONIKEY=$(get_random_value)
|
SENSORONIKEY=$(get_random_value)
|
||||||
|
|||||||
Reference in New Issue
Block a user