joyce8/EMBER2024-capa huggingface dataset:
Function at 0x48a5f8
Capabilities:
Access peb ldr_data
Check for peb beingdebugged flag

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
mov byte [ebp - 2], cl
mov byte [ebp - 1], dl
mov ebx, eax
mov eax, 0x40
call fcn.0040272c
mov dword [ebp - 8], eax
mov edx, 0x40
mov eax, dword [ebp - 8]
call fcn.00407594
xor eax, eax
push ebp
push 0x48a67d
push dword fs:[eax]
mov dword fs:[eax], esp
mov esi, dword [ebp - 8]
mov byte [esi + 0x30], bl
mov al, byte [ebp + 8]
mov byte [esi + 2], al
mov al, byte [ebp - 1]
mov byte [esi + 0xa], al
mov byte [esi + 0xb], 0
mov al, byte [ebp - 2]
mov byte [esi + 0xc], al
mov byte [esi + 0xd], 0
mov byte [esi], 0x32
mov eax, dword [ebp - 8]
push eax
call sub.netapi32.dll_Netbios
mov al, byte [esi + 0x31]
mov byte [ebp - 3], al
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x48a684
mov edx, 0x40
mov eax, dword [ebp - 8]
call fcn.0040274c
ret

Function at 0x48aef8
Capabilities:
Get hostname
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe28
push ebx
push esi
push edi
xor eax, eax
mov dword [ebp - 0x1d8], eax
xor eax, eax
push ebp
push 0x48afa9
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x1d4]
push eax
push 0x101
call sub.wsock32.dll_WSAStartup
mov dl, 1
mov eax, dword [0x414470]
call fcn.00403884
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x44]
push 0x40
lea eax, [ebp - 0x44]
push eax
call sub.wsock32.dll_gethostname
lea eax, [ebp - 0x44]
push eax
call sub.wsock32.dll_gethostbyname
test eax, eax
je 0x48af90
mov esi, dword [eax + 0xc]
xor ebx, ebx
jmp 0x48af84
push dword [edi]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
lea eax, [ebp - 0x1d8]
call fcn.00404810
mov edx, dword [ebp - 0x1d8]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx + 0x38]
inc ebx
mov edi, dword [esi + ebx*4]
test edi, edi
jne 0x48af61
call sub.wsock32.dll_WSACleanup
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x48afb0
lea eax, [ebp - 0x1d8]
call fcn.00404620
ret
Function at 0x48b6a0
Capabilities:
Execute anti-debugging instructions

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffe8
push ebx
push esi
call sub.kernel32.dll_GetCurrentProcess
push eax
call sub.kernel32.dll_GetPriorityClass
mov ebx, eax
call sub.kernel32.dll_GetCurrentThread
push eax
call sub.kernel32.dll_GetThreadPriority
mov esi, eax
push pe_nt_image_headers32
call sub.kernel32.dll_GetCurrentProcess
push eax
call sub.kernel32.dll_SetPriorityClass
push 0xf
call sub.kernel32.dll_GetCurrentThread
push eax
call sub.kernel32.dll_SetThreadPriority
push 0xa
call sub.kernel32.dll_Sleep_1
rdtsc
mov dword [ebp - 4], eax
mov dword [ebp - 8], edx
push 0x1f4
call sub.kernel32.dll_Sleep_1
rdtsc
sub eax, dword [ebp - 4]
sbb edx, dword [ebp - 8]
mov dword [ebp - 4], eax
mov dword [ebp - 8], edx
push esi
call sub.kernel32.dll_GetCurrentThread
push eax
call sub.kernel32.dll_SetThreadPriority
push ebx
call sub.kernel32.dll_GetCurrentProcess
push eax
call sub.kernel32.dll_SetPriorityClass
mov eax, dword [ebp - 4]
mov dword [ebp - 0x18], eax
xor eax, eax
mov dword [ebp - 0x14], eax
fild qword [ebp - 0x18]
fdiv dword [0x48b740]
fstp qword [ebp - 0x10]
wait
fld qword [ebp - 0x10]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403185
Capabilities:
Enumerate gui resources

Disassembly:
cmp dword [esp + 4], 0
push ebx
push esi
push edi
je 0x4031da
push dword [esp + 0x10]
push 0x403104
call dword [sym.imp.USER32.DLL_EnumWindows]
mov esi, dword [0x530574]
test esi, esi
je 0x403233
xor edi, edi
mov ebx, dword [esi]
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [esi + 8], eax
jne 0x4031d2
cmp byte [esi + 0x10], 0
je 0x4031d2
push 3
push edi
push edi
push edi
push edi
push 0xfffffffffffffffe
push dword [esi + 0xc]
call dword [sym.imp.USER32.DLL_SetWindowPos]
mov esi, ebx
test ebx, ebx
jne 0x4031ae
jmp 0x403233
mov esi, dword [0x530574]
test esi, esi
je 0x403233
xor edi, edi
push ebp
mov ebx, dword [esi]
lea ebp, [esi + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [ebp], eax
jne 0x40322c
cmp byte [esi + 0x11], 0
je 0x403208
push 1
push dword [esi + 0xc]
call dword [sym.imp.USER32.DLL_EnableWindow]
cmp byte [esi + 0x10], 0
je 0x40321f
push 3
push edi
push edi
push edi
push edi
push 0xffffffffffffffff
push dword [esi + 0xc]
call dword [sym.imp.USER32.DLL_SetWindowPos]
push ebp
push 0x530574
call fcn.0042068e
pop ecx
pop ecx
mov esi, ebx
test ebx, ebx
jne 0x4031e7
pop ebp
pop edi
pop esi
pop ebx
ret 4
Function at 0x41d638
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push edi
xor edi, edi
cmp dword [ebp + 8], edi
je 0x41d6d6
cmp dword [ebp + 0xc], edi
je 0x41d6d6
push esi
push 0x58
push 8
push dword [0x530518]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
push dword [ebp + 8]
mov esi, eax
or dword [esi + 4], 0xffffffff
mov dword [esi], edi
call sub.MSVCRT.dll__wcsdup
push dword [ebp + 0xc]
mov dword [esi + 8], eax
call sub.MSVCRT.dll__wcsdup
push dword [ebp + 0x14]
mov dword [esi + 0xc], eax
call sub.MSVCRT.dll__wcsdup
mov dword [esi + 0x38], eax
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov dword [esi + 0x24], eax
test al, 1
je 0x41d6c5
lea eax, [ebp + 8]
push eax
push edi
push esi
push 0x41d83c
push 0x10000
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
je 0x41d6bd
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, esi
jmp 0x41d6d5
push esi
call fcn.0041d88d
jmp 0x41d6d4
push esi
call fcn.0041d6dd
push esi
mov edi, eax
call fcn.0041d88d
pop ecx
pop ecx
pop esi
mov eax, edi
pop edi
pop ebp
ret 0x10

Function at 0x41d6dd
Capabilities:
Delete file

Disassembly:
push ecx
push ecx
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
xor ebx, ebx
push edi
mov ebp, dword [esi + 0xc]
push dword [esi + 8]
mov dword [esp + 0x18], ebp
call fcn.005007f0
push dword [esi + 0x38]
mov dword [esp + 0x20], eax
call fcn.005007f0
mov dword [esp + 0x10], eax
call fcn.00420ec0
mov edi, eax
test edi, edi
je 0x41d812
push ebx
push pe_nt_image_headers32
push 2
push ebx
push 1
push 0xc0000000
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x41d7fd
test byte [esi + 0x24], 2
mov dword [esi + 0x10], ebp
jne 0x41d74f
push 1
push 0x34
push edi
call fcn.00423e10
add esp, 0xc
mov eax, dword [0x530620]
test eax, eax
je 0x41d767
push eax
push 0x2714
push edi
call fcn.00423e10
add esp, 0xc
mov eax, dword [0x530624]
test eax, eax
je 0x41d798
cmp dword [0x530628], ebx
je 0x41d798
push eax
push 0x27bf
push edi
call fcn.00423e10
push dword [0x530628]
push 0x27c0
push edi
call fcn.00423e10
add esp, 0x18
push dword [esp + 0x1c]
push 0x2712
push edi
call fcn.00423e10
push dword [esp + 0x1c]
push 0x2722
push edi
call fcn.00423e10
push 0x41d84b
push 0x4e2b
push edi
call fcn.00423e10
push esi
push 0x2711
push edi
call fcn.00423e10
push edi
call fcn.00420f60
add esp, 0x34
test eax, eax
jne 0x41d7e8
cmp dword [esi + 4], 0xfffffffb
je 0x41d7e8
xor ebx, ebx
inc ebx
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
jne 0x41d7fd
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push edi
call fcn.00420ea0
pop ecx
cmp ebx, 1
jne 0x41d812
mov dword [esi + 4], 0xfffffffe
jmp 0x41d821
xor ecx, ecx
cmp dword [esi + 4], 0xfffffffb
setne cl
add ecx, 0xfffffffc
mov dword [esi + 4], ecx
push dword [esp + 0x1c]
call fcn.005007e0
push dword [esp + 0x10]
call fcn.005007e0
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
pop ecx
pop ecx
ret
Function at 0x41df66
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
cmp word [0x53062c], 0
jne 0x41e028
push edi
lea eax, [esp + 4]
push eax
push 0x101
call dword [sym.imp.WSOCK32.DLL_WSAStartup]
xor edi, edi
inc edi
test eax, eax
jne 0x41df9b
mov word [0x53062c], di
jmp 0x41dfa3
xor eax, eax
mov word [0x53062c], ax
push str.ws2_32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0x530648], eax
test eax, eax
je 0x41e027
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x515238
push eax
call esi
push 0x515244
push dword [0x530648]
mov dword [0x530638], eax
call esi
push str.getnameinfo
push dword [0x530648]
mov dword [0x53063c], eax
call esi
push str.WSAStringToAddressA
push dword [0x530648]
mov dword [0x530640], eax
call esi
cmp dword [0x530638], 0
mov dword [0x530644], eax
pop esi
je 0x41e027
cmp dword [0x53063c], 0
je 0x41e027
cmp dword [0x530640], 0
je 0x41e027
test eax, eax
je 0x41e027
mov dword [0x530630], edi
pop edi
movsx eax, word [0x53062c]
add esp, 0x190
ret

Function at 0x41e0d0
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
mov dword [esp + 4], 0
cmp dword [esi + 0x14], 0
jne 0x41e10c
push 0
lea eax, [esp + 8]
push eax
mov eax, dword [esi + 8]
sub eax, dword [esi + 0xc]
push eax
push dword [esi + 4]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esi + 8]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 4]
pop esi
pop ecx
ret 4
xor eax, eax
pop esi
pop ecx
ret 4

Function at 0x41e4d0
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
push esi
push dword [esp + 0x10]
mov dword [esp + 8], 0
push dword [0x530fd4]
call fcn.00420006
mov esi, eax
test esi, esi
je 0x41e54f
cmp dword [esi + 4], 0
je 0x41e520
push 1
lea eax, [esp + 8]
push eax
push esi
call fcn.0041e7c0
test eax, eax
je 0x41e514
inc dword [esi + 0xc]
xor eax, eax
pop esi
add esp, 8
ret 4
mov eax, 1
pop esi
add esp, 8
ret 4
push 0
lea eax, [esp + 0xc]
push eax
push 1
lea eax, [esp + 0x1c]
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41e55a
cmp dword [esp + 8], 0
je 0x41e55a
push 1
push 0
push 0xffffffffffffffff
push dword [esi]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 4]
pop esi
add esp, 8
ret 4
or eax, 0xffffffff
pop esi
add esp, 8
ret 4
Function at 0x41e680
Capabilities:
Write file on windows

Disassembly:
push ecx
mov edx, dword [esp + 0xc]
mov dword [esp], 0
test edx, edx
je 0x41e788
cmp word [edx], 0
je 0x41e788
mov ecx, dword [esp + 0x10]
push esi
mov esi, dword [esp + 0xc]
test ecx, ecx
jne 0x41e6ae
mov ecx, dword [esi + 0x18]
push edi
cmp ecx, 0x19
jne 0x41e70d
cmp dword [esi + 4], 0
mov ecx, edx
lea edi, [ecx + 2]
je 0x41e6e0
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x41e6c0
sub ecx, edi
sar ecx, 1
lea eax, [ecx + ecx]
push eax
push edx
push esi
call fcn.0041ed90
pop edi
pop esi
pop ecx
ret 0xc
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x41e6e0
sub ecx, edi
lea eax, [esp + 8]
push 0
sar ecx, 1
push eax
lea eax, [ecx + ecx]
push eax
push edx
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
xor eax, eax
cmp ecx, 2
lea ecx, [esp + 0x14]
setne al
push ecx
dec eax
and eax, 0xfde9
push edx
push eax
call fcn.0041eea0
mov edi, eax
test edi, edi
je 0x41e703
cmp dword [esi + 4], 0
je 0x41e75b
push dword [esp + 0x14]
push edi
push esi
call fcn.0041ed90
push edi
push 0
push dword [0x530518]
mov dword [esp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
push 0
lea eax, [esp + 0xc]
push eax
push dword [esp + 0x1c]
push edi
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
push 0
push dword [0x530518]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [esp + 8]
pop edi
pop esi
pop ecx
ret 0xc
xor eax, eax
pop ecx
ret 0xc
Function at 0x41e7c0
Capabilities:
Read file on windows

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
push edi
cmp dword [esi + 0x14], 0
jne 0x41e7e1
push esi
call fcn.0041e0d0
mov dword [esi + 0x14], 1
mov dword [esi + 0xc], 0
mov ebx, dword [esi + 0xc]
mov edi, dword [esp + 0x18]
mov eax, dword [esi + 0x10]
cmp ebx, edi
jl 0x41e855
add eax, dword [esi + 4]
mov ecx, edi
sub eax, ebx
dec ecx
je 0x41e842
dec ecx
je 0x41e82d
sub ecx, 2
je 0x41e81a
push edi
push eax
push dword [esp + 0x1c]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [eax]
mov eax, dword [esp + 0x14]
mov dword [eax], ecx
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov cx, word [eax]
mov eax, dword [esp + 0x14]
mov word [eax], cx
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
mov ecx, dword [esp + 0x14]
mov dl, byte [eax]
mov eax, edi
mov byte [ecx], dl
sub dword [esi + 0xc], edi
pop edi
pop esi
pop ebx
ret 0xc
push ebp
mov ebp, dword [esp + 0x18]
sub eax, ebx
add eax, dword [esi + 4]
push ebx
push eax
push ebp
call sub.MSVCRT.dll_memcpy
mov eax, dword [esi + 8]
add esp, 0xc
sub edi, ebx
add ebp, ebx
push 0
cmp edi, eax
jl 0x41e89a
lea eax, [esp + 0x18]
push eax
push edi
push ebp
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
pop ebp
pop edi
mov dword [esi + 0xc], 0
add eax, ebx
pop esi
pop ebx
ret 0xc
lea ecx, [esp + 0x18]
push ecx
push eax
push dword [esi + 4]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
cmp edi, eax
jle 0x41e8bb
mov edi, eax
push edi
push dword [esi + 4]
push ebp
call sub.MSVCRT.dll_memcpy
sub dword [esi + 0xc], edi
lea eax, [ebx + edi]
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
ret 0xc
Function at 0x41e8e0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x14
push 0x1000
push 0
push dword [0x530518]
mov dword [esp + 0x14], 0x1000
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esp + 0x10], edx
test edx, edx
je 0x41ea64
mov cl, byte [esp + 3]
push ebx
mov ebx, dword [esp + 0x1c]
push ebp
mov ebp, dword [esp + 0x28]
push esi
push edi
mov esi, edx
mov edi, edi
cmp ebp, 0xffffffff
je 0x41e92e
test ebp, ebp
je 0x41e9d0
dec ebp
cmp dword [ebx + 4], 0
je 0x41e947
push 1
lea eax, [esp + 0x17]
push eax
push ebx
call fcn.0041e7c0
mov dword [esp + 0x14], eax
jmp 0x41e961
push 0
lea eax, [esp + 0x18]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
mov cl, byte [esp + 0x13]
cmp eax, 1
jne 0x41e9d0
test cl, cl
je 0x41e975
mov byte [esi], cl
inc esi
mov cl, byte [esp + 0x13]
mov eax, dword [esp + 0x18]
mov edi, esi
mov edx, dword [esp + 0x20]
dec eax
sub edi, edx
cmp edi, eax
jle 0x41e9b0
mov eax, dword [esp + 0x18]
add eax, 0x1000
push eax
push edx
push 8
push dword [0x530518]
mov dword [esp + 0x28], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov cl, byte [esp + 0x13]
mov edx, eax
mov dword [esp + 0x20], edx
lea esi, [edi + edx]
test cl, cl
je 0x41e9d0
cmp dword [esp + 0x2c], 0
jne 0x41e920
cmp cl, 0xd
je 0x41e9d7
cmp cl, 0xa
jne 0x41e920
dec esi
jmp 0x41ea47
cmp dword [esp + 0x2c], 0
jne 0x41ea47
cmp cl, 0xa
jne 0x41e9df
dec esi
jmp 0x41ea47
cmp cl, 0xd
jne 0x41ea47
dec esi
cmp dword [ebx + 4], 0
je 0x41e9fe
push 1
lea eax, [esp + 0x17]
push eax
push ebx
call fcn.0041e7c0
mov dword [esp + 0x14], eax
jmp 0x41ea14
push 0
lea eax, [esp + 0x18]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp byte [esp + 0x13], 0xa
je 0x41ea47
cmp dword [ebx + 4], 0
je 0x41ea26
inc dword [ebx + 0xc]
jmp 0x41ea47
push 1
lea eax, [esp + 0x20]
mov dword [esp + 0x1c], 0xffffffff
push eax
push 0xffffffffffffffff
push dword [ebx]
mov dword [esp + 0x2c], 0
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x34]
mov ecx, esi
sub ecx, dword [esp + 0x20]
pop edi
mov dword [eax], ecx
mov eax, dword [esp + 0x1c]
mov byte [esi], 0
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x10
xor eax, eax
add esp, 0x14
ret 0x10
Function at 0x41ea70
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x18
push 0x1000
push 0
push dword [0x530518]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, eax
mov dword [esp + 8], ecx
test ecx, ecx
je 0x41ec1d
mov ax, word [esp]
push ebx
mov ebx, dword [esp + 0x20]
push ebp
mov ebp, dword [esp + 0x2c]
push esi
push edi
mov edi, ecx
mov dword [esp + 0x20], 0x1000
mov dword [esp + 0x1c], 0x7ff
cmp ebp, 0xffffffff
je 0x41eac4
test ebp, ebp
je 0x41eb7d
dec ebp
cmp dword [ebx + 4], 0
je 0x41eadd
push 2
lea eax, [esp + 0x14]
push eax
push ebx
call fcn.0041e7c0
mov dword [esp + 0x14], eax
jmp 0x41eaf7
push 0
lea eax, [esp + 0x18]
push eax
push 2
lea eax, [esp + 0x1c]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
cmp eax, 2
mov ax, word [esp + 0x10]
jne 0x41eb7d
test ax, ax
je 0x41eb11
mov word [edi], ax
add edi, 2
mov ax, word [esp + 0x10]
mov ecx, dword [esp + 0x18]
mov esi, edi
mov edx, dword [esp + 0x1c]
sub esi, ecx
sar esi, 1
cmp esi, edx
jle 0x41eb58
mov eax, dword [esp + 0x20]
add edx, 0x800
add eax, 0x1000
mov dword [esp + 0x1c], edx
push eax
push ecx
push 8
push dword [0x530518]
mov dword [esp + 0x30], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, eax
mov ax, word [esp + 0x10]
mov dword [esp + 0x18], ecx
lea edi, [ecx + esi*2]
test ax, ax
je 0x41eb7d
cmp dword [esp + 0x30], 0
jne 0x41eab6
cmp ax, 0xd
je 0x41eb84
cmp ax, 0xa
jne 0x41eab6
sub edi, 2
jmp 0x41ebfc
cmp dword [esp + 0x30], 0
jne 0x41ebfc
cmp ax, 0xa
jne 0x41eb8f
sub edi, 2
jmp 0x41ebfc
cmp ax, 0xd
jne 0x41ebfc
sub edi, 2
cmp dword [ebx + 4], 0
je 0x41ebb1
push 2
lea eax, [esp + 0x14]
push eax
push ebx
call fcn.0041e7c0
mov dword [esp + 0x14], eax
jmp 0x41ebc7
push 0
lea eax, [esp + 0x18]
push eax
push 2
lea eax, [esp + 0x1c]
push eax
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp word [esp + 0x10], 0xa
je 0x41ebfc
cmp dword [ebx + 4], 0
je 0x41ebdb
add dword [ebx + 0xc], 2
jmp 0x41ebfc
push 1
lea eax, [esp + 0x28]
mov dword [esp + 0x24], 0xfffffffe
push eax
push 0xfffffffffffffffe
push dword [ebx]
mov dword [esp + 0x34], 0
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x38]
mov ecx, edi
sub ecx, dword [esp + 0x18]
sar ecx, 1
mov dword [eax], ecx
xor eax, eax
mov word [edi], ax
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x18
ret 0x10
xor eax, eax
add esp, 0x18
ret 0x10
Function at 0x41ec30
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x14
push 0x1000
push 0
push dword [0x530518]
mov dword [esp + 0x10], 0x1000
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esp + 0xc], edx
test edx, edx
je 0x41ed80
mov eax, dword [esp + 0x1c]
mov cl, byte [esp + 3]
push ebx
push ebp
mov ebp, dword [esp + 0x20]
push esi
push edi
mov edi, dword [esp + 0x30]
mov esi, edx
cmp edi, 0xffffffff
je 0x41ec7c
test edi, edi
je 0x41eced
dec edi
push esi
push ebp
call fcn.0041ef10
mov dword [esp + 0x20], eax
test eax, eax
jne 0x41ec8f
xor cl, cl
jmp 0x41ec91
mov cl, byte [esi]
mov edx, dword [esp + 0x1c]
add esi, eax
mov eax, dword [esp + 0x14]
mov ebx, esi
sub ebx, edx
mov byte [esp + 0x13], cl
add eax, 0xfffffffb
cmp ebx, eax
jle 0x41ecd4
mov eax, dword [esp + 0x14]
add eax, 0x1000
push eax
push edx
push 8
push dword [0x530518]
mov dword [esp + 0x24], eax
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov cl, byte [esp + 0x13]
mov edx, eax
mov dword [esp + 0x1c], edx
lea esi, [ebx + edx]
mov eax, dword [esp + 0x2c]
test cl, cl
je 0x41eced
test eax, eax
jne 0x41ec72
cmp cl, 0xd
je 0x41ecf1
cmp cl, 0xa
jne 0x41ec72
dec esi
jmp 0x41ed63
test eax, eax
jne 0x41ed63
cmp cl, 0xa
jne 0x41ecf9
dec esi
jmp 0x41ed63
cmp cl, 0xd
jne 0x41ed63
dec esi
cmp dword [ebp + 4], 0
je 0x41ed18
push 1
lea eax, [esp + 0x17]
push eax
push ebp
call fcn.0041e7c0
mov dword [esp + 0x20], eax
jmp 0x41ed2f
push 0
lea eax, [esp + 0x24]
push eax
push 1
lea eax, [esp + 0x1f]
push eax
push dword [ebp]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp byte [esp + 0x13], 0xa
je 0x41ed63
cmp dword [ebp + 4], 0
je 0x41ed41
inc dword [ebp + 0xc]
jmp 0x41ed63
push 1
lea eax, [esp + 0x1c]
mov dword [esp + 0x18], 0xffffffff
push eax
push 0xffffffffffffffff
push dword [ebp]
mov dword [esp + 0x28], 0xffffffff
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x34]
mov ecx, esi
sub ecx, dword [esp + 0x1c]
pop edi
mov dword [eax], ecx
mov eax, dword [esp + 0x18]
mov byte [esi], 0
pop esi
pop ebp
pop ebx
add esp, 0x14
ret 0x10
xor eax, eax
add esp, 0x14
ret 0x10
Function at 0x41ed90
Capabilities:
Write file on windows

Disassembly:
sub esp, 0xc
push esi
mov esi, dword [esp + 0x14]
mov dword [esp + 4], 0
cmp dword [esi + 0x1c], 0
jne 0x41ee97
cmp dword [esi + 0x14], 1
jne 0x41eddb
mov eax, dword [esi + 0xc]
lea ecx, [esp + 0xc]
push 1
neg eax
cdq
push ecx
push eax
push dword [esi]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esi + 8]
mov dword [esi + 0x14], 0
mov dword [esi + 0xc], eax
mov eax, dword [esi + 0xc]
push edi
mov edi, dword [esp + 0x20]
cmp eax, edi
jle 0x41ee58
mov ecx, dword [esi + 8]
add ecx, dword [esi + 4]
sub ecx, eax
mov eax, edi
dec eax
je 0x41ee43
dec eax
je 0x41ee2c
sub eax, 2
je 0x41ee17
push edi
push dword [esp + 0x20]
push ecx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
add esp, 0xc
ret 0xc
mov eax, dword [esp + 0x1c]
mov eax, dword [eax]
mov dword [ecx], eax
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
add esp, 0xc
ret 0xc
mov eax, dword [esp + 0x1c]
mov ax, word [eax]
mov word [ecx], ax
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
add esp, 0xc
ret 0xc
mov eax, dword [esp + 0x1c]
mov al, byte [eax]
mov byte [ecx], al
mov eax, edi
sub dword [esi + 0xc], edi
pop edi
pop esi
add esp, 0xc
ret 0xc
push esi
call fcn.0041e0d0
mov eax, dword [esi + 8]
cmp edi, eax
jl 0x41ee85
push 0
lea eax, [esp + 0xc]
push eax
push edi
push dword [esp + 0x28]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0xc
ret 0xc
mov ecx, dword [esi + 4]
sub ecx, dword [esi + 0xc]
push edi
push dword [esp + 0x20]
add ecx, eax
jmp 0x41ee01
xor eax, eax
pop esi
add esp, 0xc
ret 0xc
Function at 0x41ef10
Capabilities:
Read file on windows

Disassembly:
push ecx
push edi
mov edi, dword [esp + 0xc]
mov dword [esp + 4], 0
cmp dword [edi + 4], 0
je 0x41ef37
push 1
lea eax, [esp + 0x10]
push eax
push edi
call fcn.0041e7c0
mov dword [esp + 4], eax
jmp 0x41ef51
push 0
lea eax, [esp + 8]
push eax
push 1
lea eax, [esp + 0x18]
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 4]
cmp eax, 1
je 0x41ef5d
xor eax, eax
pop edi
pop ecx
ret 8
mov cl, byte [esp + 0xc]
test cl, cl
js 0x41ef79
mov eax, dword [esp + 0x10]
pop edi
mov byte [eax], cl
mov byte [eax + 1], 0
mov eax, 1
pop ecx
ret 8
mov al, cl
and al, 0xe0
push esi
cmp al, 0xc0
jne 0x41ef89
mov esi, 2
jmp 0x41efa5
mov al, cl
and al, 0xf0
cmp al, 0xe0
jne 0x41ef98
mov esi, 3
jmp 0x41efa5
mov al, cl
and al, 0xf8
cmp al, 0xf0
jne 0x41f002
mov esi, 4
mov edx, dword [esp + 0x14]
mov byte [edx], cl
cmp dword [edi + 4], 0
je 0x41efd4
lea eax, [esi - 1]
push eax
lea eax, [edx + 1]
push eax
push edi
call fcn.0041e7c0
mov edx, eax
lea ecx, [esi - 1]
xor eax, eax
cmp edx, ecx
setne al
dec eax
and eax, esi
pop esi
pop edi
pop ecx
ret 8
push 0
lea eax, [esp + 0xc]
push eax
lea eax, [esi - 1]
push eax
lea eax, [edx + 1]
push eax
push dword [edi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [esp + 8]
lea ecx, [esi - 1]
xor eax, eax
cmp edx, ecx
setne al
dec eax
and eax, esi
pop esi
pop edi
pop ecx
ret 8
mov eax, dword [esp + 0x14]
pop esi
pop edi
mov word [eax], 0x3f
mov eax, 1
pop ecx
ret 8