joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404b20
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x40d1b0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x22c
push ebx
xor ebx, ebx
push esi
mov esi, ecx
mov dword [esp + 0xc], ebx
lea ecx, [esp + 0x10]
mov dword [esp + 0x23c], 2
call fcn.0040bef0
mov eax, dword [esi + 4]
push ebx
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x244], 3
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
jne 0x404be2
push ebx
push ebx
push 0x413160
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CFileFind::Close
mov esi, dword [esp + 0x244]
push 0x413660
mov ecx, esi
call fcn.0040bf38
mov dword [esp + 0xc], 1
lea ecx, [esp + 0x10]
mov byte [esp + 0x23c], 2
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x248]
mov byte [esp + 0x23c], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x24c]
mov byte [esp + 0x23c], bl
call sub.MFC42.DLL_CString::CString
mov eax, esi
jmp 0x404cd0
push edi
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CFileFind::Close
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CString::CString_2
mov eax, dword [esi + 4]
mov esi, dword [esp + 0x250]
mov edi, dword [esp + 0x24c]
push eax
push 0x208
push 0x208
lea ecx, [esp + 0x18]
mov byte [esp + 0x24c], 4
call sub.MFC42.DLL_CString::GetBuffer
push eax
push 0x413084
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov eax, dword [esp + 0xc]
lea ecx, [esp + 0x30]
push eax
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
lea edi, [esp + 0x38]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x38]
repne scasb al, byte es:[edi]
not ecx
dec ecx
push edx
lea eax, [esp + 0x18]
push 0x41315c
push eax
mov byte [esp + ecx + 0x45], bl
call sub.MFC42.DLL_CString::Format
mov esi, dword [esp + 0x25c]
add esp, 0x14
lea ecx, [esp + 0xc]
push ecx
mov ecx, esi
call sub.MFC42.DLL_CString::CString_1
lea ecx, [esp + 0xc]
mov dword [esp + 0x10], 1
mov byte [esp + 0x240], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x240], 2
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x24c]
mov byte [esp + 0x240], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x250]
mov byte [esp + 0x240], bl
call sub.MFC42.DLL_CString::CString
mov eax, esi
pop edi
mov ecx, dword [esp + 0x234]
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x238
ret 0xc
Function at 0x404cf0
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x40d1d6
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x32c
push esi
mov esi, ecx
lea ecx, [esp + 8]
call fcn.0040bef0
mov eax, dword [esi + 4]
push 0
push eax
lea ecx, [esp + 0x10]
mov dword [esp + 0x340], 0
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
jne 0x404d63
push eax
push eax
push 0x413160
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 8]
call sub.MFC42.DLL_CFileFind::Close
lea ecx, [esp + 8]
mov dword [esp + 0x338], 0xffffffff
call sub.MFC42.DLL_CFileFind::CFileFind
jmp 0x404df1
push ebp
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CFileFind::Close
mov esi, dword [esi + 4]
lea eax, [esp + 0x28]
push esi
push 0x30c
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionNamesA]
mov ebp, eax
xor esi, esi
test ebp, ebp
jle 0x404ddc
push edi
mov edi, dword [esp + 0x348]
lea ecx, [esp + esi + 0x2c]
push ecx
lea ecx, [esp + 0x10]
call fcn.0040bf38
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0xc]
push ecx
mov ecx, edi
mov eax, dword [edx - 8]
mov byte [esp + 0x344], 1
lea esi, [esi + eax + 1]
mov eax, dword [edi + 8]
push eax
call sub.MFC42.DLL_CStringArray::SetAtGrow
lea ecx, [esp + 0xc]
mov byte [esp + 0x340], 0
call sub.MFC42.DLL_CString::CString
mov edx, ebp
sub edx, esi
test edx, edx
jg 0x404d91
pop edi
lea ecx, [esp + 0xc]
mov dword [esp + 0x33c], 0xffffffff
call sub.MFC42.DLL_CFileFind::CFileFind
pop ebp
mov ecx, dword [esp + 0x330]
pop esi
mov dword fs:[0], ecx
add esp, 0x338
ret 4
Function at 0x404e10
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x40d1fe
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x32c
push esi
mov esi, ecx
lea ecx, [esp + 8]
mov dword [esp + 0x338], 0
call fcn.0040bef0
mov eax, dword [esi + 4]
push 0
push eax
lea ecx, [esp + 0x10]
mov byte [esp + 0x340], 1
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
jne 0x404e9f
push eax
push eax
push 0x413160
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 8]
call sub.MFC42.DLL_CFileFind::Close
lea ecx, [esp + 8]
mov byte [esp + 0x338], 0
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x340]
mov dword [esp + 0x338], 0xffffffff
call sub.MFC42.DLL_CString::CString
jmp 0x404f49
push ebp
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CFileFind::Close
mov esi, dword [esi + 4]
mov ecx, dword [esp + 0x344]
push esi
lea eax, [esp + 0x2c]
push 0x30c
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionA]
mov ebp, eax
xor esi, esi
test ebp, ebp
jle 0x404f20
push edi
mov edi, dword [esp + 0x34c]
lea edx, [esp + esi + 0x2c]
lea ecx, [esp + 0xc]
push edx
call fcn.0040bf38
mov eax, dword [esp + 0xc]
lea ecx, [esp + 0xc]
push ecx
mov ecx, edi
mov eax, dword [eax - 8]
mov byte [esp + 0x344], 2
lea esi, [esi + eax + 1]
mov eax, dword [edi + 8]
push eax
call sub.MFC42.DLL_CStringArray::SetAtGrow
lea ecx, [esp + 0xc]
mov byte [esp + 0x340], 1
call sub.MFC42.DLL_CString::CString
mov edx, ebp
sub edx, esi
test edx, edx
jg 0x404ed5
pop edi
lea ecx, [esp + 0xc]
mov byte [esp + 0x33c], 0
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x344]
mov dword [esp + 0x33c], 0xffffffff
call sub.MFC42.DLL_CString::CString
pop ebp
mov ecx, dword [esp + 0x330]
pop esi
mov dword fs:[0], ecx
add esp, 0x338
ret 8
Function at 0x407c10
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x40d9d8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
lea ecx, [esp]
mov dword [esp + 0x28], 0
call sub.MFC42.DLL_CString::CString_2
lea eax, [esp + 0x30]
lea ecx, [esp]
push eax
mov byte [esp + 0x2c], 1
call sub.MFC42.DLL_CString::operator_1
lea ecx, [esp + 4]
call fcn.0040bef0
mov ecx, dword [esp]
push 0
push ecx
lea ecx, [esp + 0xc]
mov byte [esp + 0x30], 2
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
lea ecx, [esp + 4]
jne 0x407cb7
call sub.MFC42.DLL_CFileFind::Close
lea ecx, [esp + 4]
mov byte [esp + 0x28], 1
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp]
mov byte [esp + 0x28], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x30]
mov dword [esp + 0x28], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor eax, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
add esp, 0x2c
ret 4
call sub.MFC42.DLL_CFileFind::Close
lea ecx, [esp + 4]
mov byte [esp + 0x28], 1
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp]
mov byte [esp + 0x28], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x30]
mov dword [esp + 0x28], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x20]
mov eax, 1
mov dword fs:[0], ecx
add esp, 0x2c
ret 4
Function at 0x407d00
Capabilities:
Get disk information

Disassembly:
push 0xffffffffffffffff
push 0x40da32
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x21c
push ebx
push ebp
mov ebp, ecx
push esi
push edi
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_2
xor esi, esi
lea ecx, [esp + 0x14]
mov dword [esp + 0x234], esi
call sub.MFC42.DLL_CString::Empty
lea eax, [esp + 0x24]
push eax
push 0x208
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsA]
mov edx, dword [0x4136d0]
lea ecx, [esp + 0x1c]
push 3
push ecx
lea ecx, [edx + 0x24]
mov edi, eax
call sub.MFC42.DLL_CString::Left
cmp edi, esi
mov byte [esp + 0x234], 1
jle 0x407e00
mov ebx, dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
lea eax, [esp + esi + 0x24]
lea ecx, [esp + 0x10]
push eax
call fcn.0040bf38
lea ecx, [esp + 0x10]
mov byte [esp + 0x234], 2
call sub.MFC42.DLL_CString::MakeUpper
mov ecx, dword [esp + 0x10]
push ecx
call ebx
cmp eax, 3
jne 0x407dbb
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
push edx
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
jne 0x407de1
mov ecx, dword [esp + 0x10]
mov byte [esp + 0x234], 1
mov eax, dword [ecx - 8]
lea ecx, [esp + 0x10]
lea esi, [esi + eax + 1]
call sub.MFC42.DLL_CString::CString
mov edx, edi
sub edx, esi
test edx, edx
jg 0x407d79
jmp 0x407e00
lea eax, [esp + esi + 0x24]
lea ecx, [esp + 0x14]
push eax
call sub.MFC42.DLL_CString::operator
lea ecx, [esp + 0x10]
mov byte [esp + 0x234], 1
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x14]
mov eax, dword [ecx - 8]
test eax, eax
jne 0x407e19
lea edx, [esp + 0x1c]
lea ecx, [esp + 0x14]
push edx
call sub.MFC42.DLL_CString::operator_1
push 0x413680
lea ecx, [esp + 0x1c]
call sub.MFC42.DLL_CString::CString_1
push 0x20
lea ecx, [esp + 0x1c]
mov byte [esp + 0x238], 3
call sub.MFC42.DLL_CString::Remove
lea eax, [esp + 0x14]
push str.UserData
lea ecx, [esp + 0x24]
push eax
push ecx
call sub.MFC42.DLL_operator_2
lea edx, [esp + 0x18]
mov bl, 4
push edx
push eax
lea eax, [esp + 0x18]
mov byte [esp + 0x23c], bl
push eax
call sub.MFC42.DLL_operator_1
push eax
lea ecx, [ebp + 0xa4]
mov byte [esp + 0x238], 5
call sub.MFC42.DLL_CString::operator_1
lea ecx, [esp + 0x10]
mov byte [esp + 0x234], bl
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x234], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x234], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov byte [esp + 0x234], 0
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov dword [esp + 0x234], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x22c]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x228
ret
Function at 0x4090b0
Capabilities:
Query or enumerate registry key

Disassembly:
push 0xffffffffffffffff
push 0x40dd2e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x124
push ebx
xor ebx, ebx
push esi
push edi
mov dword [esp + 0x24], ebx
xor esi, esi
mov dword [esp + 0x138], 1
mov dword [esp + 0x14], esi
lea ecx, [esp + 0xc]
mov byte [esp + 0x138], 2
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [esp + 0x144]
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [esp + 0x18]
mov byte [esp + 0x138], 3
push eax
push 8
push ebx
push ecx
push 0x80000001
call edi
cmp eax, ebx
jne 0x40921c
push ebp
xor ebp, ebp
mov ecx, dword [esp + 0x1c]
push ebx
push ebx
push ebx
lea edx, [esp + 0x30]
push ebx
lea eax, [esp + 0x40]
push edx
push eax
push ebp
push ecx
mov dword [esp + 0x44], 0x104
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
cmp eax, 0x103
je 0x40920a
cmp eax, ebx
jne 0x40920a
lea edx, [esp + 0x30]
lea ecx, [esp + 0x10]
push edx
call sub.MFC42.DLL_CString::operator
lea eax, [esp + 0x148]
push 0x41305c
lea ecx, [esp + 0x24]
push eax
push ecx
call sub.MFC42.DLL_operator_2
lea edx, [esp + 0x10]
mov byte [esp + 0x13c], 4
push edx
push eax
lea eax, [esp + 0x34]
push eax
call sub.MFC42.DLL_operator_1
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x140], 5
call sub.MFC42.DLL_CString::operator_1
lea ecx, [esp + 0x2c]
mov byte [esp + 0x13c], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x13c], 3
call sub.MFC42.DLL_CString::CString
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push ecx
push 0xf003f
push ebx
push edx
push 0x80000001
mov dword [esp + 0x28], ebx
call edi
cmp eax, ebx
jne 0x409204
xor eax, eax
cmp esi, ebx
je 0x4091f8
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [esp + 0x14]
cmp eax, ebx
mov dword [esp + 0x18], esi
je 0x40920a
inc ebp
jmp 0x409126
cmp esi, ebx
pop ebp
je 0x40921c
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor esi, esi
mov dword [esp + 0x14], esi
mov edi, dword [esp + 0x140]
lea eax, [esp + 0xc]
push eax
mov ecx, edi
call sub.MFC42.DLL_CString::CString_1
mov dword [esp + 0x24], 1
lea ecx, [esp + 0xc]
mov byte [esp + 0x138], 2
call sub.MFC42.DLL_CString::CString
cmp esi, ebx
je 0x409253
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esp + 0x144]
mov byte [esp + 0x138], bl
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x130]
mov eax, edi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x130
ret 8
Function at 0x4099f0
Capabilities:
Shutdown system

Disassembly:
mov eax, dword [ecx + 0x18]
sub esp, 0x14
test eax, eax
jne 0x409a74
lea eax, [esp]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x409a1e
push eax
push eax
push str.OpenProcessToken
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 8]
push ecx
push str.SeShutdownPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov eax, dword [esp]
push 0
push 0
lea edx, [esp + 0xc]
push 0
push edx
push 0
push eax
mov dword [esp + 0x1c], 1
mov dword [esp + 0x28], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x409a74
push 0
push 0
push 0x4134e4
call sub.MFC42.DLL_AfxMessageBox
add esp, 0x14
ret
push 0
push 2
call dword [sym.imp.USER32.dll_ExitWindowsEx]
test eax, eax
jne 0x409a8e
push eax
push eax
push str.ExitWindowsEx
call sub.MFC42.DLL_AfxMessageBox
add esp, 0x14
ret
Function at 0x409c90
Capabilities:
Create directory

Disassembly:
push 0xffffffffffffffff
push 0x40dea8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x28
push ebp
push esi
mov eax, dword [esp + 0x40]
mov dword [esp + 0x38], 0
mov eax, dword [eax - 8]
cmp eax, 3
je 0x409e20
lea ecx, [esp + 0x14]
call fcn.0040bef0
mov ecx, dword [esp + 0x40]
push 0
push ecx
lea ecx, [esp + 0x1c]
mov byte [esp + 0x40], 1
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
jne 0x409e12
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CString::CString_2
lea edx, [esp + 0x40]
lea ecx, [esp + 8]
push edx
mov byte [esp + 0x3c], 2
call sub.MFC42.DLL_CString::CString_1
push 4
push 0x41305c
lea ecx, [esp + 0x10]
mov byte [esp + 0x40], 3
call sub.MFC42.DLL_CString::Find
mov ebp, dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov esi, eax
cmp esi, 0xffffffff
je 0x409d8b
lea eax, [esp + 0x10]
push esi
push eax
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::Left
push eax
lea ecx, [esp + 0x10]
mov byte [esp + 0x3c], 4
call sub.MFC42.DLL_CString::operator_1
lea ecx, [esp + 0x10]
mov byte [esp + 0x38], 3
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0xc]
push 0
push ecx
lea ecx, [esp + 0x1c]
call sub.MFC42.DLL_CFileFind::FindFile
test eax, eax
jne 0x409d72
mov edx, dword [esp + 0xc]
push eax
push edx
call ebp
test eax, eax
je 0x409d98
lea eax, [esi + 1]
lea ecx, [esp + 8]
push eax
push 0x41305c
call sub.MFC42.DLL_CString::Find
mov esi, eax
cmp esi, 0xffffffff
jne 0x409d26
mov eax, dword [esp + 0x40]
push 0
push eax
call ebp
test eax, eax
jne 0x409df6
push 0
push 0
push str.Create__directory_fail_
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 8]
mov byte [esp + 0x38], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0xc]
mov byte [esp + 0x38], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x38], 0
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x40]
mov dword [esp + 0x38], 0xffffffff
call sub.MFC42.DLL_CString::CString
pop esi
xor eax, eax
pop ebp
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
add esp, 0x34
ret 4
lea ecx, [esp + 8]
mov byte [esp + 0x38], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0xc]
mov byte [esp + 0x38], 1
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x38], 0
call sub.MFC42.DLL_CFileFind::CFileFind
lea ecx, [esp + 0x40]
mov dword [esp + 0x38], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x30]
pop esi
mov eax, 1
pop ebp
mov dword fs:[0], ecx
add esp, 0x34
ret 4
Function at 0x40b950
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x40e18b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0xc], esi
mov dword [esi], 0x40fd88
mov eax, dword [esi + 0x30]
xor ebp, ebp
cmp eax, ebp
mov dword [esp + 0x1c], 1
je 0x40b9e0
mov edx, dword [esi + 0x24]
mov eax, dword [esi + 0x2c]
mov edi, dword [esi + 0x20]
mov ecx, edx
push ebx
sub eax, ecx
mov ecx, dword [esi + 0x28]
mov ebx, edi
sub ecx, ebx
mov ebx, dword [esi + 0x1c]
cmp esi, ebp
je 0x40b9a7
mov ebp, dword [esi + 4]
push 0xcc0020
push edx
push edi
push ebp
push eax
mov eax, dword [ebx + 4]
push ecx
push edx
push edi
push eax
call dword [sym.imp.GDI32.dll_BitBlt]
mov eax, dword [esi + 0x18]
pop ebx
test eax, eax
jne 0x40b9d1
mov ecx, dword [esi + 4]
push eax
push ecx
call sub.MFC42.DLL_CDC::SelectGdiObject
jmp 0x40b9e6
mov eax, dword [eax + 4]
mov ecx, dword [esi + 4]
push eax
push ecx
call sub.MFC42.DLL_CDC::SelectGdiObject
jmp 0x40b9e6
mov dword [esi + 8], ebp
mov dword [esi + 4], ebp
lea edi, [esi + 0x10]
mov dword [esp + 0x10], edi
mov dword [edi], 0x40fd58
mov ecx, edi
mov byte [esp + 0x1c], 2
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov ecx, esi
mov dword [edi], 0x40f514
mov dword [esp + 0x1c], 0xffffffff
call fcn.0040c322
mov ecx, dword [esp + 0x14]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x419bda
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push edi
push dword [ebp + 8]
mov ebx, eax
push ebx
push esi
call fcn.0040ada2
push esi
call dword [sym.imp.MSVCRT.dll_wcslen]
cmp eax, 3
pop ecx
jle 0x419bff
lea edi, [esi + eax*2 - 8]
jmp 0x419c0e
mov ecx, 0x103
sub ecx, eax
cmp ecx, 3
jl 0x419c44
lea edi, [esi + eax*2]
and dword [ebp - 4], 0
mov eax, edi
sub eax, esi
sar eax, 1
sub ebx, eax
push dword [ebp - 4]
push 0x402b38
push ebx
push edi
call fcn.00419b49
add esp, 0x10
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x419c4a
inc dword [ebp - 4]
cmp dword [ebp - 4], 0x3e7
jl 0x419c1a
xor al, al
pop edi
pop ebx
leave
ret
mov al, 1
jmp 0x419c46

Function at 0x419c4e
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x24
mov eax, dword [0x492bc0]
push ebx
mov ebx, dword [esp + 0x2c]
push esi
push dword [esp + 0x38]
xor esi, esi
push dword [esp + 0x38]
mov dword [esp + 0x30], eax
push ebx
mov dword [esp + 0x14], 1
mov dword [esp + 0x1c], esi
call fcn.0040ada2
push ebx
call dword [sym.imp.MSVCRT.dll_wcslen]
cmp eax, 3
pop ecx
jle 0x419c93
lea eax, [ebx + eax*2 - 8]
mov dword [esp + 0x10], eax
jmp 0x419cac
mov ecx, 0x103
sub ecx, eax
cmp ecx, 3
jl 0x419ca4
lea eax, [ebx + eax*2]
jmp 0x419c8d
mov dword [esp + 8], 0x80040212
cmp dword [esp + 8], 1
mov dword [esp + 0xc], esi
jne 0x419d6b
push ebp
push edi
cmp dword [esp + 0x14], 0x3e7
jge 0x419d69
mov eax, dword [esp + 0x18]
push dword [esp + 0x14]
mov ecx, dword [esp + 0x40]
sub eax, ebx
sar eax, 1
push 0x402b38
sub ecx, eax
push ecx
push dword [esp + 0x24]
call fcn.00419b49
add esp, 0x10
push esi
push 0x8000000
push 3
push esi
push 1
push SysReAllocStringLen
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x419d69
push esi
push esi
push dword [0x491a9c]
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push esi
lea eax, [esp + 0x20]
push eax
push 0x10
lea eax, [esp + 0x2c]
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x419d5a
cmp dword [esp + 0x1c], 0x10
jne 0x419d5a
push 4
pop ecx
mov edi, 0x40547c
lea esi, [esp + 0x20]
xor eax, eax
repe cmpsd dword [esi], dword es:[edi]
jne 0x419d58
and dword [esp + 0x10], eax
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
inc dword [esp + 0x14]
cmp dword [esp + 0x10], 1
je 0x419cbd
pop edi
pop ebp
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 8]
pop esi
pop ebx
call fcn.0046cd1e
add esp, 0x24
ret
Function at 0x41c31a
Capabilities:
Enumerate pe sections
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
push 2
xor ebx, ebx
lea eax, [ebp - 0x14]
push eax
push ebx
push dword [ebp + 8]
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], ebx
call esi
cmp eax, 0xffffffff
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x18], eax
jne 0x41c36e
call edi
test eax, eax
je 0x41c36e
call edi
push eax
call fcn.0042f6c9
cmp eax, ebx
pop ecx
mov dword [ebp - 4], eax
jl 0x41c36e
mov dword [ebp - 4], 0x80030019
cmp dword [ebp - 0x14], ebx
je 0x41c37a
mov dword [ebp - 4], 0x8002000a
cmp dword [ebp - 4], ebx
jl 0x41c4be
mov eax, dword [0x491a9c]
push eax
mov dword [ebp - 0xc], eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
cmp eax, ebx
pop ecx
mov dword [ebp - 8], eax
jne 0x41c3a0
mov dword [ebp - 4], 0x8007000e
cmp dword [ebp - 4], ebx
jl 0x41c4be
push ebx
push ebx
push ebx
push dword [ebp + 8]
call esi
cmp eax, 0xffffffff
jne 0x41c3c2
call edi
push eax
call fcn.0042f6c9
pop ecx
mov dword [ebp - 4], eax
cmp dword [ebp - 4], ebx
jl 0x41c4be
mov esi, dword [ebp - 0xc]
push ebx
lea eax, [ebp - 0x10]
push eax
push esi
push dword [ebp - 8]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41c3e9
cmp dword [ebp - 0x10], esi
je 0x41c3f5
call edi
push eax
call fcn.0042f6c9
pop ecx
mov dword [ebp - 4], eax
cmp dword [ebp - 4], ebx
jl 0x41c4be
mov eax, dword [ebp - 8]
mov esi, dword [eax + 0x3c]
add esi, eax
cmp dword [esi], 0x4550
jne 0x41c472
cmp word [esi + 0x18], 0x10b
jne 0x41c472
movzx ecx, word [esi + 6]
movzx eax, word [esi + 0x14]
imul ecx, ecx, 0x28
lea eax, [esi + eax + 0x18]
lea edi, [ecx + eax - 0x28]
jmp 0x41c437
test byte [eax + 0x24], 0x40
je 0x41c434
add ebx, dword [eax + 0x10]
add eax, 0x28
cmp eax, edi
jne 0x41c42b
mov ecx, dword [ebp - 0x18]
sub ecx, dword [edi + 0x14]
or dword [edi + 0x24], 0x40
mov dword [edi + 0x10], ecx
push dword [esi + 0x38]
add ebx, ecx
call fcn.0041c2fe
mov dword [edi + 8], eax
mov ecx, dword [esi + 0x54]
push dword [esi + 0x38]
add ecx, ebx
mov dword [esi + 0x20], ebx
call fcn.0041c2fe
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
pop ecx
pop ecx
mov dword [esi + 0x50], eax
xor ebx, ebx
push ebx
push ebx
push ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x41c48f
call edi
push eax
call fcn.0042f6c9
pop ecx
mov dword [ebp - 4], eax
cmp dword [ebp - 4], ebx
jl 0x41c4be
mov esi, dword [ebp - 0xc]
push ebx
lea eax, [ebp - 0x10]
push eax
push esi
push dword [ebp - 8]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41c4b2
cmp dword [ebp - 0x10], esi
je 0x41c4be
call edi
push eax
call fcn.0042f6c9
pop ecx
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0x8002000a
jne 0x41c4ce
mov dword [ebp - 4], 1
cmp dword [ebp - 8], ebx
pop edi
pop esi
pop ebx
je 0x41c4df
push dword [ebp - 8]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
mov eax, dword [ebp - 4]
leave
ret