joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10001140
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100152b0
push 0x10013a9b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
add esp, 0xffffffcc
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
push 0x1c
lea eax, [ebp - 0x34]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x30]
mov dword [ebp - 0x38], edx
mov eax, dword [ebp - 0x38]
xor ecx, ecx
mov cx, word [eax]
cmp ecx, 0x5a4d
je 0x100011a6
mov byte [ebp - 0x3d], 0
mov dword [ebp - 4], 0xffffffff
mov al, byte [ebp - 0x3d]
jmp 0x1000122f
mov edx, dword [ebp - 0x38]
mov eax, dword [ebp - 0x38]
add eax, dword [edx + 0x3c]
mov dword [ebp - 0x3c], eax
mov ecx, dword [ebp - 0x3c]
cmp dword [ecx], 0x4550
je 0x100011cd
mov byte [ebp - 0x3e], 0
mov dword [ebp - 4], 0xffffffff
mov al, byte [ebp - 0x3e]
jmp 0x1000122f
mov edx, dword [ebp - 0x3c]
mov eax, dword [ebp - 0x38]
add eax, dword [edx + 0xd8]
cmp dword [ebp + 0xc], eax
jb 0x10001208
mov ecx, dword [ebp - 0x3c]
mov edx, dword [ebp - 0x38]
add edx, dword [ecx + 0xd8]
mov eax, dword [ebp - 0x3c]
add edx, dword [eax + 0xdc]
cmp dword [ebp + 0xc], edx
jae 0x10001208
mov byte [ebp - 0x3f], 1
mov dword [ebp - 4], 0xffffffff
mov al, byte [ebp - 0x3f]
jmp 0x1000122f
mov byte [ebp - 0x40], 0
mov dword [ebp - 4], 0xffffffff
mov al, byte [ebp - 0x40]
jmp 0x1000122f
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x100012d0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [0x1001b3c0]
mov dword [ebp - 4], eax
jmp 0x100012e9
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 4]
mov dword [ebp - 4], edx
cmp dword [ebp - 4], 0
je 0x10001306
lea eax, [ebp - 8]
push eax
push 0x40
push 0x10000
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
jmp 0x100012e0
mov esp, ebp
pop ebp
ret
Function at 0x10001310
Capabilities:
Resume thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [0x1001b3d0], eax
je 0x1000132e
mov eax, 0x10dd
jmp 0x10001410
mov eax, dword [0x1001b3e0]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x100013ad
lea ecx, [ebp - 0xc]
push ecx
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x14]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x10]
xor eax, eax
mov al, byte [edx + 0x36]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov eax, dword [ebp - 8]
cmp dword [eax + 4], 0
jne 0x1000138b
mov ecx, dword [ebp - 8]
cmp dword [ecx + 0x10], 0
je 0x1000138b
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x10]
push eax
call fcn.10001480
add esp, 4
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x10], 0
mov edx, dword [ebp - 8]
mov eax, dword [edx]
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 8]
mov dword [ebp - 0x18], ecx
mov edx, dword [ebp - 0x18]
push edx
call fcn.100135a0
add esp, 4
mov eax, dword [ebp - 0x10]
mov dword [ebp - 8], eax
jmp 0x10001336
mov dword [0x1001b3e0], 0
call fcn.10001420
mov ecx, dword [0x1001b3dc]
mov dword [ebp - 4], ecx
cmp dword [ebp - 4], 0
je 0x100013fa
mov edx, dword [ebp - 4]
mov eax, dword [edx + 4]
push eax
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 4]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.100135a0
add esp, 4
mov edx, dword [ebp - 0x14]
mov dword [ebp - 4], edx
jmp 0x100013c5
mov dword [0x1001b3dc], 0
mov dword [0x1001b3d0], 0
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x10001980
Capabilities:
Hook routines via microsoft detours

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 8]
cmp dword [eax], 0x52727464
je 0x10001995
xor eax, eax
jmp 0x10001a0a
mov ecx, dword [ebp + 8]
mov dword [ebp - 8], ecx
mov edx, dword [ebp - 8]
add edx, 0x10000
mov dword [ebp - 4], edx
mov eax, dword [ebp + 8]
add eax, 0x48
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], 0
jmp 0x100019c2
mov ecx, dword [ebp - 0xc]
add ecx, 1
mov dword [ebp - 0xc], ecx
cmp dword [ebp - 0xc], 0x38d
jae 0x10001a05
mov edx, dword [ebp - 0xc]
imul edx, edx, 0x48
mov eax, dword [ebp - 0x10]
cmp dword [eax + edx + 0x40], 0
je 0x10001a03
mov ecx, dword [ebp - 0xc]
imul ecx, ecx, 0x48
mov edx, dword [ebp - 0x10]
mov eax, dword [edx + ecx + 0x40]
cmp eax, dword [ebp - 8]
jb 0x100019ff
mov ecx, dword [ebp - 0xc]
imul ecx, ecx, 0x48
mov edx, dword [ebp - 0x10]
mov eax, dword [edx + ecx + 0x40]
cmp eax, dword [ebp - 4]
jb 0x10001a03
xor eax, eax
jmp 0x10001a0a
jmp 0x100019b9
mov eax, 1
mov esp, ebp
pop ebp
ret

Function at 0x10001ac0
Capabilities:
Suspend thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
cmp dword [0x1001b3d4], 0
je 0x10001ad9
mov eax, dword [0x1001b3d4]
jmp 0x10001b79
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
cmp dword [ebp + 8], eax
jne 0x10001aeb
xor eax, eax
jmp 0x10001b79
push 8
call fcn.10012bad
add esp, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x10001b41
mov dword [ebp - 8], 8
cmp dword [ebp - 4], 0
je 0x10001b2a
mov ecx, dword [ebp - 4]
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp - 0x10]
push edx
call fcn.100135a0
add esp, 4
mov dword [ebp - 4], 0
mov eax, dword [ebp - 8]
mov dword [0x1001b3d4], eax
mov dword [0x1001b3d8], 0
mov eax, dword [ebp - 8]
jmp 0x10001b79
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_SuspendThread]
cmp eax, 0xffffffff
jne 0x10001b5b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 8], eax
jmp 0x10001b0b
mov edx, dword [ebp - 4]
mov eax, dword [ebp + 8]
mov dword [edx + 4], eax
mov ecx, dword [ebp - 4]
mov edx, dword [0x1001b3dc]
mov dword [ecx], edx
mov eax, dword [ebp - 4]
mov dword [0x1001b3dc], eax
xor eax, eax
mov esp, ebp
pop ebp
ret 4
Function at 0x1000a640
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1001420c
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x1001b010]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x14], ecx
push 0x3c
call fcn.10012bad
mov esi, eax
add esp, 4
mov dword [ebp - 0x10], esi
mov edi, dword [ebp + 0xc]
mov ecx, esi
push 0
push 0
mov dword [ebp - 4], 0
mov ebx, dword [ebp + 0x10]
push ebx
push edi
call fcn.10009f20
mov byte [ebp - 4], 1
mov dword [esi], vtable.Buttons.0
add esi, 0x28
mov dword [ebp + 0x10], esi
push 0x18
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.10012bad
add esp, 4
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [esi], eax
mov esi, dword [ebp - 0x10]
mov dword [ebp - 4], 0xffffffff
mov dword [ebp + 0x10], esi
mov dword [esi + 8], ebx
mov ebx, dword [ebp - 0x14]
mov dword [esi + 0x30], 1
mov dword [esi + 0x34], 0
mov byte [esi + 0x38], 0
mov dword [esi + 4], edi
mov eax, dword [ebx + 0x2c]
cmp eax, dword [ebx + 0x30]
je 0x1000a703
mov dword [eax], esi
add dword [ebx + 0x2c], 4
jmp 0x1000a710
lea ecx, [ebp + 0x10]
push ecx
push eax
lea ecx, [ebx + 0x28]
call fcn.10009dc0
mov dword [esi + 0x1c], ebx
cmp dword [ebx + 0x3c], 0
jne 0x1000a726
cmp byte [esi + 0x1a], 0
je 0x1000a726
mov dword [ebx + 0x3c], esi
mov byte [esi + 0x1b], 1
mov esi, dword [ebx + 0x2c]
lea eax, [ebp + 8]
sub esi, dword [ebx + 0x28]
lea ecx, [ebx + 0x34]
push eax
sar esi, 2
call fcn.10005c90
lea ecx, [esi - 1]
mov dword [eax], ecx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x1000b670
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
mov dword [0x1001b78c], 0x4f0f30
call fcn.10001240
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push eax
call fcn.10001ac0
push 0x1000b870
push 0x1001b78c
call fcn.10001b80
call fcn.100014c0
mov esi, dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea eax, [ebp - 4]
push eax
push 0x40
push 5
push 0x50446f
call esi
mov eax, 0x1000ba80
mov byte [0x50446f], 0xe9
sub eax, 0x504474
mov dword [0x504470], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x50446f
call esi
lea eax, [ebp - 4]
mov dword [0x1001b798], 0x504474
push eax
push 0x40
push 5
push 0x40e0ee
call esi
mov eax, 0x1000bc10
mov byte [0x40e0ee], 0xe9
sub eax, 0x40e0f3
mov dword [0x40e0ef], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x40e0ee
call esi
lea eax, [ebp - 4]
mov dword [0x1001b790], 0x40e0f3
push eax
push 0x40
push 5
push 0x40e3b6
call esi
mov eax, 0x1000bc30
mov byte [0x40e3b6], 0xe9
sub eax, 0x40e3bb
mov dword [0x40e3b7], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x40e3b6
call esi
lea eax, [ebp - 4]
mov dword [0x1001b7ac], 0x40e3bb
push eax
push 0x40
push 5
push 0x41101c
call esi
mov eax, 0x1000bc50
mov byte [0x41101c], 0xe9
sub eax, 0x411021
mov dword [0x41101d], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x41101c
call esi
lea eax, [ebp - 4]
mov dword [0x1001b7a0], 0x411021
push eax
push 0x40
push 5
push 0x40e193
call esi
mov eax, 0x1000bc00
mov byte [0x40e193], 0xe9
sub eax, 0x40e198
mov dword [0x40e194], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x40e193
call esi
lea eax, [ebp - 4]
mov dword [0x1001b784], 0x40e198
push eax
push 0x40
push 5
push 0x40e062
call esi
mov eax, 0x1000bbf0
mov byte [0x40e062], 0xe9
sub eax, 0x40e067
mov dword [0x40e063], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x40e062
call esi
lea eax, [ebp - 4]
mov dword [0x1001b7a4], 0x40e067
push eax
push 0x40
push 5
push 0x4110b2
call esi
mov eax, 0x1000bc60
mov byte [0x4110b2], 0xe9
sub eax, 0x4110b7
mov dword [0x4110b3], eax
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push 5
push 0x4110b2
call esi
mov dword [0x1001b780], 0x4110b9
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x1000e190
Capabilities:
Encode data using xor
Encrypt data using xtea
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x1001b010]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov dword [ebp - 0x28], ebx
mov eax, dword [ebx + 8]
mov ecx, dword [ebx + 0xc]
cmp eax, 1
jne 0x1000e1bc
mov ax, word [ebx]
mov word [ecx + 2], ax
jmp 0x1000e1da
cmp eax, 2
jne 0x1000e1d4
mov dword [ecx + 2], 0xc1e7cae
mov ecx, dword [ebx + 0xc]
mov ax, word [ebx]
mov word [ecx + 6], ax
jmp 0x1000e1da
mov ax, word [ebx]
mov word [ecx], ax
mov eax, dword [0x7998bc]
xor edx, edx
cmp dword [ebx + 8], 2
mov esi, dword [ebx]
sete dl
mov dword [ebp - 0x14], eax
mov eax, dword [0x7998c0]
mov dword [ebp - 0x10], eax
mov eax, dword [0x7998c4]
lea edx, [edx*4 + 2]
mov dword [ebp - 0xc], eax
mov eax, dword [0x7998c8]
add esi, edx
mov ecx, esi
mov dword [ebp - 8], eax
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x1c], esi
and ecx, 0x80000007
jns 0x1000e225
dec ecx
or ecx, 0xfffffff8
add ecx, 1
je 0x1000e233
mov eax, 8
sub eax, ecx
add esi, eax
mov dword [ebp - 0x1c], esi
mov ecx, dword [ebx + 0xc]
mov eax, esi
add ecx, edx
cdq
and edx, 3
mov dword [ebp - 0x20], ecx
add eax, edx
sar eax, 2
mov dword [ebp - 0x24], eax
test eax, eax
jle 0x1000e2c1
xor ebx, ebx
push edi
mov esi, dword [ecx + ebx*4]
xor eax, eax
mov edi, dword [ecx + ebx*4 + 4]
mov dword [ebp - 0x18], 0x20
mov edx, edi
mov ecx, edi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
and ecx, 3
add edx, edi
mov ecx, dword [ebp + ecx*4 - 0x14]
add ecx, eax
sub eax, 0x61c88647
xor edx, ecx
add esi, edx
mov edx, esi
mov ecx, esi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
shr ecx, 0xb
add edx, esi
and ecx, 3
mov ecx, dword [ebp + ecx*4 - 0x14]
add ecx, eax
xor edx, ecx
add edi, edx
sub dword [ebp - 0x18], 1
jne 0x1000e260
mov ecx, dword [ebp - 0x20]
mov dword [ecx + ebx*4], esi
mov dword [ecx + ebx*4 + 4], edi
add ebx, 2
cmp ebx, dword [ebp - 0x24]
jl 0x1000e250
mov ebx, dword [ebp - 0x28]
mov esi, dword [ebp - 0x1c]
pop edi
mov eax, dword [ebx + 0xc]
mov ecx, dword [ebp - 0x2c]
add ecx, 0xfffffffe
add ecx, esi
mov word [eax], cx
mov ecx, dword [ebx + 0xc]
mov dword [ebx], esi
push 0
movzx eax, word [ecx]
add eax, 2
push eax
push ecx
push dword [0x1001b060]
call dword [sym.imp.WS2_32.dll_send]
push dword [ebx + 0xc]
call fcn.10013116
push 0x10
push ebx
call fcn.10012bdd
mov ecx, dword [ebp - 4]
add esp, 0xc
xor ecx, ebp
pop esi
pop ebx
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
Function at 0x1000e6d0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x15c
mov eax, dword [0x1001b010]
xor eax, esp
mov dword [esp + 0x158], eax
cmp dword [ebp + 0xc], 1
push ebx
push esi
push edi
jne 0x1000e7ea
push 0x104
lea eax, [esp + 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
movaps xmm0, xmmword [0x10017340]
lea ecx, [esp + 0x28]
movups xmmword [esp + 0x28], xmm0
lea eax, [esp + 0x58]
sub esp, 0xc
movaps xmm0, xmmword [0x10017460]
sub eax, ecx
movups xmmword [esp + 0x44], xmm0
mov edi, esp
mov ebx, eax
movaps xmm0, xmmword [str.p]
movups xmmword [esp + 0x54], xmm0
sar ebx, 2
mov dword [edi], 0
mov dword [edi + 4], 0
mov dword [edi + 8], 0
mov dword [esp + 0x18], eax
test ebx, ebx
je 0x1000e77d
push ebx
mov ecx, edi
call fcn.10005c00
push dword [esp + 0x18]
mov esi, dword [edi]
lea eax, [esp + 0x38]
push eax
push esi
call sub.VCRUNTIME140.dll_memmove
lea eax, [esi + ebx*4]
add esp, 0xc
mov dword [edi + 4], eax
lea ecx, [esp + 0x1c]
call fcn.1000fd60
add esp, 0xc
cmp dword [eax + 0x14], 0x10
jb 0x1000e791
mov eax, dword [eax]
push eax
lea eax, [esp + 0x5c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
mov ecx, dword [esp + 0x24]
cmp ecx, 0x10
jb 0x1000e7d5
mov edx, dword [esp + 0x10]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x1000e7cb
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1000e7cb
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.10012bdd
add esp, 8
lea eax, [esp + 0x58]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [0x1001b7bc], eax
call fcn.1000e310
mov ecx, dword [esp + 0x164]
mov eax, 1
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 0xc
Function at 0x100120f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
mov ebx, ecx
push esi
push edi
cmp dword [ebx + 0x38], 0
je 0x1001211c
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const___long_long___int64__]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x20]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x20], esi
mov ecx, dword [eax]
lea eax, [ebx + 0x30]
mov dword [esp + 0x24], edi
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
test ecx, ecx
je 0x10012144
mov eax, dword [eax]
mov ecx, dword [eax]
jmp 0x1001214a
xor ecx, ecx
mov dword [esp + 0x18], eax
mov eax, ecx
cdq
mov dword [esp + 0x10], eax
mov ecx, edx
mov dword [esp + 0x14], ecx
test edi, edi
jl 0x100121b2
jg 0x10012161
test esi, esi
je 0x100121b2
test ecx, ecx
jl 0x100121ad
jg 0x1001216b
test eax, eax
je 0x100121ad
cmp edi, ecx
jg 0x1001217f
jl 0x10012175
cmp esi, eax
jae 0x1001217f
mov eax, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
push eax
push dword [ebp + 8]
push dword [esp + 0x24]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [esp + 0x24]
add esp, 0xc
mov edx, dword [esp + 0x10]
mov ecx, dword [ebp + 8]
add ecx, edx
sub esi, edx
mov eax, dword [eax]
sbb edi, dword [esp + 0x14]
sub dword [eax], edx
mov eax, dword [ebx + 0x20]
add dword [eax], edx
jmp 0x100121b5
mov ecx, dword [ebp + 8]
jmp 0x100121bf
mov ecx, dword [ebp + 8]
test edi, edi
jl 0x100121d9
jg 0x100121bf
test esi, esi
je 0x100121d9
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x100121d9
push eax
push esi
push 1
push ecx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
sub esi, eax
sbb edi, 0
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub eax, esi
sbb edx, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x100121f0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x10]
sub esp, 8
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
test eax, eax
jg 0x10012214
jl 0x10012209
test ecx, ecx
jne 0x10012214
xor eax, eax
xor edx, edx
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x1001222e
push eax
push ecx
push dword [ebp + 8]
mov ecx, ebx
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char___long_long___int64__]
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
push esi
push edi
mov edi, ecx
mov eax, dword [eax]
mov dword [ebp - 8], eax
test eax, eax
je 0x1001227a
mov eax, dword [ebx + 0x2c]
lea edx, [ebx + 0x2c]
mov dword [ebp - 4], edx
mov eax, dword [eax]
test eax, eax
je 0x10012280
mov edi, dword [ebp + 8]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push dword [ebp - 8]
push edi
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [ebp + 8], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
jmp 0x10012280
lea eax, [ebx + 0x2c]
mov dword [ebp - 4], eax
cmp dword [ebx + 0x4c], 0
mov esi, dword [ebp + 8]
je 0x100122f6
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x100122ac
mov eax, dword [ebx + 0xc]
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [ebp - 4]
mov eax, dword [eax]
mov dword [eax], edx
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp edi, 0xfff
jbe 0x100122e4
nop dword [eax]
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call eax
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x100122f6
cmp edi, eax
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
ja 0x100122c0
test edi, edi
je 0x100122f6
push dword [ebx + 0x4c]
push edi
push 1
push esi
call eax
add esp, 0x10
sub edi, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x10012660
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x1001b010]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x10012690
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
mov eax, dword [eax]
test eax, eax
je 0x100126c0
mov edx, dword [esi + 0x30]
mov edx, dword [edx]
add edx, eax
cmp eax, edx
jae 0x100126c0
call dword [sym.imp.MSVCP140.dll_protected:_char____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void_]
pop esi
mov byte [eax], bl
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
push edi
je 0x10012798
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x100126e9
mov edx, dword [esi + 0x54]
mov ecx, dword [esi + 0x50]
sub edx, ecx
mov dword [edi], ecx
mov eax, dword [esi + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi + 0x2c]
mov dword [eax], edx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x100126f5
movsx eax, bl
jmp 0x1001272d
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x25], bl
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x25]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet___char_const___char_const___char_const____char___char___char___const]
sub eax, 0
je 0x10012757
sub eax, 1
je 0x10012757
sub eax, 2
jne 0x10012798
movsx eax, byte [ebp - 0x25]
push dword [esi + 0x4c]
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x10012775
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x10012798
lea ecx, [ebp - 0x25]
mov byte [esi + 0x3d], 1
or eax, 0xffffffff
cmp dword [ebp - 0x30], ecx
pop edi
pop esi
cmovne eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10012b9f
mov esp, ebp
pop ebp
ret 4
Function at 0x10012940
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x1001b010]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x100129fc
cmp byte [esi + 0x3d], 0
je 0x100129fc
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x100129ea
mov ecx, dword [esi + 0x38]
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet___char___char___char___const]
sub eax, 0
je 0x100129b1
sub eax, 1
je 0x100129b5
sub eax, 2
jne 0x100129ea
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x100129d3
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x100129ea
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10012b9f
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.10012b9f
mov esp, ebp
pop ebp
ret
Function at 0x1000f433
Capabilities:
Parse pe header

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