2019-06-28 02:39:56 +00:00
|
|
|
#!/bin/sh
|
|
|
|
set -e
|
|
|
|
|
2019-08-02 02:15:39 +00:00
|
|
|
setup_motd() {
|
2019-06-28 02:39:56 +00:00
|
|
|
RESET='\033[0m'
|
|
|
|
GREEN='\033[0;32m'
|
|
|
|
BGREEN='\033[1;32m'
|
|
|
|
YELLOW='\033[0;33m'
|
|
|
|
CYAN='\033[0;36m'
|
|
|
|
GREY='\033[1;30m'
|
|
|
|
RED='\033[1;31m'
|
|
|
|
BLUE='\033[1;34m'
|
|
|
|
UBLUE='\033[4;34m'
|
2021-02-13 19:35:45 +00:00
|
|
|
echo -e "╔═══════════════════════╦══════════════════════════════════════════════════════════════╗"
|
|
|
|
echo -e "║${GREEN} ▄▄▄· ▄▄· ▪ ·▄▄▄▄ ${RESET}║ ${RED}Connection Notice${RESET} ║"
|
|
|
|
echo -e "║${GREEN} ▐█ ▀█ ▐█ ▌▪██ ██▪ ██ ${RESET}╟──────────────────────────────────────────────────────────────╢"
|
|
|
|
echo -e "║${GREEN} ▄█▀▀█ ██ ▄▄▐█·▐█· ▐█▌ ${RESET}║ ║"
|
|
|
|
echo -e "║${GREEN} ▐█ ▪▐▌▐███▌▐█▌██. ██ ${RESET}║ ${YELLOW}This system is for the use of authorized users only.${RESET} ║"
|
|
|
|
echo -e "║${GREEN} ▀ ▀ ·▀▀▀ ▀▀▀▀▀▀▀▀• ${RESET}║ ${YELLOW}All connections will be monitored and logged by the system.${RESET} ║"
|
|
|
|
echo -e "║${GREEN} ▄▄▄▄· ▐▄• ▄ ${RESET}║ ║"
|
|
|
|
echo -e "║${GREEN} ▐█ ▀█▪▪ █▌█▌▪ ${RESET}║ ${YELLOW}Connection issues? Contact ${UBLUE}${BLUE}acid.vegas@acid.vegas${YELLOW} for help.${RESET} ║"
|
|
|
|
echo -e "║${GREEN} ▐█▀▀█▄ ▄█▀▄ ·██· ${RESET}║ ║"
|
|
|
|
echo -e "║${GREEN} ██▄▪▐█▐█▌.▐▌▪▐█·█▌ ${RESET}║ ${YELLOW}Right about now, the funk soul brudda. Check it out now...${RESET} ║"
|
|
|
|
echo -e "║${GREEN} ·▀▀▀▀ ▀█▄▀▪•▀▀ ▀▀ ${RESET}║ ║"
|
|
|
|
echo -e "╚═══════════════════════╩══════════════════════════════════════════════════════════════╝"
|
|
|
|
echo "${YELLOW}Hello ${CYAN}$(whoami)${YELLOW}! You are now connected to ${RED}$(hostname)"
|
|
|
|
echo "${YELLOW}Type ${BGREEN}cmds${YELLOW} to see a list of commands available.${RESET}"
|
|
|
|
echo "[${BLUE}RULES${RESET}]"
|
|
|
|
echo " ${GREY}*${YELLOW} This is a private system that you are not to give out access to anyone"
|
|
|
|
echo " without permission from the system admin. No illegal files or activites."
|
|
|
|
echo " ${GREY}*${YELLOW} Avoid denial of service attacks out of respect for other users on the system."
|
|
|
|
echo " ${GREY}*${YELLOW} Stay in your home directory, keep the system clean, and make regular backups."
|
2019-06-28 02:39:56 +00:00
|
|
|
}
|
|
|
|
|
2019-08-02 02:15:39 +00:00
|
|
|
setup_user() {
|
2020-05-19 03:02:34 +00:00
|
|
|
sudo useradd -m -s /bin/bash $1
|
2019-06-28 02:39:56 +00:00
|
|
|
mkdir /home/$1/.scripts
|
|
|
|
wget -O /home/$1/.bashrc https://git.supernets.org/acidvegas/acidbox/blob/master/files/.bashrc
|
|
|
|
wget -O /home/$1/.scripts/cmds https://git.supernets.org/acidvegas/acidbox/blob/master/files/cmds
|
|
|
|
wget -O /home/$1/.scripts/contact https://git.supernets.org/acidvegas/acidbox/blob/master/files/contact
|
|
|
|
wget -O /home/$1/.scripts/rules https://git.supernets.org/acidvegas/acidbox/blob/master/files/rules
|
|
|
|
wget -O /home/$1/.scripts/vhosts https://git.supernets.org/acidvegas/acidbox/blob/master/files/vhosts
|
2021-02-13 19:35:45 +00:00
|
|
|
echo "clear && reset/home/$1/.bash_logout"
|
2019-06-28 02:39:56 +00:00
|
|
|
echo "[[ -f ~/.bashrc ]] && . ~/.bashrc" > /home/$1/.bash_profile
|
2019-08-02 02:15:39 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
setup_motd
|