joyce8/EMBER2024-capa huggingface dataset:
Function at 0x42037c
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff778
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 4], ecx
xor ecx, ecx
push ebp
push 0x4204a1
push dword fs:[ecx]
mov dword fs:[ecx], esp
push 0x400
lea ecx, [ebp - 0x888]
call fcn.00420184
mov esi, eax
mov eax, dword [0x4aaf5c]
cmp byte [eax], 0
je 0x420449
mov eax, dword [0x4aadf4]
call fcn.00404e88
call fcn.00404c50
push 0
push 0
push 0
push 0
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
mov ebx, eax
push ebx
lea eax, [ebp - 4]
mov ecx, 1
mov edx, dword [0x42034c]
call fcn.004088a8
add esp, 4
push 0
push 0
push ebx
mov eax, dword [ebp - 4]
push eax
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
push 0
lea eax, [ebp - 8]
push eax
push ebx
mov eax, dword [ebp - 4]
push eax
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
push 0
lea eax, [ebp - 8]
push eax
push 2
push 0x4204bc
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
jmp 0x420485
push 0x40
lea eax, [ebp - 0x88]
push eax
mov eax, dword [0x4aadc8]
mov eax, dword [eax + 4]
push eax
mov eax, dword [0x4aec48]
call fcn.00408a84
push eax
call sub.user32.dll_LoadStringW_1
push 0x2010
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x888]
push eax
push 0
call sub.user32.dll_MessageBoxW
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4204a8
lea eax, [ebp - 4]
mov edx, dword [0x42034c]
call fcn.004089cc
ret

Function at 0x422020
Capabilities:
Get geographical location

Disassembly:
push ebx
add esp, 0xfffff800
mov ebx, ecx
mov word [esp], 0
push 0x400
lea ecx, [esp + 4]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
mov eax, ebx
mov edx, esp
mov ecx, 0x400
call fcn.00407648
add esp, 0x800
pop ebx
ret

Function at 0x423938
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
mov ebx, eax
xor eax, eax
push ebp
push 0x42397e
push dword fs:[eax]
mov dword fs:[eax], esp
lea edx, [ebp - 4]
mov eax, ebx
call fcn.004238cc
mov eax, dword [ebp - 4]
call fcn.004075a4
push eax
call sub.kernel32.dll_GetFileAttributesW
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x423985
lea eax, [ebp - 4]
call fcn.00406a7c
ret
Function at 0x423b94
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffdf4
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 4], ecx
mov edi, edx
mov esi, eax
xor eax, eax
push ebp
push 0x423c29
push dword fs:[eax]
mov dword fs:[eax], esp
test esi, esi
jne 0x423bdf
push 0x104
lea eax, [ebp - 0x20c]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW_1
mov ecx, eax
lea edx, [ebp - 0x20c]
mov eax, edi
call fcn.00406c04
jmp 0x423c13
call sub.kernel32.dll_GetCommandLineW_1
mov ebx, eax
cmp word [ebx], 0
jne 0x423bf6
lea eax, [ebp - 4]
call fcn.00406a7c
jmp 0x423c09
lea edx, [ebp - 4]
mov eax, ebx
call fcn.00423a54
mov ebx, eax
test esi, esi
je 0x423c09
dec esi
jmp 0x423be6
mov eax, edi
mov edx, dword [ebp - 4]
call fcn.00406e5c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x423c30
lea eax, [ebp - 4]
call fcn.00406a7c
ret

Function at 0x423c38
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffdf8
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetWindowsDirectoryW
mov edx, ebx
mov eax, esp
call fcn.0041c060
add esp, 0x208
pop ebx
ret

Function at 0x423c64
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffdf8
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemDirectoryW
mov edx, ebx
mov eax, esp
call fcn.0041c060
add esp, 0x208
pop ebx
ret
Function at 0x423dc0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov edi, eax
xor eax, eax
push ebp
push 0x423ef6
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
xor eax, eax
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x14]
push eax
push 0
lea eax, [ebp - 0x10]
push eax
push 0
mov eax, dword [ebp - 8]
push eax
push edi
call sub.advapi32.dll_RegQueryValueExW_1
test eax, eax
jne 0x423ee0
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 0xc]
je 0x423e1d
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 8]
jne 0x423ee0
cmp dword [ebp - 0x14], 0
jne 0x423e32
mov eax, dword [ebp - 0xc]
call fcn.00406a7c
mov bl, 1
jmp 0x423ee0
cmp dword [ebp - 0x14], 0x70000000
jb 0x423e40
call fcn.004204e0
mov esi, dword [ebp - 0x14]
inc esi
shr esi, 1
lea eax, [ebp - 4]
mov ecx, esi
xor edx, edx
call fcn.00406c04
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 4]
call fcn.00406ffc
push eax
lea eax, [ebp - 0x10]
push eax
push 0
mov eax, dword [ebp - 8]
push eax
push edi
call sub.advapi32.dll_RegQueryValueExW_1
cmp eax, 0xea
je 0x423de6
test eax, eax
jne 0x423ee0
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 0xc]
je 0x423e8e
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 8]
jne 0x423ee0
mov esi, dword [ebp - 0x14]
shr esi, 1
jmp 0x423e96
dec esi
test esi, esi
je 0x423ea5
mov eax, dword [ebp - 4]
cmp word [eax + esi*2 - 2], 0
je 0x423e95
cmp dword [ebp - 0x10], 7
jne 0x423eb0
test esi, esi
je 0x423eb0
inc esi
lea eax, [ebp - 4]
mov edx, esi
call fcn.00407720
cmp dword [ebp - 0x10], 7
jne 0x423ed3
test esi, esi
je 0x423ed3
lea eax, [ebp - 4]
call fcn.00406ffc
mov word [eax + esi*2 - 2], 0
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
call fcn.00406e5c
mov bl, 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x423efd
lea eax, [ebp - 4]
call fcn.00406a7c
ret

Function at 0x4254bc
Capabilities:
Hash data with crc32

Disassembly:
push esi
xor esi, esi
mov ecx, 0x4b3148
mov eax, esi
mov edx, 8
test al, 1
je 0x4254d8
shr eax, 1
xor eax, 0xedb88320
jmp 0x4254da
shr eax, 1
dec edx
jne 0x4254cb
mov dword [ecx], eax
inc esi
add ecx, 4
cmp esi, 0x100
jne 0x4254c4
pop esi
ret

Function at 0x4254f0
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
mov esi, ecx
mov edi, edx
mov ebx, eax
cmp dword [0x4b3144], 0
jne 0x425513
call fcn.004254bc
push 1
push 0x4b3144
call sub.kernel32.dll_InterlockedExchange
mov eax, edi
test esi, esi
je 0x42553d
mov edx, 0xff
and edx, ebx
movzx ecx, byte [eax]
xor dx, cx
movzx edx, dx
mov edx, dword [edx*4 + 0x4b3148]
shr ebx, 8
xor edx, ebx
mov ebx, edx
dec esi
inc eax
test esi, esi
jne 0x425519
mov eax, ebx
pop edi
pop esi
pop ebx
ret
Function at 0x4280a8
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
push esi
mov esi, edx
mov ebx, eax
lea edx, [ebp - 0xc]
mov eax, ebx
call fcn.0042805c
test al, al
jne 0x4280c9
xor eax, eax
mov dword [ebp - 4], eax
jmp 0x428115
xor eax, eax
push ebp
push 0x428105
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, esi
call fcn.004075a4
push eax
call sub.kernel32.dll_DeleteFileW
mov dword [ebp - 4], eax
call sub.kernel32.dll_GetLastError_2
mov dword [ebp - 0x10], eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x42810c
lea eax, [ebp - 0xc]
call fcn.00428098
ret
mov eax, dword [ebp - 4]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4a0380
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
mov ecx, 4
push 0
push 0
dec ecx
jne 0x4a0388
push ecx
push ebx
push esi
mov esi, eax
xor eax, eax
push ebp
push 0x4a0475
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
call fcn.00423c90
mov edx, dword [ebp - 8]
mov ecx, 0x4a0490
xor eax, eax
call fcn.004a0264
push 0
mov eax, dword [ebp - 4]
call fcn.004075a4
push eax
call sub.kernel32.dll_CreateDirectoryW
test eax, eax
jne 0x4a0443
call sub.kernel32.dll_GetLastError_2
mov ebx, eax
cmp ebx, 0xb7
je 0x4a03a2
lea eax, [ebp - 0xc]
push eax
lea ecx, [ebp - 0x1c]
mov edx, dword [ebp - 4]
mov al, 0x3b
call fcn.00427e60
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], eax
mov eax, ebx
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x20]
call fcn.0041b88c
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x14], eax
lea edx, [ebp - 0x24]
mov eax, ebx
call fcn.0042420c
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x10], eax
lea edx, [ebp - 0x18]
mov ecx, 2
mov al, 0x70
call fcn.00427e30
mov ecx, dword [ebp - 0xc]
mov dl, 1
mov eax, dword [0x417654]
call fcn.004204ec
call fcn.00406244
jmp 0x4a03a2
mov eax, esi
mov edx, dword [ebp - 4]
call fcn.00406e5c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4a047c
lea eax, [ebp - 0x24]
mov edx, 3
call fcn.00406adc
lea eax, [ebp - 0xc]
mov edx, 3
call fcn.00406adc
ret

Function at 0x4a04a4
Capabilities:
Shutdown system

Disassembly:
add esp, 0xffffffec
mov eax, dword [0x4ab008]
cmp dword [eax], 2
jne 0x4a050c
push esp
push 0x28
call sub.kernel32.dll_GetCurrentProcess
push eax
call sub.advapi32.dll_OpenProcessToken
test eax, eax
jne 0x4a04c7
xor eax, eax
jmp 0x4a051b
lea eax, [esp + 8]
push eax
push 0x4a0520
push 0
call sub.advapi32.dll_LookupPrivilegeValueW
mov dword [esp + 4], 1
mov dword [esp + 0x10], 2
push 0
push 0
push 0
lea eax, [esp + 0x10]
push eax
push 0
mov eax, dword [esp + 0x14]
push eax
call sub.advapi32.dll_AdjustTokenPrivileges
call sub.kernel32.dll_GetLastError_2
test eax, eax
je 0x4a050c
xor eax, eax
jmp 0x4a051b
push 0
push 2
call sub.user32.dll_ExitWindowsEx
cmp eax, 1
sbb eax, eax
inc eax
add esp, 0x14
ret

Function at 0x4a0548
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], edx
mov ebx, eax
mov esi, ecx
dec esi
test esi, esi
jl 0x4a05a2
inc esi
xor edi, edi
cmp edi, 1
jne 0x4a056e
mov eax, dword [ebp + 0xc]
push eax
call sub.kernel32.dll_Sleep_2
jmp 0x4a057c
cmp edi, 1
jle 0x4a057c
mov eax, dword [ebp + 8]
push eax
call sub.kernel32.dll_Sleep_2
mov edx, dword [ebp - 4]
mov eax, ebx
call fcn.004280a8
test eax, eax
jne 0x4a05a2
call sub.kernel32.dll_GetLastError_2
cmp eax, 2
je 0x4a05a2
call sub.kernel32.dll_GetLastError_2
cmp eax, 3
je 0x4a05a2
inc edi
dec esi
jne 0x4a055e
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret 8
Function at 0x4a05ac
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, eax
push 2
lea eax, [ebp - 4]
push eax
push 0x20001004
movzx eax, bx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x4a05d0
mov eax, dword [ebp - 4]
jmp 0x4a05d3
or eax, 0xffffffff
pop ebx
pop ecx
pop ebp
ret

Function at 0x4a05d8
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
push edi
mov esi, ecx
mov byte [ebp - 1], dl
mov edi, eax
mov eax, dword [ebp + 8]
xor edx, edx
mov dword [eax], edx
mov byte [ebp - 2], 0
test esi, esi
je 0x4a0625
xor ebx, ebx
jmp 0x4a061a
mov eax, dword [ebp - 8]
mov edx, dword [eax]
mov eax, esi
call fcn.0041b1b8
test eax, eax
jne 0x4a0619
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 2
jmp 0x4a06d0
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call edi
test al, al
jne 0x4a05fb
movzx eax, byte [ebp - 1]
sub al, 1
jb 0x4a0631
je 0x4a063a
jmp 0x4a0643
call fcn.00423f3c
mov esi, eax
jmp 0x4a0645
call sub.kernel32.dll_GetUserDefaultLangID
mov esi, eax
jmp 0x4a0645
xor esi, esi
test si, si
je 0x4a06d0
xor ebx, ebx
jmp 0x4a066b
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x28]
movzx edx, si
cmp eax, edx
jne 0x4a066a
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 1
jmp 0x4a06d0
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call edi
test al, al
jne 0x4a0652
xor ebx, ebx
jmp 0x4a06c5
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x28]
and eax, 0x3ff
mov dx, 0x3ff
and dx, si
movzx edx, dx
cmp eax, edx
jne 0x4a06c4
mov ax, 0x3ff
and ax, si
cmp ax, 4
jne 0x4a06b9
mov eax, dword [ebp - 8]
movzx eax, word [eax + 0x28]
call fcn.004a05ac
push eax
mov eax, esi
call fcn.004a05ac
pop edx
cmp edx, eax
jne 0x4a06c4
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 1
jmp 0x4a06d0
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call edi
test al, al
jne 0x4a067a
movzx eax, byte [ebp - 2]
pop edi
pop esi
pop ebx
pop ecx
pop ecx
pop ebp
ret 4
Function at 0x4a0ab8
Capabilities:
Create process on windows
Create process suspended

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], ebx
mov edi, ecx
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x4a0b8d
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x4a0ba8
push ebx
push 0x4a0bb8
push esi
lea eax, [ebp - 4]
mov edx, 4
call fcn.00407880
lea eax, [ebp - 0x48]
xor ecx, ecx
mov edx, 0x44
call fcn.00404eec
mov dword [ebp - 0x48], 0x44
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x48]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
mov eax, dword [ebp - 4]
call fcn.004075a4
push eax
push 0
call sub.kernel32.dll_CreateProcessW
test eax, eax
jne 0x4a0b38
mov al, 0x72
call fcn.004a06e0
mov eax, dword [ebp - 0x54]
push eax
call sub.kernel32.dll_CloseHandle_1
call fcn.004a0a8c
push 0x4ff
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x58]
push eax
push 1
call sub.user32.dll_MsgWaitForMultipleObjects
cmp eax, 1
je 0x4a0b41
call fcn.004a0a8c
push edi
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_GetExitCodeProcess
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_CloseHandle_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4a0b94
lea eax, [ebp - 4]
call fcn.00406a7c
ret

Function at 0x4a0ca8
Capabilities:
Allocate or change rwx memory
Get system information on windows

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffb4
mov dword [esp], eax
lea esi, [esp + 0x30]
lea eax, [esp + 0xc]
push eax
call sub.kernel32.dll_GetSystemInfo_1
mov edi, dword [esp]
push 0x1c
push esi
push edi
call sub.kernel32.dll_VirtualQuery_1
test eax, eax
je 0x4a0d73
jmp 0x4a0d67
cmp dword [esi + 0x10], 0x1000
jne 0x4a0d53
test byte [esi + 0x15], 1
jne 0x4a0d53
mov byte [esp + 4], 0
mov ebp, dword [esi + 0x14]
cmp ebp, 1
je 0x4a0d04
cmp ebp, 2
je 0x4a0d04
cmp ebp, 0x10
je 0x4a0d04
cmp ebp, 0x20
jne 0x4a0d20
lea eax, [esp + 8]
push eax
push 0x40
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
test eax, eax
je 0x4a0d20
mov byte [esp + 4], 1
xor ebx, ebx
jmp 0x4a0d31
mov eax, dword [esi]
add eax, ebx
call fcn.004a0ca0
add ebx, dword [esp + 0x10]
cmp ebx, dword [esi + 0xc]
jb 0x4a0d24
cmp byte [esp + 4], 0
je 0x4a0d53
lea eax, [esp + 8]
push eax
mov eax, dword [esp + 0xc]
push eax
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
mov eax, dword [esi]
add eax, dword [esi + 0xc]
mov edi, eax
push 0x1c
push esi
push edi
call sub.kernel32.dll_VirtualQuery_1
test eax, eax
je 0x4a0d73
mov eax, dword [esi + 4]
cmp eax, dword [esp]
je 0x4a0cd9
add esp, 0x4c
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x401058
Capabilities:
Print debug messages

Disassembly:
push esi
lea eax, [esp + 0xc]
push eax
push dword [esp + 0xc]
mov esi, section..data
push esi
call dword [sym.imp.USER32.dll_wvsprintfA]
push esi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 0x200010
push str.Loader
push esi
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop esi
ret

Function at 0x4010e9
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90
push edi
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
xor edi, edi
call dword [sym.imp.VERSION.dll_GetFileVersionInfoSizeW]
mov ecx, eax
test ecx, ecx
mov dword [ebp - 4], ecx
je 0x4011be
push ebx
call fcn.004017a6
mov ebx, eax
push ebx
push dword [ebp - 4]
push dword [ebp - 0xc]
push dword [ebp + 8]
call dword [sym.imp.VERSION.dll_GetFileVersionInfoW]
test eax, eax
je 0x4011b4
push esi
mov esi, dword [sym.imp.VERSION.dll_VerQueryValueW]
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x10]
push eax
push str.VarFileInfoTranslation
push ebx
call esi
test eax, eax
je 0x4011b3
cmp dword [ebp - 4], 4
jb 0x4011b3
mov eax, dword [ebp - 0x10]
movzx ecx, word [eax + 2]
movzx eax, word [eax]
push ecx
push eax
lea eax, [ebp - 0x90]
push str.StringFileInfo_04x_04xArguments
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x90]
push eax
push ebx
call esi
test eax, eax
je 0x4011b3
cmp dword [ebp - 8], edi
je 0x4011b3
mov eax, dword [ebp - 4]
test eax, eax
je 0x4011b3
lea ecx, [eax + eax + 2]
call fcn.004017a6
push dword [ebp - 4]
mov edi, eax
push dword [ebp - 8]
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
mov eax, dword [ebp - 4]
and word [edi + eax*2], 0
pop esi
mov ecx, ebx
call fcn.004017b7
mov eax, edi
pop ebx
pop edi
leave
ret 4
Function at 0x4011c3
Capabilities:
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push edi
xor edi, edi
push edi
push edi
push 3
push edi
push 3
push 0x80000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
jne 0x4011f0
xor eax, eax
jmp 0x40138b
lea ecx, [ebp - 0xc]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0x10000
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 8], ecx
jae 0x40120c
dec ecx
mov dword [ebp - 8], ecx
push ebx
push esi
push edi
push edi
push edi
lea esi, [eax - 0x10000]
push 2
push edi
push dword [ebp - 4]
and esi, 0xffff0000
sub eax, esi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
push dword [ebp - 4]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp + 8], eax
call edi
cmp dword [ebp + 8], 0
je 0x40125f
push ebx
push esi
push dword [ebp - 8]
push 4
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
push dword [ebp + 8]
mov esi, eax
mov dword [ebp - 4], esi
call edi
test esi, esi
jne 0x401266
xor eax, eax
jmp 0x401389
lea ecx, [esi + ebx]
push 0x7c
lea eax, [ecx - 2]
pop edx
xor ebx, ebx
cmp byte [eax], dl
lea edi, [ecx - 4]
jne 0x401313
cmp byte [eax + 1], 0x3e
jne 0x401313
mov edi, dword [ebp - 4]
add edi, 2
cmp eax, edi
mov esi, eax
jbe 0x40137e
lea ecx, [esi - 1]
cmp byte [ecx], dl
jne 0x4012a3
cmp byte [esi - 2], 0x3c
je 0x4012ae
mov esi, ecx
cmp esi, edi
ja 0x401296
jmp 0x40137e
sub eax, esi
mov edi, eax
mov eax, dword [ebp - 4]
add eax, 5
cmp esi, eax
jbe 0x4012f4
cmp byte [esi - 5], 0xef
jne 0x4012f4
cmp byte [esi - 4], 0xbb
jne 0x4012f4
cmp byte [esi - 3], 0xbf
jne 0x4012f4
lea ecx, [edi + edi + 2]
call fcn.004017a6
push edi
mov ebx, eax
push ebx
push edi
push esi
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
and word [ebx + eax*2], 0
jmp 0x40137e
lea ecx, [edi + edi + 2]
call fcn.004017a6
push edi
mov ebx, eax
push ebx
push edi
push esi
xor esi, esi
push esi
push esi
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov word [ebx + eax*2], si
jmp 0x40137e
cmp word [edi], dx
jne 0x40137e
cmp word [edi + 2], 0x3e
jne 0x40137e
add esi, 4
cmp edi, esi
mov ecx, edi
mov dword [ebp + 8], ecx
jbe 0x40137e
jmp 0x401330
mov ecx, dword [ebp + 8]
lea eax, [ecx - 2]
cmp word [eax], dx
jne 0x40133f
cmp word [ecx - 4], 0x3c
je 0x401348
cmp eax, esi
mov dword [ebp + 8], eax
ja 0x40132d
jmp 0x40137e
mov eax, edi
sub eax, ecx
sar eax, 1
lea esi, [eax + eax]
lea ecx, [esi + 2]
call fcn.004017a6
mov ecx, dword [ebp + 8]
cmp ecx, edi
mov ebx, eax
jae 0x40137a
add esi, ebx
sub ecx, ebx
cmp eax, esi
jae 0x40137a
mov dx, word [ecx + eax]
mov word [eax], dx
inc eax
inc eax
lea edx, [ecx + eax]
cmp edx, edi
jb 0x401366
and word [eax], 0
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov eax, ebx
pop esi
pop ebx
pop edi
leave
ret 4
Function at 0x401390
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
push dword [ebp + 8]
call fcn.004010e9
test eax, eax
push 2
mov dword [ebp - 4], eax
pop esi
jne 0x4013b8
mov ecx, esi
call fcn.004017a6
and word [eax], 0
mov dword [ebp - 4], eax
push dword [ebp + 8]
call fcn.004011c3
mov ebx, eax
test ebx, ebx
mov dword [ebp + 8], ebx
jne 0x4013d9
mov ecx, esi
call fcn.004017a6
mov ebx, eax
and word [ebx], 0
mov dword [ebp + 8], ebx
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push 0x20
mov edi, eax
pop ecx
jmp 0x4013e8
add edi, esi
cmp word [edi], cx
je 0x4013e6
cmp word [edi], 0x22
jne 0x401407
add edi, esi
movzx eax, word [edi]
test ax, ax
je 0x40141a
add edi, esi
cmp ax, 0x22
jne 0x4013f5
jmp 0x40141a
movzx eax, word [edi]
test ax, ax
je 0x40141a
add edi, esi
cmp ax, cx
jne 0x401407
jmp 0x40141a
add edi, esi
cmp word [edi], cx
je 0x401418
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push edi
call esi
push ebx
mov dword [ebp - 8], eax
call esi
mov ecx, dword [ebp - 8]
push dword [ebp - 4]
lea ebx, [ecx + eax]
call esi
mov ecx, dword [ebp + 0xc]
add eax, ebx
lea eax, [eax + ecx + 0x20]
lea esi, [eax + eax]
mov ecx, esi
call fcn.004017a6
mov edx, dword [ebp - 4]
mov ebx, eax
lea esi, [esi + ebx - 2]
push esi
call fcn.0040103a
mov edx, dword [ebp + 8]
mov word [eax], 0x20
push esi
add eax, 2
call fcn.0040103a
mov word [eax], 0x20
push esi
add eax, 2
mov edx, edi
call fcn.0040103a
mov ecx, dword [ebp - 4]
call fcn.004017b7
mov ecx, dword [ebp + 8]
call fcn.004017b7
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret 8
Function at 0x40180a
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [esi + 4]
push edi
mov edi, dword [esi + 0x10]
mov dword [esi + 0xc], eax
mov dword [esi + 8], eax
jmp 0x40183d
push 0
lea eax, [ebp - 4]
push eax
push edi
push dword [esi + 0xc]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401846
mov eax, dword [ebp - 4]
test eax, eax
je 0x40184e
add dword [esi + 0xc], eax
sub edi, eax
jne 0x40181d
xor eax, eax
pop edi
leave
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x401843
mov eax, dword [esi + 0xc]
cmp dword [esi + 4], eax
sbb eax, eax
and eax, 0xffffffda
add eax, 0x26
jmp 0x401843