joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1001d7cf
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 0x1001d86c
push ebx
push esi
call fcn.1001d798
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.1001d72c
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1001d819
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1001d86b
push edi
push eax
call fcn.1001e78a
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1001d839
call fcn.1001c274
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1001d86a
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.1001d72c
add esp, 0x20
test eax, eax
jne 0x1001d858
push edi
call fcn.1001c274
jmp 0x1001d860
push ebx
call fcn.1001c274
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 0x1001dad9
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10025cc8
push 0x10025cc0
push str.FlsAlloc
push 0x1f
call fcn.1001d9f5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001db0d
push dword [ebp + 8]
mov ecx, esi
call dword [0x1002414c]
call esi
jmp 0x1001db13
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1001db57
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10025cd8
push 0x10025cd0
push str.FlsGetValue
push 0x21
call fcn.1001d9f5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001db8e
push dword [ebp + 8]
mov ecx, esi
call dword [0x1002414c]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1001db96
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10025ce0
push 0x10025cd8
push str.FlsSetValue
push 0x22
call fcn.1001d9f5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1001dbd0
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x1002414c]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x10023260
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1002328d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1002328d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x10001000
Capabilities:
Delete file
Extract resource via kernel32 functions
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
push edi
push esi
push ebx
sub esp, 0x14
mov ebx, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
call fcn.1004662b
pop ecx
call fcn.10046638
mov dword [0x100656f8], eax
test esi, esi
mov dword [0x100657c8], ebx
je 0x10001135
cmp esi, 1
je 0x1000104d
mov eax, 1
add esp, 0x14
pop ebx
pop esi
pop edi
mov esp, ebp
pop ebp
ret 0xc
push str.EXTRAS9
push 0x7b
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
test esi, esi
je 0x100010b6
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [esp], eax
xor edx, edx
push edx
push 0x80
push 2
push edx
push edx
push 0x40000000
push str.3da_extra9.dll
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
lea edx, [esp + 0x10]
push 0
push edx
push edi
mov ecx, dword [esp + 0xc]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x10065640
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
movq mm1, qword [0x100543c8]
mov dword [0x100657c4], ebx
xor eax, eax
pxor mm0, mm0
movq qword [eax + 0x10061cc0], mm1
movq qword [eax + 0x100621e0], mm0
movq qword [eax + 0x10062700], mm0
movq qword [eax + 0x10061cc8], mm1
movq qword [eax + 0x100621e8], mm0
movq qword [eax + 0x10062708], mm0
add eax, 0x10
cmp eax, 0x510
jb 0x100010d3
emms
mov dword [0x100621d0], 1
xor eax, eax
mov dword [0x100626f0], eax
mov dword [0x10062c10], eax
call fcn.100011b8
mov eax, 1
add esp, 0x14
pop ebx
pop esi
pop edi
mov esp, ebp
pop ebp
ret 0xc
mov dword [0x100657c4], 0
push str.3da_extra9.dll
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
movq mm1, qword [0x100543c8]
xor eax, eax
pxor mm0, mm0
movq qword [eax + 0x10061cc0], mm1
movq qword [eax + 0x100621e0], mm0
movq qword [eax + 0x10062700], mm0
movq qword [eax + 0x10061cc8], mm1
movq qword [eax + 0x100621e8], mm0
movq qword [eax + 0x10062708], mm0
add eax, 0x10
cmp eax, 0x510
jb 0x10001156
emms
mov dword [0x100621d0], 1
xor edx, edx
mov eax, 1
mov dword [0x100626f0], edx
mov dword [0x10062c10], edx
add esp, 0x14
pop ebx
pop esi
pop edi
mov esp, ebp
pop ebp
ret 0xc
Function at 0x10038a82
Capabilities:
Enumerate pe sections

Disassembly:
mov ecx, dword [esp + 8]
push esi
push edi
xor edi, edi
movzx eax, word [ecx + 0x14]
movzx esi, word [ecx + 6]
test esi, esi
lea eax, [eax + ecx + 0x18]
jbe 0x10038abd
mov ecx, dword [eax + 8]
test ecx, ecx
jne 0x10038aa4
mov ecx, dword [eax + 0x10]
mov edx, dword [eax + 0xc]
cmp dword [esp + 0xc], edx
jb 0x10038ab5
add edx, ecx
cmp dword [esp + 0xc], edx
jb 0x10038abf
inc edi
add eax, 0x28
cmp edi, esi
jb 0x10038a9a
xor eax, eax
pop edi
pop esi
ret
Function at 0x10041210
Capabilities:
Get common file path

Disassembly:
push edi
push esi
sub esp, 0x800
lea eax, [esp]
push 0x800
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea edi, [esp]
mov edx, 0x10059a94
mov ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
add edi, 0xffffffff
mov al, byte [edx]
add edx, 1
mov byte [edi], al
add edi, 1
test al, al
jne 0x1004123b
lea edi, [esp]
mov edx, 0x1005456c
mov ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
add edi, 0xffffffff
mov al, byte [edx]
add edx, 1
mov byte [edi], al
add edi, 1
test al, al
jne 0x1004125d
lea eax, [esp]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
test esi, esi
je 0x10041286
mov eax, esi
add esp, 0x800
pop esi
pop edi
ret
lea edx, [esp]
push 0x10
push 0x1005456c
push edx
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
jmp 0x1004127b

Function at 0x10046f3f
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
cmp eax, 1
push esi
jne 0x1004702f
mov eax, 0x94
call fcn.1004ac40
mov esi, esp
push esi
mov dword [esi], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x100470a4
mov ecx, dword [esi + 0x10]
mov dword [0x10065840], ecx
mov eax, dword [esi + 4]
mov dword [0x1006584c], eax
mov edx, dword [esi + 8]
mov dword [0x10065850], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
cmp ecx, 2
mov dword [0x10065844], esi
je 0x10046faa
or esi, 0x8000
mov dword [0x10065844], esi
shl eax, 8
add eax, edx
push 1
mov dword [0x10065848], eax
call fcn.1004ab62
test eax, eax
pop ecx
je 0x100470a4
call fcn.10047871
test eax, eax
jne 0x10046fd7
call fcn.1004abb3
jmp 0x100470a4
call fcn.1004aac0
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x10067504], eax
call fcn.1004a99e
mov dword [0x1006580c], eax
call fcn.1004a47f
test eax, eax
jl 0x10047028
call fcn.1004a8fc
test eax, eax
jl 0x10047023
call fcn.1004a6c9
test eax, eax
jl 0x10047023
push 0
call fcn.1004a277
test eax, eax
pop ecx
jne 0x10047023
inc dword [0x10065808]
jmp 0x100470b5
call fcn.1004a67d
call fcn.1004765a
jmp 0x10046fcd
test eax, eax
jne 0x1004705f
cmp dword [0x10065808], eax
jle 0x100470a4
dec dword [0x10065808]
cmp dword [0x1006587c], eax
jne 0x1004704e
call fcn.1004a3b5
call fcn.1004a67d
call fcn.1004765a
call fcn.1004abb3
jmp 0x100470b5
cmp eax, 2
jne 0x100470a8
push 0x8c
push 1
call fcn.1004a3c4
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x100470a4
push esi
push dword [0x1006018c]
call dword [0x10065824]
test eax, eax
push esi
je 0x1004709e
call fcn.10047677
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
or dword [esi + 4], 0xffffffff
mov dword [esi], eax
jmp 0x100470b5
call fcn.100488c9
pop ecx
xor eax, eax
jmp 0x100470b8
cmp eax, 3
jne 0x100470b5
push 0
call fcn.10047842
pop ecx
xor eax, eax
inc eax
lea esp, [ebp - 4]
pop esi
pop ebp
ret 0xc
Function at 0x10049c58
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 8], 0
cmp dword [ebp + 0x10], 0
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edx, ebx
je 0x10049e2c
mov eax, dword [ebp + 8]
mov ecx, eax
and eax, 0x1f
sar ecx, 5
lea esi, [eax + eax*8]
lea edi, [ecx*4 + 0x100663e0]
mov eax, dword [edi]
shl esi, 2
add eax, esi
mov cl, byte [eax + 4]
test cl, 2
jne 0x10049e2c
test cl, 0x48
je 0x10049cc3
cmp byte [eax + 5], 0xa
je 0x10049cc3
mov eax, dword [edi]
mov al, byte [eax + esi + 5]
dec dword [ebp + 0x10]
mov byte [ebx], al
mov eax, dword [edi]
lea edx, [ebx + 1]
mov dword [ebp - 8], 1
mov byte [eax + esi + 5], 0xa
push 0
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 0x10]
mov eax, dword [edi]
push edx
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x10049d15
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 5
pop esi
cmp eax, esi
jne 0x10049cfd
call fcn.100485ca
mov dword [eax], 9
call fcn.100485d3
mov dword [eax], esi
jmp 0x10049d0d
cmp eax, 0x6d
je 0x10049e2c
push eax
call fcn.100485dc
pop ecx
or eax, 0xffffffff
jmp 0x10049e2e
mov eax, dword [ebp - 0xc]
mov ecx, dword [edi]
add dword [ebp - 8], eax
test byte [ecx + esi + 4], 0x80
je 0x10049e27
test eax, eax
je 0x10049d3c
cmp byte [ebx], 0xa
jne 0x10049d3c
mov eax, ecx
lea eax, [eax + esi + 4]
or byte [eax], 4
jmp 0x10049d45
mov eax, dword [edi]
lea eax, [eax + esi + 4]
and byte [eax], 0xfb
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
add ecx, eax
cmp eax, ecx
mov dword [ebp + 0x10], eax
mov dword [ebp - 8], ecx
jae 0x10049e21
mov eax, dword [ebp + 0x10]
mov al, byte [eax]
cmp al, 0x1a
je 0x10049e11
cmp al, 0xd
je 0x10049d77
mov byte [ebx], al
inc ebx
inc dword [ebp + 0x10]
jmp 0x10049e03
dec ecx
cmp dword [ebp + 0x10], ecx
jae 0x10049d91
mov eax, dword [ebp + 0x10]
inc eax
cmp byte [eax], 0xa
jne 0x10049d8c
add dword [ebp + 0x10], 2
jmp 0x10049de5
mov dword [ebp + 0x10], eax
jmp 0x10049dff
inc dword [ebp + 0x10]
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [edi]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x10049db9
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x10049dff
cmp dword [ebp - 0xc], 0
je 0x10049dff
mov eax, dword [edi]
test byte [eax + esi + 4], 0x48
je 0x10049dda
mov al, byte [ebp - 1]
cmp al, 0xa
je 0x10049de5
mov byte [ebx], 0xd
mov ecx, dword [edi]
mov byte [ecx + esi + 5], al
jmp 0x10049e02
cmp ebx, dword [ebp + 0xc]
jne 0x10049dea
cmp byte [ebp - 1], 0xa
jne 0x10049dea
mov byte [ebx], 0xa
jmp 0x10049e02
push 1
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1004c493
add esp, 0xc
cmp byte [ebp - 1], 0xa
je 0x10049e03
mov byte [ebx], 0xd
inc ebx
mov ecx, dword [ebp - 8]
cmp dword [ebp + 0x10], ecx
jb 0x10049d5b
jmp 0x10049e21
mov eax, dword [edi]
test byte [eax + esi + 4], 0x40
jne 0x10049e21
lea esi, [eax + esi + 4]
or byte [esi], 2
sub ebx, dword [ebp + 0xc]
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 8]
jmp 0x10049e2e
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x1004a2e1
Capabilities:
Terminate process

Disassembly:
push 8
push 0x10059d48
call fcn.10048774
push 8
call fcn.1004bdb4
pop ecx
xor edi, edi
mov dword [ebp - 4], edi
xor esi, esi
inc esi
cmp dword [0x10065880], esi
jne 0x1004a315
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov dword [0x1006587c], esi
mov al, byte [ebp + 0x10]
mov byte [0x10065878], al
cmp dword [ebp + 0xc], edi
jne 0x1004a35f
cmp dword [0x100664e8], edi
je 0x1004a34f
mov eax, dword [0x100664e4]
sub eax, 4
mov dword [0x100664e4], eax
cmp eax, dword [0x100664e8]
jb 0x1004a34f
mov eax, dword [eax]
cmp eax, edi
je 0x1004a330
call eax
jmp 0x1004a330
push 0x1005f030
mov eax, 0x1005f028
call fcn.1004a25f
pop ecx
push 0x1005f03c
mov eax, 0x1005f034
call fcn.1004a25f
pop ecx
or dword [ebp - 4], 0xffffffff
call 0x1004a390
cmp dword [ebp + 0x10], edi
jne 0x1004a39e
mov dword [0x10065880], esi
push dword [ebp + 8]
call fcn.1004a21d
xor edi, edi
xor esi, esi
inc esi
cmp dword [ebp + 0x10], edi
je 0x1004a39d
push 8
call fcn.1004bcff
pop ecx
ret
call fcn.100487af
ret

Function at 0x1004adfc
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x10060584]
mov ecx, dword [ebp + 0x94]
push ebx
push esi
mov dword [ebp + 0x88], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x10060648]
je 0x1004ae31
inc eax
cmp eax, 0x13
jb 0x1004ae22
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x10060648]
jne 0x1004af57
mov eax, dword [0x10065814]
cmp eax, 1
je 0x1004af2f
cmp eax, edx
jne 0x1004ae61
cmp dword [0x10065818], 1
je 0x1004af2f
cmp ecx, 0xfc
je 0x1004af57
push 0x104
lea eax, [ebp - 0x80]
push eax
push edx
mov byte [ebp + 0x84], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x1004ae97
lea eax, [ebp - 0x80]
push 0x1005a174
push eax
call fcn.1004b7b0
pop ecx
pop ecx
lea edi, [ebp - 0x80]
mov eax, edi
push eax
call fcn.10048ed0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x1004aecb
mov eax, edi
push eax
call fcn.10048ed0
mov edi, eax
lea eax, [ebp - 0x80]
sub eax, 0x3b
push 3
add edi, eax
push 0x1005a170
push edi
call fcn.1004e3f0
add esp, 0x10
push edi
call fcn.10048ed0
push dword [esi + 0x1006064c]
mov ebx, eax
call fcn.10048ed0
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.1004ac40
mov ebx, esp
push 0x1005a154
push ebx
call fcn.1004b7b0
push edi
push ebx
call fcn.1004b7c0
push 0x1005a150
push ebx
call fcn.1004b7c0
push dword [esi + 0x1006064c]
push ebx
call fcn.1004b7c0
push 0x12010
push 0x1005a128
push ebx
call fcn.1004e2f3
add esp, 0x2c
jmp 0x1004af57
push edx
lea eax, [ebp + 0x94]
push eax
lea esi, [esi + 0x1006064c]
push dword [esi]
call fcn.10048ed0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x8c]
mov ecx, dword [ebp + 0x88]
call fcn.1004ba76
pop edi
pop esi
pop ebx
add ebp, 0x8c
leave
ret
Function at 0x1004c5b2
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3a0]
sub esp, 0x420
mov eax, dword [0x10060584]
push edi
xor edi, edi
cmp dword [ebp + 0x3b0], edi
mov dword [ebp + 0x39c], eax
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x7c], edi
jne 0x1004c5e3
xor eax, eax
jmp 0x1004c76c
mov eax, dword [ebp + 0x3a8]
push ebx
mov ebx, dword [ebp + 0x3a8]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x100663e0]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x1004c61f
push 2
push edi
push edi
push dword [ebp + 0x3a8]
call fcn.1004e0c0
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x1004c6fa
cmp dword [ebp + 0x3b0], edi
mov eax, dword [ebp + 0x3ac]
mov dword [ebp - 0x74], eax
mov dword [ebp - 0x6c], edi
jbe 0x1004c738
mov ecx, dword [ebp - 0x74]
sub ecx, dword [ebp + 0x3ac]
lea eax, [ebp - 0x68]
mov dword [ebp - 0x70], edi
cmp ecx, dword [ebp + 0x3b0]
jae 0x1004c683
mov edx, dword [ebp - 0x74]
inc dword [ebp - 0x74]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x1004c674
inc dword [ebp - 0x7c]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 0x70]
mov byte [eax], dl
inc eax
inc dword [ebp - 0x70]
cmp dword [ebp - 0x70], 0x400
jl 0x1004c654
mov edi, eax
lea eax, [ebp - 0x68]
sub edi, eax
push 0
lea eax, [ebp - 0x80]
push eax
push edi
lea eax, [ebp - 0x68]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1004c6c3
mov eax, dword [ebp - 0x80]
add dword [ebp - 0x78], eax
cmp eax, edi
jl 0x1004c6cc
mov eax, dword [ebp - 0x74]
sub eax, dword [ebp + 0x3ac]
xor edi, edi
cmp eax, dword [ebp + 0x3b0]
jb 0x1004c645
jmp 0x1004c6ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
xor edi, edi
mov eax, dword [ebp - 0x78]
cmp eax, edi
jne 0x1004c767
cmp dword [ebp - 0x6c], edi
je 0x1004c738
push 5
pop esi
cmp dword [ebp - 0x6c], esi
jne 0x1004c72d
call fcn.100485ca
mov dword [eax], 9
call fcn.100485d3
mov dword [eax], esi
jmp 0x1004c762
push edi
lea ecx, [ebp - 0x80]
push ecx
push dword [ebp + 0x3b0]
push dword [ebp + 0x3ac]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1004c722
mov eax, dword [ebp - 0x80]
mov dword [ebp - 0x6c], edi
mov dword [ebp - 0x78], eax
jmp 0x1004c6ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x6c], eax
jmp 0x1004c6ce
push dword [ebp - 0x6c]
call fcn.100485dc
pop ecx
jmp 0x1004c762
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x1004c750
mov eax, dword [ebp + 0x3ac]
cmp byte [eax], 0x1a
jne 0x1004c750
xor eax, eax
jmp 0x1004c76a
call fcn.100485ca
mov dword [eax], 0x1c
call fcn.100485d3
mov dword [eax], edi
or eax, 0xffffffff
jmp 0x1004c76a
sub eax, dword [ebp - 0x7c]
pop esi
pop ebx
mov ecx, dword [ebp + 0x39c]
pop edi
call fcn.1004ba76
add ebp, 0x3a0
leave
ret
Function at 0x1004e2f3
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x10065b54], ebx
push esi
push edi
jne 0x1004e373
push 0x1005a988
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x1004e3ae
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x1005a97c
push edi
call esi
test eax, eax
mov dword [0x10065b54], eax
je 0x1004e3ae
push 0x1005a96c
push edi
call esi
push 0x1005a958
push edi
mov dword [0x10065b58], eax
call esi
cmp dword [0x10065840], 2
mov dword [0x10065b5c], eax
jne 0x1004e373
push 0x1005a93c
push edi
call esi
test eax, eax
mov dword [0x10065b64], eax
je 0x1004e373
push 0x1005a924
push edi
call esi
mov dword [0x10065b60], eax
mov eax, dword [0x10065b60]
test eax, eax
je 0x1004e3b8
call eax
test eax, eax
je 0x1004e39f
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x10065b64]
test eax, eax
je 0x1004e39f
test byte [ebp - 8], 1
jne 0x1004e3b8
cmp dword [0x1006584c], 4
jb 0x1004e3b2
or byte [ebp + 0x12], 0x20
jmp 0x1004e3d7
xor eax, eax
jmp 0x1004e3e7
or byte [ebp + 0x12], 4
jmp 0x1004e3d7
mov eax, dword [0x10065b58]
test eax, eax
je 0x1004e3d7
call eax
mov ebx, eax
test ebx, ebx
je 0x1004e3d7
mov eax, dword [0x10065b5c]
test eax, eax
je 0x1004e3d7
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x10065b54]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x1004fb30
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x100c
call fcn.1004ac40
mov eax, dword [0x10060584]
push ebx
push esi
push 1
xor esi, esi
push esi
push dword [ebp + 8]
mov dword [ebp - 4], eax
call fcn.1004c493
or ebx, 0xffffffff
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 0x1008], eax
je 0x1004fc63
push 2
push esi
push dword [ebp + 8]
call fcn.1004c493
add esp, 0xc
cmp eax, ebx
je 0x1004fc63
push edi
mov edi, dword [ebp + 0xc]
sub edi, eax
test edi, edi
jle 0x1004fc03
mov ebx, 0x1000
push ebx
lea eax, [ebp - 0x1004]
push esi
push eax
call fcn.1004ba90
push 0x8000
push dword [ebp + 8]
call fcn.1005057e
add esp, 0x14
mov dword [ebp - 0x100c], eax
cmp edi, ebx
mov eax, ebx
jge 0x1004fbb9
mov eax, edi
push eax
lea eax, [ebp - 0x1004]
push eax
push dword [ebp + 8]
call fcn.1004c5b2
add esp, 0xc
cmp eax, 0xffffffff
je 0x1004fbd9
sub edi, eax
test edi, edi
jg 0x1004fbb1
jmp 0x1004fbf1
call fcn.100485d3
cmp dword [eax], 5
jne 0x1004fbee
call fcn.100485ca
mov dword [eax], 0xd
or esi, 0xffffffff
push dword [ebp - 0x100c]
push dword [ebp + 8]
call fcn.1005057e
pop ecx
pop ecx
jmp 0x1004fc4b
jge 0x1004fc4b
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.1004c493
push dword [ebp + 8]
call fcn.1004dc6e
add esp, 0x10
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov esi, eax
neg esi
sbb esi, esi
neg esi
dec esi
cmp esi, ebx
jne 0x1004fc4b
call fcn.100485ca
mov dword [eax], 0xd
call fcn.100485d3
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], eax
push 0
push dword [ebp - 0x1008]
push dword [ebp + 8]
call fcn.1004c493
add esp, 0xc
mov eax, esi
pop edi
jmp 0x1004fc65
mov eax, ebx
mov ecx, dword [ebp - 4]
pop esi
pop ebx
call fcn.1004ba76
leave
ret
Function at 0x100500a0
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.1004ac40
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x1005013b
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 [0x10065840]
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 0x1005013b
cmp eax, 1
je 0x1005015c
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 0x1005013b
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x10050108
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x10050137
xor eax, eax
inc eax
jmp 0x1005017b
cmp edi, eax
jae 0x1005013f
xor eax, eax
jmp 0x1005017b
cmp eax, esi
jae 0x10050146
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 [0x10065840]
jmp 0x1005015f
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 0x401027
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x10]
test esi, esi
push edi
jne 0x401058
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov edx, dword [0x403020]
test edx, edx
mov esi, eax
jne 0x401069
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edx, eax
add edx, esi
mov dword [0x403020], edx
jmp 0x401069
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edx, dword [0x403020]
lea esi, [esi + eax + 1]
cmp esi, edx
jae 0x4010a8
mov ebp, 0x40301a
mov ebx, 0x40301d
jmp 0x40107a
inc esi
push ebp
push esi
call section..text
test eax, eax
jne 0x401079
cmp byte [esi], 0x22
jne 0x40108b
inc esi
mov edi, esi
jmp 0x401090
inc esi
push ebx
push esi
call section..text
test eax, eax
je 0x40108f
mov byte [esi], 0
cmp byte [edi], 0
jne 0x4010b1
inc esi
cmp esi, edx
jb 0x40107a
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret 4
mov eax, edi
jmp 0x4010aa