joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10013320
Capabilities:
Generate random numbers using a mersenne twister

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov dword [ebp - 4], ecx
mov dword [ebp - 0x28], 0x26f
mov dword [ebp - 0x2c], 0xe3
mov dword [ebp - 8], 0
jmp 0x10013349
mov eax, dword [ebp - 8]
add eax, 1
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0xe3
jae 0x100133b5
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, dword [edx + ecx*4 + 0x9c4]
and eax, 0x80000000
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov ecx, dword [edx + ecx*4 + 0x9c8]
and ecx, 0x7fffffff
or eax, ecx
mov dword [ebp - 0x10], eax
mov edx, dword [ebp - 0x10]
and edx, 1
je 0x1001338d
mov dword [ebp - 0x14], 0x9908b0df
jmp 0x10013394
mov dword [ebp - 0x14], 0
mov eax, dword [ebp - 0x10]
shr eax, 1
xor eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
xor eax, dword [edx + ecx*4 + 0xff8]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov dword [edx + ecx*4 + 4], eax
jmp 0x10013340
mov dword [ebp - 0xc], 0xe3
jmp 0x100133c7
mov eax, dword [ebp - 0xc]
add eax, 1
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0x26f
jae 0x10013433
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov eax, dword [edx + ecx*4 + 0x9c4]
and eax, 0x80000000
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov ecx, dword [edx + ecx*4 + 0x9c8]
and ecx, 0x7fffffff
or eax, ecx
mov dword [ebp - 0x18], eax
mov edx, dword [ebp - 0x18]
and edx, 1
je 0x1001340b
mov dword [ebp - 0x1c], 0x9908b0df
jmp 0x10013412
mov dword [ebp - 0x1c], 0
mov eax, dword [ebp - 0x18]
shr eax, 1
xor eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
xor eax, dword [edx + ecx*4 - 0x388]
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov dword [edx + ecx*4 + 4], eax
jmp 0x100133be
mov dword [ebp - 0x30], 0x26f
mov eax, 4
imul ecx, eax, 0x4df
mov edx, dword [ebp - 4]
mov eax, dword [edx + ecx + 4]
and eax, 0x80000000
mov ecx, 4
imul edx, ecx, 0
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + edx + 4]
and edx, 0x7fffffff
or eax, edx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x20]
and eax, 1
je 0x1001347c
mov dword [ebp - 0x24], 0x9908b0df
jmp 0x10013483
mov dword [ebp - 0x24], 0
mov ecx, dword [ebp - 0x20]
shr ecx, 1
xor ecx, dword [ebp - 0x24]
mov edx, 4
imul eax, edx, 0x18c
mov edx, dword [ebp - 4]
xor ecx, dword [edx + eax + 4]
mov eax, 4
imul edx, eax, 0x26f
mov eax, dword [ebp - 4]
mov dword [eax + edx + 4], ecx
mov ecx, dword [ebp - 4]
mov dword [ecx], 0
mov esp, ebp
pop ebp
ret
Function at 0x100158a0
Capabilities:
Resolve function by fnv-1a hash

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x1004b080]
xor eax, ebp
mov dword [ebp - 4], eax
lea ecx, [ebp - 0x14]
call fcn.10015480
nop
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax + 0x18]
push ecx
lea ecx, [ebp - 0x10]
call fcn.10015350
nop
lea ecx, [ebp - 0x10]
call fcn.100153b0
movzx edx, al
test edx, edx
je 0x10015924
lea ecx, [ebp - 0x10]
call fcn.100153e0
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x18]
sub ecx, 1
mov dword [ebp - 0x18], ecx
cmp dword [ebp - 0x1c], 0
je 0x10015924
mov edx, dword [ebp - 0x18]
push edx
lea ecx, [ebp - 0x10]
call fcn.10015400
push eax
call fcn.10015950
add esp, 4
cmp eax, 0x820621f3
jne 0x10015922
mov eax, dword [ebp - 0x18]
push eax
lea ecx, [ebp - 0x10]
call fcn.10015430
jmp 0x10015935
jmp 0x100158e3
lea ecx, [ebp - 0x14]
call fcn.100154a0
movzx ecx, al
test ecx, ecx
jne 0x100158b9
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100198a3
mov esp, ebp
pop ebp
ret

Function at 0x10015a50
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov dword [ebp - 4], ecx
cmp dword [ebp + 0x10], 0
je 0x10015a67
mov eax, dword [ebp - 4]
cmp dword [eax], 0
jne 0x10015a6b
xor al, al
jmp 0x10015ad3
mov ecx, dword [ebp + 8]
push ecx
call fcn.10022f40
add esp, 4
test eax, eax
jne 0x10015a7f
xor al, al
jmp 0x10015ad3
lea edx, [ebp + 0x14]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov ecx, dword [ebp - 4]
call fcn.10015c30
movzx edx, al
test edx, edx
jne 0x10015a9e
xor al, al
jmp 0x10015ad3
lea eax, [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
lea edx, [ebp + 0xc]
push edx
push 0
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10015ac9
mov dword [ebp - 8], 1
jmp 0x10015ad0
mov dword [ebp - 8], 0
mov al, byte [ebp - 8]
mov esp, ebp
pop ebp
ret 0x10

Function at 0x10015ae0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov dword [ebp - 4], ecx
cmp dword [ebp + 0x10], 0
je 0x10015af7
mov eax, dword [ebp - 4]
cmp dword [eax], 0
jne 0x10015afb
xor al, al
jmp 0x10015b63
mov ecx, dword [ebp + 8]
push ecx
call fcn.10022f40
add esp, 4
test eax, eax
jne 0x10015b0f
xor al, al
jmp 0x10015b63
lea edx, [ebp + 0x14]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov ecx, dword [ebp - 4]
call fcn.10015b70
movzx edx, al
test edx, edx
jne 0x10015b2e
xor al, al
jmp 0x10015b63
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
push 0
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x10015b59
mov dword [ebp - 8], 1
jmp 0x10015b60
mov dword [ebp - 8], 0
mov al, byte [ebp - 8]
mov esp, ebp
pop ebp
ret 0x10
Function at 0x10016180
Capabilities:
Enumerate threads

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x1004b080]
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 0x1001628b
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_Thread32First]
test eax, eax
je 0x10016284
inc edi
cmp dword [ebp - 0x20], 0x10
jb 0x10016248
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [ebp - 0x14], eax
jne 0x10016248
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [ebp - 0x18], eax
je 0x10016248
mov edx, dword [esi]
test edx, edx
jne 0x10016211
push 0x200
push edx
push dword [0x1004d268]
mov dword [esi + 4], 0x80
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esi], edx
test edx, edx
je 0x1001626d
lea ebx, [esi + 8]
jmp 0x1001623b
mov eax, dword [esi + 4]
lea ebx, [esi + 8]
cmp dword [ebx], eax
jb 0x1001623b
add eax, eax
mov dword [esi + 4], eax
shl eax, 2
push eax
push edx
push 0
push dword [0x1004d268]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edx, eax
test edx, edx
je 0x1001629c
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 0x100161c9
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
je 0x10016284
xor edi, edi
cmp dword [esi], edi
je 0x10016284
push dword [esi]
push edi
push dword [0x1004d268]
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.100198a3
leave
ret
mov ebx, dword [ebp - 0x24]
jmp 0x1001626d

Function at 0x100162a1
Capabilities:
Suspend thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push edi
mov edi, ecx
mov dword [ebp - 8], edx
xor esi, esi
mov dword [edi], esi
mov dword [edi + 4], esi
mov dword [edi + 8], esi
call fcn.10016180
test eax, eax
jne 0x100162c5
push 9
pop esi
jmp 0x1001630c
cmp dword [edi], esi
je 0x1001630c
push ebx
mov ebx, esi
cmp dword [edi + 8], esi
jbe 0x1001630b
mov eax, dword [edi]
push dword [eax + ebx*4]
push esi
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov dword [ebp - 4], eax
test eax, eax
je 0x10016305
push eax
call dword [sym.imp.KERNEL32.dll_SuspendThread]
push dword [ebp + 8]
mov edx, dword [ebp - 8]
mov ecx, dword [ebp - 4]
call fcn.1001602b
pop ecx
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc ebx
cmp ebx, dword [edi + 8]
jb 0x100162d1
pop ebx
pop edi
mov eax, esi
pop esi
leave
ret
Function at 0x10016312
Capabilities:
Resume thread

Disassembly:
push esi
mov esi, ecx
cmp dword [esi], 0
je 0x1001635e
push edi
xor edi, edi
cmp dword [esi + 8], edi
jbe 0x1001634d
push ebx
mov eax, dword [esi]
push dword [eax + edi*4]
push 0
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov ebx, eax
test ebx, ebx
je 0x10016346
push ebx
call dword [sym.imp.KERNEL32.dll_ResumeThread]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc edi
cmp edi, dword [esi + 8]
jb 0x10016323
pop ebx
push dword [esi]
push 0
push dword [0x1004d268]
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
pop esi
ret

Function at 0x10016360
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 [0x1004d2f0]
mov dword [ebp - 8], esi
mov al, byte [esi + 0x14]
mov ebx, dword [esi]
and al, 1
je 0x10016386
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 0x100163ad
push 0xa
pop eax
jmp 0x1001642d
test edi, edi
je 0x100163ce
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 0x100163ed
mov eax, dword [esi]
mov word [eax], 0xf9eb
jmp 0x100163ed
test byte [esi + 0x14], 1
je 0x100163e2
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 0x100163ed
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 0x10016a56
Capabilities:
Allocate or change rwx memory

Disassembly:
mov edx, dword [0x1004d2ec]
push esi
xor esi, esi
jmp 0x10016a68
cmp dword [edx + 4], esi
jne 0x10016ab4
mov edx, dword [edx]
test edx, edx
jne 0x10016a61
push 0x40
push 0x3000
push 0x1000
push esi
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov edx, eax
test edx, edx
je 0x10016ac1
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 0x10016a8f
mov eax, dword [0x1004d2ec]
pop edi
mov dword [edx], eax
mov dword [0x1004d2ec], 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 0x10018346
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
push edi
mov edi, dword [ebp + 0xc]
test eax, eax
jg 0x10018367
jl 0x1001835e
test edi, edi
jne 0x10018367
xor eax, eax
xor edx, edx
jmp 0x10018428
cmp dword [ebx + 0x38], 0
je 0x1001837c
push eax
push edi
push dword [ebp + 8]
call fcn.1001842e
jmp 0x10018428
mov eax, dword [ebx + 0x1c]
push esi
mov esi, edi
mov ecx, dword [eax]
test ecx, ecx
je 0x100183c3
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
mov dword [ebp - 4], eax
test eax, eax
je 0x100183c3
cmp eax, edi
jb 0x1001839d
mov eax, edi
mov dword [ebp - 4], edi
push eax
push ecx
push dword [ebp + 8]
call fcn.1001b020
mov ecx, dword [ebp - 4]
add esp, 0xc
mov eax, dword [ebp + 8]
sub esi, ecx
add eax, ecx
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x2c]
sub dword [eax], ecx
mov eax, dword [ebx + 0x1c]
add dword [eax], ecx
jmp 0x100183c9
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
cmp dword [ebx + 0x4c], 0
je 0x1001841d
mov ecx, ebx
call fcn.10017bdc
mov ecx, dword [ebp - 4]
mov edx, esi
mov eax, 0xfff
cmp esi, eax
jbe 0x10018408
push dword [ebx + 0x4c]
push eax
push 1
push ecx
call fcn.1002414b
mov ecx, dword [ebp - 4]
sub esi, eax
add ecx, eax
add esp, 0x10
mov dword [ebp - 4], ecx
mov edx, esi
cmp eax, 0xfff
jne 0x1001841d
jmp 0x100183db
test edx, edx
je 0x1001841d
push dword [ebx + 0x4c]
push esi
push 1
push ecx
call fcn.1002414b
add esp, 0x10
sub esi, eax
mov edx, dword [ebp + 0x10]
sub edi, esi
mov eax, edi
sbb edx, 0
pop esi
pop edi
pop ebx
leave
ret 0xc
Function at 0x1001f016
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x1020
call fcn.1001abc0
mov eax, dword [0x1004b080]
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.10027722
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x1001f058
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x1001f1cf
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.10039da0
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 + 0x1004ce40]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.10027931
mov ecx, dword [esi*4 + 0x1004ce40]
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 0x1001f1c8
cmp eax, dword [edi + ecx + 0x24]
jne 0x1001f1c8
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 0x1001f1c8
push dword [ebp - 0x100c]
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10027931
add esp, 0x14
cmp edx, esi
jl 0x1001f1c8
jg 0x1001f123
cmp eax, esi
jb 0x1001f1c8
mov ebx, dword [ebp - 0x1014]
mov eax, dword [ebp - 0x101c]
cmp ebx, esi
jg 0x1001f1c8
jl 0x1001f145
cmp dword [ebp - 0x1008], eax
ja 0x1001f1c8
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 0x1001f16a
cmp ebx, esi
je 0x1001f1af
mov edx, dword [ebp - 0x1014]
mov esi, dword [ebp - 0x1018]
cmp ecx, edi
jae 0x1001f1af
mov al, byte [ecx]
cmp al, 0xd
jne 0x1001f190
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1001f19c
cmp byte [ecx + 1], 0xa
jne 0x1001f19c
inc ecx
jmp 0x1001f19c
movzx eax, al
movsx eax, byte [eax + 0x1004b310]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x1001f176
cmp edx, ebx
jne 0x1001f176
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x1020]
jmp 0x1001f1cd
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.100198a3
leave
ret
Function at 0x10022e04
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x1004b080]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
cmp eax, 0x1a
jbe 0x10022e47
call fcn.10025440
mov dword [eax], 0xf
call fcn.10025455
mov dword [eax], 0xd
call fcn.1002361a
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100198a3
leave
ret
test eax, eax
jne 0x10022e4e
inc eax
jmp 0x10022e3b
add eax, 0x40
push 0x3a
mov word [ebp - 0xc], ax
pop eax
mov word [ebp - 0xa], ax
push 0x5c
pop eax
mov word [ebp - 8], ax
xor eax, eax
mov word [ebp - 6], ax
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
mov ecx, eax
test ecx, ecx
je 0x10022e39
xor eax, eax
cmp ecx, 1
setne al
jmp 0x10022e3b

Function at 0x1002626e
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x100262ad
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x100262ad
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x100262ad
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x100262ad
cmp dword [ecx + 0x74], 0xe
jbe 0x100262ad
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x10029615
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 + 0x1004ce40]
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 0x10029657
cmp byte [ebx], 0xa
jne 0x10029657
or byte [edi + eax + 0x28], 4
jmp 0x1002965c
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1002975f
mov cl, byte [eax]
cmp cl, 0x1a
je 0x1002973a
lea ebx, [eax + 1]
mov dword [ebp - 8], ebx
mov ebx, dword [ebp + 0xc]
cmp cl, 0xd
je 0x1002968b
mov eax, dword [ebp - 8]
jmp 0x100296ab
mov edx, dword [ebp - 0x10]
cmp dword [ebp - 8], edx
mov edx, dword [ebp + 8]
jae 0x100296c7
mov ebx, dword [ebp - 8]
cmp byte [ebx], 0xa
jne 0x100296a5
add eax, 2
mov cl, 0xa
jmp 0x100296a8
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 0x1002966d
jmp 0x1002975f
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 0x10029735
cmp dword [ebp - 0x10], 0
je 0x10029735
mov edx, dword [ebp - 0x18]
mov eax, dword [edx*4 + 0x1004ce40]
test byte [eax + edi + 0x28], 0x48
je 0x10029714
mov cl, byte [ebp - 1]
cmp cl, 0xa
jne 0x10029704
mov byte [esi], 0xa
jmp 0x1002975e
mov byte [esi], 0xd
mov eax, dword [edx*4 + 0x1004ce40]
mov byte [eax + edi + 0x2a], cl
jmp 0x1002975e
cmp byte [ebp - 1], 0xa
jne 0x1002971e
cmp esi, ebx
je 0x100296ff
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1002794f
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1002975f
mov byte [esi], 0xd
jmp 0x1002975e
mov eax, edx
and edx, 0x3f
sar eax, 6
imul edx, edx, 0x38
mov edi, dword [eax*4 + 0x1004ce40]
mov al, byte [edi + edx + 0x28]
test al, 0x40
jne 0x1002975c
or al, 2
mov byte [edi + edx + 0x28], al
jmp 0x1002975f
mov byte [esi], cl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x10029768
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 8]
and eax, 0x3f
push ebx
mov ebx, dword [ebp + 0xc]
sar edx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [edx*4 + 0x1004ce40]
mov dword [ebp - 8], edx
mov edx, dword [eax + edi + 0x18]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp + 0x10]
test edx, edx
je 0x100297ac
push 0xa
pop esi
cmp word [ebx], si
jne 0x100297ac
or byte [eax + edi + 0x28], 4
jmp 0x100297b1
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + edx*2]
mov eax, ebx
mov dword [ebp - 0x10], edx
mov esi, ebx
cmp ebx, edx
jae 0x1002991c
movzx edx, word [eax]
mov ecx, edx
mov dword [ebp - 0xc], ecx
movzx ecx, cx
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 8]
cmp edx, 0x1a
je 0x100298f4
lea ebx, [eax + 2]
mov dword [ebp - 4], ebx
push 0xd
pop ebx
cmp dx, bx
mov ebx, dword [ebp + 0xc]
je 0x100297fe
mov ebx, dword [ebp - 0x14]
mov edx, esi
mov eax, dword [ebp - 4]
movzx ebx, bx
mov dword [ebp - 4], ebx
jmp 0x10029828
mov edx, dword [ebp - 4]
cmp edx, dword [ebp - 0x10]
jae 0x10029847
push 0xa
pop ebx
cmp word [edx], bx
jne 0x10029815
push ebx
add eax, 4
pop edx
jmp 0x1002981d
mov eax, edx
mov edx, dword [ebp - 0xc]
movzx edx, dx
movzx edx, dx
mov dword [ebp - 4], edx
mov edx, esi
mov dword [ebp - 0x14], esi
mov ecx, dword [ebp - 4]
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0xc], 2
mov word [esi], cx
mov esi, dword [ebp - 0xc]
add esi, edx
cmp eax, dword [ebp - 0x10]
jb 0x100297c3
jmp 0x1002991c
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x100298ef
cmp dword [ebp - 0x14], 0
je 0x100298ef
mov eax, dword [ebp - 8]
push 0xa
mov eax, dword [eax*4 + 0x1004ce40]
test byte [eax + edi + 0x28], 0x48
pop eax
je 0x100298cb
mov dx, word [ebp - 4]
cmp dx, ax
jne 0x10029893
mov word [esi], ax
jmp 0x10029919
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebp - 8]
movzx ecx, dx
shr ecx, 8
push 0xa
mov eax, dword [eax*4 + 0x1004ce40]
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x1004ce40]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x1004ce40]
pop ecx
mov byte [eax + edi + 0x2c], cl
jmp 0x10029919
cmp word [ebp - 4], ax
jne 0x100298d5
cmp esi, ebx
je 0x1002988b
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.1002794f
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x1002991c
push 0xd
pop eax
jmp 0x1002988b
mov eax, ecx
and ecx, 0x3f
sar eax, 6
imul ecx, ecx, 0x38
mov edi, dword [eax*4 + 0x1004ce40]
mov al, byte [edi + ecx + 0x28]
test al, 0x40
jne 0x10029916
or al, 2
mov byte [edi + ecx + 0x28], al
jmp 0x1002991c
mov word [esi], dx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1002ebeb
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 0x1002ec05
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 0x1002ec1c
mov ecx, dword [eax]
cmp ecx, dword [eax + 4]
je 0x1002ec74
mov eax, dword [eax + 0x10]
nop
push eax
call fcn.10031f23
mov esi, eax
pop ecx
cmp esi, 0xffffffff
je 0x1002ec74
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 0x1002ec74
lea eax, [ebp - 0x18]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x1002ec74
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x18]
jne 0x1002ec6e
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x14]
je 0x1002ec70
xor bl, bl
mov al, bl
jmp 0x1002ec76
xor al, al
pop esi
pop ebx
leave
ret