joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401fe0
Capabilities:
Create process on windows

Disassembly:
push 0xffffffffffffffff
push 0x415ce0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x58
push esi
mov esi, dword [esp + 0x6c]
mov dword [esp + 0x64], 0
test esi, esi
jne 0x40202c
lea ecx, [esp + 0x74]
mov dword [esp + 0x64], 0xffffffff
call fcn.00415882
xor eax, eax
pop esi
mov ecx, dword [esp + 0x58]
mov dword fs:[0], ecx
add esp, 0x64
ret
lea ecx, [esp + 0x6c]
call sub.MFC42.DLL_CString::CString_2
push esi
lea eax, [esp + 0x70]
push 0x41a408
push eax
mov byte [esp + 0x70], 1
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea ecx, [esp + 0x74]
push 0x41a64c
call sub.MFC42.DLL_CString::operator_1
lea ecx, [esp + 0x6c]
push ecx
lea ecx, [esp + 0x78]
call sub.MFC42.DLL_CString::operator
lea edx, [esp + 4]
push str.EXPLORER.EXE
push edx
call fcn.00401e90
add esp, 8
test eax, eax
jne 0x4020af
lea ecx, [esp + 0x6c]
mov byte [esp + 0x64], al
call fcn.00415882
lea ecx, [esp + 0x74]
mov dword [esp + 0x64], 0xffffffff
call fcn.00415882
xor eax, eax
pop esi
mov ecx, dword [esp + 0x58]
mov dword fs:[0], ecx
add esp, 0x64
ret
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x1c]
rep stosd dword es:[edi], eax
lea eax, [esp + 0xc]
lea ecx, [esp + 0x1c]
mov edx, dword [esp + 0x78]
push eax
mov eax, dword [esp + 0xc]
push ecx
push 0
push 0
push 0x10
push 0
push 0
push 0
push 0
push edx
push eax
mov dword [esp + 0x48], 0x44
mov dword [esp + 0x50], str.winsta0default
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserA]
mov ecx, dword [esp + 8]
mov esi, eax
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
test esi, esi
push str.mylog.txt
je 0x402113
push str.CreateProcessAsUser_ok__r_n
jmp 0x402118
push str.CreateProcessAsUser_false__r_n
call fcn.00412500
add esp, 8
lea ecx, [esp + 0x6c]
mov byte [esp + 0x64], 0
call fcn.00415882
lea ecx, [esp + 0x74]
mov dword [esp + 0x64], 0xffffffff
call fcn.00415882
mov ecx, dword [esp + 0x5c]
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x64
ret
Function at 0x402160
Capabilities:
Delete file
Read .ini file

Disassembly:
sub esp, 0x240
push ebp
push esi
push edi
mov ecx, 5
mov esi, str.c:windows_system32_
lea edi, [esp + 0x4c]
rep movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
mov ecx, 0x3a
xor eax, eax
lea edi, [esp + 0x61]
mov byte [esp + 0x14c], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x14d]
mov byte [esp + 0xc], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, 0xf
xor eax, eax
lea edi, [esp + 0xd]
push 0xff
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x50]
lea ecx, [esp + 0x150]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll_strncpy]
mov edi, str.cfig.ini
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x158]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push eax
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
lea edx, [esp + 0x5c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.config.ini
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
lea eax, [esp + 0x15c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.MSVCRT.dll__access]
add esp, 0x14
cmp eax, 0xffffffff
je 0x4022b5
lea ecx, [esp + 0x4c]
lea edx, [esp + 0x14c]
push ecx
push edx
call fcn.00410630
add esp, 8
lea eax, [esp + 0x4c]
lea ecx, [esp + 0xc]
push eax
push 0x104
push ecx
push 0
push 0x41a658
push str.CONFIG
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea edx, [esp + 0x4c]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea edi, [esp + 0xc]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, 0x41cd08
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov al, 1
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebp
add esp, 0x240
ret
pop edi
pop esi
xor al, al
pop ebp
add esp, 0x240
ret
Function at 0x4022d0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x415d24
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push ebx
push esi
mov esi, ecx
push edi
mov dword [esp + 0x10], esi
mov dword [esi], 0x41728c
lea ebx, [esi + 4]
xor edi, edi
mov ecx, ebx
mov dword [esp + 0x1c], edi
call fcn.00411b50
lea ecx, [esi + 0x20]
mov byte [esp + 0x1c], 1
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esi + 0x24]
mov byte [esp + 0x1c], 2
call sub.MFC42.DLL_CString::CString_2
mov al, byte [esp + 0xf]
push 0xb20
mov byte [esp + 0x20], 3
mov byte [esi + 0x38], al
call sub.MFC42.DLL_operatornew
mov dword [eax], eax
mov dword [eax + 4], eax
add esp, 4
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], edi
lea ecx, [esi + 0xb74]
mov byte [esp + 0x1c], 4
call fcn.00413350
mov cl, byte [esp + 0xf]
lea eax, [esi + 0xb60]
mov byte [esi + 0xb90], cl
mov dword [esi + 0xb94], edi
mov dword [esi + 0xb98], edi
mov dword [esi + 0xb9c], edi
mov dword [esi + 0xba0], edi
mov dword [esi + 0xba4], edi
mov dword [esi + 0xba8], edi
mov dword [esi + 0xbac], edi
mov dword [esi + 0xbb0], edi
mov dword [esi + 0xbb4], edi
mov dword [esi + 0xbb8], edi
mov dword [esi + 0xbbc], edi
xor edx, edx
mov dword [esi], 0x417280
mov dword [ebx], 0x417270
mov dword [esi + 0x18], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edi
mov dword [eax], edx
mov ecx, dword [esp + 0x14]
pop edi
mov dword [eax + 4], edx
mov dword [eax + 8], edx
mov dword [eax + 0xc], edx
mov dword [eax + 0x10], edx
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x410630
Capabilities:
Read file on windows
Write file on windows

Disassembly:
sub esp, 0xc8
mov ecx, 0x19
xor eax, eax
push ebx
push ebp
push esi
push edi
lea edi, [esp + 0x10]
mov esi, dword [sym.imp.MSVCRT.dll_fopen]
rep stosd dword es:[edi], eax
mov ecx, 0x19
lea edi, [esp + 0x74]
rep stosd dword es:[edi], eax
mov edi, dword [esp + 0xdc]
push 0x41b5bc
push edi
call esi
mov ebp, eax
add esp, 8
test ebp, ebp
jne 0x41068c
push edi
push str.open__s_error_n
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc8
ret
mov edi, dword [esp + 0xe0]
push 0x41b5a8
push edi
call esi
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x4106c7
push edi
push str.open__s_error_n
call dword [sym.imp.MSVCRT.dll_printf]
push ebp
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc8
ret
test byte [ebp + 0xc], 0x10
jne 0x410723
push ebp
push 0x64
lea eax, [esp + 0x18]
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fread]
lea ecx, [esp + 0x84]
mov esi, eax
push ecx
mov edi, str.DLF394_k3__k
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
lea edx, [esp + 0x24]
push esi
dec ecx
push edx
push ecx
push str.DLF394_k3__k
call fcn.00410790
push ebx
push esi
lea eax, [esp + 0xa0]
push 1
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
mov al, byte [ebp + 0xc]
add esp, 0x34
test al, 0x10
je 0x4106cd
mov esi, dword [sym.imp.MSVCRT.dll_fclose]
push ebp
call esi
push ebx
call esi
add esp, 8
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc8
ret

Function at 0x410880
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 4]
mov edx, ecx
push esi
mov esi, dword [eax + 0x400]
dec ecx
push edi
mov edi, dword [eax + 0x404]
test edx, edx
je 0x4108e7
push ebx
mov ebx, dword [esp + 0x14]
push ebp
lea ebp, [ecx + 1]
inc esi
and esi, 0xff
mov edx, dword [eax + esi*4]
add edi, edx
and edi, 0xff
mov ecx, dword [eax + edi*4]
mov dword [eax + edi*4], edx
mov dword [eax + esi*4], ecx
add cl, dl
mov dl, byte [ebx]
and ecx, 0xff
mov cl, byte [eax + ecx*4]
xor dl, cl
mov byte [ebx], dl
inc ebx
dec ebp
jne 0x4108a6
pop ebp
mov dword [eax + 0x404], edi
pop ebx
mov dword [eax + 0x400], esi
pop edi
pop esi
ret
mov dword [eax + 0x404], edi
mov dword [eax + 0x400], esi
pop edi
pop esi
ret

Function at 0x410900
Capabilities:
Initialize winsock library
Terminate process

Disassembly:
sub esp, 0x190
lea eax, [esp]
push esi
mov esi, ecx
push eax
push 0x202
mov dword [esi], 0x4172a8
mov dword [esi + 4], 0xffffffff
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x410940
push 0x41b5c8
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 4
push 0
call dword [sym.imp.MSVCRT.dll_exit]
mov eax, esi
pop esi
add esp, 0x190
ret
Function at 0x4109a0
Capabilities:
Create tcp socket
Create udp socket

Disassembly:
push esi
push 0
push 1
mov esi, ecx
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esi + 4], eax
je 0x4109cf
mov eax, dword [esi]
push 0x2dc6c0
mov ecx, esi
call dword [eax + 0x44]
mov edx, dword [esi]
push 0x4c4b40
mov ecx, esi
call dword [edx + 0x48]
mov ecx, dword [esi + 4]
xor eax, eax
cmp ecx, 0xffffffff
pop esi
setne al
ret

Function at 0x410a00
Capabilities:
Connect socket
Get socket status
Resolve dns
Set socket configuration

Disassembly:
sub esp, 0x124
xor eax, eax
push ebx
mov dword [esp + 4], eax
mov ebx, ecx
mov ecx, dword [esp + 0x130]
mov dword [esp + 8], eax
push esi
push edi
mov dword [esp + 0x14], eax
push ecx
mov dword [esp + 0x1c], eax
mov word [esp + 0x10], 2
call dword [sym.imp.WS2_32.dll_htons]
mov esi, dword [esp + 0x134]
mov word [esp + 0xe], ax
push esi
call dword [sym.imp.WS2_32.dll_inet_addr]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x410a80
push esi
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x410a65
pop edi
pop esi
pop ebx
add esp, 0x124
ret 0xc
movsx ecx, word [eax + 0xa]
mov edx, dword [eax + 0xc]
mov eax, ecx
lea edi, [esp + 0x10]
mov esi, dword [edx]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x13c]
test edi, edi
jle 0x410b6a
mov edx, dword [ebx + 4]
mov esi, dword [sym.imp.WS2_32.dll_ioctlsocket]
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], 1
push ecx
push 0x8004667e
push edx
call esi
cmp eax, 0xffffffff
jne 0x410ac0
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 0xc
mov ecx, dword [ebx + 4]
lea eax, [esp + 0xc]
push 0x10
push eax
push ecx
call dword [sym.imp.WS2_32.dll_connect]
mov edx, dword [ebx + 4]
mov dword [esp + 0x24], edi
lea eax, [esp + 0x24]
xor edi, edi
push eax
lea ecx, [esp + 0x30]
push edi
push ecx
push edi
push edi
mov dword [esp + 0x44], edx
mov dword [esp + 0x40], 1
mov dword [esp + 0x3c], edi
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jg 0x410b24
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x41b5ec
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebx
add esp, 0x124
ret 0xc
mov eax, dword [ebx + 4]
lea edx, [esp + 0x1c]
push edx
push 0x8004667e
push eax
mov dword [esp + 0x28], edi
call esi
cmp eax, 0xffffffff
jne 0x410b59
push 0x41b5d8
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
add esp, 0x124
ret 0xc
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x124
ret 0xc
mov edx, dword [ebx + 4]
lea ecx, [esp + 0xc]
push 0x10
push ecx
push edx
call dword [sym.imp.WS2_32.dll_connect]
neg eax
sbb eax, eax
pop edi
pop esi
inc eax
pop ebx
add esp, 0x124
ret 0xc
Function at 0x410de0
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, dword [esp + 8]
mov edx, dword [esp + 4]
push esi
push 0
push eax
mov eax, dword [ecx + 4]
push edx
push eax
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
test esi, esi
jge 0x410e1c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push esi
push 0x41b640
call dword [sym.imp.MSVCRT.dll_printf]
mov eax, dword [0x41b5c0]
add esp, 0xc
pop esi
ret 0xc
mov eax, esi
pop esi
ret 0xc

Function at 0x411380
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x54
push esi
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x18]
mov esi, dword [esp + 0x60]
rep stosd dword es:[edi], eax
lea eax, [esp + 8]
lea ecx, [esp + 0x18]
push eax
push ecx
push 0
push 0
push 0x30
push 0
push 0
push 0
push 0
push esi
mov dword [esp + 0x40], 0x44
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x4113e1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push 0x41b710
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 0xc
xor eax, eax
pop edi
pop esi
add esp, 0x54
ret 4
pop edi
mov eax, 1
pop esi
add esp, 0x54
ret 4
Function at 0x4113f0
Capabilities:
Enumerate processes
Terminate process

Disassembly:
sub esp, 0x228
push ebx
push ebp
push esi
push edi
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x139]
mov byte [esp + 0x138], 0
rep stosd dword es:[edi], eax
mov ebp, dword [esp + 0x23c]
lea ecx, [esp + 0x138]
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x240]
push ebp
push eax
push 0x41b7b0
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x10
xor eax, eax
mov ecx, 0x4a
lea edi, [esp + 0x10]
push eax
push 2
rep stosd dword es:[edi], eax
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x411465
push str.CreateToolhelp32Snapshot_error_n
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 4
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
mov dword [esp + 0x10], 0x128
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov esi, ecx
add esi, ebp
cmp esi, ebp
jbe 0x411493
mov al, byte [esi]
cmp al, 0x2f
je 0x411492
cmp al, 0x5c
je 0x411492
dec esi
cmp esi, ebp
ja 0x411481
jmp 0x411493
inc esi
lea edx, [esp + 0x10]
push edx
push ebx
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x4114bc
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x4114d2
push ebp
push 0x41b774
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 8
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x228
ret 8
lea eax, [esp + 0x10]
push eax
push ebx
call sub.KERNEL32.dll_Process32Next
test eax, eax
je 0x4114bc
mov edi, dword [sym.imp.MSVCRT.dll__stricmp]
lea ecx, [esp + 0x34]
push ecx
push esi
call edi
add esp, 8
test eax, eax
je 0x41151d
lea edx, [esp + 0x34]
lea eax, [esp + 0x138]
push edx
push eax
call edi
add esp, 8
test eax, eax
je 0x41151d
lea ecx, [esp + 0x10]
push ecx
push ebx
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x4114e7
jmp 0x4114bc
mov edx, dword [esp + 0x18]
push edx
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
jne 0x411540
push ebp
push 0x41b754
jmp 0x4114b3
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x41157e
lea eax, [esp + 0x138]
push eax
push 0x41b73c
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 8
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push ebx
call esi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x228
ret 8
lea ecx, [esp + 0x138]
push ecx
push 0x41b724
call dword [sym.imp.MSVCRT.dll_printf]
add esp, 8
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push ebx
call esi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x228
ret 8

Function at 0x411bb0
Capabilities:
Create thread

Disassembly:
push esi
push 0
push 0
push 0
mov esi, ecx
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [esi + 0x10], eax
lea eax, [esi + 4]
push eax
push 0
push esi
push 0x411c60
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
mov dword [esi + 0xc], eax
pop esi
setne al
ret
Function at 0x411d50
Capabilities:
Read file via mapping

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x24
test eax, eax
push esi
push edi
mov esi, ecx
jne 0x411d8c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
lea ecx, [esi + 8]
call sub.MFC42.DLL_CString::GetBuffer
push eax
add esi, 0x1c
push 0x41b880
push esi
call sub.MFC42.DLL_CString::Format
add esp, 0x10
xor al, al
pop edi
pop esi
add esp, 0x24
ret 4
lea edi, [esi + 8]
push eax
mov ecx, edi
call fcn.004158b8
mov eax, dword [edi]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x411e96
lea ecx, [esp + 8]
push ecx
push eax
call dword [sym.imp.MSVCRT.dll__stat]
add esp, 8
cmp eax, 0xffffffff
jne 0x411de4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
mov ecx, edi
call sub.MFC42.DLL_CString::GetBuffer
push eax
add esi, 0x1c
push 0x41b84c
push esi
call sub.MFC42.DLL_CString::Format
add esp, 0x10
xor al, al
pop edi
pop esi
add esp, 0x24
ret 4
mov eax, dword [edi]
push 0
push 0x80
push 3
push 0
push 1
push closesocket
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [esi + 0xc], eax
jne 0x411e23
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
mov ecx, edi
call sub.MFC42.DLL_CString::GetBuffer
push eax
lea edx, [esi + 0x1c]
push 0x41b81c
push edx
jmp 0x411e87
push 0
push 0
push 0
push 2
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
test eax, eax
mov dword [esi + 0x10], eax
jne 0x411e57
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
mov ecx, edi
call sub.MFC42.DLL_CString::GetBuffer
push eax
lea eax, [esi + 0x1c]
push 0x41b7e8
push eax
jmp 0x411e87
push 0
push 0
push 0
push 4
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
test eax, eax
mov dword [esi + 0x14], eax
jne 0x411ea0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
mov ecx, edi
call sub.MFC42.DLL_CString::GetBuffer
push eax
lea ecx, [esi + 0x1c]
push 0x41b7b8
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0x10
mov ecx, esi
call fcn.00411f30
pop edi
xor al, al
pop esi
add esp, 0x24
ret 4
mov eax, dword [esp + 0x1c]
pop edi
mov dword [esi + 0x18], eax
shr eax, 0xf
mov dword [esi + 4], eax
mov al, 1
pop esi
add esp, 0x24
ret 4
Function at 0x412500
Capabilities:
Delete file
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4166e0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x25c
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov dword [ebp - 0x10], esp
mov ecx, 0x41
xor eax, eax
lea edi, [ebp - 0x164]
push str.mylog.txt
push esi
rep stosd dword es:[edi], eax
call dword [sym.imp.MSVCRT.dll__strcmpi]
add esp, 8
mov ecx, 0x41
test eax, eax
jne 0x41256d
xor eax, eax
lea edi, [ebp - 0x268]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x268]
push eax
call fcn.004126e0
push esi
lea ecx, [ebp - 0x268]
jmp 0x41258a
xor eax, eax
lea edi, [ebp - 0x268]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x268]
push eax
call fcn.004126e0
push esi
lea ecx, [ebp - 0x268]
mov edi, dword [sym.imp.MSVCRT.dll_sprintf]
push ecx
lea edx, [ebp - 0x164]
push 0x41b7b0
push edx
call edi
add esp, 0x14
lea eax, [ebp - 0x164]
push 0
push 0x80
push 4
push 0
push 7
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x4126c3
mov eax, dword [ebp + 8]
mov dword [ebp - 4], 0
test eax, eax
je 0x4126c3
lea ecx, [ebp - 0x20]
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x16]
mov ecx, dword [ebp - 0x18]
and edx, 0xffff
and eax, 0xffff
push edx
mov edx, dword [ebp - 0x1a]
and ecx, 0xffff
push eax
mov eax, dword [ebp - 0x1e]
push ecx
mov ecx, dword [ebp - 0x20]
and edx, 0xffff
and eax, 0xffff
push edx
and ecx, 0xffff
push eax
push ecx
lea edx, [ebp - 0x60]
push str._d__02d__02d__02d:_02d:_02d
push edx
call edi
add esp, 0x20
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [ebp + 0xc]
push 0
push eax
lea edi, [ebp - 0x60]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
dec ecx
push ecx
lea ecx, [ebp - 0x60]
push ecx
push esi
call ebx
lea edx, [ebp + 0xc]
push 0
push edx
mov edx, dword [ebp + 8]
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push esi
call ebx
lea eax, [ebp + 0xc]
push 0
push eax
push 2
push 0x41b8e8
push esi
call ebx
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp edi, 0x100000
jbe 0x4126c3
lea ecx, [ebp - 0x164]
push 0x41cd48
push ecx
call fcn.00412750
add esp, 8
lea edx, [ebp - 0x164]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x412750
Capabilities:
Copy file

Disassembly:
sub esp, 0x35c
lea eax, [esp]
push ebx
push ebp
push esi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x1a]
mov eax, dword [esp + 0x18]
and ecx, 0xffff
and edx, 0xffff
push ecx
mov ecx, dword [esp + 0x1a]
and eax, 0xffff
push edx
mov edx, dword [esp + 0x1a]
push eax
mov eax, dword [esp + 0x1c]
and ecx, 0xffff
and edx, 0xffff
push ecx
and eax, 0xffff
push edx
push eax
lea ecx, [esp + 0x38]
push str._d_02d_02d_02d_02d_02d
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
mov ebx, dword [esp + 0x394]
add esp, 0x20
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x268]
mov esi, 0x41cd48
rep stosd dword es:[edi], eax
mov ecx, 0x41
lea edi, [esp + 0x164]
rep stosd dword es:[edi], eax
mov eax, ebx
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x412808
test cl, cl
je 0x412804
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x412808
add eax, 2
add esi, 2
test cl, cl
jne 0x4127e4
xor eax, eax
jmp 0x41280d
sbb eax, eax
sbb eax, 0xffffffff
mov ebp, dword [sym.imp.MSVCRT.dll_strrchr]
test eax, eax
je 0x41291b
push ebx
lea eax, [esp + 0x168]
push 0x41a408
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
push 0x5c
push ebx
call ebp
add esp, 0x14
test eax, eax
je 0x412899
mov esi, 0x41a64c
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x412864
test cl, cl
je 0x412860
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x412864
add eax, 2
add esi, 2
test cl, cl
jne 0x412840
xor eax, eax
jmp 0x412869
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x412899
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x164]
push 0x41a64c
rep stosd dword es:[edi], eax
push ebx
lea eax, [esp + 0x16c]
push 0x41b7b0
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x10
mov ebx, dword [esp + 0x370]
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x60]
push ebx
lea edx, [esp + 0x64]
push 0x41a408
rep stosd dword es:[edi], eax
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
push 0x5c
push ebx
call ebp
mov ebp, eax
add esp, 0x14
test ebp, ebp
je 0x412956
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x60]
push 1
rep stosd dword es:[edi], eax
lea eax, [esp + 0x64]
push ebp
push eax
call dword [sym.imp.MSVCRT.dll_strncpy]
add esp, 0xc
mov esi, 0x41a64c
lea eax, [esp + 0x60]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x412938
test cl, cl
je 0x412917
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x412938
add eax, 2
add esi, 2
test cl, cl
jne 0x4128f7
xor eax, eax
jmp 0x41293d
mov ebx, dword [esp + 0x370]
lea ecx, [esp + 0x164]
push ecx
push ebx
call fcn.004129a0
add esp, 8
jmp 0x4128a0
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x412956
inc ebp
lea eax, [esp + 0x60]
push ebp
push 0x41a408
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea ecx, [esp + 0x60]
lea edx, [esp + 0x20]
push ecx
lea eax, [esp + 0x168]
push edx
push eax
lea ecx, [esp + 0x274]
push str._s_s_s
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x14
lea edx, [esp + 0x268]
push 0
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x35c
ret