joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40db33
Capabilities:
Print debug messages
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1878
call fcn.0045be00
mov eax, dword [0x4b8db8]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, ecx
mov eax, dword [esi]
cmp eax, dword [ebp + 8]
jl 0x40dc5a
push edi
xor edi, edi
cmp dword [esi + 8], 0xffffffff
jne 0x40db8b
push edi
push 0x80
push 4
push edi
push 3
push 0xc0000000
lea eax, [esi + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esi + 8], eax
cmp eax, 0xffffffff
je 0x40dc59
push 2
push edi
push edi
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [ebp - 0x1874]
push eax
call fcn.0045d9db
lea eax, [ebp - 0x1874]
mov dword [esp], 0x4930a4
push eax
call fcn.0045c1fa
lea eax, [ebp - 0x104]
push eax
call fcn.0045d901
lea eax, [ebp - 0x104]
push eax
lea eax, [ebp - 0x1874]
push eax
call fcn.0045c1fa
lea eax, [ebp - 0x1874]
push 0x493fa0
push eax
call fcn.0045c1fa
lea eax, [ebp - 0x1874]
push ebx
push eax
call fcn.0045c1fa
lea eax, [ebp - 0x1874]
push 0x493f98
push eax
call fcn.0045c1fa
add esp, 0x2c
push edi
push edi
push 0x7d0
lea eax, [ebp - 0x8d4]
push eax
push 0xffffffffffffffff
lea eax, [ebp - 0x1874]
push eax
push edi
push edi
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
lea eax, [ebp - 0x1878]
push eax
lea eax, [ebp - 0x8d4]
push eax
call fcn.0045cd70
pop ecx
push eax
lea eax, [ebp - 0x8d4]
push eax
push dword [esi + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [esi], 1
jl 0x40dc59
push ebx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.004583c3
leave
ret 8

Function at 0x40e6f4
Capabilities:
Create directory

Disassembly:
push 4
mov eax, 0x489377
call fcn.004583d2
mov ebx, dword [ebp + 8]
xor edi, edi
push edi
mov esi, 0x493fc4
push esi
mov ecx, ebx
call fcn.0040e585
cmp eax, 0xffffffff
je 0x40e72c
push edi
push esi
mov ecx, ebx
call fcn.0040e585
push esi
mov edi, eax
call fcn.00457dfa
pop ecx
add edi, eax
mov esi, 0x49285c
jmp 0x40e787
push edi
push esi
mov ecx, ebx
call fcn.0040e585
push esi
mov edi, eax
call fcn.00457dfa
pop ecx
add edi, eax
push edi
push 0
lea eax, [ebp - 0x10]
push eax
mov ecx, ebx
call fcn.0040aa4e
and dword [ebp - 4], 0
lea eax, [ebp - 0x10]
push 0x10
push eax
call fcn.0040e5fc
pop ecx
pop ecx
test eax, eax
jne 0x40e778
push eax
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x40e79e
mov ecx, dword [ebp - 0x10]
or dword [ebp - 4], 0xffffffff
add ecx, 0xfffffff0
call fcn.00401548
push edi
push esi
mov ecx, ebx
call fcn.0040e585
cmp eax, 0xffffffff
jne 0x40e733
xor eax, eax
inc eax
call fcn.004584aa
ret
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
call fcn.00401548
xor eax, eax
jmp 0x40e798
Function at 0x410457
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x808
mov eax, dword [0x4b8db8]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x808], 0
push esi
mov esi, dword [ebp + 8]
mov eax, 0x400
push eax
mov dword [ebp - 0x808], eax
lea eax, [ebp - 0x804]
push 0
push eax
call fcn.0045b7f0
add esp, 0xc
lea eax, [ebp - 0x808]
push eax
lea eax, [ebp - 0x804]
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
mov ecx, esi
test eax, eax
je 0x4104ba
lea eax, [ebp - 0x804]
push eax
call fcn.004021ff
jmp 0x4104c4
push str.default
call fcn.0040ee75
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.004583c3
leave
ret
Function at 0x416fa5
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov edi, ecx
mov dword [edi + 0x58], ebx
test ebx, 0xffff0000
jne 0x416fc9
cmp dword [edi + 0x54], 0
jne 0x416fc9
movzx eax, bx
mov dword [edi + 0x54], eax
call fcn.004226b3
mov esi, dword [eax + 0xc]
push 5
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push dword [ebp + 0xc]
mov ebx, eax
push ebx
mov ecx, edi
call fcn.00416f66
push ebx
mov esi, eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 8

Function at 0x41a341
Capabilities:
Inspect section memory permissions

Disassembly:
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
cmp eax, ebx
je fcn.0041a36b
test eax, 0x80000000
lea ecx, [eax + esi]
je 0x41a346
and eax, 0xffff
add byte [eax], al
push eax
jmp 0x41a34a
add ecx, 2
push ecx
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00419cfa
add esp, 0xc
cmp edi, ebx
mov dword [edi], eax
je 0x41a524
add edi, 4
add dword [ebp + 0x10], 4
jmp 0x41a32b
push 0x8000
push ebx
push esi
call dword [ebp - 8]
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x41a36b
Capabilities:
Inspect section memory permissions

Disassembly:
cmp dword [eax + 4], ebx
jne 0x41a2da
cmp dword [eax + 0xc], ebx
je 0x41a37d
mov edi, dword [eax + 0xc]
add edi, esi
push edi
call dword [ebp - 0xc0]
mov dword [ebp + 0xc], eax
call fcn.00419d35
invalid
rol byte [ebx - 0x74eb43bb], 0xbd
js 0x41a372
add dword [ebp - 0x44], 0x14
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp - 0x44]
jmp 0x41a2cc
invalid
invalid
call fcn.00419d35
lodsb al, byte [esi]
jp 0x41a36a
nop
mov eax, dword [edi + 0xa0]
cmp eax, ebx
je 0x41a3e9
add eax, esi

Function at 0x41a44f
Capabilities:
Inspect section memory permissions

Disassembly:
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp + 0xc]
cmp ax, word [edi + 6]
jne 0x41a40c
mov edx, dword [ebp - 0xb4]
xor ecx, ecx
mov edi, 0x60000000
jmp 0x41a42a
movzx eax, ax
lea eax, [eax + eax*4]
mov ecx, dword [edi + eax*8 + 0x104]
mov edx, dword [edi + eax*8 + 0x108]
lea eax, [edi + eax*8 + 0xf8]
mov edi, dword [eax + 0x24]
lea eax, [edx + ecx - 1]
xor edx, edx
div dword [ebp - 0xac]
xor edx, edx
mov dword [ebp - 0x44], eax
mov eax, ecx
div dword [ebp - 0xac]
cmp eax, dword [ebp - 0x44]
ja 0x41a488
mov edx, edi
mov dword [ebp + 8], edi
and dword [ebp + 8], 0x40000000
or byte [eax], al
add byte [eax], al
inc eax
mov dword [ebp + 0x10], edi
and edx, 0x20000000
and dword [ebp + 0x10], 0x80000000
mov ecx, dword [ebp + 0x18]
cmp edx, ebx
je 0x41a46f
or byte [eax + ecx], 1
cmp dword [ebp + 8], ebx
je 0x41a478
or byte [eax + ecx], 2
cmp dword [ebp + 0x10], ebx
je 0x41a482
add ecx, eax
or byte [ecx], 4
inc eax
cmp eax, dword [ebp - 0x44]
jbe 0x41a464
inc dword [ebp + 0xc]
mov eax, dword [ebp - 0x88]
mov cx, word [ebp + 0xc]
cmp cx, word [eax + 6]
invalid
invalid
dec edi
Function at 0x41a47b
Capabilities:
Inspect section memory permissions

Disassembly:
mov edi, dword [ebp - 0x88]
mov eax, dword [ebp + 0xc]
cmp ax, word [edi + 6]
jne 0x41a40c
mov edx, dword [ebp - 0xb4]
xor ecx, ecx
mov edi, 0x60000000
jmp 0x41a42a
movzx eax, ax
lea eax, [eax + eax*4]
mov ecx, dword [edi + eax*8 + 0x104]
mov edx, dword [edi + eax*8 + 0x108]
lea eax, [edi + eax*8 + 0xf8]
mov edi, dword [eax + 0x24]
lea eax, [edx + ecx - 1]
xor edx, edx
div dword [ebp - 0xac]
xor edx, edx
mov dword [ebp - 0x44], eax
mov eax, ecx
div dword [ebp - 0xac]
cmp eax, dword [ebp - 0x44]
ja 0x41a488
mov edx, edi
mov dword [ebp + 8], edi
and dword [ebp + 8], 0x40000000
or byte [eax], al
add byte [eax], al
inc eax
mov dword [ebp + 0x10], edi
and edx, 0x20000000
and dword [ebp + 0x10], 0x80000000
mov ecx, dword [ebp + 0x18]
cmp edx, ebx
je 0x41a46f
or byte [eax + ecx], 1
cmp dword [ebp + 8], ebx
je 0x41a478
or byte [eax + ecx], 2
cmp dword [ebp + 0x10], ebx
je 0x41a482
add ecx, eax
or byte [ecx], 4
inc eax
cmp eax, dword [ebp - 0x44]
jbe 0x41a464
inc dword [ebp + 0xc]
mov eax, dword [ebp - 0x88]
mov cx, word [ebp + 0xc]
cmp cx, word [eax + 6]
invalid
invalid
dec edi

Function at 0x41ac04
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push ebx
stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
and byte [ebp - 0x12c], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x12b]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
and byte [ebp - 0x654], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x653]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
and byte [ebp - 0x504], 0
push 0x40
pop ecx
xor eax, eax
lea edi, [ebp - 0x503]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call fcn.00419d13
or byte [eax + 0x2ff845c6], ah
mov byte [ebp - 0x24], 0x34
xor al, 0x80
movsd dword es:[edi], dword [esi]
xchg esp, eax
cld
invalid
inc dword [eax]
and byte [ebp - 0x36b], 0
mov byte [ebp - 0x36a], 0xaa
and byte [ebp - 0x369], 0
mov byte [ebp - 0x368], 0x12
mov byte [ebp - 0x367], 0x30
mov byte [ebp - 0x366], 0x21
mov byte [ebp - 0x365], 6
mov byte [ebp - 0x364], 0x2c
mov byte [ebp - 0x363], 0x26
mov byte [ebp - 0x362], 0x21
mov byte [ebp - 0x361], 0x30
mov byte [ebp - 0x360], 0x38
mov byte [ebp - 0x35f], 0x11
mov byte [ebp - 0x35e], 0x3c
mov byte [ebp - 0x35d], 0x27
mov byte [ebp - 0x35c], 0x30
mov byte [ebp - 0x35b], 0x36
mov byte [ebp - 0x35a], 0x21
mov byte [ebp - 0x359], 0x3a
mov byte [ebp - 0x358], 0x27
mov byte [ebp - 0x357], 0x2c
invalid
Function at 0x41db6d
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor ebx, ebx
xor edi, edi
mov dword [ebp - 4], ecx
cmp dword [ebp + 8], ebx
je 0x41dbb4
call fcn.004226b3
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x41dbb4
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
je 0x41dbd0
push ebx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
mov ecx, dword [ebp - 4]
push edi
call fcn.0041d6e5
mov esi, eax
test edi, edi
je 0x41dbce
test ebx, ebx
je 0x41dbce
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x41ee7a
Capabilities:
Get graphical window text

Disassembly:
push 4
mov eax, 0x48ad72
call fcn.004583d2
mov esi, ecx
cmp dword [esi + 0x50], 0
jne 0x41ee9f
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [esi + 0x20]
call dword [sym.imp.USER32.dll_GetWindowTextW]
jmp 0x41eee5
lea ecx, [ebp - 0x10]
call fcn.00405190
mov ecx, dword [esi + 0x50]
mov eax, dword [ecx]
and dword [ebp - 4], 0
lea edx, [ebp - 0x10]
push edx
call dword [eax + 0x8c]
push 0xffffffffffffffff
push dword [ebp - 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004028a5
add esp, 0x10
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
mov esi, eax
call fcn.00401548
mov eax, esi
call fcn.004584aa
ret 8

Function at 0x4255df
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 4], ebx
cmp dword [ebp + 0xc], ebx
je 0x425627
call fcn.004226b3
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x425627
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 4], eax
test eax, eax
je 0x42566a
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
mov esi, dword [ebp + 8]
mov dword [ebp + 0xc], 1
test ebx, ebx
je 0x425653
push dword [ebp + 0x10]
mov eax, dword [edi]
push ebx
push esi
mov ecx, edi
call dword [eax + 0x20]
cmp dword [ebp - 4], 0
mov dword [ebp + 0xc], eax
je 0x425653
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [esi + 0x4c], 0
je 0x425667
mov ecx, dword [esi + 0x4c]
push dword [ebp + 0x10]
mov eax, dword [ecx]
call dword [eax + 0xa0]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x42ba28
Capabilities:
Query or enumerate registry value

Disassembly:
push 0
mov eax, 0x48baac
call fcn.004583d2
push dword [ebp + 0xc]
lea ecx, [ebp + 0xc]
call fcn.004021ff
and dword [ebp - 4], 0
cmp dword [ebp + 8], 0x80000000
jne 0x42ba8a
call fcn.00421ab3
cmp eax, 1
jne 0x42ba8a
lea eax, [ebp + 0xc]
push eax
lea eax, [ebp + 8]
push str.SoftwareClasses_
push eax
call fcn.0040c284
add esp, 0xc
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 1
call fcn.0040ad54
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00401548
mov dword [ebp + 8], SysReAllocString
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueW]
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
mov esi, eax
call fcn.00401548
mov eax, esi
call fcn.004584aa
ret 0x10

Function at 0x42bab3
Capabilities:
Set registry value

Disassembly:
push 0
mov eax, 0x48bad7
call fcn.004583d2
push dword [ebp + 0xc]
lea ecx, [ebp + 0xc]
call fcn.004021ff
and dword [ebp - 4], 0
cmp dword [ebp + 8], 0x80000000
jne 0x42bb15
call fcn.00421ab3
cmp eax, 1
jne 0x42bb15
lea eax, [ebp + 0xc]
push eax
lea eax, [ebp + 8]
push str.SoftwareClasses_
push eax
call fcn.0040c284
add esp, 0xc
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 1
call fcn.0040ad54
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00401548
mov dword [ebp + 8], SysReAllocString
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueW]
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
mov esi, eax
call fcn.00401548
mov eax, esi
call fcn.004584aa
ret 0x14

Function at 0x42bb41
Capabilities:
Delete registry key

Disassembly:
push 0
mov eax, 0x48bb02
call fcn.004583d2
push dword [ebp + 0xc]
lea ecx, [ebp + 0xc]
call fcn.004021ff
and dword [ebp - 4], 0
cmp dword [ebp + 8], 0x80000000
jne 0x42bba3
call fcn.00421ab3
cmp eax, 1
jne 0x42bba3
lea eax, [ebp + 0xc]
push eax
lea eax, [ebp + 8]
push str.SoftwareClasses_
push eax
call fcn.0040c284
add esp, 0xc
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 1
call fcn.0040ad54
mov ecx, dword [ebp + 8]
add ecx, 0xfffffff0
call fcn.00401548
mov dword [ebp + 8], SysReAllocString
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov ecx, dword [ebp + 0xc]
add ecx, 0xfffffff0
mov esi, eax
call fcn.00401548
mov eax, esi
call fcn.004584aa
ret 8

Function at 0x4583c3
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4b8db8]
jne 0x4583cd
repz ret
jmp fcn.0046386c
Function at 0x45d7ab
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x45d7dc
call fcn.0045f390
mov dword [eax], esi
call fcn.0045f37d
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.0045d234
add esp, 0x14
push 0x16
pop eax
jmp 0x45d831
test dword [ebp + 0xc], 0xfffffff9
jne 0x45d7b8
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x45d809
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0045f3a3
pop ecx
call fcn.0045f37d
mov eax, dword [eax]
jmp 0x45d831
test al, 0x10
jne 0x45d82f
test al, 1
je 0x45d82f
test byte [ebp + 0xc], 2
je 0x45d82f
call fcn.0045f390
mov dword [eax], 5
call fcn.0045f37d
mov dword [eax], 0xd
jmp 0x45d800
xor eax, eax
pop esi
pop ebp
ret

Function at 0x47297e
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0046139c
and dword [ebp - 4], 0
cmp dword [0x4bd15c], 0
mov ebx, eax
jne 0x472a2f
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x472ae0
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxA
push edi
call esi
test eax, eax
je 0x472ae0
push eax
call fcn.0046132a
mov dword [esp], 0x49deb4
push edi
mov dword [0x4bd15c], eax
call esi
push eax
call fcn.0046132a
mov dword [esp], 0x49dea0
push edi
mov dword [0x4bd160], eax
call esi
push eax
call fcn.0046132a
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x4bd164], eax
call esi
push eax
call fcn.0046132a
pop ecx
mov dword [0x4bd16c], eax
test eax, eax
je 0x472a2f
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.0046132a
pop ecx
mov dword [0x4bd168], eax
mov eax, dword [0x4bd168]
cmp eax, ebx
je 0x472a87
cmp dword [0x4bd16c], ebx
je 0x472a87
push eax
call fcn.004613a5
push dword [0x4bd16c]
mov esi, eax
call fcn.004613a5
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x472a87
test edi, edi
je 0x472a87
call esi
test eax, eax
je 0x472a7e
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x472a7e
test byte [ebp - 0xc], 1
jne 0x472a87
or dword [ebp + 0x10], 0x200000
jmp 0x472ac0
mov eax, dword [0x4bd160]
cmp eax, ebx
je 0x472ac0
push eax
call fcn.004613a5
pop ecx
test eax, eax
je 0x472ac0
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x472ac0
mov eax, dword [0x4bd164]
cmp eax, ebx
je 0x472ac0
push eax
call fcn.004613a5
pop ecx
test eax, eax
je 0x472ac0
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x4bd15c]
call fcn.004613a5
pop ecx
test eax, eax
je 0x472ae0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x472ae2
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4884fb
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x48852c
call fcn.0045f390
mov dword [eax], esi
call fcn.0045f37d
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.0045d234
add esp, 0x14
push 0x16
pop eax
jmp 0x488581
test dword [ebp + 0xc], 0xfffffff9
jne 0x488508
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x488559
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0045f3a3
pop ecx
call fcn.0045f37d
mov eax, dword [eax]
jmp 0x488581
test al, 0x10
jne 0x48857f
test al, 1
je 0x48857f
test byte [ebp + 0xc], 2
je 0x48857f
call fcn.0045f390
mov dword [eax], 5
call fcn.0045f37d
mov dword [eax], 0xd
jmp 0x488550
xor eax, eax
pop esi
pop ebp
ret
Function at 0x404d80
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffdf4
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.0040725c
test esi, esi
jne 0x404db6
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.004073e4
jmp 0x404dd4
call sub.kernel32.dll_GetCommandLineW
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00404c64
mov edi, eax
test esi, esi
je 0x404dd4
cmp dword [ebx], 0
je 0x404dd4
dec esi
jmp 0x404dbd
add esp, 0x20c
pop edi
pop esi
pop ebx
ret

Function at 0x404e08
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x708008], 0x8088405
inc edx
mov dword [ebx + 0x708008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x405f14
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff4
mov edi, edx
mov esi, eax
mov ebp, dword [esi + 0x10]
mov eax, esi
call fcn.00406358
mov byte [esp], al
cmp byte [esp], 0
jne 0x4060a0
test edi, edi
je 0x4060a0
mov byte [esp + 1], 0
test ebp, ebp
jle 0x405fd7
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
test ebp, ebp
jle 0x405fb2
cmp edi, 0xffffffff
je 0x405f73
call sub.kernel32.dll_GetTickCount
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x405f73
mov byte [esp], 0
jmp 0x4060a0
mov ebx, dword [esi]
cmp ebx, 1
jg 0x405fb2
test ebx, ebx
jne 0x405fa8
mov eax, esi
xor ecx, ecx
mov edx, 1
call fcn.00402994
test eax, eax
jne 0x405fa8
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
mov byte [esp], 1
jmp 0x4060a0
call 0x40649c
dec ebp
test ebp, ebp
jg 0x405f58
cmp edi, 0xffffffff
je 0x405fd7
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x405fd5
mov byte [esp], 0
jmp 0x4060a0
sub edi, eax
mov ebx, dword [esi]
test ebx, ebx
je 0x405f22
lea edx, [ebx + 2]
mov eax, esi
mov ecx, ebx
call fcn.00402994
cmp ebx, eax
jne 0x405fd7
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
mov eax, esi
call fcn.00406110
mov edx, eax
mov ebx, dword [0x7198f8]
mov ecx, edi
xor eax, eax
call dword [ebx + 0x10]
test eax, eax
sete byte [esp]
cmp edi, 0xffffffff
je 0x40603e
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
jbe 0x40603c
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
sub edi, eax
jmp 0x40603e
xor edi, edi
cmp byte [esp], 0
je 0x406067
mov ebx, dword [esi]
test bl, 1
jne 0x406080
mov edx, ebx
sub edx, 2
or edx, 1
mov eax, esi
mov ecx, ebx
call fcn.00402994
cmp ebx, eax
jne 0x406044
mov byte [esp + 1], 1
jmp 0x406080
mov ebx, dword [esi]
mov edx, ebx
sub edx, 2
mov eax, esi
mov ecx, ebx
call fcn.00402994
cmp ebx, eax
jne 0x406067
mov byte [esp + 1], 1
cmp byte [esp + 1], 0
je 0x405ff1
cmp byte [esp], 0
je 0x4060a0
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
movzx eax, byte [esp]
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x406eb8
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x719058], 0
je 0x406f1f
cmp word [0x719344], 0xd7b2
jne 0x406ee1
cmp dword [0x71934c], 0
jbe 0x406ee1
mov eax, 0x719340
call dword [0x71935c]
push 0
lea eax, [esp + 4]
push eax
push 0x1d
push str.Runtime_error_____at_00000000
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
mov eax, 0x406f4c
call fcn.00407b70
push eax
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x708034], 0
jne 0x406f3b
push 0
push 0x7089ca
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret

Function at 0x407118
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
push edi
mov esi, ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov edi, dword [ebp + 0x10]
cmp dword [0x708038], 0
je 0x407143
mov edx, edi
mov eax, esi
call dword [0x708038]
mov ebx, eax
jmp 0x407154
mov eax, 8
call fcn.00404930
mov ebx, eax
mov dword [ebx], esi
mov dword [ebx + 4], edi
mov byte [0x719059], 1
mov eax, dword [ebp + 8]
push eax
mov eax, dword [ebp + 0xc]
push eax
push ebx
mov eax, 0x4070e0
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_CreateThread
mov esi, eax
test esi, esi
jne 0x407189
mov edx, 8
mov eax, ebx
call fcn.0040494c
mov eax, esi
pop edi
pop esi
pop ebx
pop ecx
pop ecx
pop ebp
ret 0xc