joyce8/EMBER2024-capa huggingface dataset:
Function at 0x498bdb
Capabilities:
Get file attributes
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
mov eax, dword [0x6780cc]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, ecx
push edi
push 0x230
xor edi, edi
push edi
push esi
call fcn.005b9e00
push 0xffffffffffffffff
push dword [ebx + 0xc]
lea eax, [esi + 0x24]
push 0x104
push eax
call fcn.005cec7e
push eax
call fcn.00403730
mov eax, dword [ebx + 4]
add esp, 0x20
cmp eax, dword [0x60cf28]
je 0x498d39
lea ecx, [ebp - 0x48]
push ecx
lea ecx, [ebp - 0x40]
push ecx
lea ecx, [ebp - 0x38]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileTime]
test eax, eax
je 0x498d4d
lea eax, [ebp - 0x30]
push eax
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x498d4d
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x2c]
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], ecx
mov eax, dword [ebx + 0xc]
cmp dword [eax - 0xc], edi
je 0x498c97
mov ecx, dword [ebx + 0x10]
test ecx, ecx
je 0x498c8b
lea edx, [ebp - 0x28]
push edx
push edi
push eax
call fcn.00498979
neg eax
sbb eax, eax
and eax, dword [ebp - 0x28]
jmp 0x498c92
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x498c99
mov eax, edi
mov ecx, esi
mov dword [ecx + 0x20], eax
lea eax, [ebp - 0x38]
push eax
call fcn.00498e8c
test eax, eax
je 0x498cc0
push 0xffffffffffffffff
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x50]
call fcn.00498800
mov ecx, dword [eax]
mov eax, dword [eax + 4]
jmp 0x498cc4
mov ecx, edi
mov eax, edi
mov dword [esi], ecx
mov dword [esi + 4], eax
lea eax, [ebp - 0x40]
push eax
call fcn.00498e8c
test eax, eax
je 0x498ceb
push 0xffffffffffffffff
lea eax, [ebp - 0x40]
push eax
lea ecx, [ebp - 0x50]
call fcn.00498800
mov ecx, dword [eax]
mov eax, dword [eax + 4]
jmp 0x498cef
mov ecx, edi
mov eax, edi
mov dword [esi + 0x10], ecx
mov dword [esi + 0x14], eax
lea eax, [ebp - 0x48]
push eax
call fcn.00498e8c
test eax, eax
je 0x498d17
push 0xffffffffffffffff
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x50]
call fcn.00498800
mov edi, dword [eax]
mov ecx, dword [eax + 4]
jmp 0x498d19
mov ecx, edi
mov dword [esi + 8], edi
mov dword [esi + 0xc], ecx
mov eax, dword [esi]
or eax, dword [esi + 4]
jne 0x498d2b
mov dword [esi], edi
mov dword [esi + 4], ecx
mov eax, dword [esi + 0x10]
or eax, dword [esi + 0x14]
jne 0x498d39
mov dword [esi + 0x10], edi
mov dword [esi + 0x14], ecx
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005a5aba
leave
ret 4
xor eax, eax
jmp 0x498d3c
Function at 0x4a0410
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
mov ecx, dword [esi + 4]
call fcn.0046386b
push 0xfffffffffffffff0
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowLongW]
push dword [ebp + 0xc]
and eax, 3
mov ecx, esi
cmp al, 3
je 0x4a044c
call fcn.004a062d
mov dword [esi + 0xc], 1
jmp 0x4a0451
call fcn.004a062d
cmp dword [esi], 0
je 0x4a049c
push edi
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
mov esi, dword [ebp + 0x10]
mov edi, eax
mov ecx, esi
test edi, edi
jle 0x4a0477
push edi
call fcn.0045b94a
lea ecx, [edi + 1]
push ecx
jmp 0x4a0486
push 0xff
call fcn.00404840
push 0x100
push eax
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_GetWindowTextW]
push 0xffffffffffffffff
mov ecx, esi
call fcn.004587d8
pop edi
jmp 0x4a04c0
mov esi, dword [ebp + 0x10]
push dword [esi]
push 0xffffffffffffffff
push 0x14d
push dword [ebp - 4]
call dword [sym.imp.USER32.dll_SendMessageW]
cmp eax, 0xffffffff
jne 0x4a04c0
push dword [esi]
push dword [ebp - 4]
call fcn.0046980b
pop esi
leave
ret 0xc

Function at 0x4a0584
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
mov ecx, esi
push edi
push dword [ebp + 0xc]
call fcn.004a062d
cmp dword [esi], 0
mov edi, eax
mov dword [esi + 0xc], 1
je 0x4a05cc
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [ebp + 0x10]
push eax
call fcn.0045b94a
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextW]
mov ecx, dword [ebp + 0x10]
push 0xffffffffffffffff
call fcn.004587d8
jmp 0x4a05d7
mov eax, dword [ebp + 0x10]
push dword [eax]
push edi
call fcn.0046980b
pop edi
pop esi
pop ebp
ret 0xc
Function at 0x4a13ba
Capabilities:
Extract resource via kernel32 functions
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
push 0x4a1500
mov ecx, 0x6776cc
call fcn.00467d10
mov esi, eax
test esi, esi
je 0x4a14f5
xor eax, eax
cmp word [esi + 8], ax
jne 0x4a14bf
push str.comctl32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov ebx, eax
test ebx, ebx
je 0x4a147b
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
mov edi, dword [ebp + 0x10]
mov ecx, 0x3ff
and ax, cx
cmp ax, 0x11
jne 0x4a1441
push 0x6112a0
call fcn.004a1546
pop ecx
test eax, eax
je 0x4a1441
mov eax, edi
neg eax
push 0xfc11
sbb eax, eax
and eax, 0xe
add eax, 0x3ee
push eax
push 5
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceExW]
test eax, eax
jne 0x4a145c
neg edi
push 5
sbb edi, edi
and edi, 0xe
add edi, 0x3ee
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x4a147b
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
test eax, eax
je 0x4a1481
push ebx
push edi
push eax
call fcn.0047fa2a
add esp, 0xc
jmp 0x4a1481
mov ebx, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov eax, dword [edi]
push 2
mov eax, dword [eax - 0xc]
inc eax
push eax
call fcn.00465311
pop ecx
pop ecx
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ecx, eax
mov dword [esi + 4], ecx
test ecx, ecx
je 0x4a14fa
mov eax, dword [edi]
push eax
mov eax, dword [eax - 0xc]
inc eax
push eax
push ecx
call fcn.00468afe
mov ax, word [ebx]
add esp, 0xc
mov word [esi + 8], ax
xor eax, eax
jmp 0x4a14c2
mov ebx, dword [ebp + 0xc]
mov edi, dword [esi + 4]
test edi, edi
je 0x4a14d0
push edi
call fcn.005cffdd
pop ecx
mov ecx, dword [ebp + 8]
push eax
push edi
call fcn.00404920
movzx ecx, word [esi + 8]
mov edx, 0xffff
xor eax, eax
mov word [ebx], cx
pop edi
cmp cx, dx
pop esi
setne al
pop ebx
pop ebp
ret 0xc
call fcn.00462564
call fcn.0046257e
int3
Function at 0x4d8a91
Capabilities:
Get file system object information

Disassembly:
push 0x4cc
mov eax, 0x5f304b
call fcn.005a64e6
mov ebx, ecx
mov eax, dword [ebx + 0x14]
sub eax, 0x10
push eax
call fcn.00455f55
pop ecx
lea esi, [eax + 0x10]
mov dword [ebp - 0x4d0], esi
and dword [ebp - 4], 0
lea ecx, [ebp - 0x4d0]
push 0
push 0x647518
call fcn.004561b4
cmp eax, 0xffffffff
jne 0x4d8b6c
push 0
push 0x647ec4
lea ecx, [ebp - 0x4d0]
call fcn.004561b4
cmp eax, 0xffffffff
jne 0x4d8b6c
push 0
push 0x64f934
lea ecx, [ebp - 0x4d0]
call fcn.004561b4
cmp eax, 0xffffffff
jne 0x4d8b6c
mov eax, dword [ebx + 0x14]
sub eax, 0x10
push eax
call fcn.00455f55
add eax, 0x10
pop ecx
mov dword [ebp - 0x4d8], eax
xor edx, edx
mov byte [ebp - 4], 1
push edx
lea ecx, [ebp - 0x218]
push ecx
push 0x104
push edx
push eax
lea edi, [eax - 0x10]
push edx
mov dword [ebp - 0x4d4], edi
call dword [sym.imp.KERNEL32.dll_SearchPathW]
test eax, eax
jne 0x4d8b3b
mov eax, dword [ebx]
mov edi, dword [eax + 0x14]
mov ecx, edi
call dword [0x5feab8]
mov ecx, ebx
call edi
mov ecx, dword [ebp - 0x4d4]
mov edi, eax
call fcn.00403850
jmp 0x4d8ba5
lea eax, [ebp - 0x218]
push eax
call fcn.005cffdd
pop ecx
push eax
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x4d0]
call fcn.00404920
mov ecx, edi
mov byte [ebp - 4], 0
call fcn.00403850
mov esi, dword [ebp - 0x4d0]
push 0x105
push 0x2b4
lea eax, [ebp - 0x4cc]
push eax
push 0
push esi
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
test eax, eax
je 0x4d8b92
mov edi, dword [ebp - 0x4cc]
jmp 0x4d8ba5
mov eax, dword [ebx]
mov edi, dword [eax + 0x14]
mov ecx, edi
call dword [0x5feab8]
mov ecx, ebx
call edi
mov edi, eax
lea ecx, [esi - 0x10]
call fcn.00403850
mov eax, edi
call fcn.005a6495
ret
Function at 0x4da490
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
xor eax, eax
push ebx
push esi
mov esi, ecx
push edi
push 1
mov dword [esi + 0x34], eax
mov dword [esi + 0x38], eax
mov dword [esi + 0x3c], eax
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jns 0x4da4bd
or dword [esi + 0x3c], 1
or dword [esi + 0x38], 2
jmp 0x4da4d2
push 2
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jns 0x4da4d2
or dword [esi + 0x3c], 2
or dword [esi + 0x38], 1
call dword [sym.imp.KERNEL32.dll_GetTickCount64]
mov edi, dword [ebp + 8]
mov ebx, eax
mov dword [ebp - 4], edx
push dword [edi + 0x20]
call dword [sym.imp.USER32.dll_SetCapture]
push eax
call fcn.0045b8fc
jmp 0x4da5a3
call dword [sym.imp.USER32.dll_GetCapture]
push eax
call fcn.0045b8fc
cmp eax, edi
jne 0x4da5ad
push 1
push 0x209
push 0x200
push 0
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
jne 0x4da53f
push 1
push 0x109
push 0x100
push eax
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.USER32.dll_PeekMessageW]
test eax, eax
je 0x4da583
mov eax, dword [ebp - 0x1c]
cmp eax, 0x202
je 0x4da5ad
cmp eax, 0x205
je 0x4da5ad
cmp eax, 0x201
je 0x4da5ad
cmp eax, 0x204
je 0x4da5ad
cmp eax, 0x100
jne 0x4da56b
cmp dword [ebp - 0x18], 0x1b
je 0x4da5ad
push dword [ebp - 8]
lea eax, [esi + 0x24]
push dword [ebp - 0xc]
push eax
call dword [sym.imp.USER32.dll_PtInRect]
neg eax
sbb eax, eax
inc eax
mov dword [esi + 0x34], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount64]
sub eax, ebx
sbb edx, dword [ebp - 4]
test edx, edx
jb 0x4da5a3
ja 0x4da59c
cmp eax, dword [0x681bb0]
jbe 0x4da5a3
mov dword [esi + 0x34], 1
cmp dword [esi + 0x34], 0
je 0x4da4f4
call dword [sym.imp.USER32.dll_ReleaseCapture]
mov eax, dword [esi + 0x34]
pop edi
pop esi
pop ebx
leave
ret 4
Function at 0x4dec71
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov dword [ebp - 4], ecx
push edi
test esi, esi
jne 0x4dec8a
call fcn.004683c3
mov esi, dword [eax + 0xc]
push 0x618314
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
test edi, edi
je 0x4deccc
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x4deccc
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
test ebx, ebx
je 0x4deccc
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp - 4]
push eax
push ebx
call fcn.004decd5
jmp 0x4decce
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x524e70
Capabilities:
Get file system object information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c0
mov eax, dword [0x6780cc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x2bc], esi
test eax, eax
je 0x524eda
push 0x208
push 0x2b4
lea ecx, [ebp - 0x2b8]
push ecx
push 0
push dword [eax + 4]
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
mov ecx, esi
test eax, eax
je 0x524ebf
lea eax, [ebp - 0x2ac]
push eax
jmp 0x524ec4
push 0x6207d0
call fcn.004555f0
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.005a5aba
leave
ret 8
call fcn.00462564
int3

Function at 0x542412
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push eax
call fcn.005d18e1
pop ecx
test eax, eax
jne 0x542454
push dword [ebp - 4]
push dword [ebp + 0xc]
push dword [ebp + 8]
push str._s_s_X.tmp
push dword [ebp + 0x14]
push dword [ebp + 0x10]
call fcn.00426080
add esp, 0x18
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x54241a
leave
ret
push dword [ebp + 0x10]
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
leave
ret
Function at 0x5a6bf5
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x5a6c34
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x5a6c34
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x5a6c34
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x5a6c34
cmp dword [ecx + 0x74], 0xe
jbe 0x5a6c34
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x5cf084
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.005a6630
mov eax, dword [0x6780cc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.005d1ca8
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x5cf0c6
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x5cf222
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.005a67a0
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x682c28]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.005da485
mov ecx, dword [esi*4 + 0x682c28]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x5cf21b
cmp eax, dword [ecx + edi + 0x24]
jne 0x5cf21b
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x5cf21b
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.005da485
add esp, 0x14
test edx, edx
jl 0x5cf21b
jg 0x5cf191
test eax, eax
jb 0x5cf21b
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x5cf21b
jl 0x5cf1ab
cmp dword [ebp - 0x1008], eax
ja 0x5cf21b
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x5cf1c9
test ebx, ebx
je 0x5cf202
cmp ecx, edi
jae 0x5cf202
mov al, byte [ecx]
cmp al, 0xd
jne 0x5cf1e3
lea eax, [edi - 1]
cmp ecx, eax
jae 0x5cf1ef
cmp byte [ecx + 1], 0xa
jne 0x5cf1ef
inc ecx
jmp 0x5cf1ef
movzx eax, al
movsx eax, byte [eax + 0x678388]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x5cf1c9
cmp edx, ebx
jne 0x5cf1c9
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x5cf220
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.005a5aba
leave
ret
Function at 0x5d92ed
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x63b10c
push 0x63b104
push str.FlsAlloc
push 0x1f
call fcn.005d9118
mov esi, eax
add esp, 0x10
test esi, esi
je 0x5d9321
push dword [ebp + 8]
mov ecx, esi
call dword [0x5feab8]
call esi
jmp 0x5d9327
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x5d936b
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x63b11c
push 0x63b114
push str.FlsGetValue
push 0x21
call fcn.005d9118
mov esi, eax
add esp, 0x10
test esi, esi
je 0x5d93a2
push dword [ebp + 8]
mov ecx, esi
call dword [0x5feab8]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x5d93aa
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x63b124
push 0x63b11c
push str.FlsSetValue
push 0x22
call fcn.005d9118
mov esi, eax
add esp, 0x10
test esi, esi
je 0x5d93e4
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x5feab8]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x5d991d
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x682c28]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x5d995d
cmp byte [ebx], 0xa
jne 0x5d995d
or byte [edi + eax + 0x28], 4
jmp 0x5d9962
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x5d9a61
mov dl, byte [eax]
cmp dl, 0x1a
je 0x5d9a44
inc eax
cmp dl, 0xd
je 0x5d998e
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x5d99b4
cmp eax, ecx
jae 0x5d99c2
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x5d9976
jmp 0x5d9a61
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x5d9a3f
cmp dword [ebp - 0x10], 0
je 0x5d9a3f
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x682c28]
test byte [eax + edi + 0x28], 0x48
je 0x5d9a19
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x5d9a04
mov byte [esi], dl
jmp 0x5d9a15
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x682c28]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x5d9a61
cmp byte [ebp - 1], 0xa
jne 0x5d9a28
cmp esi, ebx
jne 0x5d9a28
mov byte [esi], 0xa
jmp 0x5d9a60
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.005da4a3
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x5d9a61
mov byte [esi], 0xd
jmp 0x5d9a60
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x682c28]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x5d9a5e
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x5d9a61
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x5d9a6a
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x682c28]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x5d9ab0
cmp word [ebx], dx
jne 0x5d9ab0
or byte [eax + edi + 0x28], 4
jmp 0x5d9ab5
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x5d9c18
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x5d9bf8
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x5d9af6
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x5d9b2c
cmp eax, edx
jae 0x5d9b3a
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x5d9ad1
jmp 0x5d9c18
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x5d9bf3
cmp dword [ebp - 0x18], 0
je 0x5d9bf3
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x682c28]
test byte [eax + edi + 0x28], 0x48
je 0x5d9bc9
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x5d9b8d
mov word [esi], cx
jmp 0x5d9bc4
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x682c28]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x682c28]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x682c28]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x5d9c18
pop eax
cmp word [ebp - 4], ax
jne 0x5d9bd9
cmp esi, ebx
jne 0x5d9bd9
mov word [esi], ax
jmp 0x5d9c15
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.005da4a3
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x5d9c18
push 0xd
pop eax
jmp 0x5d9bd4
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x682c28]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x5d9c12
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x5d9c18
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x5de864
Capabilities:
Enumerate files on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [0x6780cc]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0xc]
mov ecx, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x25c], ecx
cmp edx, edi
je 0x5de8af
movzx eax, word [edx]
lea ecx, [ebp - 0x255]
push eax
call fcn.005de9ff
test al, al
jne 0x5de8a9
sub edx, 2
cmp edx, edi
jne 0x5de88f
mov ecx, dword [ebp - 0x25c]
movzx esi, word [edx]
cmp esi, 0x3a
jne 0x5de8d1
lea eax, [edi + 2]
cmp edx, eax
je 0x5de8d1
push ecx
xor ebx, ebx
push ebx
push ebx
push edi
call fcn.005de7b0
add esp, 0x10
jmp 0x5de9cb
push esi
lea ecx, [ebp - 0x255]
call fcn.005de9ff
sub edx, edi
movzx eax, al
sar edx, 1
inc edx
neg eax
sbb eax, eax
xor ebx, ebx
push ebx
push ebx
and eax, edx
push ebx
mov dword [ebp - 0x260], eax
lea eax, [ebp - 0x254]
push eax
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileExW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x5de914
push dword [ebp - 0x25c]
jmp 0x5de8c1
mov ebx, dword [ebp - 0x25c]
push 0x2e
mov eax, dword [ebx + 4]
sub eax, dword [ebx]
sar eax, 2
mov dword [ebp - 0x25c], eax
pop eax
cmp word [ebp - 0x228], ax
jne 0x5de951
cmp word [ebp - 0x226], 0
je 0x5de972
cmp word [ebp - 0x226], ax
jne 0x5de951
cmp word [ebp - 0x224], 0
je 0x5de972
push ebx
push dword [ebp - 0x260]
lea eax, [ebp - 0x228]
push edi
push eax
call fcn.005de7b0
add esp, 0x10
mov dword [ebp - 0x264], eax
test eax, eax
jne 0x5de9be
lea eax, [ebp - 0x254]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
push 0x2e
test eax, eax
pop eax
jne 0x5de92b
mov eax, dword [ebx + 4]
mov edx, dword [ebx]
sub eax, edx
mov ecx, dword [ebp - 0x25c]
sar eax, 2
cmp ecx, eax
jne 0x5de9a6
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
xor eax, eax
jmp 0x5de9cb
push 0x5de5e0
sub eax, ecx
push 4
push eax
lea eax, [edx + ecx*4]
push eax
call fcn.005e5410
add esp, 0x10
jmp 0x5de99b
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [ebp - 0x264]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005a5aba
leave
ret

Function at 0x5df495
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x5df4a6
pop esi
ret
push ebx
push edi
push esi
call fcn.005df45e
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.005d674a
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x5df4ce
push ebx
push esi
push edi
call fcn.005b9060
add esp, 0xc
push 0
call fcn.005d60d8
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x5df89e
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.005df4e3