Advertisement
Guest User

Untitled

a guest
Apr 19th, 2016
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.47 KB | None | 0 0
  1. length=$[ 6 +$[RANDOM % 6]]
  2.  
  3. char=(0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R S T U V W X Y Z)
  4.  
  5. max=${#char[*]}
  6. for ((i = 1; i <= $length ; i++))do
  7.  
  8. let rand=${RANDOM}%${max}
  9. password="${password}${char[$rand]}"
  10.  
  11. done
  12. length=$[ 6 +$[RANDOM % 6]]
  13.  
  14. char=(0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R S T U V W X Y Z)
  15.  
  16. max=${#char[*]}
  17. for ((i = 1; i <= $length ; i++))do
  18.  
  19. let rand=${RANDOM}%${max}
  20. username="${username}${char[$rand]}"
  21. done
  22. echo "##Main##
  23.  
  24. #Starting 3proxy as a service/daemon
  25. daemon
  26.  
  27. #DNS Servers to resolve domains and for the local DNS cache
  28. #that providers faster resolution for cached entries
  29. nserver 91.239.100.100
  30. nserver 89.233.43.71
  31. nscache 65536
  32.  
  33. #Authentication
  34. #CL = Clear Text, CR = Encrypted Passswords (MD5)
  35. #Add MD5 users with MD5 passwords with "" (see below)
  36. #users "user:CR:password"
  37. users $username:CL:$password
  38.  
  39. #Logging
  40. log /var/log/3proxy/3proxy.log D
  41. logformat \"- +_L%t.%. %N.%p %E %U %C:%c %R:%r %O %I %h %T\"
  42. rotate 30
  43.  
  44. #Auth type
  45. #auth strong = username & password
  46. auth strong
  47.  
  48. #Binding address
  49. external 0.0.0.0
  50. internal 0.0.0.0
  51.  
  52. #SOCKS5
  53. auth strong
  54. flush
  55. allow $username
  56. maxconn 384
  57. socks -p1080" > /root/3proxy/3proxy.cfg
  58. sleep 1
  59. echo "username: " $username
  60. echo "password: " $password
  61. echo ifconfig | awk -F':' '/inet addr/&&!/127.0.0.1/{split($2,_," ");print _[1]}'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement