From a58c7d9ca36643a362571ec562042a4569e0e973 Mon Sep 17 00:00:00 2001 From: lipinandrei306 Date: Thu, 28 May 2026 12:42:50 +0500 Subject: [PATCH] ]['; --- hqs | 74 ------------------------------------------------------------- 1 file changed, 74 deletions(-) delete mode 100755 hqs diff --git a/hqs b/hqs deleted file mode 100755 index 9a22fb0..0000000 --- a/hqs +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/bash -echo "hostname" -read -p "enter name" name -if [[ -n $name ]]; then - hostnamectl set-hostname $name - exec bash -fi -echo "enter enp0s3" -read enp0s3 -if [[ -n $enp0s3 ]]; then - read -p "enter gateway" gat - read -p "enter dns" dns - cat > /etc/NetworkManager/system-connections/enp0s3.nmconnection << EOF -[connnection] -id=enp0s3 -uuid=$(uuidgen) -tipe=ethernet -autoconnect-priority=-999 -interface-name=enp0s3 -timestamp=$(date +%s) - -[ethernet] - - -[ipv4] -address1=$enp0s3 -dns=$dns -gateway=$gat -method=manual - -[ipv6] -addr-gen-mode=eui64 -method=disabled - -[proxy] - -EOF - - chmod 600 /etc/NetworkManager/system-connections/enp0s3.nmconnection -fi -read -p "Reboot?" o -if [[ -n $o ]]; then - reboot -fi - -echo "enter accaunt" -read -p "continue: " can -if [[ -n $can ]]; then - useradd -u 2026 remote_user - passwd remote_user - cat >> /etc/sudoers << EOF -remote_user ALL=(ALL)NOPASSWD:ALL - -EOF - -fi - -read -p "ftp?: " ftp -read -p "enter ip: " ip -if [[ -n $ftp ]]; then - iptables -I INPUT -p tcp --match multiport --dports 21,22,20000:25000 -j ACCEPT - iptables -t nat -A POSTROUTING -p tcp -d $ip --dport 21 -j MASQUERADE - iptables -t nat -A PREROUTING -i enp0s3 -p tcp --dport 21 -j DNAT --to-destination $ip:21 - service iptables save - - cat >> /etc/vsftpd/vsftpd.conf << EOF -pasv_min_port=20000 -pasv_max_port=25000 -pasv_enable=YES - -EOF - chmod 600 /etc/vsftpd/vsftpd.conf -fi -