joyce8/EMBER2024-capa huggingface dataset:
Function at 0x412ee0
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x429888]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x412f26
cmp word [ebx], dx
jne 0x412f26
or byte [eax + edi + 0x28], 4
jmp 0x412f2b
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x41308e
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x41306e
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x412f6c
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x412fa2
cmp eax, edx
jae 0x412fb0
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x412f47
jmp 0x41308e
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x413069
cmp dword [ebp - 0x18], 0
je 0x413069
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x429888]
test byte [eax + edi + 0x28], 0x48
je 0x41303f
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x413003
mov word [esi], cx
jmp 0x41303a
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x429888]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x429888]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x429888]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x41308e
pop eax
cmp word [ebp - 4], ax
jne 0x41304f
cmp esi, ebx
jne 0x41304f
mov word [esi], ax
jmp 0x41308b
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00413919
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x41308e
push 0xd
pop eax
jmp 0x41304a
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x429888]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x413088
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x41308e
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x416c0c
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x416ca9
push ebx
push esi
call fcn.00416bd5
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.004158c7
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x416c56
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x416ca8
push edi
push eax
call fcn.00412267
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x416c76
call fcn.00410889
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x416ca7
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.004158c7
add esp, 0x20
test eax, eax
jne 0x416c95
push edi
call fcn.00410889
jmp 0x416c9d
push ebx
call fcn.00410889
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x41947b
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
call fcn.0041034f
mov esi, dword [ebp + 8]
mov edi, eax
push 2
lea eax, [ebp - 4]
mov ecx, esi
push eax
and ecx, 0x3ff
push 0x20000001
or ecx, 0x400
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x4194ea
cmp esi, dword [ebp - 4]
je 0x4194e5
cmp dword [ebp + 0xc], 0
je 0x4194e5
mov esi, dword [edi + 0x50]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x4194c2
push dword [edi + 0x50]
sub esi, ecx
sar esi, 1
call fcn.00418fcd
pop ecx
xor ecx, ecx
cmp eax, esi
setne cl
mov eax, ecx
jmp 0x4194ec
xor eax, eax
inc eax
jmp 0x4194ec
xor eax, eax
pop edi
pop esi
leave
ret
Function at 0x419551
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x428080]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 0x18], eax
call fcn.0041034f
add eax, 0x50
lea edi, [ebp - 0x10]
mov dword [ebp - 0x14], eax
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
call fcn.0041034f
lea ecx, [ebp - 0x10]
xor edx, edx
mov dword [eax + 0x34c], ecx
lea ecx, [esi + 0x80]
mov eax, dword [ebp - 0x14]
mov dword [eax], esi
lea edi, [eax + 4]
mov dword [edi], ecx
test ecx, ecx
je 0x4195c8
cmp word [ecx], dx
je 0x4195c8
mov eax, dword [0x421974]
push edi
dec eax
push eax
push 0x421860
call fcn.004194f0
mov eax, dword [ebp - 0x14]
add esp, 0xc
xor edx, edx
mov dword [ebp - 0x10], edx
mov eax, dword [eax]
test eax, eax
je 0x41963b
cmp word [eax], dx
je 0x41963b
mov eax, dword [edi]
test eax, eax
je 0x4195ec
cmp word [eax], dx
je 0x4195ec
lea eax, [ebp - 0x10]
push eax
call fcn.00418ed3
jmp 0x4195f5
lea eax, [ebp - 0x10]
push eax
call fcn.00418f6e
cmp dword [ebp - 0x10], 0
pop ecx
jne 0x419665
mov eax, dword [0x42185c]
push dword [ebp - 0x14]
dec eax
push eax
push 0x421550
call fcn.004194f0
add esp, 0xc
test al, al
je 0x419665
mov eax, dword [edi]
xor edi, edi
test eax, eax
je 0x419630
cmp word [eax], di
je 0x419630
lea eax, [ebp - 0x10]
push eax
call fcn.00418ed3
pop ecx
jmp 0x419667
lea eax, [ebp - 0x10]
push eax
call fcn.00418f6e
jmp 0x41962d
mov eax, dword [edi]
test eax, eax
je 0x419652
cmp word [eax], dx
je 0x419652
lea eax, [ebp - 0x10]
push eax
call fcn.00418e88
pop ecx
jmp 0x419665
mov dword [ebp - 0x10], 0x104
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
xor edi, edi
cmp dword [ebp - 0x10], 0
je 0x419730
lea eax, [ebp - 0x10]
push eax
lea eax, [esi + 0x100]
neg esi
sbb esi, esi
and esi, eax
push esi
call fcn.00419375
mov esi, eax
pop ecx
pop ecx
test esi, esi
je 0x419730
movzx ecx, si
push ecx
call dword [sym.imp.KERNEL32.dll_IsValidCodePage]
test eax, eax
je 0x419730
push 1
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_IsValidLocale]
test eax, eax
je 0x419730
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x4196bd
mov dword [eax], esi
mov eax, dword [ebp - 0x14]
push edi
push 0x55
add eax, 0x250
push eax
push dword [ebp - 0xc]
call fcn.00410efa
test ebx, ebx
je 0x41972b
push edi
push 0x55
lea eax, [ebx + 0x120]
push eax
push dword [ebp - 0xc]
call fcn.00410efa
push 0x40
push ebx
push 0x1001
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x419730
push 0x40
lea eax, [ebx + 0x80]
push eax
push 0x1002
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x419730
push 0xa
push 0x10
lea ecx, [ebx + 0x100]
push ecx
push esi
call fcn.0041ba17
add esp, 0x10
xor eax, eax
inc eax
jmp 0x419732
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004056e0
leave
ret
Function at 0x41c0d5
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.0041c051
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x41c244
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x41c244
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x41c1f9
jg 0x41c131
test eax, eax
je 0x41c1ef
push 1
push 0x1000
call fcn.0041082c
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x41c154
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x41c1e6
push 0x8000
push ebx
call fcn.0040ded0
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x41c17d
jg 0x41c178
cmp ecx, 0x1000
jb 0x41c17d
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.00411b47
add esp, 0x10
cmp eax, 0xffffffff
je 0x41c1c2
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x41c178
jl 0x41c1a9
test ecx, ecx
jne 0x41c16a
push dword [ebp - 0xc]
push ebx
call fcn.0040ded0
push esi
call fcn.00410889
add esp, 0xc
xor ebx, ebx
jmp 0x41c252
cmp byte [edi + 0x24], 0
je 0x41c1d9
cmp dword [edi + 0x20], 5
jne 0x41c1d9
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x41c1e4
mov ebx, dword [edi + 0x18]
jmp 0x41c1e6
xor ebx, ebx
push esi
call fcn.00410889
pop ecx
jmp 0x41c252
test ecx, ecx
jg 0x41c1bb
jl 0x41c1f9
test eax, eax
jae 0x41c1bb
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00413919
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x41c219
cmp byte [edi + 0x1c], 0
je 0x41c1bb
jmp 0x41c24a
push ebx
call fcn.0041744c
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x41c1bb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x41c252
cmp byte [edi + 0x1c], 0
je 0x41c24f
mov ebx, dword [edi + 0x18]
jmp 0x41c252
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.00413919
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x41d5b0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x41d5dd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x41d5dd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x419c50
Capabilities:
Write file on windows

Disassembly:
mov eax, 0x1004
call fcn.0042d600
mov ecx, dword [esp + 0x100c]
lea eax, [esp + 0x1010]
push edi
push eax
push ecx
lea edx, [esp + 0x10]
push 0x1000
push edx
call fcn.0042d62f
lea edi, [esp + 0x18]
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
mov byte [esp + 0x1007], 0
repne scasb al, byte es:[edi]
not ecx
dec ecx
pop edi
cmp ecx, 0xffffffff
jbe 0x419caa
push 0x57
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
add esp, 0x1004
ret
mov edx, dword [esp + 0x1008]
lea eax, [esp]
push 0
push eax
push ecx
lea ecx, [esp + 0x10]
push ecx
push edx
mov dword [esp + 0x14], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
add esp, 0x1004
ret

Function at 0x41a1c0
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x108
lea eax, [esp + 4]
push ebx
push esi
push edi
push 0x104
xor edi, edi
push eax
push 1
push edi
push edi
push 0x4395a0
call fcn.00418de0
mov esi, eax
cmp esi, 0xffffffff
je 0x41a265
mov ebx, dword [esp + 0x11c]
mov edx, dword [esp + 0x118]
lea ecx, [esp + 0xc]
push edi
push ecx
push ebx
push edx
push esi
mov dword [esp + 0x20], edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x41a25e
cmp ebx, dword [esp + 0xc]
jne 0x41a25e
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [esp + 0x10]
push eax
call fcn.00419fa0
mov esi, eax
cmp esi, edi
je 0x41a250
push edi
push 0x4000000
push 3
push edi
push 1
lea ecx, [esp + 0x24]
push 0xc0000000
push ecx
call fcn.00418c10
push eax
push esi
call fcn.0041a280
add esp, 8
mov eax, esi
pop edi
pop esi
pop ebx
add esp, 0x108
ret 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x108
ret 8

Function at 0x41a290
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ecx
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
push edi
push eax
push ecx
xor ebp, ebp
push edx
push ebx
mov dword [esp + 0x20], ebp
call dword [sym.imp.KERNEL32.dll_FindResourceExA]
mov esi, eax
test esi, esi
je 0x41a30d
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x41a30d
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebp, eax
test ebp, ebp
je 0x41a2f8
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push eax
push ebp
call fcn.0041a1c0
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 0x10
mov esi, dword [esp + 0x10]
push edi
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 0x10
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
pop ecx
ret 0x10
Function at 0x401630
Capabilities:
Read file via mapping

Disassembly:
push ebx
push esi
mov esi, ecx
mov eax, dword [esi + 0x4fe0]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov edi, dword [esp + 0x10]
mov ecx, dword [esi + 0x4fd8]
mov ebx, dword [esi + 0x4fdc]
shr ecx, 0x1c
mov eax, edi
and eax, 0xf
shl ebx, 4
add ecx, ebx
mov edx, edi
shr edx, 4
shl eax, 0x1c
cmp edi, ecx
sbb ecx, ecx
and ecx, 0x10000000
push ecx
push eax
push edx
mov edx, dword [esi + 0x28]
push 4
push edx
mov dword [esi + 0x1c], ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
test eax, eax
mov dword [esi + 0x4fe0], eax
je 0x401696
mov dword [esi + 0x18], edi
pop edi
pop esi
pop ebx
ret 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [0x4425b8]
push 0x430518
push str.Debug.txt
mov esi, eax
call fcn.0041b5c6
push esi
push esi
push 0x430530
push str._s_d__x__n
push eax
mov dword [edi], eax
call fcn.0041b50c
mov eax, dword [edi]
push eax
call fcn.0041b4bb
push 0xdf
call fcn.00416e00
push eax
call fcn.00416e50
add esp, 0x28
pop edi
pop esi
pop ebx
ret 4
Function at 0x40bee0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x42f188
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, dword [esp + 0x2c]
push esi
mov esi, ecx
mov ecx, dword [esp + 0x2c]
push eax
mov eax, dword [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x28]
sub esp, 0x10
mov edx, esp
mov dword [edx], eax
mov eax, dword [esp + 0x3c]
mov dword [edx + 4], ecx
mov ecx, dword [esp + 0x40]
mov dword [edx + 8], eax
mov dword [edx + 0xc], ecx
mov edx, dword [esp + 0x30]
push edx
mov ecx, esi
mov dword [esp + 0x20], esi
call fcn.00416ec0
mov ecx, dword [esp + 0x34]
xor eax, eax
mov dword [esi + 0x10cc078], ecx
mov ecx, esi
mov dword [esp + 0x10], eax
mov dword [esi], 0x4311b0
mov dword [esi + 0x1097a10], eax
call fcn.0040efb0
mov ecx, dword [esp + 8]
mov eax, esi
mov dword fs:[0], ecx
pop esi
add esp, 0x10
ret 0x20
Function at 0x419c70
Capabilities:
Get common file path

Disassembly:
sub esp, 0x4c
push esi
xor esi, esi
cmp word [0x443fe8], si
push edi
jne 0x419c92
push 0x443fe8
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
jmp 0x419ca8
push 0x5c
push 0x443fe8
call fcn.0041c053
add esp, 8
cmp eax, esi
je 0x419ca8
mov word [eax], si
push 0x443fe8
call fcn.0041b333
add esp, 4
cmp eax, 3
jne 0x419ccb
cmp word [0x443fec], 0x5c
jne 0x419ccb
mov word [0x443fec], si
mov eax, dword [esp + 0x6c]
cmp eax, esi
je 0x419ce1
push eax
push 0x443fe8
call fcn.0041bd2a
add esp, 8
mov eax, dword [esp + 0x68]
push ebx
push eax
push 0x443fe8
call fcn.0041bd00
mov ecx, dword [esp + 0x68]
mov edx, dword [esp + 0x70]
mov eax, dword [esp + 0x6c]
mov edi, dword [esp + 0x64]
push 0x4309c4
push edi
mov dword [esp + 0x1c], 0x4c
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], edx
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], esi
mov dword [esp + 0x38], 0x443fe8
mov dword [esp + 0x3c], 0x104
mov dword [esp + 0x40], esi
mov dword [esp + 0x44], 0x200
mov dword [esp + 0x48], esi
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], 0x88002c
mov word [esp + 0x54], si
mov word [esp + 0x56], si
mov dword [esp + 0x58], esi
mov dword [esp + 0x5c], 1
mov dword [esp + 0x60], 0x419b30
mov dword [esp + 0x64], esi
call fcn.0041c23b
add esp, 0x10
test eax, eax
jne 0x419d90
lea ecx, [esp + 0xc]
push ecx
call dword [sym.imp.comdlg32.dll_GetOpenFileNameW]
mov ebx, eax
jmp 0x419d94
mov ebx, dword [esp + 0x70]
push 0x430a8c
push edi
call fcn.0041c23b
add esp, 8
test eax, eax
jne 0x419db3
lea edx, [esp + 0xc]
push edx
call dword [sym.imp.comdlg32.dll_GetSaveFileNameW]
mov ebx, eax
cmp ebx, esi
pop ebx
jne 0x419dc0
pop edi
xor eax, eax
pop esi
add esp, 0x4c
ret
push 0x430a8c
push edi
call fcn.0041c23b
add esp, 8
test eax, eax
jne 0x419e14
cmp word [esp + 0x42], si
mov edx, dword [esp + 0x14]
jne 0x419e14
mov ecx, dword [esp + 0x20]
lea ecx, [ecx + ecx - 1]
cmp ecx, esi
jbe 0x419e03
lea esp, [esp]
mov si, word [edx]
add edx, 2
test si, si
jne 0x419df0
inc eax
movzx esi, ax
cmp esi, ecx
jb 0x419df0
add edx, 2
push edx
push 0x443fe8
call fcn.0041bd00
add esp, 8
pop edi
mov eax, 0x443fe8
pop esi
add esp, 0x4c
ret

Function at 0x419f86
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x419f9b
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
jne 0x419fad
xor eax, eax
jmp 0x419fdf
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
add eax, esi
and ecx, 0xf
jbe 0x419fd1
cmp esi, eax
jae 0x419fa9
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x419fc3
cmp esi, eax
jae 0x419fa9
mov ax, word [esi]
neg ax
sbb eax, eax
and eax, esi
pop esi
pop ebp
ret
Function at 0x41c9a5
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x432b60
call fcn.0041cec0
mov edi, 0x94
mov eax, edi
call fcn.0041c890
mov dword [ebp - 0x18], esp
mov esi, esp
mov dword [esi], edi
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ecx, dword [esi + 0x10]
mov dword [0x4463e0], ecx
mov eax, dword [esi + 4]
mov dword [0x4463ec], eax
mov edx, dword [esi + 8]
mov dword [0x4463f0], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x4463e4], esi
cmp ecx, 2
je 0x41ca05
or esi, 0x8000
mov dword [0x4463e4], esi
shl eax, 8
add eax, edx
mov dword [0x4463e8], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x41ca40
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x41ca40
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x41ca58
cmp eax, 0x20b
je 0x41ca45
mov dword [ebp - 0x1c], esi
jmp 0x41ca6c
cmp dword [ecx + 0x84], 0xe
jbe 0x41ca40
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x41ca66
cmp dword [ecx + 0x74], 0xe
jbe 0x41ca40
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push 1
call fcn.004231d4
pop ecx
test eax, eax
jne 0x41ca80
push 0x1c
call fcn.0041c981
pop ecx
call fcn.0041dfff
test eax, eax
jne 0x41ca91
push 0x10
call fcn.0041c981
pop ecx
call fcn.00423132
mov dword [ebp - 4], esi
call fcn.00422f34
test eax, eax
jge 0x41caaa
push 0x1b
call fcn.0041c95c
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x447cb4], eax
call fcn.00422e12
mov dword [0x4463cc], eax
call fcn.00422d70
test eax, eax
jge 0x41cad0
push 8
call fcn.0041c95c
pop ecx
call fcn.00422b3d
test eax, eax
jge 0x41cae1
push 9
call fcn.0041c95c
pop ecx
push 1
call fcn.0041d8b5
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x41caf7
push eax
call fcn.0041c95c
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.00422ae0
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x41cb18
movzx eax, word [ebp - 0x40]
jmp 0x41cb1b
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call fcn.0040b9e0
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x41cb39
push edi
call fcn.0041d9e2
call fcn.0041da04
jmp 0x41cb6b
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.0041cefb
ret
Function at 0x41d6ce
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.0041c890
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x41d769
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x4463e0]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x41d769
cmp eax, 1
je 0x41d78a
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x41d769
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x41d736
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x41d765
xor eax, eax
inc eax
jmp 0x41d7a9
cmp edi, eax
jae 0x41d76d
xor eax, eax
jmp 0x41d7a9
cmp eax, esi
jae 0x41d774
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x4463e0]
jmp 0x41d78d
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x41d91f
Capabilities:
Terminate process

Disassembly:
push 8
push 0x432c20
call fcn.0041cec0
push 8
call fcn.00423378
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x446420], esi
jne 0x41d953
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x44641c], esi
mov al, byte [ebp + 0x10]
mov byte [0x446418], al
cmp dword [ebp + 0xc], edi
jne 0x41d99d
cmp dword [0x447cac], edi
je 0x41d98d
mov eax, dword [0x447ca8]
sub eax, 4
mov dword [0x447ca8], eax
cmp eax, dword [0x447cac]
jb 0x41d98d
mov eax, dword [eax]
cmp eax, edi
je 0x41d96e
call eax
jmp 0x41d96e
push 0x437070
mov eax, 0x437068
call fcn.0041d89d
pop ecx
push 0x43707c
mov eax, 0x437074
call fcn.0041d89d
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x41d9ce
cmp dword [ebp + 0x10], edi
jne 0x41d9dc
mov dword [0x446420], esi
push dword [ebp + 8]
call fcn.0041d85b
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x41d9db
push 8
call fcn.004232c3
pop ecx
ret
call fcn.0041cefb
ret