joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40f140
Capabilities:
Get common file path

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x429ffb
push eax
mov al, byte [0x43708c]
mov dword fs:[0], esp
sub esp, 0x108
test al, al
jne 0x40f219
push esi
push edi
push 1
lea eax, [esp + 0x10]
push 0
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
lea ecx, [esp + 0xc]
push ecx
lea ecx, [esp + 0xc]
call fcn.004200a5
mov eax, dword [esp + 8]
lea edx, [esp + 0xc]
push 0x104
push edx
push eax
mov dword [esp + 0x124], 0
call dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
lea ecx, [esp + 0xc]
push ecx
lea ecx, [esp + 0xc]
call fcn.00420174
push 0x4343dc
lea ecx, [esp + 0xc]
call fcn.00420386
mov edi, dword [esp + 8]
or ecx, 0xffffffff
xor eax, eax
mov dword [esp + 0x118], 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, 0x43708c
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 8]
call fcn.00420037
pop edi
mov eax, 0x43708c
pop esi
mov ecx, dword [esp + 0x108]
mov dword fs:[0], ecx
add esp, 0x114
ret
mov ecx, dword [esp + 0x108]
mov eax, 0x43708c
mov dword fs:[0], ecx
add esp, 0x114
ret

Function at 0x40f240
Capabilities:
Get common file path

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x42a01b
push eax
mov al, byte [0x436f88]
mov dword fs:[0], esp
sub esp, 0x108
test al, al
jne 0x40f319
push esi
push edi
push 1
lea eax, [esp + 0x10]
push 2
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
lea ecx, [esp + 0xc]
push ecx
lea ecx, [esp + 0xc]
call fcn.004200a5
mov eax, dword [esp + 8]
lea edx, [esp + 0xc]
push 0x104
push edx
push eax
mov dword [esp + 0x124], 0
call dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
lea ecx, [esp + 0xc]
push ecx
lea ecx, [esp + 0xc]
call fcn.00420174
push 0x4343dc
lea ecx, [esp + 0xc]
call fcn.00420386
mov edi, dword [esp + 8]
or ecx, 0xffffffff
xor eax, eax
mov dword [esp + 0x118], 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, 0x436f88
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 8]
call fcn.00420037
pop edi
mov eax, 0x436f88
pop esi
mov ecx, dword [esp + 0x108]
mov dword fs:[0], ecx
add esp, 0x114
ret
mov ecx, dword [esp + 0x108]
mov eax, 0x436f88
mov dword fs:[0], ecx
add esp, 0x114
ret
Function at 0x40f3b0
Capabilities:
Shutdown system

Disassembly:
sub esp, 0x14
call fcn.0040f340
test al, al
je 0x40f410
lea eax, [esp]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
lea ecx, [esp + 8]
push ecx
push str.SeShutdownPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
mov eax, dword [esp]
push 0
push 0
lea edx, [esp + 0xc]
push 0
push edx
push 0
push eax
mov dword [esp + 0x1c], 1
mov dword [esp + 0x28], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x18]
push 0xffffffffffffffff
push ecx
call dword [sym.imp.USER32.dll_ExitWindowsEx]
add esp, 0x14
ret
Function at 0x40fc40
Capabilities:
Create directory

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x42a138
push eax
mov dword fs:[0], esp
sub esp, 8
push ebp
push esi
mov esi, dword [esp + 0x20]
push edi
mov edi, dword [sym.imp.SHLWAPI.dll_PathIsDirectoryA]
push esi
call edi
test eax, eax
jne 0x40fd22
push esi
lea ecx, [esp + 0x28]
call fcn.004200a5
mov eax, dword [0x43501c]
xor esi, esi
mov dword [esp + 0x1c], esi
mov dword [esp + 0xc], eax
mov ebp, dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov byte [esp + 0x1c], 1
push esi
push 0x4343dc
lea ecx, [esp + 0x2c]
call fcn.0041f30d
mov esi, eax
cmp esi, 0xffffffff
je 0x40fcf0
lea ecx, [esp + 0x10]
push esi
push ecx
lea ecx, [esp + 0x2c]
call fcn.0041f265
push eax
lea ecx, [esp + 0x10]
mov byte [esp + 0x20], 2
call fcn.00420124
lea ecx, [esp + 0x10]
mov byte [esp + 0x1c], 1
call fcn.00420037
mov edx, dword [esp + 0xc]
push edx
call edi
test eax, eax
jne 0x40fced
push eax
mov eax, dword [esp + 0x10]
push eax
call ebp
test eax, eax
je 0x40fd03
inc esi
jmp 0x40fc94
mov ecx, dword [esp + 0x24]
push ecx
call edi
test eax, eax
jne 0x40fd03
mov edx, dword [esp + 0x24]
push eax
push edx
call ebp
lea ecx, [esp + 0xc]
mov byte [esp + 0x1c], 0
call fcn.00420037
lea ecx, [esp + 0x24]
mov dword [esp + 0x1c], 0xffffffff
call fcn.00420037
mov ecx, dword [esp + 0x14]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x14
ret

Function at 0x40fda0
Capabilities:
Check if file exists

Disassembly:
mov al, byte [0x437190]
sub esp, 0x104
test al, al
jne 0x40fe11
mov eax, dword [str.a:cfinfo.sys]
mov ecx, dword [0x434f14]
mov edx, dword [0x434f18]
mov dword [esp], eax
mov ax, word [0x434f1c]
push ebx
push esi
push edi
mov dword [esp + 0x10], ecx
mov word [esp + 0x18], ax
mov ecx, 0x3d
xor eax, eax
lea edi, [esp + 0x1a]
mov dword [esp + 0x14], edx
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
mov bl, 0x64
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0xc]
mov byte [esp + 0xc], bl
push ecx
call esi
test eax, eax
jne 0x40fe07
inc bl
cmp bl, 0x7a
jle 0x40fdf1
mov al, bl
pop edi
pop esi
mov byte [0x437190], al
pop ebx
add esp, 0x104
ret
Function at 0x410760
Capabilities:
Get disk information

Disassembly:
push 0xffffffffffffffff
push 0x42a238
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov al, byte [esp + 0x18]
push ebx
push ebp
lea ecx, [esp + 0x20]
push esi
push ecx
mov byte [esp + 0x28], al
call fcn.00413c00
mov ebp, dword [esp + 0x24]
add esp, 4
mov bl, byte [ebp]
movsx esi, bl
sub esi, 0x41
call dword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov ecx, esi
shr eax, cl
test eax, eax
mov dword [esp + 0xc], eax
je 0x410810
mov esi, dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
test al, 1
je 0x410806
cmp bl, byte [esp + 0x24]
je 0x410806
mov edx, dword [0x43501c]
mov dword [esp + 0x20], edx
movsx eax, bl
push eax
lea ecx, [esp + 0x24]
push 0x434f8c
push ecx
mov dword [esp + 0x24], 0
call fcn.0041f640
mov edx, dword [esp + 0x2c]
add esp, 0xc
push edx
call esi
cmp eax, 3
je 0x410824
lea ecx, [esp + 0x20]
mov dword [esp + 0x18], 0xffffffff
call fcn.00420037
mov eax, dword [esp + 0xc]
inc bl
shr eax, 1
mov dword [esp + 0xc], eax
jne 0x4107b3
pop esi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 4]
mov dword fs:[0], ecx
add esp, 0x10
ret
lea ecx, [esp + 0x20]
mov byte [ebp], bl
mov dword [esp + 0x18], 0xffffffff
call fcn.00420037
mov ecx, dword [esp + 0x10]
pop esi
pop ebp
mov al, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x10
ret

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

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4139ca
test byte [esp + 8], 0x80
je 0x4139b9
and al, 0xfe
jmp 0x4139bb
or al, 1
push eax
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x4139db
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00414ba3
pop ecx
or eax, 0xffffffff
ret
xor eax, eax
ret
Function at 0x41b385
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x4360c8
cmp edx, dword [eax]
je 0x41b3a7
add eax, 8
inc ecx
cmp eax, 0x436158
jl 0x41b398
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x4360c8]
jne 0x41b4d5
mov eax, dword [0x439280]
cmp eax, 1
je 0x41b4af
test eax, eax
jne 0x41b3d8
cmp dword [0x435638], 1
je 0x41b4af
cmp edx, 0xfc
je 0x41b4d5
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x41b40f
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00418430
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.004172f0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x41b452
lea eax, [ebp - 0x1a4]
push eax
call fcn.004172f0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x42d348
push edi
call fcn.00412530
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00418430
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00418440
lea eax, [ebp - 0xa0]
push 0x42d328
push eax
call fcn.00418440
push dword [esi + 0x4360cc]
lea eax, [ebp - 0xa0]
push eax
call fcn.00418440
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.0041d24c
add esp, 0x2c
pop edi
jmp 0x41b4d5
lea eax, [ebp + 8]
lea esi, [esi + 0x4360cc]
push 0
push eax
push dword [esi]
call fcn.004172f0
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]
pop esi
leave
ret

Function at 0x424341
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x424383
call fcn.00427f29
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x424383
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x42437a
xor eax, eax
jmp 0x42438b
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.00424391
pop edi
pop esi
pop ebx
ret 4

Function at 0x428a0d
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x428a3b
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x428a59
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.00428973
jmp 0x428a59
mov eax, dword [esi + 0x14]
test eax, eax
je 0x428a59
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.00428973
test edi, edi
mov eax, edi
jne 0x428a43
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x40141e
Capabilities:
Delete registry key
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
sub esp, 0x214
lea eax, [esp]
push ebp
push esi
mov esi, dword [esp + 0x228]
push edi
mov edi, dword [esp + 0x22c]
and esi, 0x300
push eax
mov eax, esi
and edi, 1
or eax, 9
push eax
push dword [esp + 0x230]
push dword [esp + 0x230]
call fcn.00406183
test eax, eax
jne 0x401527
xor ebp, ebp
test byte [esp + 0x22c], 2
je 0x401493
push ebp
push ebp
push ebp
push ebp
lea eax, [esp + 0x20]
mov dword [esp + 0x20], ebp
push eax
lea eax, [esp + 0x28]
push eax
push ebp
push dword [esp + 0x28]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
cmp eax, 0x103
jne 0x401503
push 0x105
lea eax, [esp + 0x18]
push eax
push ebp
mov ebp, dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
jmp 0x4014ce
test edi, edi
jne 0x401503
push dword [esp + 0x22c]
lea eax, [esp + 0x18]
push eax
push dword [esp + 0x14]
call fcn.0040141e
test eax, eax
jne 0x4014d8
push 0x105
lea eax, [esp + 0x18]
push eax
push edi
push dword [esp + 0x18]
call ebp
test eax, eax
je 0x4014a6
push dword [esp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 3
call fcn.00406791
test eax, eax
jne 0x401514
push dword [esp + 0x228]
push dword [esp + 0x228]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
jmp 0x401527
push dword [esp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 0x3eb
jmp 0x401527
push 0
push esi
push dword [esp + 0x230]
push dword [esp + 0x230]
call eax
pop edi
pop esi
pop ebp
add esp, 0x214
ret 0xc
Function at 0x403194
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0x9c
mov ecx, dword [esp + 0xa0]
mov eax, 0x4189e8
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0xb8]
mov ebx, 0x8000
test edi, edi
cmovne ebx, dword [esp + 0xbc]
xor esi, esi
test edi, edi
cmovne eax, edi
mov dword [esp + 0x1c], eax
test ecx, ecx
js 0x4031dc
mov eax, dword [0x429578]
add eax, ecx
push eax
call fcn.0040317d
push 4
lea eax, [esp + 0x14]
push eax
push dword [0x40a010]
call fcn.004067f3
test eax, eax
je 0x4033a0
mov eax, dword [esp + 0x10]
test eax, eax
jns 0x403342
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x40c960
mov dword [esp + 0x14], eax
call fcn.00407b1f
mov eax, dword [esp + 0x10]
and eax, 0x7fffffff
mov ecx, eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x10], ecx
jbe 0x40333a
mov ebp, 0x4000
cmp ecx, ebp
cmovl ebp, ecx
push ebp
push 0x4149e8
call fcn.00403167
test eax, eax
je 0x4033a0
sub dword [esp + 0x10], ebp
mov dword [0x40c97c], ebp
mov ebp, dword [esp + 0x1c]
mov dword [0x40c978], 0x4149e8
mov ecx, 0x40c960
mov dword [0x40c980], ebp
mov dword [0x40c984], ebx
call fcn.00406d53
mov dword [esp + 0x28], eax
test eax, eax
js 0x40333e
mov eax, dword [0x40c980]
sub eax, ebp
mov dword [esp + 0x18], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
test byte [0x429614], 1
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x24], eax
je 0x4032f3
sub eax, dword [esp + 0x14]
cmp eax, 0xc8
ja 0x4032b7
test ecx, ecx
jne 0x4032f3
mov eax, dword [esp + 0x20]
push eax
push 0x64
sub eax, ecx
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
push eax
lea eax, [esp + 0x30]
push str....__d__
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [esp + 0x2c]
push eax
push 0
call fcn.00405bf4
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x18]
test eax, eax
je 0x403332
test edi, edi
jne 0x403317
push eax
push ebp
push dword [esp + 0xbc]
call fcn.004068b6
test eax, eax
je 0x403385
mov eax, dword [esp + 0x18]
jmp 0x403323
mov ebp, dword [0x40c980]
sub ebx, eax
mov dword [esp + 0x1c], ebp
add esi, eax
cmp dword [esp + 0x28], 1
jne 0x403264
jmp 0x40333a
test ecx, ecx
jg 0x40322f
mov eax, esi
jmp 0x4033a3
push 0xfffffffffffffffc
jmp 0x4033a2
test edi, edi
jne 0x403389
test eax, eax
jle 0x40333a
mov ebp, 0x4149e8
cmp eax, ebx
mov edi, ebx
cmovl edi, eax
push edi
push ebp
call fcn.00403167
test eax, eax
je 0x4033a0
push edi
push ebp
push dword [esp + 0xbc]
call fcn.004068b6
test eax, eax
je 0x403385
mov eax, dword [esp + 0x10]
add esi, edi
sub eax, edi
mov dword [esp + 0x10], eax
test eax, eax
jg 0x40334f
jmp 0x40333a
push 0xfffffffffffffffe
jmp 0x4033a2
mov esi, dword [esp + 0xbc]
cmp eax, esi
cmovl esi, eax
push esi
push edi
call fcn.00403167
test eax, eax
jne 0x40333a
push 0xfffffffffffffffd
pop eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x9c
ret 0x10
Function at 0x4033b0
Capabilities:
Hide graphical window

Disassembly:
cmp dword [esp + 4], 0
je 0x4033cf
mov eax, dword [0x40c958]
test eax, eax
je 0x4033c7
push eax
call dword [sym.imp.USER32.dll_DestroyWindow]
and dword [0x40c958], 0
ret
cmp dword [0x40c958], 0
je 0x4033e0
push 0
call fcn.004060ba
ret
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp eax, dword [0x429520]
jbe 0x403413
push 0
push 0x403676
push 0
push 0x6f
push dword [0x428514]
call dword [sym.imp.USER32.dll_CreateDialogParamW]
push 5
push eax
mov dword [0x40c958], eax
call dword [sym.imp.USER32.dll_ShowWindow]
ret
Function at 0x405cd8
Capabilities:
Create directory

Disassembly:
push esi
xor esi, esi
push esi
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x405cf2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov eax, esi
pop esi
ret 4
Function at 0x406049
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
lea eax, [ebp - 0x23c]
push esi
mov esi, 0x104
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
ja 0x406083
test eax, eax
je 0x406083
add eax, eax
cmp word [ebp + eax - 0x23e], 0x5c
je 0x406085
mov ecx, 0x4082a8
jmp 0x40608a
xor eax, eax
mov ecx, 0x4082aa
push dword [ebp + 8]
push ecx
lea ecx, [ebp - 0x23c]
add eax, ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4

Function at 0x4060e8
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x40610b
push dword [esp + 8]
push dword [esp + 8]
call fcn.004061b1
pop ecx
pop ecx
inc dword [0x4295f0]
ret 8

Function at 0x4061b1
Capabilities:
Get file size

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x14]
mov ebx, 0x400
mov dword [0x426670], 0x55004e
mov ebp, 0x426670
mov dword [0x426674], 0x4c
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
test esi, esi
je 0x406207
push 1
push 0
push esi
call fcn.004067c6
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
push ebp
push esi
call edi
test eax, eax
je 0x4062e7
cmp eax, ebx
jg 0x4062e7
push ebx
mov esi, 0x425e70
push esi
push dword [esp + 0x1c]
call edi
test eax, eax
je 0x4062e7
cmp eax, ebx
jg 0x4062e7
push esi
push ebp
push str._ls_ls_r_n
push 0x425a70
call dword [sym.imp.USER32.dll_wsprintfA]
mov ecx, dword [0x429530]
add esp, 0x10
mov ebp, eax
push dword [ecx + 0x128]
push esi
call fcn.00405d53
push 4
push 0xc0000000
push esi
call fcn.004067c6
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4062e7
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
lea ecx, [ebp + 0xa]
add ecx, esi
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov edi, eax
test edi, edi
je 0x4062e0
push esi
push edi
push ebx
call fcn.004067f3
test eax, eax
je 0x4062e0
push str._Rename__r_n
push edi
call fcn.004069e1
test eax, eax
jne 0x4062ec
push str._Rename__r_n
lea eax, [edi + esi]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add esi, 0xa
mov ecx, esi
push ebp
push 0x425a70
lea eax, [ecx + edi]
push eax
call fcn.0040655f
xor eax, eax
push eax
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [esi + ebp]
push eax
push edi
push ebx
call fcn.004068b6
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret
push 0x408984
add eax, 0xa
push eax
call fcn.004069e1
mov ecx, eax
test ecx, ecx
je 0x4062b1
lea edx, [edi + esi]
jmp 0x40630b
mov al, byte [edx]
mov byte [edx + ebp], al
dec edx
cmp edx, ecx
ja 0x406305
sub ecx, edi
inc ecx
jmp 0x4062b3
Function at 0x406430
Capabilities:
Delete directory
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push edi
push dword [ebp + 8]
call fcn.00406a48
mov edi, eax
cmp edi, 0xffffffff
je 0x406473
test byte [ebp + 0xc], 1
push dword [ebp + 8]
je 0x406454
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x40645a
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x406463
xor eax, eax
inc eax
jmp 0x406475
test byte [ebp + 0xc], 4
jne 0x406473
push edi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
xor eax, eax
pop edi
pop ebp
ret 8

Function at 0x4064e3
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebx
push esi
push dword [esp + 0xc]
mov ebx, 0x425270
push ebx
call fcn.004069c5
push ebx
call fcn.00406a70
mov esi, eax
test esi, esi
je 0x406558
push esi
call fcn.00406be8
test byte [0x42952c], 0x80
je 0x40651c
movzx eax, word [esi]
test ax, ax
je 0x406558
cmp eax, 0x5c
je 0x406558
sub esi, ebx
sar esi, 1
jmp 0x406536
call fcn.0040647a
test eax, eax
je 0x406530
test byte [eax], 0x10
je 0x406558
push ebx
call fcn.00406bbb
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebx
cmp eax, esi
jg 0x406522
call fcn.00406401
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x406558
xor eax, eax
inc eax
jmp 0x40655a
xor eax, eax
pop esi
pop ebx
ret 4

Function at 0x406581
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov dword [0x424a28], 0x44
lea eax, [ebp - 0x10]
push eax
push 0x424a28
xor eax, eax
push eax
push eax
push 0x4000000
push eax
push eax
push eax
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x4065c0
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4
Function at 0x4065c4
Capabilities:
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
sub esp, 0x25c
push ebx
mov ebx, dword [esp + 0x268]
push esi
mov esi, dword [esp + 0x268]
push edi
mov edi, ebx
push esi
and edi, 4
call fcn.004064e3
mov dword [esp + 0x14], eax
test bl, 8
je 0x406606
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
inc eax
add dword [0x4295e8], eax
jmp 0x406785
push ebp
mov ebp, ebx
and ebp, 1
mov dword [esp + 0x14], ebp
je 0x406623
test eax, eax
je 0x406774
test bl, 2
je 0x40673d
push esi
push 0x424a70
call fcn.004069c5
test ebp, ebp
mov ebp, dword [sym.imp.KERNEL32.dll_lstrcatW]
je 0x406646
push str..
push 0x424a70
call ebp
jmp 0x40664c
push esi
call fcn.00406bbb
xor eax, eax
cmp word [esi], ax
jne 0x40665d
cmp word [0x424a70], 0x5c
jne 0x406665
push 0x4082a8
push esi
call ebp
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [esi + eax*2]
mov dword [esp + 0x10], eax
lea eax, [esp + 0x1c]
push eax
push 0x424a70
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x406726
push 0x2e
pop eax
cmp word [esp + 0x48], ax
jne 0x4066af
cmp word [esp + 0x4a], 0
je 0x406708
cmp word [esp + 0x4a], ax
jne 0x4066af
cmp word [esp + 0x4c], 0
je 0x406708
lea eax, [esp + 0x48]
push eax
push dword [esp + 0x14]
call fcn.004069c5
test byte [esp + 0x1c], 0x10
je 0x4066d6
mov eax, ebx
and eax, 3
cmp al, 3
jne 0x406708
push ebx
push esi
call fcn.004065c4
jmp 0x406708
push edi
push esi
call fcn.00406430
test eax, eax
jne 0x406700
test edi, edi
je 0x4066f8
push esi
push 0xfffffffffffffff1
call fcn.00405bf4
xor eax, eax
push eax
push esi
call fcn.004060e8
jmp 0x406708
inc dword [0x4295e8]
jmp 0x406708
push esi
push 0xfffffffffffffff2
call fcn.00405bf4
lea eax, [esp + 0x1c]
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
push 0x2e
test eax, eax
pop eax
jne 0x406691
push ebp
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [esp + 0x14], 0
je 0x406784
mov eax, dword [esp + 0x10]
xor ecx, ecx
mov word [eax - 2], cx
cmp dword [esp + 0x18], ecx
je 0x406774
push esi
call fcn.0040647a
test eax, eax
je 0x406784
push esi
call fcn.00406401
mov eax, edi
or eax, 1
push eax
push esi
call fcn.00406430
test eax, eax
jne 0x40677c
test edi, edi
je 0x406774
push esi
push 0xfffffffffffffff1
call fcn.00405bf4
xor eax, eax
push eax
push esi
call fcn.004060e8
jmp 0x406784
inc dword [0x4295e8]
jmp 0x406784
push esi
push 0xffffffffffffffe5
call fcn.00405bf4
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x25c
ret 8

Function at 0x4067c6
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor ecx, ecx
cmp eax, 0xffffffff
push 0
cmove eax, ecx
push eax
push dword [esp + 0x14]
push ecx
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
ret 0xc