mirror of
https://github.com/PierreGode/Linux-Active-Directory-join-script.git
synced 2025-12-21 08:50:12 +01:00
Update ADconnection.sh
This commit is contained in:
parent
09a2cc8a0b
commit
772e967198
@ -424,7 +424,7 @@ if [ "$sshsec" = "no" ]
|
|||||||
then
|
then
|
||||||
echo "Skipping SSHSecurity config"
|
echo "Skipping SSHSecurity config"
|
||||||
else
|
else
|
||||||
read -r -p "${RED_TEXT}Do you wish to enable SSH login.group.allowed${END}${NUMBER}(y/n)?${END}" yn
|
read -r -p "Do you wish to enable SSH login.group.allowed(y/n)?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* ) sudo echo "Checking if there is any previous configuration"
|
[Yy]* ) sudo echo "Checking if there is any previous configuration"
|
||||||
if [ -f /etc/ssh/login.group.allowed ] < /dev/null > /dev/null 2>&1
|
if [ -f /etc/ssh/login.group.allowed ] < /dev/null > /dev/null 2>&1
|
||||||
@ -475,7 +475,6 @@ then
|
|||||||
sudo echo "%DOMAIN\ admins ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/domain_admins
|
sudo echo "%DOMAIN\ admins ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/domain_admins
|
||||||
#sudo realm permit --groups "$myhost""sudoers"
|
#sudo realm permit --groups "$myhost""sudoers"
|
||||||
else
|
else
|
||||||
echo "error in readfile config"
|
|
||||||
sudo echo "administrator ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
sudo echo "administrator ALL=(ALL:ALL) ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
@ -488,7 +487,7 @@ else
|
|||||||
echo "Skipping"
|
echo "Skipping"
|
||||||
states="12"
|
states="12"
|
||||||
else
|
else
|
||||||
read -r -p "${RED_TEXT}Do you wish to give users on this machine sudo rights?${END}${NUMBER}(y/n)?${END}" yn
|
read -r -p "Do you wish to give users on this machine sudo rights?(y/n)?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* ) sudo echo "Checking if there is any previous configuration"
|
[Yy]* ) sudo echo "Checking if there is any previous configuration"
|
||||||
if [ -f /etc/sudoers.d/sudoers ] < /dev/null > /dev/null 2>&1
|
if [ -f /etc/sudoers.d/sudoers ] < /dev/null > /dev/null 2>&1
|
||||||
@ -497,7 +496,7 @@ else
|
|||||||
echo "The Sudoers file seems already to be modified, skipping..."
|
echo "The Sudoers file seems already to be modified, skipping..."
|
||||||
echo ""
|
echo ""
|
||||||
else
|
else
|
||||||
read -r -p "${RED_TEXT}Do you wish to DISABLE password prompt for users in terminal?${END}${NUMBER}(y/n)?${END}" yn
|
read -r -p "Do you wish to DISABLE password prompt for users in terminal?(y/n)?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* )
|
[Yy]* )
|
||||||
sudo echo "administrator ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
sudo echo "administrator ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/sudoers
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user