joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4048f9
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push edi
mov edi, eax
mov dword [ebp - 4], 0xc8
push dword [ebp - 4]
call fcn.004222b8
pop ecx
mov ebx, eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
lea ecx, [ebp - 4]
push ecx
push ebx
lea ecx, [ebp - 8]
push ecx
push 0
push eax
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
cmp eax, 0xea
jne 0x40493a
inc dword [ebp - 4]
jmp 0x404909
test eax, eax
jne 0x404988
cmp dword [ebp - 8], 1
je 0x404960
cmp dword [ebp - 8], 4
jne 0x404909
push dword [ebx]
push 0x424924
push edi
call fcn.0040382d
add esp, 0xc
mov byte [ebp + 0xf], 1
jmp 0x40498c
mov eax, dword [ebp - 4]
push esi
push ebx
lea esi, [ebp + 0xc]
mov byte [eax + ebx], 0
call fcn.00401d1b
call fcn.0040158b
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
call fcn.0040175b
mov byte [ebp + 0xf], 1
pop esi
jmp 0x40498c
mov byte [ebp + 0xf], 0
push ebx
call fcn.004222bd
mov al, byte [ebp + 0xf]
pop ecx
pop edi
pop ebx
leave
ret

Function at 0x404bc8
Capabilities:
Get file size

Disassembly:
mov eax, dword [eax]
push esi
push 0
push 0x80
push 3
push 0
push 0
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x404bf6
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop esi
ret
push ebx
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
test esi, esi
mov ebx, eax
je 0x404c0d
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
pop ebx
pop esi
ret
Function at 0x404e05
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x88
mov eax, dword [0x429060]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
lea eax, [ebp - 0x70]
call fcn.00415c7c
mov edx, dword [edx]
xor ebx, ebx
push ebx
push ebx
push 3
push ebx
push 3
push 0x80000000
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 0x88], eax
jne 0x404e51
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x404f10
push esi
push edi
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
sub edi, dword [ebp + 8]
mov esi, 0xc000
push esi
lea eax, [ebp - 0x78]
push eax
mov dword [ebp - 0x7c], ebx
mov dword [ebp - 0x78], ebx
call fcn.004038ae
push ebx
lea eax, [ebp - 0x80]
push eax
push esi
push dword [ebp - 0x78]
push dword [ebp - 0x88]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x404ede
mov ebx, dword [ebp - 0x80]
test ebx, ebx
je 0x404edc
mov eax, dword [ebp - 0x7c]
lea ecx, [ebx + eax]
cmp ecx, edi
mov byte [ebp - 0x71], 0
jbe 0x404eae
mov ebx, edi
sub ebx, eax
mov dword [ebp - 0x80], ebx
mov byte [ebp - 0x71], 1
push dword [ebp - 0x78]
lea eax, [ebp - 0x70]
call fcn.00415b09
cmp byte [ebp - 0x71], 0
jne 0x404edc
add dword [ebp - 0x7c], ebx
push 0
lea eax, [ebp - 0x80]
push eax
push esi
push dword [ebp - 0x78]
push dword [ebp - 0x88]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x404e8e
xor ebx, ebx
lea esi, [ebp - 0x70]
call fcn.00415ba3
mov eax, esi
call fcn.00415c25
push dword [ebp - 0x78]
mov esi, eax
call fcn.004222bd
cmp dword [ebp - 0x88], ebx
pop ecx
je 0x404f0c
push dword [ebp - 0x88]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.0042254d
leave
ret

Function at 0x404f7c
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
push ebx
push esi
push edi
xor eax, eax
push 0x10
xor ebx, ebx
cmp byte [ebp + 0x18], bl
pop ecx
lea edi, [ebp - 0x58]
mov dword [ebp - 0x5c], 0x44
rep stosd dword es:[edi], eax
mov dword [ebp - 0x18], ebx
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov dword [ebp - 8], ebx
mov byte [ebp - 4], bl
je 0x404fb4
lea esi, [ebp - 8]
call fcn.00421a93
mov eax, dword [ebp + 8]
mov edi, dword [eax]
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x5c]
push eax
push ebx
push ebx
push dword [ebp + 0x14]
push ebx
push ebx
push ebx
call fcn.00403840
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
cmp byte [ebp + 0x18], bl
mov edi, eax
je 0x404fe8
lea esi, [ebp - 8]
call fcn.00421aa9
cmp edi, ebx
je 0x405013
cmp dword [ebp + 0x10], ebx
je 0x405008
push 0xffffffffffffffff
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp + 0x10]
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov bl, 1
lea esi, [ebp - 8]
call fcn.00421aa9
pop edi
pop esi
mov al, bl
pop ebx
leave
ret
Function at 0x405022
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
push ebx
push edi
push 0xe
xor eax, eax
pop ecx
lea edi, [ebp - 0x38]
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x3c], 0x3c
je 0x405049
mov dword [ebp - 0x38], 0x40
push esi
mov esi, dword [edx]
mov edi, edx
call fcn.0040cd16
test al, al
je 0x40505a
add esi, 4
xor eax, eax
cmp byte [ebp + 0x10], bl
mov dword [ebp - 0x2c], esi
sete al
mov dword [ebp - 0x30], str.open
pop esi
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax]
cmp dword [eax - 0xc], ebx
je 0x40507d
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x3c]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
test eax, eax
jne 0x40508f
xor al, al
jmp 0x4050b2
cmp dword [ebp + 0xc], ebx
je 0x4050b0
cmp dword [ebp - 4], ebx
je 0x4050b0
push 0xffffffffffffffff
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp + 0xc]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov al, 1
pop edi
pop ebx
leave
ret
Function at 0x4054a9
Capabilities:
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x394]
sub esp, 0x414
mov eax, dword [0x429060]
push ebx
push esi
push edi
xor ebx, ebx
push ebx
push 0x80
push 3
xor eax, ebp
push ebx
mov dword [ebp + 0x390], eax
mov eax, dword [ebp + 0x39c]
mov eax, dword [eax]
push 3
push 0x80000000
push eax
mov dword [ebp - 0x78], ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
lea ecx, [ebp - 0x74]
push ecx
mov edi, 0x3ff
push edi
lea ecx, [ebp - 0x70]
push ecx
mov dword [ebp - 0x80], eax
mov dword [ebp - 0x74], ebx
push eax
jmp 0x405529
mov eax, dword [ebp - 0x74]
mov byte [ebp + eax - 0x70], bl
lea eax, [ebp - 0x70]
push eax
push dword [ebp - 0x78]
call fcn.00403a66
push ebx
lea eax, [ebp - 0x74]
push eax
push edi
lea eax, [ebp - 0x70]
push eax
push dword [ebp - 0x80]
call esi
cmp dword [ebp - 0x74], ebx
jne 0x405509
mov esi, dword [ebp - 0x78]
mov eax, dword [esi]
mov eax, dword [eax - 0xc]
cmp eax, 2
jl 0x40555b
lea ecx, [ebp - 0x78]
add eax, 0xfffffffe
push ecx
call fcn.004014a5
mov edi, esi
call fcn.0040158b
mov eax, dword [ebp - 0x78]
add eax, 0xfffffff0
call fcn.0040175b
cmp dword [ebp - 0x80], ebx
pop edi
pop esi
pop ebx
je 0x40556c
push dword [ebp - 0x80]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp + 0x390]
xor ecx, ebp
call fcn.0042254d
add ebp, 0x394
leave
ret
Function at 0x407802
Capabilities:
Delete directory
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [0x429570]
push ebx
push esi
push edi
mov ecx, 0x429570
call dword [eax + 0xc]
mov edi, dword [ebp + 8]
mov ebx, dword [ebp + 0x10]
add eax, 0x10
mov dword [ebp - 0x14], eax
mov eax, dword [edi + 0x80]
mov ecx, dword [eax]
mov eax, dword [ebx + 0x10]
add ecx, 4
call fcn.004192e6
add eax, 0x1c
mov eax, dword [eax]
sub eax, 0x10
call fcn.00401773
mov esi, eax
add esi, 0x10
cmp dword [esi - 0xc], 0
mov dword [ebp - 8], esi
je 0x407954
mov eax, dword [edi + 0x84]
mov eax, dword [eax]
sub eax, 0x10
call fcn.00401773
add eax, 0x10
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
call fcn.0040c50c
mov eax, dword [ebx + 0x14]
push dword [eax - 0xc]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00401cb8
lea eax, [ebp - 4]
call fcn.0040c50c
lea eax, [ebp - 0xc]
push eax
mov eax, ebx
call fcn.00406048
mov eax, dword [eax]
pop ecx
push dword [eax - 0xc]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00401cb8
mov eax, dword [ebp - 0xc]
add eax, 0xfffffff0
call fcn.0040175b
xor bl, bl
mov esi, edi
call fcn.00407a18
push 0x8a
lea ecx, [ebp - 0xc]
call fcn.00401000
pop ecx
push dword [ebp - 0xc]
push 2
push dword [edi + 0xf4]
push dword [ebp + 0xc]
call fcn.00407cfa
lea eax, [ebp - 8]
push 0
push eax
lea edx, [ebp - 4]
call fcn.00404f1d
mov bl, al
test bl, bl
pop ecx
pop ecx
jne 0x407937
lea esi, [ebp - 4]
call fcn.00403840
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [ebp - 4]
push 0x5c
call fcn.004015e9
test eax, eax
pop ecx
jne 0x407915
or eax, 0xffffffff
jmp 0x407918
sub eax, dword [ebp - 4]
lea ecx, [ebp - 0x10]
push ecx
lea esi, [ebp - 4]
call fcn.004014a5
push dword [eax]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.0040175b
mov eax, dword [ebp - 0xc]
add eax, 0xfffffff0
call fcn.0040175b
mov eax, dword [ebp - 4]
add eax, 0xfffffff0
call fcn.0040175b
test bl, bl
je 0x40797c
mov esi, dword [ebp - 8]
push dword [edi + 0xf4]
push dword [ebp + 0xc]
call fcn.004088ee
mov ecx, dword [edi + 0x80]
mov ecx, dword [ecx]
add ecx, 4
call fcn.004192e6
mov byte [eax + 0x5c], 1
mov byte [ebp + 0xf], 1
jmp 0x4079e9
inc dword [edi + 0x17c]
mov eax, dword [0x429570]
mov ecx, 0x429570
call dword [eax + 0xc]
add eax, 0x10
push 0x8b
lea ecx, [ebp - 0x10]
mov dword [ebp - 0xc], eax
call fcn.00401000
pop ecx
lea edi, [ebp - 0xc]
call fcn.0040158b
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
call fcn.0040175b
mov esi, dword [ebp - 0xc]
mov eax, dword [ebp + 8]
push esi
push 2
push dword [eax + 0xf4]
push dword [ebp + 0xc]
call fcn.00407cfa
mov eax, dword [ebp + 0x10]
mov dword [eax + 0xc], 1
lea eax, [esi - 0x10]
mov byte [ebp + 0xf], 0
call fcn.0040175b
mov edi, dword [ebp + 8]
mov esi, dword [ebp - 8]
cmp dword [esi - 0xc], 0
je 0x4079fb
mov bl, 1
mov esi, edi
call fcn.00407a18
mov esi, dword [ebp - 8]
lea eax, [esi - 0x10]
call fcn.0040175b
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
call fcn.0040175b
mov al, byte [ebp + 0xf]
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x4089a9
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push ecx
test eax, eax
je 0x408a55
dec eax
dec eax
push esi
mov esi, 0x85
je 0x4089ea
sub eax, 3
je 0x4089e3
dec eax
je 0x4089dc
dec eax
je 0x4089d5
sub eax, 3
je 0x408a54
jmp 0x4089ef
mov esi, 0x83
jmp 0x4089ef
mov esi, 0x82
jmp 0x4089ef
mov esi, 0x81
jmp 0x4089ef
mov esi, 0x84
cmp byte [0x42916c], 0
mov eax, dword [0x429570]
mov ecx, 0x429570
je 0x408a2f
push edi
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 4], eax
push esi
lea eax, [ebp - 4]
push eax
call fcn.00401b0b
push 0
lea edi, [ebp - 4]
call fcn.00408a82
mov eax, dword [ebp - 4]
pop ecx
add eax, 0xfffffff0
call fcn.0040175b
pop edi
jmp 0x408a54
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 4], eax
push esi
lea eax, [ebp - 4]
push eax
call fcn.00401b0b
mov esi, dword [ebp - 4]
push esi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
lea eax, [esi - 0x10]
call fcn.0040175b
pop esi
leave
ret

Function at 0x408a82
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
xor eax, eax
cmp byte [0x42916c], al
je 0x408ae3
cmp byte [ebp + 8], al
push ebx
push esi
push 0x10
pop ebx
je 0x408aa0
mov ebx, 0x40010
push eax
lea esi, [ebp - 8]
call fcn.00401d1b
push dword [edi]
lea esi, [ebp - 4]
call fcn.00401d1b
push ebx
lea eax, [ebp - 8]
push eax
mov eax, esi
push eax
call dword [sym.imp.USER32.dll_GetActiveWindow]
call fcn.0042196a
mov eax, dword [ebp - 4]
add esp, 0xc
add eax, 0xfffffff0
call fcn.0040175b
mov eax, dword [ebp - 8]
add eax, 0xfffffff0
call fcn.0040175b
pop esi
pop ebx
leave
ret
push dword [edi]
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
leave
ret
Function at 0x40959e
Capabilities:
Get geographical location

Disassembly:
sub esp, 0x14
mov eax, dword [edi + 0x28]
push ebx
push ebp
push esi
push dword [eax]
lea esi, [edi + 4]
push dword [esi]
call dword [sym.imp.USER32.dll_SetWindowTextA]
mov eax, dword [esi]
push 0x80
push eax
call fcn.004218ee
mov ebx, dword [sym.imp.USER32.dll_GetDlgItem]
pop ecx
pop ecx
push 0x414
push dword [esi]
mov ebp, eax
call ebx
push 0
push ebp
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push 0x170
push eax
call ebp
push esi
xor eax, eax
call fcn.00403de9
push dword [esi]
call dword [sym.imp.USER32.dll_SetForegroundWindow]
push 0x412
push dword [edi + 4]
call ebx
and dword [esp + 0xc], 0
mov dword [esp + 0x10], eax
mov eax, dword [edi + 0x24]
mov esi, dword [eax + 4]
test esi, esi
mov dword [esp + 0x1c], esi
jle 0x4096a4
push dword [esp + 0xc]
mov ecx, dword [edi + 0x24]
call fcn.00401a5f
movzx eax, word [eax]
push 0
push 0x424686
push 2
push eax
mov dword [esp + 0x28], eax
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
mov esi, eax
lea ebx, [esi - 1]
push 0x78
lea eax, [esp + 0x18]
call fcn.004037ec
push esi
lea esi, [esp + 0x18]
call fcn.00403840
push eax
push 2
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
mov esi, dword [esp + 0x14]
push esi
push 0
push 0x143
push dword [esp + 0x1c]
call ebp
push dword [esp + 0x18]
push eax
push 0x151
push dword [esp + 0x1c]
call ebp
lea eax, [esi - 0x10]
call fcn.0040175b
inc dword [esp + 0xc]
mov eax, dword [esp + 0xc]
cmp eax, dword [esp + 0x1c]
jl 0x40961a
mov esi, dword [esp + 0x1c]
xor ebx, ebx
cmp esi, ebx
mov dword [esp + 0x1c], ebx
jle 0x4096cd
push 0
push ebx
push 0x150
push dword [esp + 0x1c]
call ebp
movzx ecx, word [edi + 0x2c]
cmp ecx, eax
jne 0x4096c8
mov dword [esp + 0x1c], ebx
inc ebx
cmp ebx, esi
jl 0x4096ae
push 0
push dword [esp + 0x20]
push 0x14e
push dword [esp + 0x1c]
call ebp
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x14
ret

Function at 0x409b38
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [0x429570]
push ebx
push esi
push edi
mov ecx, 0x429570
call dword [eax + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_GetLocaleInfoA]
add eax, 0x10
push 0
mov dword [ebp - 8], eax
movzx eax, word [ebp + 0xc]
push 0x424686
push 2
push eax
call edi
mov esi, eax
lea ebx, [esi - 1]
push 0x78
lea eax, [ebp - 4]
call fcn.004037ec
push esi
lea esi, [ebp - 4]
call fcn.00403840
push eax
movzx eax, word [ebp + 0xc]
push 2
push eax
call edi
mov edi, dword [ebp - 4]
push edi
push dword [ebp + 0xc]
lea eax, [ebp - 8]
push str._d__s
push eax
call fcn.0040382d
mov esi, dword [ebp - 8]
add esi, 0xfffffff0
add esp, 0x10
mov eax, esi
call fcn.00401773
mov ebx, dword [ebp + 8]
add eax, 0x10
mov dword [ebx], eax
lea eax, [edi - 0x10]
call fcn.0040175b
mov eax, esi
call fcn.0040175b
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret
Function at 0x40a5bd
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov edi, ecx
xor ebx, ebx
mov dword [edi + 0x10], eax
cmp dword [eax], ebx
je 0x40a5f0
push ebx
push ebx
push ebx
push ebx
lea esi, [edi + 0x14]
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push eax
call fcn.0040a7b9
mov eax, dword [edi + 0x10]
mov ecx, dword [eax]
push dword [esi]
mov eax, dword [ecx]
call dword [eax + 0x10]
lea eax, [ebp - 4]
push eax
push ebx
push edi
push 0x40a7ab
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov esi, eax
mov eax, dword [edi + 0x10]
cmp dword [eax], ebx
mov dword [ebp - 0x14], esi
je 0x40a644
call fcn.0040a680
mov ebx, dword [edi + 4]
mov esi, eax
mov eax, dword [edi]
mov dword [ebp - 8], edx
call fcn.0040b43f
add esi, eax
adc dword [ebp - 8], edx
mov eax, dword [edi + 0x10]
push dword [ebp - 8]
mov ecx, dword [eax]
mov eax, dword [ecx]
push esi
call dword [eax]
mov eax, dword [edi + 0x10]
mov ecx, dword [eax]
mov eax, dword [ecx]
call dword [eax + 8]
mov esi, dword [ebp - 0x14]
xor ebx, ebx
push 0xffffffffffffffff
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 4]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x40a66e
cmp esi, ebx
mov edi, dword [ebp - 4]
je 0x40a66a
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
jmp 0x40a67b
cmp esi, ebx
je 0x40a679
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40a94f
Capabilities:
Delete directory
Delete file

Disassembly:
cmp byte [esi + 0xac], 0
push ebx
push edi
mov dword [esi], 0x424c94
je 0x40a9e6
cmp dword [esi + 0x78], 3
je 0x40a999
mov edi, esi
call fcn.0040b860
mov eax, dword [esi + 0x78]
cmp eax, 2
je 0x40a999
cmp eax, 1
je 0x40a999
mov eax, dword [esi + 0x40]
mov ecx, eax
shr ecx, 3
test cl, 1
jne 0x40a992
shr eax, 6
test al, 1
je 0x40a999
mov edi, esi
call fcn.0040af1d
mov ebx, dword [esi + 0x94]
xor edi, edi
test ebx, ebx
jle 0x40a9c3
push ebp
lea ebp, [esi + 0x90]
mov eax, edi
mov ecx, ebp
call fcn.0040a7d2
push dword [eax]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
inc edi
cmp edi, ebx
jl 0x40a9ac
pop ebp
mov edi, dword [esi + 0xa0]
dec edi
js 0x40a9e6
lea ebx, [esi + 0x9c]
mov eax, edi
mov ecx, ebx
call fcn.0040a7d2
push dword [eax]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
dec edi
jns 0x40a9d2
mov eax, dword [esi + 0xb0]
push 0x10
pop ebx
sub eax, ebx
call fcn.0040175b
mov eax, dword [esi + 0xa8]
sub eax, ebx
call fcn.0040175b
lea edi, [esi + 0x9c]
call fcn.00403a31
lea edi, [esi + 0x90]
call fcn.00403a31
lea edi, [esi + 0x84]
call fcn.0040c470
mov eax, dword [esi + 0x6c]
test eax, eax
je 0x40aa36
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
and dword [esi + 0x6c], 0
lea edi, [esi + 0x60]
call fcn.0040c41f
mov eax, dword [esi + 0x5c]
sub eax, ebx
call fcn.0040175b
mov eax, dword [esi + 0x58]
sub eax, ebx
call fcn.0040175b
mov eax, dword [esi + 0x54]
sub eax, ebx
call fcn.0040175b
mov eax, dword [esi + 0x50]
pop edi
sub eax, ebx
pop ebx
jmp fcn.0040175b
Function at 0x40af1d
Capabilities:
Delete directory

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [edi + 0x58]
push ebx
push esi
sub eax, 0x10
call fcn.00401773
add eax, 0x10
xor ecx, ecx
mov dword [ebp - 4], eax
mov eax, dword [edi + 0x40]
inc ecx
test cl, al
jne 0x40af6b
shr eax, 3
xor edx, edx
mov dl, al
and al, cl
and edx, ecx
shl edx, 1
or edx, ecx
neg al
push edx
sbb eax, eax
and eax, 7
push eax
mov eax, edi
call fcn.0040b4a2
lea ecx, [edi + 0x60]
call fcn.0040c2da
add eax, 0x18
jmp 0x40afb2
shr eax, 6
test cl, al
je 0x40afd4
lea esi, [ebp - 8]
mov ecx, edi
call fcn.0040c1f6
mov eax, dword [eax]
push dword [eax - 0xc]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00401cb8
mov eax, dword [ebp - 8]
add eax, 0xfffffff0
call fcn.0040175b
lea eax, [ebp - 4]
call fcn.0040c50c
push 6
mov eax, edi
call fcn.0040b4e6
lea ecx, [edi + 0x84]
call fcn.0040c2fb
lea ebx, [ebp - 8]
call fcn.0040c6d2
mov eax, dword [eax]
push dword [eax - 0xc]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00401cb8
mov eax, dword [ebp - 8]
add eax, 0xfffffff0
call fcn.0040175b
lea eax, [ebp - 4]
push eax
call fcn.0040c84e
mov esi, dword [ebp - 4]
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
lea eax, [esi - 0x10]
call fcn.0040175b
pop esi
xor eax, eax
pop ebx
leave
ret
Function at 0x40b860
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [edi + 0x40]
test al, 1
je 0x40b878
shr eax, 6
test al, 1
je 0x40b940
mov eax, dword [edi + 0x64]
and dword [ebp - 8], 0
test eax, eax
mov dword [ebp - 0x10], eax
jle 0x40b940
push ebx
push esi
mov eax, dword [ebp - 8]
lea ecx, [edi + 0x60]
call fcn.0040c2da
mov esi, eax
cmp byte [esi + 0x1c], 0
je 0x40b92f
mov eax, dword [esi]
cmp eax, 1
je 0x40b8bc
cmp eax, 3
je 0x40b8bc
cmp eax, 0x64
jb 0x40b8d4
cmp dword [edi + 0x78], 2
jne 0x40b8d4
jmp 0x40b92f
mov eax, dword [edi + 0x78]
cmp eax, 4
je 0x40b8d4
cmp eax, 2
je 0x40b92f
cmp eax, 1
je 0x40b92f
test byte [esi + 8], 1
jne 0x40b92f
lea ebx, [edi + 0x58]
mov eax, dword [ebx]
sub eax, 0x10
call fcn.00401773
add eax, 0x10
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x18]
push dword [eax - 0xc]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00401cb8
lea esi, [ebp - 4]
call fcn.00403840
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push ebx
mov eax, esi
lea ebx, [ebp - 0xc]
call fcn.0040c6d2
push eax
call fcn.0040caa5
mov eax, dword [ebp - 0xc]
pop ecx
pop ecx
add eax, 0xfffffff0
call fcn.0040175b
mov eax, dword [ebp - 4]
add eax, 0xfffffff0
call fcn.0040175b
inc dword [ebp - 8]
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 0x10]
jl 0x40b88c
pop esi
pop ebx
leave
ret
Function at 0x40b942
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push esi
push edi
mov edi, 0x400
push edi
mov esi, eax
call fcn.004222b8
pop ecx
xor ecx, ecx
cmp eax, ecx
mov dword [ebp - 0xc], eax
jne 0x40b970
push ecx
call fcn.004222bd
pop ecx
push 3
pop eax
jmp 0x40ba81
mov dword [ebp - 0x14], ecx
mov dword [ebp - 4], ecx
mov dword [ebp - 0x10], ecx
push ebx
mov eax, dword [ebp - 0x10]
add dword [ebp - 4], 0xa
add eax, edi
cmp eax, edi
mov dword [ebp - 0x10], eax
jle 0x40b98d
sub eax, dword [ebp - 4]
mov ecx, dword [esi + 0x6c]
push 2
push 0
neg eax
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
mov dword [ebp - 0x18], eax
je 0x40ba72
mov eax, dword [esi + 0x6c]
push 0
lea ecx, [ebp - 8]
push ecx
push edi
push dword [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40ba72
cmp dword [ebp - 8], edi
jne 0x40ba72
xor eax, eax
mov ecx, dword [ebp - 0xc]
xor edx, edx
add ecx, eax
mov bl, byte [ecx]
cmp bl, byte [edx + str.ADVINSTSFX]
jne 0x40b9e9
inc edx
inc ecx
cmp edx, 0xa
jl 0x40b9d8
cmp edx, 0xa
jne 0x40b9fc
mov ecx, dword [ebp - 0x18]
lea ebx, [eax + ecx - 0x40]
mov dword [ebp - 0x14], ebx
add eax, edx
jmp 0x40b9ff
mov ebx, dword [ebp - 0x14]
inc eax
cmp eax, 0x3f6
jb 0x40b9d1
test ebx, ebx
je 0x40b97a
mov eax, dword [esi + 0x6c]
push 0
push 0
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x40ba72
mov eax, dword [esi + 0x6c]
push 0
lea ecx, [ebp - 8]
push ecx
push 0x4c
lea ecx, [esi + 4]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40ba72
cmp dword [ebp - 8], 0
je 0x40ba72
xor eax, eax
movzx ecx, byte [esi + eax + 0x44]
movsx edx, byte [eax + str.ADVINSTSFX]
cmp ecx, edx
jne 0x40ba61
inc eax
cmp eax, 0xa
jl 0x40ba45
cmp dword [esi + 0x10], 0x64
je 0x40ba65
push 5
jmp 0x40ba74
sub ebx, dword [esi + 0x14]
mov dword [esi + 0x80], ebx
xor esi, esi
jmp 0x40ba75
push 2
pop esi
push dword [ebp - 0xc]
call fcn.004222bd
pop ecx
mov eax, esi
pop ebx
pop edi
pop esi
leave
ret