joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1001cfc0
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1005e430
mov eax, dword fs:[0]
push eax
mov eax, dword [0x1007a058]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ecx + 8], 0xffffffff
mov dword [ecx + 4], 0xffffffff
mov dword [ecx + 0xc], 0
mov dword [ecx + 0x20], 0
mov dword [ecx + 0x30], 0
mov eax, ecx
mov dword [ecx + 0x34], 0xf
mov dword [ecx + 0x10], 0
mov dword [ecx + 0x14], 3
mov dword [ecx + 0x18], 0
mov dword [ecx + 0x1c], 0
mov dword [ecx + 0x38], 0
mov dword [ecx + 0x3c], 0
mov dword [ecx], vtable.TiXmlUnknown.0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov esp, ebp
pop ebp
ret

Function at 0x1002e464
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.10020db0
mov eax, dword [0x1007a058]
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.10035d4a
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x1002e4a6
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x1002e602
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.10044d50
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x1007e1b8]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.10039f4d
mov ecx, dword [esi*4 + 0x1007e1b8]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x1002e5fb
cmp eax, dword [edi + ecx + 0x24]
jne 0x1002e5fb
push 0
lea eax, [ebp - 0x1014]
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 0x1002e5fb
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10039f4d
add esp, 0x14
test edx, edx
jl 0x1002e5fb
jg 0x1002e571
test eax, eax
jb 0x1002e5fb
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x1002e5fb
jl 0x1002e58b
cmp dword [ebp - 0x1008], eax
ja 0x1002e5fb
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x1002e5a9
test ebx, ebx
je 0x1002e5e2
cmp ecx, edi
jae 0x1002e5e2
mov al, byte [ecx]
cmp al, 0xd
jne 0x1002e5c3
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1002e5cf
cmp byte [ecx + 1], 0xa
jne 0x1002e5cf
inc ecx
jmp 0x1002e5cf
movzx eax, al
movsx eax, byte [eax + 0x1007a488]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x1002e5a9
cmp edx, ebx
jne 0x1002e5a9
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x1002e600
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.1001fac4
leave
ret
Function at 0x10036521
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10065e44
push 0x10065e3c
push str.FlsAlloc
push 0x1e
call fcn.1003634e
mov esi, eax
add esp, 0x10
test esi, esi
je 0x10036555
push dword [ebp + 8]
mov ecx, esi
call dword [0x10061204]
call esi
jmp 0x1003655b
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1003659f
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10065e54
push 0x10065e4c
push str.FlsGetValue
push 0x20
call fcn.1003634e
mov esi, eax
add esp, 0x10
test esi, esi
je 0x100365d6
push dword [ebp + 8]
mov ecx, esi
call dword [0x10061204]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x100384c4
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.10038335

Function at 0x100393eb
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x1007e1b8]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1003942b
cmp byte [ebx], 0xa
jne 0x1003942b
or byte [eax + edi + 0x28], 4
jmp 0x10039430
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1003952e
mov al, byte [edx]
cmp al, 0x1a
je 0x10039510
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x1003945f
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x10039484
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x1003948e
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x10039441
jmp 0x1003952e
push 0
lea eax, [ebp - 0xc]
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 0x1003950b
cmp dword [ebp - 0xc], 0
je 0x1003950b
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x1007e1b8]
test byte [eax + edi + 0x28], 0x48
je 0x100394e5
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x100394d0
mov byte [esi], dl
jmp 0x100394e1
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x1007e1b8]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x1003952e
cmp byte [ebp - 1], 0xa
jne 0x100394f4
cmp esi, ebx
jne 0x100394f4
mov byte [esi], 0xa
jmp 0x1003952d
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.10039f6b
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1003952e
mov byte [esi], 0xd
jmp 0x1003952d
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x1007e1b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003952a
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1003952e
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x10039537
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x1007e1b8]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1003957a
cmp word [esi], dx
jne 0x1003957a
or byte [edi + eax + 0x28], 4
jmp 0x1003957f
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x100396d2
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x100396b2
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x100395c1
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x100395f7
cmp eax, edx
jae 0x10039603
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x10039599
jmp 0x100396d2
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 0x100396ae
cmp dword [ebp - 0x14], 0
je 0x100396ae
mov eax, dword [ebx*4 + 0x1007e1b8]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x10039686
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x1003964f
mov word [esi], cx
jmp 0x10039682
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x1007e1b8]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x1007e1b8]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x1007e1b8]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x100396d2
pop ebx
cmp word [ebp - 4], bx
jne 0x10039697
cmp esi, dword [ebp + 0xc]
jne 0x10039697
mov word [esi], bx
jmp 0x100396cf
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.10039f6b
add esp, 0x10
cmp word [ebp - 4], bx
je 0x100396d2
push 0xd
jmp 0x100396cb
mov ecx, dword [ebx*4 + 0x1007e1b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x100396c9
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x100396d2
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1003ce23
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x1003cec0
push ebx
push esi
call fcn.1003cdec
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.1003827e
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1003ce6d
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003cebf
push edi
push eax
call fcn.10034f15
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1003ce8d
call fcn.10032365
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003cebe
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.1003827e
add esp, 0x20
test eax, eax
jne 0x1003ceac
push edi
call fcn.10032365
jmp 0x1003ceb4
push ebx
call fcn.10032365
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x1003cec3
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x1003ced4
pop esi
ret
push ebx
push edi
push esi
call fcn.1003cdec
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.10034f15
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x1003cefc
push ebx
push esi
push edi
call fcn.10021610
add esp, 0xc
push 0
call fcn.10032365
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x1003d2c0
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.1003cf11
Function at 0x10043fa1
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10043f1d
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10044119
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10044119
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x100440c8
jg 0x10043ffa
test eax, eax
je 0x100440be
push 1
push 0x1000
call fcn.100340b8
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x10044020
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x100440b5
push 0x8000
push ebx
call fcn.10043e4e
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x1004404c
jg 0x10044047
cmp ecx, 0x1000
jb 0x1004404c
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.10037dbe
add esp, 0x10
cmp eax, 0xffffffff
je 0x10044091
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x10044047
jl 0x10044078
test ecx, ecx
jne 0x10044039
push dword [ebp - 0xc]
push ebx
call fcn.10043e4e
push esi
call fcn.10032365
add esp, 0xc
xor edi, edi
jmp 0x1004412a
cmp byte [edi + 0x24], 0
je 0x100440a8
cmp dword [edi + 0x20], 5
jne 0x100440a8
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x100440b3
mov edi, dword [edi + 0x18]
jmp 0x100440b5
xor edi, edi
push esi
call fcn.10032365
pop ecx
jmp 0x1004412a
test ecx, ecx
jg 0x1004408a
jl 0x100440c8
test eax, eax
jae 0x1004408a
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10039f6b
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x100440eb
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x1004408a
jmp 0x10044122
push ebx
call fcn.10041aff
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x1004408a
mov esi, dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [esi + 0x24], 1
mov dword [esi + 0x20], eax
pop edi
mov byte [esi + 0x1c], 1
mov dword [esi + 0x18], edi
jmp 0x1004412a
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x10044127
mov edi, dword [edi + 0x18]
jmp 0x1004412a
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.10039f6b
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x10044c30
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x10044c5d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x10044c5d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x100478f0
Capabilities:
Hash data using fnv

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1005eabc
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x1007a058]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x14], ecx
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x10]
mov esi, dword [sym.imp.USER32.dll_GetRawInputData]
push 0x10
push eax
push 0
push 0x10000003
push edi
call esi
push dword [ebp - 0x10]
call fcn.10020175
mov ebx, eax
add esp, 4
mov dword [ebp + 8], ebx
push 0x10
lea eax, [ebp - 0x10]
mov dword [ebp - 4], 0
push eax
push ebx
push 0x10000003
push edi
call esi
movzx eax, byte [ebx + 8]
lea edx, [ebx + 8]
xor eax, 0x811c9dc5
mov edi, dword [ebp - 0x14]
imul ecx, eax, 0x1000193
movzx eax, byte [edx + 1]
xor ecx, eax
movzx eax, byte [edx + 2]
imul ecx, ecx, 0x1000193
xor ecx, eax
movzx eax, byte [edx + 3]
imul ecx, ecx, 0x1000193
xor ecx, eax
imul eax, ecx, 0x1000193
lea ecx, [edi + 0x44]
push eax
push edx
lea eax, [ebp - 0x20]
push eax
call fcn.1000c9d0
mov esi, dword [eax + 4]
test esi, esi
je 0x10047a60
lea eax, [edi + 0x48]
lea ecx, [edi + 0x48]
cmove ecx, eax
cmp esi, dword [ecx]
je 0x10047a60
push 0
push 0x1007af84
push 0x1007b854
mov byte [ebp - 4], 1
push 0
push dword [esi + 0xc]
call fcn.1005bfcc
mov ecx, eax
add esp, 0x14
test ecx, ecx
je 0x100479f0
mov eax, dword [esi + 0x10]
test eax, eax
je 0x100479eb
lock inc dword [eax + 4]
mov esi, dword [esi + 0x10]
jmp 0x100479fc
xorps xmm0, xmm0
xor ecx, ecx
movlpd qword [ebp - 0x18], xmm0
xor esi, esi
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x18], ecx
mov byte [ebp - 4], 2
test ecx, ecx
je 0x10047a3b
mov eax, dword [ecx]
push ebx
mov eax, dword [eax + 8]
call eax
mov bl, al
test esi, esi
je 0x10047a62
or edi, 0xffffffff
mov eax, edi
lock xadd dword [esi + 4], eax
jne 0x10047a62
mov eax, dword [esi]
mov ecx, esi
call dword [eax]
lock xadd dword [esi + 8], edi
dec edi
jne 0x10047a62
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 4]
jmp 0x10047a62
test esi, esi
je 0x10047a60
or edi, 0xffffffff
mov eax, edi
lock xadd dword [esi + 4], eax
jne 0x10047a60
mov eax, dword [esi]
mov ecx, esi
call dword [eax]
lock xadd dword [esi + 8], edi
dec edi
jne 0x10047a60
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 4]
xor bl, bl
push dword [ebp + 8]
call fcn.1001fad2
add esp, 4
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x10055840
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push ebp
push esi
mov esi, ecx
push edi
test ebx, ebx
jne 0x1005587c
cmp byte [esi + 0x40], bl
jne 0x10055961
mov edx, dword [str.Failed_to_open_file]
mov ecx, edx
mov byte [esi + 0x40], 1
mov dword [esi + 0x44], 2
lea edi, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10055870
jmp 0x10055947
mov edi, dword [esi + 0x18]
test edi, edi
je 0x10055892
mov ecx, edi
mov edi, dword [edi + 0x3c]
push 1
mov eax, dword [ecx]
call dword [eax]
test edi, edi
jne 0x10055883
push 2
push 0
push ebx
mov dword [esi + 0x18], 0
mov dword [esi + 0x1c], 0
mov dword [esi + 8], 0xffffffff
mov dword [esi + 4], 0xffffffff
call fcn.1002df89
push ebx
call fcn.1002e6a1
push 0
push 0
push ebx
mov ebp, eax
call fcn.1002df89
add esp, 0x1c
test ebp, ebp
jg 0x100558fa
cmp byte [esi + 0x40], 0
jne 0x10055961
mov edx, dword [str.Error_document_empty.]
mov ecx, edx
mov byte [esi + 0x40], 1
mov dword [esi + 0x44], 0xc
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x100558f1
jmp 0x10055947
lea eax, [ebp + 1]
push eax
call fcn.10020175
push ebx
mov edi, eax
push 1
push ebp
push edi
mov byte [edi], 0
call fcn.1002dbba
add esp, 0x14
cmp eax, 1
je 0x1005596a
push edi
call fcn.1001fad2
add esp, 4
cmp byte [esi + 0x40], 0
jne 0x10055961
mov edx, dword [str.Failed_to_open_file]
mov ecx, edx
mov byte [esi + 0x40], 1
mov dword [esi + 0x44], 2
lea edi, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10055940
sub ecx, edi
push ecx
push edx
lea ecx, [esi + 0x48]
call fcn.10002f50
mov dword [esi + 0x64], 0xffffffff
mov dword [esi + 0x68], 0xffffffff
pop edi
pop esi
pop ebp
xor al, al
pop ebx
ret 8
mov byte [edi + ebp], 0
mov eax, edi
mov dl, byte [edi]
mov ecx, edi
test dl, dl
je 0x10055996
inc eax
lea ebx, [ecx + 1]
cmp dl, 0xd
jne 0x1005598c
mov byte [ecx], 0xa
cmp byte [eax], 0xa
jne 0x1005598e
inc eax
jmp 0x1005598e
mov byte [ecx], dl
mov dl, byte [eax]
mov ecx, ebx
test dl, dl
jne 0x10055978
mov byte [ecx], 0
mov ecx, esi
mov eax, dword [esi]
push 0
push 0
push edi
call dword [eax + 8]
push edi
call fcn.1001fad2
add esp, 4
cmp byte [esi + 0x40], 0
sete al
pop edi
pop esi
pop ebp
pop ebx
ret 8
Function at 0x10056d10
Capabilities:
Access peb ldr_data
Check for peb ntglobalflag flag

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1005fe30
mov eax, dword fs:[0]
push eax
push ecx
push esi
push edi
mov eax, dword [0x1007a058]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
push 0x70
call fcn.1001fad7
mov esi, eax
add esp, 4
mov dword [ebp - 0x10], esi
mov dword [esi + 8], 0xffffffff
mov dword [esi + 4], 0xffffffff
mov dword [esi + 0xc], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0xf
mov byte [esi + 0x20], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov dword [esi + 0x18], 0
mov dword [esi + 0x1c], 0
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
lea eax, [esi + 0x48]
mov dword [esi], vtable.TiXmlDocument.0
mov dword [eax], 0
lea ecx, [eax + 0x10]
mov dword [ecx], 0
mov dword [eax + 0x14], 0xf
mov byte [eax], 0
mov dword [esi + 0x68], 0xffffffff
mov dword [esi + 0x64], 0xffffffff
mov dword [esi + 0x60], 4
mov byte [esi + 0x6c], 0
mov byte [esi + 0x40], 0
mov dword [esi + 0x44], 0
cmp dword [eax + 0x14], 0x10
jb 0x10056dec
mov eax, dword [eax]
mov dword [ecx], 0
mov ecx, edi
mov byte [eax], 0
push esi
mov dword [esi + 0x68], 0
mov dword [esi + 0x64], 0
mov dword [ebp - 4], 0xffffffff
call fcn.100556c0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x300035b8
Capabilities:
Get common file path

Disassembly:
push ebx
push esi
mov ebx, eax
mov esi, edx
mov eax, dword [ebx]
test eax, eax
je 0x300035d0
mov dword [ebx], 0
push eax
call sym.imp.KERNEL32.dll_GetTempPathW
add ebx, 4
dec esi
jne 0x300035be
pop esi
pop ebx
ret

Function at 0x300035dc
Capabilities:
Get common file path

Disassembly:
mov al, 1
jmp fcn.30002530
test edx, edx
je fcn.300035a0
mov ecx, dword [edx - 4]
shr ecx, 1
je fcn.300035a0
push ecx
push edx
push eax
call sym.imp.KERNEL32.dll_VerSetConditionMask
test eax, eax
je 0x30003598
ret

Function at 0x3001136d
Capabilities:
Query environment variable

Disassembly:
push 0x234
mov eax, 0x3003e6b1
call fcn.3001eda5
mov edi, ecx
lea ecx, [ebp - 0x28]
call fcn.3001094d
and dword [ebp - 4], 0
push 0x104
lea ecx, [ebp - 0x28]
call fcn.3001417d
mov ecx, eax
call fcn.3001085c
lea ecx, [ebp - 0x28]
call fcn.3001417d
mov esi, dword [eax + 0xc]
lea ecx, [ebp - 0x28]
call fcn.3000c9c7
mov eax, dword [eax + 8]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push eax
push dword [edi + 8]
call esi
lea ecx, [ebp - 0x28]
mov ebx, eax
call fcn.3001417d
cmp ebx, dword [eax + 0xc]
jbe 0x300113ff
push ebx
lea ecx, [ebp - 0x28]
call fcn.3001417d
mov ecx, eax
call fcn.3001085c
lea ecx, [ebp - 0x28]
call fcn.3001417d
mov ebx, dword [eax + 0xc]
lea ecx, [ebp - 0x28]
call fcn.3000c9c7
mov eax, dword [eax + 8]
push ebx
push eax
push dword [edi + 8]
call esi
mov ebx, eax
test ebx, ebx
jne 0x3001143c
push 0x30003694
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x240]
push eax
call fcn.3001028f
add esp, 0xc
push 0x43
pop ecx
mov esi, eax
push 0x30044ba4
lea eax, [ebp - 0x134]
lea edi, [ebp - 0x134]
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.3001f2c0
lea ecx, [ebp - 0x28]
call fcn.3000c9c7
push eax
mov ecx, edi
call fcn.300112a1
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x28]
call fcn.3000c6c3
call fcn.3001ee7d
ret

Function at 0x300125bd
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x21c
push esi
mov esi, ecx
cmp dword [esi + 0x30], 0xffffffff
push edi
jne 0x30012604
push 0x30003924
lea eax, [ebp - 0x21c]
push 0x15
push eax
call fcn.3000c862
add esp, 0xc
push 0x43
pop ecx
mov esi, eax
push 0x30044ba4
lea eax, [ebp - 0x110]
lea edi, [ebp - 0x110]
push eax
rep movsd dword es:[edi], dword [esi]
call fcn.3001f2c0
mov ecx, dword [ebp + 8]
and dword [ebp - 4], 0
call fcn.300103f8
mov edi, eax
push 0
lea eax, [ebp - 4]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push edi
push dword [esi + 0x30]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x30012648
push 0x3000390c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x21c]
push eax
call fcn.3001028f
jmp 0x300125e3
pop edi
pop esi
leave
ret 4