2012-03-22 14:33:15 +01:00
|
|
|
|
//CODED by Veliant, Leency 2008-2012. GNU GPL licence.
|
2008-12-19 03:44:13 +01:00
|
|
|
|
|
2008-11-26 03:05:33 +01:00
|
|
|
|
struct f70{
|
|
|
|
|
dword func;
|
|
|
|
|
dword param1;
|
|
|
|
|
dword param2;
|
|
|
|
|
dword param3;
|
|
|
|
|
dword param4;
|
|
|
|
|
char rezerv;
|
|
|
|
|
dword name;
|
|
|
|
|
};
|
|
|
|
|
|
2008-12-19 03:44:13 +01:00
|
|
|
|
struct BDVK{
|
|
|
|
|
dword attr;
|
|
|
|
|
byte type_name;
|
|
|
|
|
byte rez1, rez2, rez3;
|
|
|
|
|
dword timecreate;
|
|
|
|
|
dword datecreate;
|
|
|
|
|
dword timelastaccess;
|
|
|
|
|
dword datelastaccess;
|
|
|
|
|
dword timelastedit;
|
|
|
|
|
dword datelastedit;
|
|
|
|
|
dword sizelo;
|
|
|
|
|
dword sizehi;
|
|
|
|
|
char name[518];
|
|
|
|
|
};
|
|
|
|
|
|
2008-12-05 20:59:10 +01:00
|
|
|
|
////////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> //
|
|
|
|
|
////////////////////////////
|
2012-11-15 23:03:43 +01:00
|
|
|
|
f70 create_file_70;
|
|
|
|
|
int CreateFile(dword file_size, read_buffer, file_path)
|
2012-05-13 02:30:49 +02:00
|
|
|
|
{
|
|
|
|
|
create_file_70.func = 2;
|
|
|
|
|
create_file_70.param1 = 0;
|
|
|
|
|
create_file_70.param2 = 0;
|
|
|
|
|
create_file_70.param3 = file_size;
|
|
|
|
|
create_file_70.param4 = read_buffer;
|
|
|
|
|
create_file_70.rezerv = 0;
|
|
|
|
|
create_file_70.name = file_path;
|
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#create_file_70.func
|
|
|
|
|
$int 0x40
|
2012-11-15 23:03:43 +01:00
|
|
|
|
}
|
2012-05-13 02:30:49 +02:00
|
|
|
|
|
|
|
|
|
////////////////////////////
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> //
|
2008-12-05 20:59:10 +01:00
|
|
|
|
////////////////////////////
|
|
|
|
|
f70 read_file_70;
|
2012-11-15 23:03:43 +01:00
|
|
|
|
int ReadFile(dword pos, file_size, read_buffer, file_path)
|
2008-12-05 20:59:10 +01:00
|
|
|
|
{
|
|
|
|
|
read_file_70.func = 0;
|
|
|
|
|
read_file_70.param1 = pos;
|
|
|
|
|
read_file_70.param2 = 0;
|
|
|
|
|
read_file_70.param3 = file_size;
|
|
|
|
|
read_file_70.param4 = read_buffer;
|
|
|
|
|
read_file_70.rezerv = 0;
|
|
|
|
|
read_file_70.name = file_path;
|
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#read_file_70.func
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
///////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> //
|
2008-12-05 20:59:10 +01:00
|
|
|
|
///////////////////////////
|
|
|
|
|
f70 read_dir_70;
|
2011-07-30 16:59:48 +02:00
|
|
|
|
int ReadDir(dword file_count, read_buffer, read_dir_path)
|
2008-12-05 20:59:10 +01:00
|
|
|
|
{
|
|
|
|
|
read_dir_70.func = 1;
|
|
|
|
|
read_dir_70.param1 = 0;
|
|
|
|
|
read_dir_70.param2 = 0;
|
|
|
|
|
read_dir_70.param3 = file_count;
|
|
|
|
|
read_dir_70.param4 = read_buffer;
|
|
|
|
|
read_dir_70.rezerv = 0;
|
|
|
|
|
read_dir_70.name = read_dir_path;
|
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#read_dir_70.func
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
2008-11-03 14:17:12 +01:00
|
|
|
|
|
|
|
|
|
///////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>v //
|
2008-11-03 14:17:12 +01:00
|
|
|
|
///////////////////////////
|
2008-11-26 03:05:33 +01:00
|
|
|
|
f70 run_file_70;
|
2011-07-30 16:59:48 +02:00
|
|
|
|
int RunProgram(dword run_path, run_param)
|
2008-11-24 01:49:58 +01:00
|
|
|
|
{
|
2008-11-03 14:17:12 +01:00
|
|
|
|
run_file_70.func = 7;
|
2008-11-26 03:05:33 +01:00
|
|
|
|
run_file_70.param1 =
|
|
|
|
|
run_file_70.param3 =
|
|
|
|
|
run_file_70.param4 =
|
2008-11-24 01:49:58 +01:00
|
|
|
|
run_file_70.rezerv = 0;
|
2008-11-26 03:05:33 +01:00
|
|
|
|
run_file_70.param2 = run_param;
|
2008-11-24 01:49:58 +01:00
|
|
|
|
run_file_70.name = run_path;
|
2008-11-03 14:17:12 +01:00
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#run_file_70.func
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
|
|
|
|
|
2008-11-26 03:05:33 +01:00
|
|
|
|
///////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> //
|
2008-11-26 03:05:33 +01:00
|
|
|
|
///////////////////////////
|
|
|
|
|
f70 create_dir_70;
|
2011-07-30 16:59:48 +02:00
|
|
|
|
int CreateFolder(dword new_folder_path)
|
2008-11-26 03:05:33 +01:00
|
|
|
|
{
|
|
|
|
|
create_dir_70.func = 9;
|
|
|
|
|
create_dir_70.param1 =
|
|
|
|
|
create_dir_70.param2 =
|
|
|
|
|
create_dir_70.param3 =
|
|
|
|
|
create_dir_70.param4 =
|
|
|
|
|
create_dir_70.rezerv = 0;
|
|
|
|
|
create_dir_70.name = new_folder_path;
|
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#create_dir_70.func
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
////////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>/<2F><><EFBFBD><EFBFBD><EFBFBD> //
|
2008-11-26 03:05:33 +01:00
|
|
|
|
////////////////////////////
|
|
|
|
|
f70 del_file_70;
|
2011-07-30 16:59:48 +02:00
|
|
|
|
int DeleleFile(dword del_file_path)
|
2008-11-26 03:05:33 +01:00
|
|
|
|
{
|
|
|
|
|
del_file_70.func = 8;
|
|
|
|
|
del_file_70.param1 =
|
|
|
|
|
del_file_70.param2 =
|
|
|
|
|
del_file_70.param3 =
|
|
|
|
|
del_file_70.param4 =
|
|
|
|
|
del_file_70.rezerv = 0;
|
|
|
|
|
del_file_70.name = del_file_path;
|
|
|
|
|
$mov eax,70
|
|
|
|
|
$mov ebx,#del_file_70.func
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
///////////////////////////
|
2012-05-13 02:30:49 +02:00
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> //
|
2008-11-26 03:05:33 +01:00
|
|
|
|
///////////////////////////
|
|
|
|
|
f70 CopyFile_f;
|
2011-08-27 23:37:45 +02:00
|
|
|
|
inline fastcall int CopyFile(dword EBX,ECX)
|
2008-11-26 03:05:33 +01:00
|
|
|
|
{
|
|
|
|
|
BDVK CopyFile_atr;
|
|
|
|
|
dword s=EBX, d=ECX, cBufer=0;
|
|
|
|
|
CopyFile_f.func = 5;
|
|
|
|
|
CopyFile_f.param1 = 0;
|
|
|
|
|
CopyFile_f.param2 = 0;
|
|
|
|
|
CopyFile_f.param3 = 0;
|
|
|
|
|
CopyFile_f.param4 = #CopyFile_atr;
|
|
|
|
|
CopyFile_f.rezerv = 0;
|
|
|
|
|
CopyFile_f.name = s;
|
|
|
|
|
$mov eax, 70
|
|
|
|
|
$mov ebx, #CopyFile_f
|
|
|
|
|
$int 0x40
|
|
|
|
|
|
|
|
|
|
if (!EAX)
|
|
|
|
|
{
|
2008-12-29 02:49:26 +01:00
|
|
|
|
cBufer = malloc(2*CopyFile_atr.sizelo);
|
2008-12-05 20:59:10 +01:00
|
|
|
|
ReadFile(dword 0, CopyFile_atr.sizelo, cBufer, s);
|
2008-11-26 03:05:33 +01:00
|
|
|
|
|
|
|
|
|
IF (!EAX)
|
|
|
|
|
{
|
|
|
|
|
CopyFile_f.func = 2;
|
|
|
|
|
CopyFile_f.param1 = 0;
|
|
|
|
|
CopyFile_f.param2 = 0;
|
|
|
|
|
CopyFile_f.param3 = CopyFile_atr.sizelo;
|
|
|
|
|
CopyFile_f.param4 = cBufer;
|
|
|
|
|
CopyFile_f.rezerv = 0;
|
|
|
|
|
CopyFile_f.name = d;
|
|
|
|
|
$mov eax, 70
|
|
|
|
|
$mov ebx, #CopyFile_f
|
|
|
|
|
$int 0x40
|
|
|
|
|
}
|
|
|
|
|
}
|
2011-08-27 23:37:45 +02:00
|
|
|
|
return EAX;
|
2008-11-26 03:05:33 +01:00
|
|
|
|
|
|
|
|
|
}
|
2008-11-03 14:17:12 +01:00
|
|
|
|
|
2008-12-19 03:44:13 +01:00
|
|
|
|
|