Skip to content

Commit

Permalink
Update sshd_ufw.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
DigneZzZ committed Mar 17, 2023
1 parent 500304f commit 927840a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tool/sshd_ufw.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ if [ -z "$current_port" ]; then
fi

# Определяем, хочет ли пользователь изменить порт
read -p "Текущий порт SSH: $current_port. Хотите изменить порт? (y/n): " change_port
read -p "${YELLOW}Текущий порт SSH: $current_port. Хотите изменить порт? (y/n): ${NC}" change_port

if [ "$change_port" == "y" ]; then
# Запрос нового порта
read -p "Введите новый порт (допустимый диапазон: 1024-65535):$'\e[0m' " new_port
read -p "${YELLOW}Введите новый порт (допустимый диапазон: 1024-65535): ${NC}" new_port

# Проверка, что введено число
if ! [[ "$new_port" =~ ^[0-9]+$ ]]; then
Expand Down

0 comments on commit 927840a

Please sign in to comment.