joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10031a00
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
mov eax, dword [0x1008f080]
xor eax, esp
mov dword [esp + 0x18], eax
cmp dword [0x10092274], 0
push ebx
push esi
push edi
jne 0x10031b5b
mov eax, dword [0x1008fb10]
mov ebx, dword [eax + 0x84]
lea ecx, [eax + 0x84]
mov dword [esp + 0x10], ecx
cmp dword [ebx + 0x10], 0
jne 0x10031aab
cmp dword [ebx + 0xc], 0
jne 0x10031a5f
cmp dword [ebx + 0x44], 0
jne 0x10031a53
push ecx
mov ecx, ebx
call fcn.1002e210
mov ecx, ebx
call fcn.1002e7b0
mov eax, dword [0x1008fb10]
mov esi, dword [ebx + 0xc]
test esi, esi
je 0x10031aab
mov ecx, dword [ebx + 0x14]
imul ecx, dword [ebx + 0x18]
inc dword [eax + 0x318]
mov eax, dword [eax + 0xc0]
shl ecx, 2
push ecx
call eax
mov ecx, dword [ebx + 0x14]
add esp, 4
imul ecx, dword [ebx + 0x18]
mov edx, eax
mov dword [ebx + 0x10], edx
test ecx, ecx
jle 0x10031aab
movzx eax, byte [esi]
lea esi, [esi + 1]
shl eax, 0x18
lea edx, [edx + 4]
or eax, 0xffffff
dec ecx
mov dword [edx - 4], eax
test ecx, ecx
jg 0x10031a92
mov eax, dword [ebx + 0x14]
mov edi, dword [ebx + 0x10]
mov ebx, dword [ebx + 0x18]
mov dword [esp + 0x14], eax
lea eax, [esp + 0x20]
push eax
push 0x8069
call dword [sym.imp.OPENGL32.dll_glGetIntegerv]
push 0x10092274
push 1
call dword [sym.imp.OPENGL32.dll_glGenTextures]
push dword [0x10092274]
push 0xde1
call dword [sym.imp.OPENGL32.dll_glBindTexture]
mov esi, dword [sym.imp.OPENGL32.dll_glTexParameteri]
push 0x2601
push 0x2801
push 0xde1
call esi
push 0x2601
push 0x2800
push 0xde1
call esi
push 0
push 0xcf2
call dword [sym.imp.OPENGL32.dll_glPixelStorei]
push edi
push 0x1401
push 0x1908
push 0
push ebx
push dword [esp + 0x28]
push 0x1908
push 0
push 0xde1
call dword [sym.imp.OPENGL32.dll_glTexImage2D]
mov eax, dword [esp + 0x10]
mov ecx, dword [eax]
mov eax, dword [0x10092274]
mov dword [ecx], eax
push dword [esp + 0x20]
push 0xde1
call dword [sym.imp.OPENGL32.dll_glBindTexture]
movd xmm0, dword [0x10091e6c]
lea eax, [esp + 0x18]
movd xmm1, dword [0x10091e70]
mov edi, dword [0x1008fb10]
cvtdq2ps xmm0, xmm0
push eax
mov dword [edi + 0x94], 0x3f800000
mov dword [edi + 0x98], 0x3f800000
cvtdq2ps xmm1, xmm1
movss dword [edi + 4], xmm0
movss dword [edi + 8], xmm1
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov ecx, dword [esp + 0x18]
sub ecx, dword [0x10092280]
mov edx, dword [esp + 0x1c]
sbb edx, dword [0x10092284]
call fcn.1006c350
mov edx, dword [0x1009227c]
mov ecx, dword [0x10092278]
movss dword [esp + 0x10], xmm0
call fcn.1006c350
movss xmm1, dword [esp + 0x10]
divss xmm1, xmm0
mov esi, dword [sym.imp.USER32.dll_GetKeyState]
push 0x11
movss dword [edi + 0xc], xmm1
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
mov dword [0x10092280], eax
mov dword [0x10092284], ecx
call esi
shr eax, 0xf
and al, 1
push 0x10
mov byte [edi + 0xe9], al
call esi
shr eax, 0xf
and al, 1
push 0x12
mov byte [edi + 0xea], al
call esi
shr eax, 0xf
and al, 1
mov byte [edi + 0xec], 0
mov byte [edi + 0xeb], al
call fcn.1000f510
mov ecx, dword [esp + 0x24]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.10046e53
mov esp, ebp
pop ebp
ret
Function at 0x10032840
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push ebx
mov ebx, dword [0x10092290]
push esi
mov esi, dword [0x10092288]
push edi
push 0xffffffffffffffef
push ebx
push esi
push str.xxxxx
push 0x100816bc
call fcn.10032b90
mov edi, eax
mov dword [0x100922c4], edi
cmp edi, esi
jb 0x10032876
cmp edi, ebx
jbe 0x10032909
push str.COffsets::FindSendCommand
push str.___s:_finding_already_injected_function._n
call fcn.1003d920
mov ecx, dword [0x10092288]
add esp, 8
mov ebx, dword [0x10092290]
test ecx, ecx
je 0x100328ed
test ebx, ebx
je 0x100328ed
cmp ecx, ebx
mov eax, ecx
mov edi, ebx
cmovbe eax, ebx
cmovbe edi, ecx
lea esi, [eax - 0x1a]
cmp edi, esi
jae 0x100328ed
mov edx, edi
sub edx, 0x1008170c
nop word [eax + eax]
xor eax, eax
nop dword [eax]
nop word [eax + eax]
mov cl, byte [eax + 0x1008170c]
cmp cl, byte [edx + eax + 0x1008170c]
jne 0x100328e7
inc eax
cmp eax, 0x1a
jb 0x100328d0
jmp 0x100328ef
inc edi
inc edx
cmp edi, esi
jb 0x100328c0
xor edi, edi
mov dword [0x100922c4], edi
cmp edi, dword [0x10092288]
jb 0x100329ae
cmp edi, ebx
ja 0x100329ae
mov esi, dword [sym.imp.KERNEL32.dll_VirtualProtect]
push 0x100b858c
push 0x40
push 0x1a
push edi
call esi
movups xmm0, xmmword [0x1008170c]
push 0x100b858c
movups xmmword [edi], xmm0
movq xmm0, qword [0x1008171c]
movq qword [edi + 0x10], xmm0
mov ax, word [0x10081724]
mov word [edi + 0x18], ax
push dword [0x100b858c]
push 0x1a
push edi
call esi
push 0x1a
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov esi, dword [0x10092290]
push 0xfffffffffffffff5
push esi
push dword [0x100922c4]
push 0x100813ac
push 0x10081728
call fcn.10032b90
mov dword [0x100922c8], eax
cmp eax, dword [0x10092288]
jb 0x10032991
cmp eax, esi
ja 0x10032991
mov al, 1
pop edi
pop esi
pop ebx
ret
push str.COffsets::FindSendCommand
push str._s:_2_not_found.
push 0x10092288
call fcn.10032b10
add esp, 0xc
xor al, al
pop edi
pop esi
pop ebx
ret
push str.COffsets::FindSendCommand
push str._s:_not_found.
push 0x10092288
call fcn.10032b10
add esp, 0xc
xor al, al
pop edi
pop esi
pop ebx
ret

Function at 0x10032b10
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
jmp 0x10032b29
lea eax, [ebp + 0x10]
push eax
push 0
push dword [ebp + 0xc]
push 0x1000
push 0x100d24c0
call fcn.1000ac10
mov ecx, dword [eax]
push dword [eax + 4]
or ecx, 2
push ecx
call fcn.10051012
add esp, 0x1c
push 0x10
push str.Hpp_Hack
push 0x100d24c0
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
push 0
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
jmp 0x10032b87
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret
Function at 0x10032ca0
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x230
mov eax, dword [0x1008f080]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, ecx
cmp byte [edi + 8], 0
je 0x10032ce0
mov eax, dword [ebp + 8]
cmp eax, dword [edi]
jne 0x10032cdb
cmp dword [edi + 4], ebx
je 0x10032cdb
push ecx
mov dword [edi + 4], ebx
call fcn.10032e80
jmp 0x10032e62
call fcn.10001610
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x210]
push ecx
push 0x40
push 0xe
push eax
mov dword [edi], eax
mov dword [edi + 4], ebx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x10032d13
pop edi
pop esi
xor al, al
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10046e53
mov esp, ebp
pop ebp
ret 8
mov eax, dword [edi]
mov cl, byte [eax]
cmp cl, 0xe9
je 0x10032d25
cmp cl, 0xe8
jne 0x10032e49
mov esi, dword [eax + 1]
mov ebx, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
add esi, eax
push 0x1c
lea eax, [ebp - 0x22c]
push eax
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_VirtualQueryEx]
test eax, eax
je 0x10032d59
cmp dword [ebp - 0x21c], 0x1000
jne 0x10032d59
mov esi, dword [ebp - 0x228]
push 0x103
lea eax, [ebp - 0x108]
push eax
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_K32GetMappedFileNameA]
test eax, eax
lea eax, [ebp - 0x108]
je 0x10032d81
mov dword [ebp - 0x230], eax
jmp 0x10032da4
push 0x103
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
lea ecx, [ebp - 0x108]
mov eax, str.unknown
cmove ecx, eax
mov dword [ebp - 0x230], ecx
mov esi, dword [edi]
call ebx
push 0x1c
lea ecx, [ebp - 0x22c]
push ecx
push esi
push eax
call dword [sym.imp.KERNEL32.dll_VirtualQueryEx]
test eax, eax
je 0x10032dcf
cmp dword [ebp - 0x21c], 0x1000
mov esi, dword [ebp - 0x228]
je 0x10032dd1
mov esi, dword [edi]
push 0x103
lea eax, [ebp - 0x20c]
push eax
push esi
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_K32GetMappedFileNameA]
test eax, eax
je 0x10032df3
lea esi, [ebp - 0x20c]
jmp 0x10032e16
push 0x103
lea eax, [ebp - 0x20c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
lea esi, [ebp - 0x20c]
mov eax, str.unknown
cmove esi, eax
push 0x5c
push esi
call fcn.10048b50
mov ebx, eax
add esp, 8
mov eax, dword [0x10092140]
test eax, eax
je 0x10032e49
push dword [ebp - 0x230]
mov edx, dword [eax]
lea ecx, [ebx + 1]
test ebx, ebx
cmove ecx, esi
push ecx
push str.WARNING:_Another_hook_is_already_present_while_trying_to_hook__s__hook_target_is__s._If_you_experience_crashes__try_disabling_the_other_hooking_application._n
push eax
call dword [edx + 0x1c]
add esp, 0x10
mov ecx, dword [edi]
movq xmm0, qword [ecx]
movq qword [edi + 9], xmm0
mov eax, dword [ecx + 8]
mov dword [edi + 0x11], eax
mov ax, word [ecx + 0xc]
mov word [edi + 0x15], ax
mov ecx, dword [ebp - 4]
mov al, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10046e53
mov esp, ebp
pop ebp
ret 8
Function at 0x10039da0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [0x1008f080]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x1007a99c
push eax
lea eax, [ebp - 8]
mov dword [ebp - 0xc], ecx
push eax
mov dword [ebp - 8], 0
call fcn.1004cbfd
mov ebx, dword [ebp - 8]
add esp, 0xc
test ebx, ebx
jne 0x10039def
lea eax, [ebx - 3]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10046e53
mov esp, ebp
pop ebp
ret 4
push 2
push 0
push ebx
call fcn.1004e2a1
add esp, 0xc
test eax, eax
je 0x10039e07
mov esi, 0xfffffffd
jmp 0x10039e7c
push ebx
call fcn.100517b5
mov esi, eax
add esp, 4
test esi, esi
js 0x10039e00
jne 0x10039e1c
xor esi, esi
jmp 0x10039e7c
lea eax, [esi + 1]
push 0x10072fd2
push eax
call fcn.1004744a
mov edi, eax
add esp, 8
test edi, edi
jne 0x10039e38
lea esi, [eax - 2]
jmp 0x10039e7c
push 0
push 0
push ebx
mov byte [edi + esi], 0
call fcn.1004e2a1
add esp, 0xc
push ebx
push esi
push 1
push edi
call fcn.1004de3b
add esp, 0x10
cmp eax, esi
je 0x10039e67
push edi
call fcn.10046e61
mov esi, 0xfffffffd
jmp 0x10039e79
mov ecx, dword [ebp - 0xc]
push eax
push edi
call fcn.1003ab30
push edi
mov esi, eax
call fcn.10046e61
add esp, 4
push dword [ebp - 8]
call fcn.1004d0cb
mov ecx, dword [ebp - 4]
add esp, 4
mov eax, esi
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.10046e53
mov esp, ebp
pop ebp
ret 4
Function at 0x1004538b
Capabilities:
Enumerate threads

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x1008f080]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor edi, edi
mov esi, ecx
push edi
push 4
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov ebx, eax
mov dword [ebp - 0x24], ebx
cmp ebx, 0xffffffff
je 0x10045496
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_Thread32First]
test eax, eax
je 0x1004548f
inc edi
cmp dword [ebp - 0x20], 0x10
jb 0x10045453
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [ebp - 0x14], eax
jne 0x10045453
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [ebp - 0x18], eax
je 0x10045453
mov edx, dword [esi]
test edx, edx
jne 0x1004541c
push 0x200
push edx
push dword [0x100922f4]
mov dword [esi + 4], 0x80
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esi], edx
test edx, edx
je 0x10045478
lea ebx, [esi + 8]
jmp 0x10045446
mov eax, dword [esi + 4]
lea ebx, [esi + 8]
cmp dword [ebx], eax
jb 0x10045446
add eax, eax
mov dword [esi + 4], eax
shl eax, 2
push eax
push edx
push 0
push dword [0x100922f4]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edx, eax
test edx, edx
je 0x100454a7
mov dword [esi], edx
mov ecx, dword [ebx]
mov eax, dword [ebp - 0x18]
mov dword [edx + ecx*4], eax
inc dword [ebx]
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_Thread32Next]
test eax, eax
jne 0x100453d4
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
je 0x1004548f
xor edi, edi
cmp dword [esi], edi
je 0x1004548f
push dword [esi]
push edi
push dword [0x100922f4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
and dword [esi], edi
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10046e53
leave
ret
mov ebx, dword [ebp - 0x24]
jmp 0x10045478
Function at 0x100454ac
Capabilities:
Suspend thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x14], edx
xor esi, esi
mov dword [edi], esi
mov dword [edi + 4], esi
mov dword [edi + 8], esi
call fcn.1004538b
test eax, eax
jne 0x100454d4
push 9
pop esi
jmp 0x10045556
cmp dword [edi], esi
je 0x10045556
mov dword [ebp - 0xc], esi
cmp dword [edi + 8], esi
jbe 0x10045556
mov edx, esi
mov dword [ebp - 4], esi
mov dword [ebp - 0x10], edx
push ebx
mov eax, dword [edi]
push dword [eax + edx]
push esi
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov ebx, eax
mov dword [ebp - 8], esi
test ebx, ebx
je 0x1004552d
push ebx
call dword [sym.imp.KERNEL32.dll_SuspendThread]
cmp eax, 0xffffffff
je 0x10045521
push dword [ebp + 8]
mov edx, dword [ebp - 0x14]
mov ecx, ebx
mov dword [ebp - 8], 1
call fcn.10045236
pop ecx
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 8], esi
jne 0x10045537
mov eax, dword [edi]
mov ecx, dword [ebp - 4]
mov dword [ecx + eax], esi
jmp 0x1004553a
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0xc]
add ecx, 4
mov edx, dword [ebp - 0x10]
inc eax
add edx, 4
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x10], edx
mov dword [ebp - 4], ecx
cmp eax, dword [edi + 8]
jb 0x100454e9
pop ebx
pop edi
mov eax, esi
pop esi
leave
ret

Function at 0x1004555c
Capabilities:
Resume thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
cmp dword [esi], 0
je 0x100455bf
push ebx
xor ebx, ebx
cmp dword [esi + 8], ebx
jbe 0x100455ae
xor ecx, ecx
mov dword [ebp - 4], ecx
push edi
mov eax, dword [esi]
mov eax, dword [ecx + eax]
test eax, eax
je 0x100455a1
push eax
push 0
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov edi, eax
test edi, edi
je 0x1004559e
push edi
call dword [sym.imp.KERNEL32.dll_ResumeThread]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
inc ebx
add ecx, 4
mov dword [ebp - 4], ecx
cmp ebx, dword [esi + 8]
jb 0x10045576
pop edi
push dword [esi]
push 0
push dword [0x100922f4]
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop ebx
pop esi
leave
ret
Function at 0x100455c2
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
imul esi, ecx, 0x2c
push edi
mov edi, edx
mov dword [ebp - 0x10], edi
add esi, dword [0x100d4d10]
mov dword [ebp - 8], esi
mov al, byte [esi + 0x14]
mov ebx, dword [esi]
and al, 1
je 0x100455e8
sub ebx, 5
movzx eax, al
lea ecx, [ebp - 4]
push ecx
push 0x40
lea eax, [eax*2 + 5]
push eax
push ebx
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1004560f
push 0xa
pop eax
jmp 0x1004568f
test edi, edi
je 0x10045630
mov byte [ebx], 0xe9
mov eax, dword [esi + 4]
sub eax, ebx
sub eax, 5
mov dword [ebx + 1], eax
test byte [esi + 0x14], 1
je 0x1004564f
mov eax, dword [esi]
mov word [eax], 0xf9eb
jmp 0x1004564f
test byte [esi + 0x14], 1
je 0x10045644
lea esi, [esi + 0xc]
mov edi, ebx
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
mov esi, dword [ebp - 8]
jmp 0x1004564f
mov eax, dword [esi + 0xc]
mov dword [ebx], eax
mov al, byte [esi + 0x10]
mov byte [ebx + 4], al
mov edi, dword [ebp - 0xc]
lea eax, [ebp - 4]
push eax
push dword [ebp - 4]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov edx, dword [ebp - 0x10]
mov cl, dl
add cl, cl
shl dl, 2
xor cl, byte [esi + 0x14]
and cl, 2
xor cl, byte [esi + 0x14]
xor dl, cl
and dl, 4
xor dl, cl
xor eax, eax
mov byte [esi + 0x14], dl
pop edi
pop esi
pop ebx
leave
ret

Function at 0x10045b8b
Capabilities:
Allocate or change rwx memory

Disassembly:
mov edx, dword [0x100d4d04]
push esi
xor esi, esi
jmp 0x10045b9d
cmp dword [edx + 4], esi
jne 0x10045be9
mov edx, dword [edx]
test edx, edx
jne 0x10045b96
push 0x40
push 0x3000
push 0x1000
push esi
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov edx, eax
test edx, edx
je 0x10045bf6
push edi
push 0x20
lea ecx, [edx + 0x20]
mov dword [edx + 8], esi
pop edi
mov dword [ecx], esi
mov eax, ecx
mov dword [edx + 4], ecx
add edi, 0x20
add ecx, 0x20
mov esi, eax
cmp edi, 0xfe0
jbe 0x10045bc4
mov eax, dword [0x100d4d04]
pop edi
mov dword [edx], eax
mov dword [0x100d4d04], edx
mov eax, dword [edx + 4]
pop esi
mov ecx, dword [eax]
inc dword [edx + 8]
mov dword [edx + 4], ecx
ret
xor eax, eax
pop esi
ret

Function at 0x1004c35f
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x1004c39e
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1004c39e
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1004c39e
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x1004c39e
cmp dword [ecx + 0x74], 0xe
jbe 0x1004c39e
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x10051545
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x1020
call fcn.10048170
mov eax, dword [0x1008f080]
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.1005c4bb
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x10051587
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x100516fe
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.1006be30
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1014], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x10090d60]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.1005f7ff
mov ecx, dword [esi*4 + 0x10090d60]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x1020], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x100516f7
cmp eax, dword [edi + ecx + 0x24]
jne 0x100516f7
xor esi, esi
lea eax, [ebp - 0x101c]
push esi
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi + ecx + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x100516f7
push dword [ebp - 0x100c]
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1005f7ff
add esp, 0x14
cmp edx, esi
jl 0x100516f7
jg 0x10051652
cmp eax, esi
jb 0x100516f7
mov ebx, dword [ebp - 0x1014]
mov eax, dword [ebp - 0x101c]
cmp ebx, esi
jg 0x100516f7
jl 0x10051674
cmp dword [ebp - 0x1008], eax
ja 0x100516f7
lea edi, [ebp - 0x1004]
xorps xmm0, xmm0
add edi, eax
movlpd qword [ebp - 0x1018], xmm0
lea ecx, [ebp - 0x1004]
cmp dword [ebp - 0x1008], esi
jne 0x10051699
cmp ebx, esi
je 0x100516de
mov edx, dword [ebp - 0x1014]
mov esi, dword [ebp - 0x1018]
cmp ecx, edi
jae 0x100516de
mov al, byte [ecx]
cmp al, 0xd
jne 0x100516bf
lea eax, [edi - 1]
cmp ecx, eax
jae 0x100516cb
cmp byte [ecx + 1], 0xa
jne 0x100516cb
inc ecx
jmp 0x100516cb
movzx eax, al
movsx eax, byte [eax + 0x1008f328]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x100516a5
cmp edx, ebx
jne 0x100516a5
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x1020]
jmp 0x100516fc
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.10046e53
leave
ret
Function at 0x1005c6aa
Capabilities:
Get file size

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
sub esp, 0x18
mov eax, dword [eax + 0xc]
nop
shr eax, 3
test al, 1
je 0x1005c6c4
mov al, 1
leave
ret
mov eax, dword [ebp + 8]
push ebx
push esi
mov eax, dword [eax + 0xc]
nop
test al, 0xc0
mov eax, dword [ebp + 8]
je 0x1005c6db
mov ecx, dword [eax]
cmp ecx, dword [eax + 4]
je 0x1005c733
mov eax, dword [eax + 0x10]
nop
push eax
call fcn.10066cb9
mov esi, eax
pop ecx
cmp esi, 0xffffffff
je 0x1005c733
xor ebx, ebx
lea eax, [ebp - 0x10]
inc ebx
xorps xmm0, xmm0
push ebx
push eax
movlpd qword [ebp - 8], xmm0
push dword [ebp - 4]
push dword [ebp - 8]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x1005c733
lea eax, [ebp - 0x18]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x1005c733
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x18]
jne 0x1005c72d
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x14]
je 0x1005c72f
xor bl, bl
mov al, bl
jmp 0x1005c735
xor al, al
pop esi
pop ebx
leave
ret
Function at 0x1005ec8b
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov edx, dword [ebp + 8]
mov ecx, edx
push ebx
mov ebx, dword [ebp + 0xc]
mov eax, edx
sar ecx, 6
and eax, 0x3f
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x10090d60]
mov dword [ebp - 0x18], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1005eccd
cmp byte [ebx], 0xa
jne 0x1005eccd
or byte [edi + eax + 0x28], 4
jmp 0x1005ecd2
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1005edd5
mov cl, byte [eax]
cmp cl, 0x1a
je 0x1005edb0
lea ebx, [eax + 1]
mov dword [ebp - 8], ebx
mov ebx, dword [ebp + 0xc]
cmp cl, 0xd
je 0x1005ed01
mov eax, dword [ebp - 8]
jmp 0x1005ed21
mov edx, dword [ebp - 0x10]
cmp dword [ebp - 8], edx
mov edx, dword [ebp + 8]
jae 0x1005ed3d
mov ebx, dword [ebp - 8]
cmp byte [ebx], 0xa
jne 0x1005ed1b
add eax, 2
mov cl, 0xa
jmp 0x1005ed1e
mov eax, dword [ebp - 8]
mov ebx, dword [ebp + 0xc]
mov byte [esi], cl
mov dword [ebp - 0xc], 1
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0xc]
add esi, dword [ebp - 8]
cmp eax, dword [ebp - 0x10]
jb 0x1005ece3
jmp 0x1005edd5
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 0x1005edab
cmp dword [ebp - 0x10], 0
je 0x1005edab
mov edx, dword [ebp - 0x18]
mov eax, dword [edx*4 + 0x10090d60]
test byte [eax + edi + 0x28], 0x48
je 0x1005ed8a
mov cl, byte [ebp - 1]
cmp cl, 0xa
jne 0x1005ed7a
mov byte [esi], 0xa
jmp 0x1005edd4
mov byte [esi], 0xd
mov eax, dword [edx*4 + 0x10090d60]
mov byte [eax + edi + 0x2a], cl
jmp 0x1005edd4
cmp byte [ebp - 1], 0xa
jne 0x1005ed94
cmp esi, ebx
je 0x1005ed75
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1005f81d
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1005edd5
mov byte [esi], 0xd
jmp 0x1005edd4
mov eax, edx
and edx, 0x3f
sar eax, 6
imul edx, edx, 0x38
mov edi, dword [eax*4 + 0x10090d60]
mov al, byte [edi + edx + 0x28]
test al, 0x40
jne 0x1005edd2
or al, 2
mov byte [edi + edx + 0x28], al
jmp 0x1005edd5
mov byte [esi], cl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret