joyce8/EMBER2024-capa huggingface dataset:
Function at 0x402f7e
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 0x402fa9
mov ecx, dword [0x42f478]
push esi
add eax, ecx
push esi
push eax
mov dword [0x42143c], eax
push dword [0x40a01c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 4
call fcn.00403086
cmp eax, esi
jl 0x403080
lea eax, [ebp + 8]
push 4
push eax
push dword [0x40a01c]
call fcn.00405b70
test eax, eax
je 0x403070
push dword [ebp + 8]
add dword [0x42143c], 4
call fcn.00403086
mov ebx, eax
cmp ebx, esi
jl 0x40307e
cmp dword [ebp + 0x10], esi
jne 0x40304c
cmp dword [ebp + 8], esi
jle 0x40307e
mov esi, 0x41d438
cmp dword [ebp + 8], 0x4000
mov eax, dword [ebp + 8]
jl 0x40300e
mov eax, 0x4000
push eax
push esi
push dword [0x40a01c]
mov dword [ebp - 4], eax
call fcn.00405b70
test eax, eax
je 0x403070
push dword [ebp - 4]
push esi
push dword [ebp + 0xc]
call fcn.00405b9f
test eax, eax
je 0x403048
mov eax, dword [ebp - 4]
sub dword [ebp + 8], eax
add dword [0x42143c], eax
add ebx, eax
cmp dword [ebp + 8], 0
jg 0x402ffd
jmp 0x40307e
push 0xfffffffffffffffe
jmp 0x403072
mov eax, dword [ebp + 8]
cmp eax, dword [ebp + 0x14]
jl 0x403057
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 0x403075
push 0xfffffffffffffffd
pop eax
jmp 0x403080
mov ebx, dword [ebp - 4]
add dword [0x42143c], ebx
mov eax, ebx
pop esi
pop ebx
leave
ret 0x10
Function at 0x405564
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, 0x408374
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], 0x408364
mov dword [ebp - 0xc], 0xc
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x4055b5
xor eax, eax
jmp 0x4055dc
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0xb7
jne 0x4055dc
lea eax, [ebp - 0x20]
push eax
push 0x80000007
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityA]
test eax, eax
jne 0x4055b1
call esi
pop esi
leave
ret 4

Function at 0x405616
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
lea eax, [ebp - 0x10]
mov dword [0x42c098], 0x44
push eax
xor eax, eax
push 0x42c098
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 0x405655
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 4

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

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
push esi
call fcn.00405ad3
mov edi, eax
cmp edi, 0xffffffff
je 0x405720
test byte [esp + 0x10], 1
push esi
je 0x405702
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
jmp 0x405708
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
je 0x405711
xor eax, eax
inc eax
jmp 0x405722
test byte [esp + 0x10], 4
jne 0x405720
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
xor eax, eax
pop edi
pop esi
ret 8
Function at 0x405727
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.004059e5
test bl, 8
mov dword [ebp - 0xc], eax
je 0x405766
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
add dword [0x42f4a8], eax
jmp 0x4058f0
mov dword [ebp + 8], ebx
and dword [ebp + 8], 1
je 0x405780
test eax, eax
je 0x40589e
test bl, 2
je 0x40589e
mov esi, 0x42b898
push edi
push esi
call fcn.00405e85
cmp dword [ebp + 8], 0
je 0x40579f
push str..
push esi
call sub.KERNEL32.dll_lstrcatA
jmp 0x4057a5
push edi
call fcn.0040593e
cmp byte [edi], 0
jne 0x4057b3
cmp byte [0x42b898], 0x5c
jne 0x4057be
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 0x405894
lea eax, [ebp - 0x120]
push 0x3f
push eax
lea esi, [ebp - 0x120]
call fcn.00405922
cmp byte [eax], 0
je 0x405804
cmp byte [ebp - 0x1c], 0
je 0x405804
lea esi, [ebp - 0x1c]
cmp byte [esi], 0x2e
jne 0x40581a
mov al, byte [esi + 1]
test al, al
je 0x405873
cmp al, 0x2e
jne 0x40581a
cmp byte [esi + 2], 0
je 0x405873
push esi
push ebx
call fcn.00405e85
test byte [ebp - 0x14c], 0x10
je 0x40583f
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x405873
push dword [ebp + 0xc]
push edi
call fcn.00405727
jmp 0x405873
push dword [ebp - 4]
push edi
call fcn.004056df
test eax, eax
jne 0x40586b
cmp dword [ebp - 4], eax
je 0x405863
push edi
push 0xfffffffffffffff1
call fcn.0040509e
push 0
push edi
call fcn.00405d40
jmp 0x405873
inc dword [0x42f4a8]
jmp 0x405873
push edi
push 0xfffffffffffffff2
call fcn.0040509e
lea eax, [ebp - 0x14c]
push eax
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4057e2
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x40589e
and byte [ebx - 1], 0
xor esi, esi
cmp dword [ebp + 8], esi
je 0x4058f0
cmp dword [ebp - 0xc], esi
jne 0x4058b2
inc dword [0x42f4a8]
jmp 0x4058f0
push edi
call fcn.00406189
test eax, eax
je 0x4058f0
push edi
call fcn.004058f7
mov eax, dword [ebp - 4]
or al, 1
push eax
push edi
call fcn.004056df
test eax, eax
jne 0x4058e8
cmp dword [ebp - 4], esi
je 0x4058aa
push edi
push 0xfffffffffffffff1
call fcn.0040509e
push esi
push edi
call fcn.00405d40
jmp 0x4058f0
push edi
push 0xffffffffffffffe5
call fcn.0040509e
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x4059e5
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x42bc98
push esi
call fcn.00405e85
push esi
call fcn.00405990
mov edi, eax
test edi, edi
jne 0x405a06
xor eax, eax
jmp 0x405a58
push edi
call fcn.004060f0
test byte [0x42f438], 0x80
je 0x405a1f
mov al, byte [edi]
test al, al
je 0x405a02
cmp al, 0x5c
je 0x405a02
sub edi, esi
jmp 0x405a37
call fcn.00406189
test eax, eax
je 0x405a31
test byte [eax], 0x10
je 0x405a02
push esi
call fcn.0040593e
push esi
call sub.KERNEL32.dll_lstrlenA
cmp eax, edi
push esi
jg 0x405a23
call fcn.004058f7
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 0x405ad3
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 0x405af2
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 0x405af8
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 0x405b27
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 [0x40a3c4]
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 0x405b6c
test edi, edi
jne 0x405b32
and byte [esi], 0
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x405b66
Function at 0x405bce
Capabilities:
Get file size

Disassembly:
push ebx
push ebp
push esi
push edi
mov edi, 0x42c620
push 0x40a3e0
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov esi, dword [esp + 0x18]
mov ebp, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
test esi, esi
mov ebx, 0x400
je 0x405c1c
push 1
push 0
push esi
call fcn.00405af8
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
push edi
push esi
call ebp
test eax, eax
je 0x405d3b
cmp eax, ebx
jg 0x405d3b
mov esi, 0x42ca20
push ebx
push esi
push dword [esp + 0x1c]
call ebp
test eax, eax
je 0x405d3b
cmp eax, ebx
jg 0x405d3b
push esi
push edi
push str._s_s_r_n
push 0x42c220
call dword [sym.imp.USER32.dll_wsprintfA]
mov ebx, eax
mov eax, dword [0x42f430]
add esp, 0x10
push dword [eax + 0x128]
push esi
call fcn.00405ea7
push 4
push 0xc0000000
push esi
call fcn.00405af8
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x18], ebp
je 0x405d3b
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x405d34
push edi
push esi
push ebp
call fcn.00405b70
test eax, eax
je 0x405d34
push str._Rename__r_n
push esi
call fcn.00405a5d
test eax, eax
jne 0x405cd2
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
add edi, 0xa
jmp 0x405d07
add eax, 0xa
push 0x40a3c8
push eax
call fcn.00405a5d
mov ebp, eax
test ebp, ebp
je 0x405d03
lea ecx, [esi + edi]
lea eax, [ecx + ebx]
jmp 0x405cf4
mov dl, byte [ecx]
mov byte [eax], dl
dec eax
dec ecx
cmp ecx, ebp
ja 0x405cee
sub ebp, esi
inc ebp
mov eax, ebp
mov ebp, dword [esp + 0x18]
jmp 0x405d09
mov ebp, dword [esp + 0x18]
mov eax, edi
push ebx
add eax, esi
push 0x42c220
push eax
call fcn.00405ab3
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
add edi, ebx
push edi
push esi
push ebp
call fcn.00405b9f
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x405d40
Capabilities:
Move file

Disassembly:
push 5
push dword [esp + 0xc]
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
test eax, eax
jne 0x405d63
push dword [esp + 8]
push dword [esp + 8]
call fcn.00405bce
pop ecx
pop ecx
inc dword [0x42f4b0]
ret 8
Function at 0x405d6c
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
lea eax, [ebp + 0x18]
push esi
push eax
mov eax, dword [ebp + 0x18]
xor ebx, ebx
neg eax
sbb eax, eax
mov esi, dword [ebp + 0x14]
and eax, 0x100
or eax, 0x20019
mov byte [esi], bl
push eax
push ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x405ddd
lea eax, [ebp + 0xc]
mov dword [ebp + 0xc], 0x400
push eax
lea eax, [ebp + 0x14]
push esi
push eax
push ebx
push dword [ebp + 0x10]
push dword [ebp + 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x405dcc
cmp dword [ebp + 0x14], 1
je 0x405dce
cmp dword [ebp + 0x14], 2
je 0x405dce
mov byte [esi], bl
push dword [ebp + 0x18]
mov byte [esi + 0x3ff], bl
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebx
pop ebp
ret 0x14
Function at 0x4061b0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x120
push esi
mov esi, 0x104
lea eax, [ebp - 0x120]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp eax, esi
pop esi
jbe 0x4061d4
xor eax, eax
test eax, eax
je 0x4061e6
cmp byte [ebp + eax - 0x121], 0x5c
je 0x4061e6
xor ecx, ecx
jmp 0x4061e9
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx + 0x40a014]
lea eax, [ebp + eax - 0x120]
push ecx
push str._s_s.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x120]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
leave
ret 4

Function at 0x406293
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x42ce24], 0
push esi
jne 0x4062ca
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x4062a4
mov dword [ecx*4 + 0x42ce20], eax
inc ecx
cmp ecx, 0x100
jl 0x40629f
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x4062fb
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x42ce20]
xor eax, esi
inc ecx
dec edx
jne 0x4062dd
pop edi
not eax
pop esi
ret 0xc
Function at 0x4010a8
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push ecx
xor eax, eax
push eax
push eax
push eax
push eax
lea ecx, [ebp - 4]
push ecx
push eax
push eax
push 0x404780
mov dword [ebp - 4], 0x123
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
xor dword [ebp - 4], 0x3e80f31
push dword [ebp - 4]
push str._08x
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
leave
ret

Function at 0x4010e7
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push ecx
xor eax, eax
push eax
push eax
push eax
push eax
lea ecx, [ebp - 4]
push ecx
push eax
push eax
push 0x404780
mov dword [ebp - 4], 0x123
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
xor dword [ebp - 4], 0x603c235
push dword [ebp - 4]
push str._08x_a
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
leave
ret

Function at 0x401126
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x380
push ebx
push esi
push dword [ebp + 8]
xor esi, esi
push 0x310
push esi
push 4
push esi
push 0xffffffffffffffff
mov byte [ebp - 1], 0
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
push esi
push esi
push esi
push 0xf001f
push eax
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
cmp eax, esi
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 8], eax
je 0x4011ab
push edi
mov edx, 0xc4
mov esi, eax
mov ecx, edx
push 0x41
lea edi, [ebp - 0x380]
rep movsd dword es:[edi], dword [esi]
pop ecx
push dword [ebp - 8]
xor eax, eax
lea edi, [ebp - 0x278]
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 8]
mov ecx, edx
lea esi, [ebp - 0x380]
rep movsd dword es:[edi], dword [esi]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push dword [ebp - 0xc]
call ebx
mov byte [ebp - 1], 1
xor esi, esi
pop edi
lea eax, [ebp - 0x70]
push eax
call fcn.004010e7
pop ecx
lea eax, [ebp - 0x70]
push eax
push esi
push 1
push esi
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov esi, eax
push esi
call dword [sym.imp.KERNEL32.dll_SetEvent]
push esi
call ebx
mov al, byte [ebp - 1]
pop esi
pop ebx
leave
ret
Function at 0x401204
Capabilities:
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push edi
xor ebx, ebx
push ebx
push ebx
push 3
push ebx
push ebx
push 0x40000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, ebx
je 0x40129d
cmp edi, 0xffffffff
je 0x40129d
lea eax, [ebp - 8]
push eax
push edi
mov dword [ebp - 8], ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push ebx
push ebx
sub eax, 0x14
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x401292
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x401292
push esi
mov esi, dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
lea eax, [ebp - 4]
push eax
push 4
lea eax, [ebp + 0x10]
push eax
push edi
mov dword [ebp - 4], ebx
call esi
test eax, eax
je 0x401291
cmp dword [ebp - 4], 4
jne 0x401291
push ebx
lea eax, [ebp - 4]
push eax
push 0x10
push dword [ebp + 0xc]
push edi
call esi
test eax, eax
je 0x401291
cmp dword [ebp - 4], 0x10
jne 0x401291
mov bl, 1
pop esi
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, bl
jmp 0x40129f
xor al, al
pop edi
pop ebx
leave
ret

Function at 0x4012a3
Capabilities:
Encode data using xor
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
push esi
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
jne 0x4012be
xor al, al
jmp 0x40134d
push edi
push ebx
push ebx
push 3
push ebx
push 1
push 0x80000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, ebx
je 0x40134a
cmp edi, 0xffffffff
je 0x40134a
push 2
push ebx
push 0xffffffffffffffec
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebx
lea eax, [ebp - 4]
push eax
push 4
lea eax, [ebp - 8]
push eax
push edi
call esi
test eax, eax
je 0x40134a
cmp dword [ebp - 4], 4
jne 0x40134a
push ebx
lea eax, [ebp - 4]
push eax
push 0x10
push dword [ebp + 0xc]
push edi
call esi
test eax, eax
je 0x40134a
cmp dword [ebp - 4], 0x10
jne 0x40134a
mov eax, dword [ebp + 0x10]
cmp eax, ebx
mov ecx, dword [ebp - 8]
je 0x40132c
mov dword [eax], ecx
cmp byte [ebp + 0x14], bl
je 0x40133f
mov eax, dword [ebp + 0xc]
push 4
pop edx
xor dword [eax], ecx
add eax, 4
dec edx
jne 0x401337
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x40134c
xor al, al
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4017c1
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push ecx
xor eax, eax
push eax
push eax
push eax
push eax
lea ecx, [ebp - 4]
push ecx
push eax
push eax
push 0x404780
mov dword [ebp - 4], 0x123
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
push dword [ebp - 4]
push str._08x
push dword [ebp + 8]
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
leave
ret
Function at 0x4021ce
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x518
push esi
mov esi, dword [ebp + 0x10]
push edi
xor edi, edi
push edi
push 0x80
push 3
push edi
push 1
push 0x80000000
push dword [ebp + 8]
mov dword [ebp - 0x10], edi
mov dword [esi], edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
jne 0x40220b
xor eax, eax
jmp 0x40239a
push ebx
mov ebx, 0x404748
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
lea ecx, [ebp + 0x10]
push ecx
push eax
mov dword [esi], eax
lea eax, [ebp - 0x518]
push eax
push dword [ebp - 4]
call edi
test eax, eax
je 0x40238d
mov eax, dword [ebp + 0x10]
cmp dword [esi], eax
jne 0x40238d
mov byte [ebp + eax - 0x518], 0
lea eax, [ebp - 0x518]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x40238d
push eax
lea eax, [ebp + 0x10]
push eax
push 4
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 4]
call edi
test eax, eax
je 0x40238d
cmp dword [ebp + 0x10], 4
jne 0x40238d
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ecx, dword [ebp + 0xc]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [eax + ecx*8 + 4]
push 0
push eax
push dword [ebp - 4]
mov dword [esi], eax
call ebx
cmp eax, dword [esi]
jne 0x40238d
push 0
lea eax, [ebp + 0x10]
push eax
push 4
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 4]
call edi
test eax, eax
je 0x40238d
cmp dword [ebp + 0x10], 4
jne 0x40238d
push 0
lea eax, [ebp + 0x10]
push eax
push 4
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
call edi
test eax, eax
je 0x40238d
cmp dword [ebp + 0x10], 4
jne 0x40238d
xor eax, eax
cmp dword [ebp - 0xc], eax
jne 0x402303
cmp dword [ebp - 8], eax
je 0x40238d
push eax
push eax
push dword [ebp - 0xc]
push dword [ebp - 4]
call ebx
cmp eax, dword [ebp - 0xc]
jne 0x40238d
mov eax, dword [ebp - 8]
inc eax
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
push 0
lea eax, [ebp + 0x10]
push eax
push dword [ebp - 8]
mov dword [ebp - 0x10], ebx
push ebx
push dword [ebp - 4]
call edi
test eax, eax
je 0x402386
mov eax, dword [ebp - 8]
cmp eax, dword [ebp + 0x10]
jne 0x402386
mov byte [eax + ebx], 0
mov eax, dword [ebp - 8]
mov dword [esi], eax
lea eax, [ebp - 0x118]
push eax
xor esi, esi
call fcn.004017c1
xor edi, edi
cmp dword [ebp - 8], edi
pop ecx
jbe 0x40238d
mov cl, byte [ebp + esi - 0x118]
lea eax, [edi + ebx]
xor byte [eax], cl
lea eax, [ebp - 0x118]
push eax
inc esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp esi, eax
jne 0x40237e
xor esi, esi
inc edi
cmp edi, dword [ebp - 8]
jb 0x40235e
jmp 0x40238d
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
pop ebx
pop edi
pop esi
leave
ret
Function at 0x4024d5
Capabilities:
Copy file
Enumerate files on windows
Enumerate files recursively
Move file

Disassembly:
push ebp
lea ebp, [esp - 0x6c]
sub esp, 0x25c
and dword [ebp + 0x68], 0
push ebx
push esi
mov esi, dword [ebp + 0x74]
push edi
push 0x50
pop ecx
xor eax, eax
lea edi, [ebp - 0xec]
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.KERNEL32.dll_FindFirstFileA]
lea eax, [ebp - 0xec]
push eax
push esi
call edi
mov ebx, eax
cmp ebx, 0xffffffff
je 0x402558
test byte [ebp - 0xec], 0x10
je 0x402546
push 0x404988
lea eax, [ebp - 0xc0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x402546
push 0x404984
lea eax, [ebp - 0xc0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
je 0x402546
inc dword [ebp + 0x68]
lea eax, [ebp - 0xec]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x40250e
cmp byte [ebp + 0x7c], 0
jne 0x402676
cmp dword [ebp + 0x68], 0
je 0x402676
push dword [ebp + 0x68]
call fcn.00402132
test eax, eax
pop ecx
mov dword [ebp + 0x68], eax
jne 0x4025db
lea eax, [ebp + 0x54]
push eax
call fcn.0040241f
mov ebx, dword [ebp + 0x78]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
pop ecx
push ebx
lea eax, [ebp - 0x1f0]
push eax
call edi
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov byte [eax + esi - 3], 0
lea eax, [ebp + 0x54]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push esi
push ebx
call edi
lea eax, [ebp - 0x1f0]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
jne 0x4026d0
lea eax, [ebp - 0x1f0]
push eax
push ebx
call edi
xor al, al
jmp 0x4026d2
and dword [ebp + 0x7c], 0
lea eax, [ebp - 0xec]
push eax
push esi
call edi
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4025d4
test byte [ebp - 0xec], 0x10
je 0x402626
mov edi, dword [sym.imp.KERNEL32.dll_lstrcmpA]
push 0x404988
lea eax, [ebp - 0xc0]
push eax
call edi
test eax, eax
je 0x402626
push 0x404984
lea eax, [ebp - 0xc0]
push eax
call edi
test eax, eax
je 0x402626
inc dword [ebp + 0x7c]
mov eax, dword [ebp + 0x7c]
cmp eax, dword [ebp + 0x68]
je 0x402642
lea eax, [ebp - 0xec]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x4025f0
jmp 0x4025d4
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcatA]
mov byte [eax + esi - 3], 0
lea eax, [ebp - 0xc0]
push eax
push esi
call edi
push str..
push esi
call edi
push 0
push dword [ebp + 0x78]
push esi
call fcn.004024d5
add esp, 0xc
jmp 0x4026d2
lea eax, [ebp + 0x54]
push eax
call fcn.0040241f
mov ebx, dword [ebp + 0x78]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
pop ecx
push ebx
lea eax, [ebp - 0x1f0]
push eax
call edi
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov byte [eax + esi - 3], 0
lea eax, [ebp + 0x54]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push esi
push ebx
call edi
cmp byte [0x407c20], 0
je 0x4025b4
push 0
push ebx
lea eax, [ebp - 0x1f0]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
jmp 0x4025c2
mov al, 1
pop edi
pop esi
pop ebx
add ebp, 0x6c
leave
ret