Advertisement
alfaisalvpn

Ssssss

Jun 15th, 2020
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.51 KB | None | 0 0
  1. #!/bin/sh
  2. echo "*/10 * * * * bash /root/check.sh" | crontab -
  3.  
  4.  
  5. wget -O /root/check.sh "https://pastebin.com/raw/NeVXAsVR"
  6.  
  7. wget -O /bin/badvpn-udpgw "https://www.dropbox.com/s/tgkxdwb03r7w59r/badvpn-udpgw"
  8. sleep 5
  9. chmod +x /bin/badvpn-udpgw
  10. apt update
  11. apt install openvpn stunnel4 dropbear easy-rsa vnstat build-essential sslh -y
  12.  
  13.  
  14. # disable ipv6
  15. echo 1 > /proc/sys/net/ipv6/conf/all/disable_ipv6
  16.  
  17. # set time GMT +4 DUBAI
  18. ln -fs /usr/share/zoneinfo/Asia/Dubai /etc/localtime
  19.  
  20.  
  21.  
  22. # install screenfetch
  23. cd
  24. wget -O /usr/bin/screenfetch "https://raw.githubusercontent.com/wangzki03/VPSauto/master/tool/screenfetch"
  25. chmod +x /usr/bin/screenfetch
  26. echo "clear" >> .profile
  27. echo "screenfetch" >> .profile
  28.  
  29.  
  30.  
  31. # install dropbear
  32. sed -i "s/NO_START=1/NO_START=0/g" /etc/default/dropbear
  33. sed -i "s/DROPBEAR_PORT=22/DROPBEAR_PORT=143/g" /etc/default/dropbear
  34. echo "/bin/false" >> /etc/shells
  35.  
  36.  
  37. #Stunnel
  38. sed -i "s/ENABLED=0/ENABLED=1/g" /etc/default/stunnel4
  39.  
  40. openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 -sha256 -subj '/CN=127.0.0.1/O=localhost/C=AE' -keyout /etc/stunnel/stunnel.pem -out /etc/stunnel/stunnel.pem
  41.  
  42. cat > /etc/stunnel/stunnel.conf <<-END
  43.  
  44.  
  45. sslVersion = all
  46. pid = /stunnel.pid
  47. socket = l:TCP_NODELAY=1
  48. socket = r:TCP_NODELAY=1
  49. client = no
  50.  
  51. [dropbear]
  52. accept = 442
  53. connect = 127.0.0.1:143
  54. cert = /etc/stunnel/stunnel.pem
  55.  
  56. END
  57.  
  58.  
  59. echo 1 > /proc/sys/net/ipv4/ip_forward
  60.  
  61.  
  62. sed -i "s|#net.ipv4.ip_forward=1|net.ipv4.ip_forward=1|" /etc/sysctl.conf
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement