#include <iostream>
#include <fstream>
#include <stdio.h>
#include <cstdlib>
#include <unistd.h>
#include <windows.h>
#include <conio.h>
using namespace std;
int main()
{
int nr, disk;
string odp;
FirstMenu:
cout << "----------__________________________________----------" << endl;
cout << "-_-_-_-_--Welcome To Hack4Fun Hacking Device--_-_-_-_-" << endl;
cout << "----------------What You Want To Hack?----------------" << endl;
cout << "--#~ 1. Windows" << endl;
cout << "--#~ 2. Mac" << endl;
cout << "--#~ 99. Exit" << endl;
cout << "------------------------------------------------------" << endl;
cout << "--#~"; cin >> nr;
getchar();
switch(nr)
case 1:
system("cls");
cout << "Choose driver:" << endl;
cout << "1. F" << endl;
cout << "2. G" << endl;
cout << "3. H" << endl;
cout << "4. D" << endl;
cout << "5. Go to menu" << endl;
cout << "99. Exit" << endl;
cin >> disk;
if ( disk == 1)
{
system("cls");
fstream myFileHandler;
myFileHandler.open("C:\\Users\\admin\\Desktop\\wat\\test\\bin\\Debug\\lol.txt");
if (myFileHandler.is_open())
{
cout << "File has been inject! (Location: %temp%)" << endl;
Sleep(3000);
goto FirstMenu;
}
else
{
cout << "ERROR! File was NOT inject!" << endl;
Sleep(3000);
system("cls");
goto FirstMenu;
}
{
if (disk == 2)
fstream myFileHandler;
myFileHandler.open("WinPowerShellD.bat");
if (myFileHandler.is_open())
{
cout << "File has been inject! (Location: %temp%)" << endl;
Sleep(3000);
goto FirstMenu;
}
else
{
cout << "ERROR! File was NOT inject!" << endl;
Sleep(3000);
system("cls");
goto FirstMenu;
}
return 0;
}
}
}
wszystko chodzi tylko, ze plik sie nie otwiera. Czemu? Prosze o pomoc. Pokazuje File has been inject ale sie nie otwiera