joyce8/EMBER2024-capa huggingface dataset:
Function at 0x746530
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x10]
push eax
push 0x40
push 0
mov ecx, dword [ebp + 8]
push ecx
call dword [ebp + 0xc]
add esp, 0x10
test eax, eax
jne 0x746553
mov eax, 1
jmp 0x74665e
mov edx, dword [ebp + 8]
movzx eax, word [edx]
cmp eax, 0x5a4d
jne 0x746569
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0x3c], 0
jne 0x746573
mov eax, 2
jmp 0x74665e
mov edx, dword [ebp + 0x10]
push edx
push 0xf8
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x3c]
push ecx
mov edx, dword [ebp + 8]
add edx, 0x40
push edx
call dword [ebp + 0xc]
add esp, 0x10
test eax, eax
jne 0x74659e
mov eax, 1
jmp 0x74665e
mov eax, dword [ebp + 8]
cmp dword [eax + 0x40], 0x4550
jne 0x7465c4
mov ecx, dword [ebp + 8]
movzx edx, word [ecx + 0x58]
cmp edx, 0x10b
jne 0x7465c4
mov eax, dword [ebp + 8]
movzx ecx, word [eax + 0x46]
test ecx, ecx
jne 0x7465ce
mov eax, 2
jmp 0x74665e
mov edx, dword [ebp + 8]
movzx eax, word [edx + 0x46]
imul eax, eax, 0x28
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x140], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x140]
push eax
call fcn.00758a10
add esp, 4
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x138], eax
mov edx, dword [ebp + 8]
cmp dword [edx + 0x138], 0
jne 0x74660f
mov eax, 3
jmp 0x74665e
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x3c]
mov edx, dword [ebp + 8]
movzx eax, word [edx + 0x54]
lea ecx, [ecx + eax + 0x18]
mov edx, dword [ebp + 8]
mov dword [edx + 0x13c], ecx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x140]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x13c]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x138]
push eax
call dword [ebp + 0xc]
add esp, 0x10
test eax, eax
jne 0x74665c
mov eax, 1
jmp 0x74665e
xor eax, eax
pop ebp
ret

Function at 0x747000
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
movzx ecx, word [eax]
cmp ecx, 0x5a4d
je 0x747016
xor eax, eax
jmp 0x747056
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 8]
add eax, dword [edx + 0x3c]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp dword [ecx], 0x4550
jne 0x74703b
mov edx, dword [ebp - 4]
movzx eax, word [edx + 0x18]
cmp eax, 0x10b
je 0x74703f
xor eax, eax
jmp 0x747056
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x78]
push ecx
call fcn.00747060
add esp, 0xc
mov esp, ebp
pop ebp
ret

Function at 0x759750
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
push ecx
mov dword [ebp - 4], 0
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov eax, dword [eax + 0x18]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
Function at 0x759780
Capabilities:
Parse pe header
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
cmp dword [ebp + 8], 0
jne 0x759793
xor eax, eax
jmp 0x759851
mov eax, dword [ebp + 8]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 0xc]
movzx edx, word [ecx]
cmp edx, 0x5a4d
je 0x7597ae
xor eax, eax
jmp 0x759851
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp + 8]
add ecx, dword [eax + 0x3c]
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp - 0x10]
cmp dword [edx], 0x4550
je 0x7597cc
xor eax, eax
jmp 0x759851
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp + 8]
add ecx, dword [eax + 0x78]
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 8]
mov eax, dword [ebp + 8]
add eax, dword [edx + 0x1c]
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp + 8]
add edx, dword [ecx + 0x24]
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 8]
add ecx, dword [eax + 0x20]
mov dword [ebp - 4], ecx
mov dword [ebp - 0x1c], 0
jmp 0x75980e
mov edx, dword [ebp - 0x1c]
add edx, 1
mov dword [ebp - 0x1c], edx
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x1c]
cmp ecx, dword [eax + 0x18]
jae 0x75984f
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 8]
add edx, dword [ecx + eax*4]
push edx
call fcn.00758a30
add esp, 8
test eax, eax
jne 0x75984d
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
movzx edx, word [ecx + eax*2]
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp + 8]
add ecx, dword [eax + edx*4]
mov eax, ecx
jmp 0x759851
jmp 0x759805
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x4017e0
Capabilities:
Create directory
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x15c
mov eax, dword [0x40b040]
xor eax, esp
mov dword [esp + 0x158], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor esi, esi
push esi
push 0x20
push 2
push esi
push 3
push 0x40000000
push str..ClinkApi.dll
mov dword [esp + 0x34], eax
mov dword [esp + 0x28], esi
mov dword [esp + 0x38], esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
mov dword [esp + 0x10], edi
jne 0x4018fa
push str..ClinkApi.dll
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov dword [esp + 0x14], eax
add eax, 2
push eax
call fcn.004019b8
add esp, 4
cmp dword [esp + 0x14], esi
mov ebx, eax
jle 0x4018cd
mov edi, ebx
sub edi, str..ClinkApi.dll
mov cl, byte [esi + str..ClinkApi.dll]
mov byte [edi + esi + str..ClinkApi.dll], cl
mov al, byte [esi + str..ClinkApi.dll]
cmp al, 0x2f
je 0x40187b
cmp al, 0x5c
jne 0x4018be
lea edx, [esp + 0x20]
push edx
push ebx
mov byte [edi + esi + str..ClinkApi.dll], 0
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
je 0x4018a4
test byte [esp + 0x20], 0x10
je 0x4018a4
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x4018b1
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov dword [esp + 0xc], eax
mov al, byte [esi + str..ClinkApi.dll]
mov byte [edi + esi + str..ClinkApi.dll], al
add esi, 1
cmp esi, dword [esp + 0x14]
jl 0x401860
mov edi, dword [esp + 0x10]
xor esi, esi
push ebx
call fcn.00401955
add esp, 4
cmp dword [esp + 0xc], esi
je 0x401940
push esi
push 0x20
push 2
push esi
push 3
push 0x40000000
push str..ClinkApi.dll
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [esp + 0x10], eax
mov edi, eax
cmp edi, esi
je 0x401927
mov edx, dword [ebp + 0xc]
mov eax, dword [esp + 0x18]
push esi
lea ecx, [esp + 0x20]
push ecx
push edx
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x401920
mov dword [esp + 0xc], 1
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x164]
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00401946
mov esp, ebp
pop ebp
ret
mov dword [esp + 0xc], esi
jmp 0x4018fe

Function at 0x401946
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x40b040]
jne 0x401950
repz ret
jmp fcn.00401c71
Function at 0x402501
Capabilities:
Write file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
xor esi, esi
xor edi, edi
cmp ebx, dword [edi*8 + 0x40b070]
je 0x40251c
inc edi
cmp edi, 0x17
jb 0x40250d
cmp edi, 0x17
jae 0x40269c
push ebp
push 3
call fcn.004051a9
cmp eax, 1
pop ecx
je 0x402668
push 3
call fcn.004051a9
test eax, eax
pop ecx
jne 0x402550
cmp dword [0x40b03c], 1
je 0x402668
cmp ebx, 0xfc
je 0x40269b
push str.Runtime_Error__n_nProgram:
mov ebx, 0x314
push ebx
mov ebp, 0x40c330
push ebp
call fcn.00404586
add esp, 0xc
test eax, eax
je 0x402586
push esi
push esi
push esi
push esi
push esi
call fcn.00404942
add esp, 0x14
push 0x104
mov esi, 0x40c349
push esi
push 0
mov byte [0x40c44d], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4025ca
push str._program_name_unknown_
push 0x2fb
push esi
call fcn.00404586
add esp, 0xc
test eax, eax
je 0x4025ca
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.00404942
add esp, 0x14
push esi
call fcn.004045f0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x40260f
push esi
call fcn.004045f0
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x40c644
push 0x40878c
sub ecx, eax
push ecx
push eax
call fcn.004050f6
add esp, 0x14
test eax, eax
je 0x40260f
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.00404942
add esp, 0x14
jmp 0x402611
xor esi, esi
push 0x408788
push ebx
push ebp
call fcn.00405085
add esp, 0xc
test eax, eax
je 0x402631
push esi
push esi
push esi
push esi
push esi
call fcn.00404942
add esp, 0x14
push dword [edi*8 + 0x40b074]
push ebx
push ebp
call fcn.00405085
add esp, 0xc
test eax, eax
je 0x402653
push esi
push esi
push esi
push esi
push esi
call fcn.00404942
add esp, 0x14
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.00404ec8
add esp, 0xc
jmp 0x40269b
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x40269b
cmp ebp, 0xffffffff
je 0x40269b
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x40b074]
push dword [esi]
call fcn.004045f0
pop ecx
push eax
push dword [esi]
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret
Function at 0x404ec8
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
call fcn.0040306d
xor ebx, ebx
cmp dword [0x40c8fc], ebx
mov dword [ebp - 8], eax
mov dword [ebp - 4], ebx
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
jne 0x404f9e
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40507e
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x4088b8
push edi
call esi
cmp eax, ebx
je 0x40507e
push eax
call fcn.00402fff
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x40c8fc], eax
call esi
push eax
call fcn.00402fff
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x40c900], eax
call esi
push eax
call fcn.00402fff
mov dword [0x40c904], eax
lea eax, [ebp - 0xc]
push eax
call fcn.0040228e
test eax, eax
pop ecx
pop ecx
je 0x404f6c
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.00404942
add esp, 0x14
cmp dword [ebp - 0xc], 2
jne 0x404f9e
push str.GetUserObjectInformationA
push edi
call esi
push eax
call fcn.00402fff
cmp eax, ebx
pop ecx
mov dword [0x40c90c], eax
je 0x404f9e
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.00402fff
pop ecx
mov dword [0x40c908], eax
mov eax, dword [0x40c908]
mov ecx, dword [ebp - 8]
cmp eax, ecx
je 0x405023
cmp dword [0x40c90c], ecx
je 0x405023
push eax
call fcn.00403076
push dword [0x40c90c]
mov esi, eax
call fcn.00403076
cmp esi, ebx
pop ecx
pop ecx
mov edi, eax
je 0x405023
cmp edi, ebx
je 0x405023
call esi
cmp eax, ebx
je 0x404ff0
lea ecx, [ebp - 0x14]
push ecx
push 0xc
lea ecx, [ebp - 0x20]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x404ff0
test byte [ebp - 0x18], 1
jne 0x405023
lea eax, [ebp - 0x10]
push eax
call fcn.004022c5
test eax, eax
pop ecx
je 0x40500b
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.00404942
add esp, 0x14
cmp dword [ebp - 0x10], 4
jb 0x40501a
or dword [ebp + 0x10], 0x200000
jmp 0x40505e
or dword [ebp + 0x10], 0x40000
jmp 0x40505e
mov eax, dword [0x40c900]
cmp eax, dword [ebp - 8]
je 0x40505e
push eax
call fcn.00403076
cmp eax, ebx
pop ecx
je 0x40505e
call eax
cmp eax, ebx
mov dword [ebp - 4], eax
je 0x40505e
mov eax, dword [0x40c904]
cmp eax, dword [ebp - 8]
je 0x40505e
push eax
call fcn.00403076
cmp eax, ebx
pop ecx
je 0x40505e
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x40c8fc]
call fcn.00403076
cmp eax, ebx
pop ecx
je 0x40507e
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x405080
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x503b67
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
mov ecx, ebp
push ebp
mov ebp, esp
mov dword [0x505076], ecx
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [0x505298], eax
mov dword [0x505220], 0x5032dd
mov dword [0x50521c], 2
jmp 0x503b97
mov dword [0x505224], 0
mov dword [0x505228], 0
mov dword [0x505218], 0x30
push 0
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
mov dword [0x50522c], eax
mov dword [0x505240], 0x504088
mov dword [0x505238], 0xf
mov dword [0x50506e], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadIconA]
mov dword [0x505230], eax
mov dword [0x505244], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorA]
mov dword [0x505234], eax
push 0x505218
call dword [sym.imp.user32.dll_RegisterClassExA]
push 0
push dword [0x50506e]
push 0
push 0
push 0x1e5
push 0x21e
push 0xffffe52a
push 0xfffff588
push 0x40000
push str.wait
push str.aroka
push 0
call dword [sym.imp.user32.dll_CreateWindowExA]
mov dword [0x505290], eax
push 5
push dword [0x505290]
call dword [sym.imp.user32.dll_ShowWindow]
push dword [0x505290]
call dword [sym.imp.user32.dll_UpdateWindow]
jmp 0x503c6a
push 0
push 0
push 0
push 0x505248
call dword [sym.imp.user32.dll_GetMessageA]
or eax, eax
je 0x503c97
push 0x505248
call dword [sym.imp.user32.dll_TranslateMessage]
push 0x505248
call dword [sym.imp.user32.dll_DispatchMessageA]
jmp 0x503c6a
mov eax, dword [0x505250]
jmp 0x503ca4
call 0x502b16
ret

Function at 0x433000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
call 0x43300c
nop
pop eax
nop
nop
nop
nop
nop
add eax, 0x40a063
nop
sub eax, 0x40a009
nop
nop
nop
nop
mov ebx, dword [eax]
mov ecx, dword [eax + 4]
nop
nop
nop
mov edx, dword [eax + 8]
nop
nop
nop
nop
nop
nop
nop
xor dword [ebx], edx
nop
nop
add ebx, 4
nop
cmp ebx, ecx
nop
nop
nop
nop
jl 0x433030
nop
nop
nop
nop
nop
nop
add eax, 0xc
nop
nop
cmp dword [eax], 0
nop
nop
nop
nop
nop
jne 0x43301e
nop
nop
nop
popal
nop
nop
nop
jmp 0x431219
Function at 0x403059
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
cmp eax, esi
jl 0x403084
mov ecx, dword [0x447798]
push esi
add eax, ecx
push esi
push eax
mov dword [0x4204dc], eax
push dword [0x40a01c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 4
call fcn.00403161
cmp eax, esi
jl 0x40315b
lea eax, [ebp + 8]
push 4
push eax
push dword [0x40a01c]
call fcn.00405ce5
test eax, eax
je 0x40314b
push dword [ebp + 8]
add dword [0x4204dc], 4
call fcn.00403161
mov ebx, eax
cmp ebx, esi
jl 0x403159
cmp dword [ebp + 0x10], esi
jne 0x403127
cmp dword [ebp + 8], esi
jle 0x403159
mov esi, 0x41c4d8
cmp dword [ebp + 8], 0x4000
mov eax, dword [ebp + 8]
jl 0x4030e9
mov eax, 0x4000
push eax
push esi
push dword [0x40a01c]
mov dword [ebp - 4], eax
call fcn.00405ce5
test eax, eax
je 0x40314b
push dword [ebp - 4]
push esi
push dword [ebp + 0xc]
call fcn.00405d14
test eax, eax
je 0x403123
mov eax, dword [ebp - 4]
sub dword [ebp + 8], eax
add dword [0x4204dc], eax
add ebx, eax
cmp dword [ebp + 8], 0
jg 0x4030d8
jmp 0x403159
push 0xfffffffffffffffe
jmp 0x40314d
mov eax, dword [ebp + 8]
cmp eax, dword [ebp + 0x14]
jl 0x403132
mov eax, dword [ebp + 0x14]
lea ecx, [ebp - 4]
push esi
push ecx
push eax
push dword [ebp + 0x10]
push dword [0x40a01c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x403150
push 0xfffffffffffffffd
pop eax
jmp 0x40315b
mov ebx, dword [ebp - 4]
add dword [0x4204dc], ebx
mov eax, ebx
pop esi
pop ebx
leave
ret 0x10
Function at 0x4056c1
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, 0x40837c
and byte [ebp - 0x1f], 0
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
and dword [ebp - 0x14], 0
and dword [ebp - 4], 0
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push esi
push eax
mov byte [ebp - 0x20], 1
push dword [ebp + 8]
mov word [ebp - 0x1e], 4
mov dword [ebp - 0x10], 0x40836c
mov dword [ebp - 0xc], 0xc
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x405712
xor eax, eax
jmp 0x405739
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0xb7
jne 0x405739
lea eax, [ebp - 0x20]
push eax
push 0x80000007
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityA]
test eax, eax
jne 0x40570e
call esi
pop esi
leave
ret 4

Function at 0x405773
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
mov dword [0x43e538], 0x44
push eax
xor eax, eax
push 0x43e538
push eax
push eax
push 0x4000000
push eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x4057b2
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

Function at 0x4057b6
Capabilities:
Create process on windows

Disassembly:
mov eax, dword [esp + 4]
push eax
and dword [eax + 0x24], 0
mov dword [eax], 0x3c
call dword [sym.imp.SHELL32.dll_ShellExecuteExA]
ret 4

Function at 0x405854
Capabilities:
Delete directory
Delete file
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.00405c48
mov edi, eax
cmp edi, 0xffffffff
je 0x405895
test byte [esp + 0x10], 1
push esi
je 0x405877
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
jmp 0x40587d
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
je 0x405886
xor eax, eax
inc eax
jmp 0x405897
test byte [esp + 0x10], 4
jne 0x405895
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
xor eax, eax
pop edi
pop esi
ret 8
Function at 0x40589c
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, ebx
and eax, 4
push edi
mov dword [ebp - 4], eax
call fcn.00405b5a
test bl, 8
mov dword [ebp - 0xc], eax
je 0x4058db
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
add dword [0x4477c8], eax
jmp 0x405a65
mov dword [ebp + 8], ebx
and dword [ebp + 8], 1
je 0x4058f5
test eax, eax
je 0x405a13
test bl, 2
je 0x405a13
mov esi, 0x43a538
push edi
push esi
call fcn.004060d4
cmp dword [ebp + 8], 0
je 0x405914
push str..
push esi
call sub.KERNEL32.dll_lstrcatA
jmp 0x40591a
push edi
call fcn.00405ab3
cmp byte [edi], 0
jne 0x405928
cmp byte [0x43a538], 0x5c
jne 0x405933
push 0x40a014
push edi
call sub.KERNEL32.dll_lstrcatA
push edi
call sub.KERNEL32.dll_lstrlenA
mov ebx, eax
lea eax, [ebp - 0x14c]
push eax
push esi
add ebx, edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [ebp - 8], eax
je 0x405a09
lea eax, [ebp - 0x120]
push 0x3f
push eax
lea esi, [ebp - 0x120]
call fcn.00405a97
cmp byte [eax], 0
je 0x405979
cmp byte [ebp - 0x1c], 0
je 0x405979
lea esi, [ebp - 0x1c]
cmp byte [esi], 0x2e
jne 0x40598f
mov al, byte [esi + 1]
test al, al
je 0x4059e8
cmp al, 0x2e
jne 0x40598f
cmp byte [esi + 2], 0
je 0x4059e8
push esi
push ebx
call fcn.004060d4
test byte [ebp - 0x14c], 0x10
je 0x4059b4
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x4059e8
push dword [ebp + 0xc]
push edi
call fcn.0040589c
jmp 0x4059e8
push dword [ebp - 4]
push edi
call fcn.00405854
test eax, eax
jne 0x4059e0
cmp dword [ebp - 4], eax
je 0x4059d8
push edi
push 0xfffffffffffffff1
call fcn.004051fb
push 0
push edi
call fcn.00405eb3
jmp 0x4059e8
inc dword [0x4477c8]
jmp 0x4059e8
push edi
push 0xfffffffffffffff2
call fcn.004051fb
lea eax, [ebp - 0x14c]
push eax
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405957
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405a13
and byte [ebx - 1], 0
xor esi, esi
cmp dword [ebp + 8], esi
je 0x405a65
cmp dword [ebp - 0xc], esi
jne 0x405a27
inc dword [0x4477c8]
jmp 0x405a65
push edi
call fcn.004063d7
test eax, eax
je 0x405a65
push edi
call fcn.00405a6c
mov eax, dword [ebp - 4]
or al, 1
push eax
push edi
call fcn.00405854
test eax, eax
jne 0x405a5d
cmp dword [ebp - 4], esi
je 0x405a1f
push edi
push 0xfffffffffffffff1
call fcn.004051fb
push esi
push edi
call fcn.00405eb3
jmp 0x405a65
push edi
push 0xffffffffffffffe5
call fcn.004051fb
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x405b5a
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x43c538
push esi
call fcn.004060d4
push esi
call fcn.00405b05
mov edi, eax
test edi, edi
jne 0x405b7b
xor eax, eax
jmp 0x405bcd
push edi
call fcn.0040633e
test byte [0x44773c], 0x80
je 0x405b94
mov al, byte [edi]
test al, al
je 0x405b77
cmp al, 0x5c
je 0x405b77
sub edi, esi
jmp 0x405bac
call fcn.004063d7
test eax, eax
je 0x405ba6
test byte [eax], 0x10
je 0x405b77
push esi
call fcn.00405ab3
push esi
call sub.KERNEL32.dll_lstrlenA
cmp eax, edi
push esi
jg 0x405b98
call fcn.00405a6c
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

Function at 0x405c48
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push esi
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov esi, eax
cmp esi, 0xffffffff
je 0x405c67
and al, 0xfe
push eax
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov eax, esi
pop esi
ret 4

Function at 0x405c6d
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
ret 0xc

Function at 0x405c9c
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
mov eax, dword [0x40a3cc]
dec edi
mov dword [ebp + 8], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp + 8]
push 0
push eax
push dword [ebp + 0xc]
add byte [ebp + 0xa], dl
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
jne 0x405ce1
test edi, edi
jne 0x405ca7
and byte [esi], 0
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x405cdb