joyce8/EMBER2024-capa huggingface dataset:
Function at 0x58e11c
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 4], ebx
je 0x58e162
call fcn.0057ee1a
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x58e162
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
mov dword [ebp - 4], eax
je 0x58e1a5
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ebx, eax
test ebx, ebx
mov esi, dword [ebp + 8]
mov dword [ebp + 0xc], 1
je 0x58e18e
push dword [ebp + 0x10]
mov eax, dword [edi]
push ebx
push esi
mov ecx, edi
call dword [eax + 0x20]
cmp dword [ebp - 4], 0
mov dword [ebp + 0xc], eax
je 0x58e18e
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeResource]
cmp dword [esi + 0x4c], 0
je 0x58e1a2
mov ecx, dword [esi + 0x4c]
push dword [ebp + 0x10]
mov eax, dword [ecx]
call dword [eax + 0xa0]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret 0xc

Function at 0x5ca5b0
Capabilities:
Allocate thread local storage

Disassembly:
push esi
push edi
push 0x10
push 1
xor edi, edi
call fcn.005d1962
mov esi, eax
add esp, 8
test esi, esi
jne 0x5ca5d2
mov ecx, dword [esp + 0xc]
lea eax, [edi + 0xc]
pop edi
mov dword [ecx], esi
pop esi
ret
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x5ca5fa
push esi
mov edi, 0xb
call fcn.005ce619
mov edx, dword [esp + 0x10]
add esp, 4
xor eax, eax
mov dword [edx], eax
mov eax, edi
pop edi
pop esi
ret
mov eax, dword [esp + 0x10]
test eax, eax
je 0x5ca617
mov dword [esi + 4], eax
mov eax, dword [esp + 0xc]
mov dword [esi + 8], 0xffffffff
mov dword [eax], esi
mov eax, edi
pop edi
pop esi
ret
mov ecx, dword [esp + 0xc]
mov eax, edi
pop edi
mov dword [ecx], esi
pop esi
ret
Function at 0x5ca8b0
Capabilities:
Get thread local storage value

Disassembly:
mov eax, dword [0x68b42c]
test eax, eax
push ebx
push ebp
push esi
push edi
mov edi, eax
je 0x5ca8f9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [edi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test edi, edi
je 0x5ca8f9
mov esi, dword [edi + 8]
mov ebp, dword [edi + 0xc]
pop edi
mov eax, esi
pop esi
mov edx, ebp
pop ebp
pop ebx
ret
call fcn.005ca670
mov esi, eax
test esi, esi
mov ebp, edx
je 0x5ca972
mov eax, 1
or dword [esi + 0x80], eax
mov dword [esi + 0x24], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov edi, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push 2
push 0
push 0
lea ebx, [esi + 4]
push ebx
mov dword [esi], eax
call edi
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call edi
push eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
jne 0x5ca956
push ebp
push esi
call fcn.005c9e20
add esp, 8
pop edi
pop esi
pop ebp
xor eax, eax
xor edx, edx
pop ebx
ret
mov ecx, dword [ebx]
push ecx
call dword [sym.imp.KERNEL32.dll_GetThreadPriority]
mov dword [esi + 0x2c], eax
mov edx, dword [0x68b42c]
push esi
push edx
call fcn.005cb3c0
add esp, 8
pop edi
mov eax, esi
pop esi
mov edx, ebp
pop ebp
pop ebx
ret
Function at 0x5cb3c0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
mov eax, dword [0x68b42c]
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x14]
cmp ebp, eax
push esi
push edi
je 0x5cb3f0
call fcn.005ca8b0
mov edi, eax
test edi, edi
mov dword [esp + 0x14], edx
jne 0x5cb43e
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
add esp, 8
ret
test eax, eax
mov esi, eax
je 0x5cb421
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test esi, esi
jne 0x5cb434
mov esi, dword [esp + 0x20]
test esi, esi
je 0x5cb3e3
mov ecx, dword [esi + 4]
mov edi, dword [esi]
mov dword [esp + 0x14], ecx
jmp 0x5cb442
mov edx, dword [esi + 0xc]
mov edi, dword [esi + 8]
mov dword [esp + 0x14], edx
mov esi, dword [esp + 0x20]
xor ebx, ebx
test ebp, ebp
je 0x5cb4c9
test edi, edi
je 0x5cb4b5
cmp dword [ebp + 4], ebx
je 0x5cb4b5
test esi, esi
je 0x5cb4b5
lea eax, [ebp + 8]
push eax
call fcn.005ca980
add esp, 4
test eax, eax
jne 0x5cb4a5
lea esi, [edi + 0x28]
push esi
call fcn.005ca980
mov eax, dword [edi + 0x84]
add esp, 4
test eax, eax
je 0x5cb48c
nop
cmp dword [eax + 4], ebp
je 0x5cb498
mov eax, dword [eax + 8]
test eax, eax
jne 0x5cb480
push ebp
push edi
call fcn.005c97b0
add esp, 8
mov ebx, eax
push esi
call fcn.005cad20
mov esi, dword [esp + 0x24]
add esp, 4
lea eax, [ebp + 8]
push eax
call fcn.005cad20
add esp, 4
test ebx, ebx
jne 0x5cb4c9
mov eax, dword [ebp]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
jne 0x5cb4c9
mov ebx, 0xb
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 8
ret
Function at 0x5cb4e0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
sub esp, 8
push edi
mov edi, dword [esp + 0x10]
test edi, edi
je 0x5cb661
push ebx
push ebp
push esi
mov dword [esp + 0x10], 0
lea ebx, [edi + 0x28]
mov edi, edi
add dword [esp + 0x10], 1
push ebx
mov dword [esp + 0x18], 0
call fcn.005ca980
mov eax, dword [edi + 0x84]
push ebx
mov dword [edi + 0x88], eax
call fcn.005cad20
push ebx
call fcn.005ca980
mov esi, dword [edi + 0x88]
add esp, 0xc
test esi, esi
je 0x5cb64a
lea esp, [esp]
mov ecx, dword [esi + 4]
add ecx, 8
push ecx
call fcn.005cada0
add esp, 4
cmp eax, 0x10
jne 0x5cb56a
push ebx
call fcn.005cad20
add esp, 4
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x5cb630
mov edx, dword [esi + 8]
mov dword [edi + 0x88], edx
mov edi, dword [esi + 4]
mov eax, dword [edi]
mov ebp, dword [edi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, dword [edi]
push 0
push ecx
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
test ebx, ebx
je 0x5cb5ba
cmp dword [esp + 0x10], 4
jg 0x5cb5ba
mov eax, dword [esp + 0x1c]
add eax, 0x28
push eax
call fcn.005cad20
add edi, 8
push edi
call fcn.005cad20
add dword [esp + 0x1c], 1
push ebx
call ebp
jmp 0x5cb629
mov ecx, dword [esi + 0x10]
test ecx, ecx
mov eax, dword [esi + 8]
je 0x5cb5c7
mov dword [ecx + 8], eax
test eax, eax
je 0x5cb5ce
mov dword [eax + 0x10], ecx
mov ecx, dword [esi]
cmp dword [ecx + 0x84], esi
jne 0x5cb5de
mov dword [ecx + 0x84], eax
mov ecx, dword [esi]
cmp dword [ecx + 0x88], esi
jne 0x5cb5ee
mov dword [ecx + 0x88], eax
mov eax, dword [esi + 0x14]
test eax, eax
mov ecx, dword [esi + 0xc]
je 0x5cb5fb
mov dword [eax + 0xc], ecx
test ecx, ecx
je 0x5cb602
mov dword [ecx + 0x14], eax
mov eax, dword [esi + 4]
cmp dword [eax + 0xc], esi
jne 0x5cb60d
mov dword [eax + 0xc], ecx
push esi
call fcn.005ce619
mov eax, dword [esp + 0x20]
add eax, 0x28
push eax
call fcn.005cad20
add edi, 8
push edi
call fcn.005cad20
mov edi, dword [esp + 0x28]
add esp, 0xc
lea ebx, [edi + 0x28]
push ebx
call fcn.005ca980
mov esi, dword [edi + 0x88]
add esp, 4
test esi, esi
jne 0x5cb540
push ebx
call fcn.005cad20
add esp, 4
cmp dword [esp + 0x14], 0
jne 0x5cb500
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret

Function at 0x5cb750
Capabilities:
Get thread local storage value

Disassembly:
push esi
mov esi, dword [0x68b430]
test esi, esi
jne 0x5cb75f
xor eax, eax
pop esi
ret
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test esi, esi
pop edi
pop ebx
je 0x5cb7b6
cmp dword [esp + 8], 0
je 0x5cb7a4
mov eax, dword [esi]
test eax, eax
je 0x5cb7a4
mov ecx, dword [esi + 4]
push ecx
call eax
add esp, 4
mov edx, dword [esi + 8]
mov eax, dword [0x68b430]
push edx
push eax
call fcn.005cb3c0
add esp, 8
mov eax, esi
pop esi
ret
Function at 0x5cb7c0
Capabilities:
Get thread local storage value

Disassembly:
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0xc]
push ebp
push esi
mov esi, dword [esp + 0xc]
mov dword [esi], eax
mov dword [esi + 4], ecx
mov eax, dword [0x68b430]
test eax, eax
mov ebp, eax
je 0x5cb80a
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov edx, dword [ebp]
push edx
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov ebp, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
pop edi
pop ebx
mov dword [esi + 8], ebp
mov eax, dword [0x68b430]
push esi
push eax
call fcn.005cb3c0
add esp, 8
pop esi
pop ebp
ret

Function at 0x5cc130
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push edi
lea ebx, [ebx]
mov esi, dword [0x68b430]
test esi, esi
je 0x5cc19b
call ebp
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test esi, esi
je 0x5cc19b
cmp dword [esp + 0x14], 0
je 0x5cc187
mov eax, dword [esi]
test eax, eax
je 0x5cc187
mov ecx, dword [esi + 4]
push ecx
call eax
add esp, 4
mov edx, dword [esi + 8]
mov eax, dword [0x68b430]
push edx
push eax
call fcn.005cb3c0
add esp, 8
jmp 0x5cc140
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x5cc3e0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
cmp dword [0x68b428], 0
je 0x5cc48f
push esi
mov esi, dword [0x68b42c]
test esi, esi
je 0x5cc44d
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test esi, esi
pop edi
pop ebx
je 0x5cc44d
cmp dword [esi + 0x24], 1
jne 0x5cc44d
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 8]
push ecx
push edx
call fcn.005cc0c0
mov eax, dword [0x68b42c]
mov ecx, dword [eax]
add esp, 8
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
call fcn.005cc000
mov eax, dword [0x68b420]
test eax, eax
mov esi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
je 0x5cc47c
push str.QueueUserAPCEx_Fini
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x5cc473
call eax
mov edx, dword [0x68b420]
push edx
call esi
mov eax, dword [0x68b424]
test eax, eax
je 0x5cc488
push eax
call esi
mov eax, 1
pop esi
ret
mov eax, 1
ret
Function at 0x5cc4a0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
cmp dword [0x68b428], 0
je 0x5cc53f
push esi
mov esi, dword [0x68b42c]
test esi, esi
je 0x5cc545
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
test esi, esi
je 0x5cc536
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 8]
push ecx
push edx
call fcn.005cb4e0
lea edi, [esi + 0x30]
push edi
call fcn.005ca980
push edi
mov dword [esi + 0x14], 6
call fcn.005cad20
add esp, 0x10
cmp dword [esi + 0x24], 1
jne 0x5cc536
mov eax, dword [esi + 0xc]
mov ecx, dword [esi + 8]
push eax
push ecx
call fcn.005cc0c0
mov edx, dword [0x68b42c]
mov eax, dword [edx]
add esp, 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
pop edi
pop ebx
mov eax, 1
pop esi
ret
mov eax, 1
ret
mov eax, 1
pop esi
ret

Function at 0x5cc720
Capabilities:
Allocate thread local storage

Disassembly:
cmp dword [0x68b428], 0
je 0x5cc72f
mov eax, 1
ret
push esi
push edi
push 0x10
push 1
mov dword [0x68b428], 1
xor edi, edi
call fcn.005d1962
mov esi, eax
add esp, 8
test esi, esi
jne 0x5cc754
lea edi, [eax + 0xc]
jmp 0x5cc771
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x5cc771
push esi
mov edi, 0xb
call fcn.005ce619
add esp, 4
xor esi, esi
test edi, edi
mov dword [0x68b42c], esi
jne 0x5cc78d
push edi
push 0x68b430
call fcn.005ca5b0
add esp, 8
test eax, eax
je 0x5cc792
call fcn.005cc000
mov esi, dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
push 0x693920
call esi
push 0x693960
call esi
push 0x6938e0
call esi
push 0x693940
call esi
push 0x693900
call esi
push 0x6938c0
call esi
mov eax, dword [0x68b428]
pop edi
pop esi
ret

Function at 0x5cc880
Capabilities:
Get thread local storage value
Terminate process

Disassembly:
push ebx
push esi
mov esi, dword [0x68b42c]
test esi, esi
push edi
je 0x5cc8b4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
call sub.WS2_32.dll_WSAGetLastError
mov ebx, eax
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push ebx
call sub.WS2_32.dll_WSASetLastError
mov ebx, dword [esp + 0x10]
cmp ebx, 2
je 0x5cc8c9
cmp ebx, 1
je 0x5cc8c9
push 1
call fcn.005ceecc
test esi, esi
je 0x5cc8d6
test byte [esi + 0x80], 1
je 0x5cc8fa
mov eax, ebx
xor edi, edi
sub eax, 1
je 0x5cc8e9
sub eax, 1
jne 0x5cc8ec
or edi, 0xffffffff
jmp 0x5cc8ec
mov edi, dword [esi + 0x18]
call fcn.005cc4a0
push edi
call fcn.005d99e0
add esp, 4
push 1
call fcn.005cc130
add esp, 4
push ebx
add esi, 0x40
push esi
call fcn.005d1090
int3
Function at 0x5ccce0
Capabilities:
Create thread
Resume thread

Disassembly:
sub esp, 0x10
mov eax, dword [esp + 0x14]
push ebx
push ebp
xor ebp, ebp
mov dword [eax + 4], ebp
mov eax, dword [esp + 0x20]
push esi
xor ebx, ebx
cmp eax, ebp
push edi
mov dword [esp + 0x10], 0xb
je 0x5ccd04
mov ebp, dword [eax]
call fcn.005ca670
mov esi, eax
test esi, esi
mov edi, edx
mov dword [esp + 0x1c], edi
je 0x5ccdd0
mov ecx, dword [esi + 0x2c]
push 0x10
mov dword [esp + 0x2c], ecx
call fcn.005ce76b
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x5ccdd0
test ebp, ebp
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x30]
mov dword [ebx], esi
mov dword [ebx + 4], edi
mov dword [ebx + 8], edx
mov dword [ebx + 0xc], eax
je 0x5ccd73
mov ecx, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov dword [esi + 0x24], ecx
cmp dword [ebp + 0x14], 0
mov edx, dword [ebp + 0x10]
mov dword [esp + 0x28], edx
jne 0x5ccd75
call fcn.005ca8b0
mov eax, dword [eax + 0x2c]
mov dword [esp + 0x14], edx
mov dword [esp + 0x28], eax
jmp 0x5ccd75
xor edi, edi
push esi
push 4
push ebx
xor eax, eax
push 0x5cc7d0
push edi
push eax
mov dword [esi + 0x14], eax
mov dword [esi + 0x84], eax
call fcn.005d9ada
mov edi, eax
add esp, 0x18
test edi, edi
mov dword [esi + 4], edi
je 0x5ccdbc
test ebp, ebp
je 0x5ccdb5
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x1c]
push ecx
push 0
push edx
push esi
call fcn.005cae90
add esp, 0x10
push edi
call dword [sym.imp.KERNEL32.dll_ResumeThread]
neg edi
sbb edi, edi
and edi, 0xfffffff5
add edi, 0xb
mov ebp, edi
je 0x5ccdf5
mov edi, dword [esp + 0x1c]
jmp 0x5ccdd4
mov ebp, dword [esp + 0x10]
push edi
push esi
call fcn.005cc0c0
add esp, 8
test ebx, ebx
je 0x5cce02
push ebx
call fcn.005ce619
add esp, 4
pop edi
pop esi
mov eax, ebp
pop ebp
pop ebx
add esp, 0x10
ret
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x1c]
mov dword [eax], esi
mov dword [eax + 4], ecx
pop edi
pop esi
mov eax, ebp
pop ebp
pop ebx
add esp, 0x10
ret

Function at 0x5ce60a
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x67f864]
jne 0x5ce614
repz ret
jmp fcn.005dbe5c

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

Disassembly:
push esi
xor esi, esi
cmp dword [esp + 8], esi
jne 0x5d4952
call fcn.005cfbf3
mov dword [eax], esi
call fcn.005cfbe0
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.005d1ee2
add esp, 0x14
push 0x16
pop eax
pop esi
ret
test dword [esp + 0xc], 0xfffffff9
jne 0x5d492e
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x5d4981
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.005cfc06
pop ecx
call fcn.005cfbe0
mov eax, dword [eax]
pop esi
ret
test al, 0x10
jne 0x5d49a8
test al, 1
je 0x5d49a8
test byte [esp + 0xc], 2
je 0x5d49a8
call fcn.005cfbf3
mov dword [eax], 5
call fcn.005cfbe0
mov dword [eax], 0xd
jmp 0x5d4978
xor eax, eax
pop esi
ret
Function at 0x5d5406
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov ecx, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
xor edi, edi
cmp dword [ebp + 0x10], edi
mov dword [ebp - 8], ecx
mov dword [ebp - 4], ebx
je 0x5d5443
cmp dword [ebp + 0x14], edi
je 0x5d5443
cmp ecx, edi
jne 0x5d544a
call fcn.005cfbe0
push edi
push edi
push edi
push edi
mov dword [eax], 0x16
push edi
call fcn.005d1ee2
add esp, 0x14
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
mov esi, dword [ebp + 0x18]
cmp esi, edi
je 0x5d545e
or eax, 0xffffffff
xor edx, edx
div dword [ebp + 0x10]
cmp dword [ebp + 0x14], eax
jbe 0x5d547f
cmp ebx, 0xffffffff
je 0x5d546e
push ebx
push edi
push ecx
call fcn.005d5de0
add esp, 0xc
cmp esi, edi
je 0x5d542b
or eax, 0xffffffff
xor edx, edx
div dword [ebp + 0x10]
cmp dword [ebp + 0x14], eax
ja 0x5d542b
mov edi, dword [ebp + 0x10]
imul edi, dword [ebp + 0x14]
test word [esi + 0xc], 0x10c
mov dword [ebp - 0x10], edi
mov ebx, edi
je 0x5d549b
mov eax, dword [esi + 0x18]
mov dword [ebp - 0xc], eax
jmp 0x5d54a2
mov dword [ebp - 0xc], 0x1000
test edi, edi
je 0x5d5593
test word [esi + 0xc], 0x10c
je 0x5d54f6
mov eax, dword [esi + 4]
test eax, eax
je 0x5d54f6
jl 0x5d55f4
cmp ebx, eax
mov edi, ebx
jb 0x5d54c7
mov edi, eax
cmp edi, dword [ebp - 4]
ja 0x5d559b
push edi
push dword [esi]
push dword [ebp - 4]
push dword [ebp - 8]
call fcn.005d06b2
sub dword [esi + 4], edi
add dword [esi], edi
add dword [ebp - 8], edi
sub ebx, edi
add esp, 0x10
sub dword [ebp - 4], edi
mov edi, dword [ebp - 0x10]
jmp 0x5d558b
cmp ebx, dword [ebp - 0xc]
jb 0x5d5563
cmp dword [ebp - 0xc], 0
je 0x5d5520
mov ecx, SysReAllocString
xor edx, edx
cmp ebx, ecx
jbe 0x5d5515
mov eax, ecx
div dword [ebp - 0xc]
mov eax, ecx
jmp 0x5d551c
mov eax, ebx
div dword [ebp - 0xc]
mov eax, ebx
sub eax, edx
jmp 0x5d552b
mov eax, SysReAllocString
cmp ebx, eax
ja 0x5d552b
mov eax, ebx
cmp eax, dword [ebp - 4]
ja 0x5d55c7
push eax
push dword [ebp - 8]
push esi
call fcn.005d3d20
pop ecx
push eax
call fcn.005eb064
add esp, 0xc
test eax, eax
je 0x5d5606
cmp eax, 0xffffffff
je 0x5d55f4
add dword [ebp - 8], eax
sub ebx, eax
sub dword [ebp - 4], eax
jmp 0x5d558b
push esi
call fcn.005ea983
cmp eax, 0xffffffff
pop ecx
je 0x5d55f8
cmp dword [ebp - 4], 0
je 0x5d55c7
mov ecx, dword [ebp - 8]
inc dword [ebp - 8]
mov byte [ecx], al
mov eax, dword [esi + 0x18]
dec ebx
dec dword [ebp - 4]
mov dword [ebp - 0xc], eax
test ebx, ebx
jne 0x5d54aa
mov eax, dword [ebp + 0x14]
jmp 0x5d5445
xor esi, esi
cmp dword [ebp + 0xc], 0xffffffff
je 0x5d55b2
push dword [ebp + 0xc]
push esi
push dword [ebp + 8]
call fcn.005d5de0
add esp, 0xc
call fcn.005cfbe0
push esi
push esi
push esi
push esi
mov dword [eax], 0x22
push esi
jmp 0x5d543b
cmp dword [ebp + 0xc], 0xffffffff
je 0x5d55dd
push dword [ebp + 0xc]
push 0
push dword [ebp + 8]
call fcn.005d5de0
add esp, 0xc
call fcn.005cfbe0
mov dword [eax], 0x22
xor eax, eax
push eax
push eax
push eax
push eax
push eax
jmp 0x5d543b
or dword [esi + 0xc], 0x20
mov eax, edi
sub eax, ebx
xor edx, edx
div dword [ebp + 0x10]
jmp 0x5d5445
or dword [esi + 0xc], 0x10
jmp 0x5d55f8
Function at 0x5daa86
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 + 0x67f888]
je 0x5daaa1
inc edi
cmp edi, 0x17
jb 0x5daa92
cmp edi, 0x17
jae 0x5dac21
push ebp
push 3
call fcn.005efd22
cmp eax, 1
pop ecx
je 0x5dabed
push 3
call fcn.005efd22
test eax, eax
pop ecx
jne 0x5daad5
cmp dword [0x67f3ac], 1
je 0x5dabed
cmp ebx, 0xfc
je 0x5dac20
push str.Runtime_Error__n_nProgram:
mov ebx, 0x314
push ebx
mov ebp, 0x68b4d8
push ebp
call fcn.005e12e8
add esp, 0xc
test eax, eax
je 0x5dab0b
push esi
push esi
push esi
push esi
push esi
call fcn.005d1dae
add esp, 0x14
push 0x104
mov esi, 0x68b4f1
push esi
push 0
mov byte [0x68b5f5], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x5dab4f
push str._program_name_unknown_
push 0x2fb
push esi
call fcn.005e12e8
add esp, 0xc
test eax, eax
je 0x5dab4f
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.005d1dae
add esp, 0x14
push esi
call fcn.005e1350
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x5dab94
push esi
call fcn.005e1350
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x68b7ec
push 0x62211c
sub ecx, eax
push ecx
push eax
call fcn.005e4b56
add esp, 0x14
test eax, eax
je 0x5dab94
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.005d1dae
add esp, 0x14
jmp 0x5dab96
xor esi, esi
push 0x622118
push ebx
push ebp
call fcn.005e4a9d
add esp, 0xc
test eax, eax
je 0x5dabb6
push esi
push esi
push esi
push esi
push esi
call fcn.005d1dae
add esp, 0x14
push dword [edi*8 + 0x67f88c]
push ebx
push ebp
call fcn.005e4a9d
add esp, 0xc
test eax, eax
je 0x5dabd8
push esi
push esi
push esi
push esi
push esi
call fcn.005d1dae
add esp, 0x14
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebp
call fcn.005efb65
add esp, 0xc
jmp 0x5dac20
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x5dac20
cmp ebp, 0xffffffff
je 0x5dac20
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x67f88c]
push dword [esi]
call fcn.005e1350
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