joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10002890
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10042afd
mov eax, dword fs:[0]
push eax
sub esp, 8
push esi
push edi
mov eax, dword [0x10054054]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x10], esi
mov dword [ebp - 4], 0
lea edi, [ebp + 8]
cmp dword [ebp + 0x1c], 0x10
mov edx, dword [ebp + 0x18]
cmovae edi, dword [ebp + 8]
xor eax, eax
test edx, edx
jle 0x10002951
cmp edx, 0x40
jb 0x10002948
mov ecx, edx
and ecx, 0x8000003f
jns 0x100028ee
dec ecx
or ecx, 0xffffffc0
inc ecx
movaps xmm2, xmmword [0x100502e0]
mov dword [ebp - 0x10], edx
sub dword [ebp - 0x10], ecx
lea ecx, [edi + 0x20]
nop
movups xmm0, xmmword [ecx - 0x20]
lea ecx, [ecx + 0x40]
add eax, 0x40
movaps xmm1, xmm2
pxor xmm0, xmm2
movups xmmword [ecx - 0x60], xmm0
movups xmm0, xmmword [ecx - 0x50]
pxor xmm1, xmm0
movups xmmword [ecx - 0x50], xmm1
movaps xmm1, xmm2
movups xmm0, xmmword [ecx - 0x40]
pxor xmm1, xmm0
movups xmmword [ecx - 0x40], xmm1
movaps xmm1, xmm2
movups xmm0, xmmword [ecx - 0x30]
pxor xmm1, xmm0
movups xmmword [ecx - 0x30], xmm1
cmp eax, dword [ebp - 0x10]
jl 0x10002900
cmp eax, edx
jge 0x10002951
xor byte [edi + eax], 0x1d
inc eax
cmp eax, edx
jl 0x10002948
mov ecx, edi
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0xf
lea edx, [ecx + 1]
mov byte [esi], 0
nop dword [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10002980
sub ecx, edx
push ecx
push edi
mov ecx, esi
call fcn.1001e410
mov ecx, dword [ebp + 0x1c]
cmp ecx, 0x10
jb 0x100029c2
mov edx, dword [ebp + 8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x100029b8
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x100029d5
push ecx
push edx
call fcn.1002145f
add esp, 8
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
call fcn.10029ddb
int3
Function at 0x10002e70
Capabilities:
Get common file path
Get startup folder

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10042bf2
mov eax, dword fs:[0]
push eax
sub esp, 0x230
mov eax, dword [0x10054054]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x234], edi
lea eax, [ebp - 0x218]
mov dword [ebp - 4], 0
push eax
push 0
push 0
push 0x28
mov dword [ebp - 0x238], edi
push 0
mov dword [ebp - 0x23c], 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
xor eax, eax
mov dword [ebp - 0x230], 0
mov word [ebp - 0x230], ax
lea eax, [ebp - 0x218]
mov dword [ebp - 0x220], 0
lea edx, [eax + 2]
mov dword [ebp - 0x21c], 7
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x10002f01
sub eax, edx
sar eax, 1
cmp eax, 7
ja 0x10002f41
lea esi, [eax + eax]
mov dword [ebp - 0x220], eax
push esi
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x230]
push eax
call fcn.10022b30
add esp, 0xc
xor eax, eax
mov word [ebp + esi - 0x230], ax
jmp 0x10002f61
lea ecx, [ebp - 0x218]
mov byte [ebp - 0x234], 0
push ecx
push dword [ebp - 0x234]
lea ecx, [ebp - 0x230]
push eax
call fcn.1001f5d0
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x230]
cmp dword [ebp - 0x21c], 8
mov eax, dword [ebp - 0x220]
cmovae ecx, dword [ebp - 0x230]
lea eax, [ecx + eax*2]
lea ecx, [ebp - 0x230]
cmovae ecx, dword [ebp - 0x230]
push ecx
push eax
push ecx
mov ecx, edi
call fcn.1001ea20
mov eax, dword [edi + 0x10]
mov edx, 9
cmp eax, edx
mov ecx, edi
cmovb edx, eax
cmp dword [edi + 0x14], 0x10
jb 0x10002fb3
mov ecx, dword [edi]
sub eax, edx
mov dword [edi + 0x10], eax
inc eax
push eax
lea eax, [ecx + edx]
push eax
push ecx
call fcn.10022b30
mov ecx, dword [ebp - 0x21c]
add esp, 0xc
cmp ecx, 8
jb 0x10003003
mov edx, dword [ebp - 0x230]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x10002ff9
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x10003020
push ecx
push edx
call fcn.1002145f
add esp, 8
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10021451
mov esp, ebp
pop ebp
ret
call fcn.10029ddb
int3

Function at 0x10003540
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x1010
call fcn.10022490
mov eax, dword [0x10054054]
xor eax, esp
mov dword [esp + 0x100c], eax
push esi
push edi
lea eax, [esp + 0xc]
push eax
push 0x1000
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_K32EnumProcesses]
test eax, eax
je 0x10003598
mov edi, dword [esp + 0xc]
xor esi, esi
shr edi, 2
test edi, edi
je 0x10003598
mov ecx, dword [esp + esi*4 + 0x10]
test ecx, ecx
je 0x10003593
call fcn.10003030
inc esi
cmp esi, edi
jb 0x10003586
mov ecx, dword [esp + 0x1014]
pop edi
pop esi
xor ecx, esp
call fcn.10021451
mov esp, ebp
pop ebp
ret
Function at 0x1001c650
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [esp + 0xc], edi
test eax, eax
jg 0x1001c682
jl 0x1001c675
test ecx, ecx
jne 0x1001c682
xor eax, eax
xor edx, edx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x1001c742
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], eax
mov ecx, ebx
call fcn.1001e1b0
mov esi, eax
mov eax, edx
mov dword [esp + 0x14], eax
test eax, eax
jl 0x1001c6ee
jg 0x1001c6ad
test esi, esi
je 0x1001c6ee
mov ecx, dword [esp + 0xc]
cmp ecx, eax
jg 0x1001c6c5
mov eax, dword [esp + 0x10]
jl 0x1001c6bf
cmp eax, esi
jae 0x1001c6c5
mov esi, eax
mov dword [esp + 0x14], ecx
mov eax, dword [ebx + 0x1c]
push esi
push dword [eax]
push edi
call fcn.10022b30
mov eax, dword [ebx + 0x2c]
add esp, 0xc
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
sub ecx, esi
sbb edx, dword [esp + 0x14]
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
jmp 0x1001c70f
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x1c]
mov edx, dword [esp + 0xc]
cmp eax, 0xffffffff
je 0x1001c72b
mov ecx, dword [esp + 0x10]
mov esi, 1
add ecx, 0xffffffff
mov byte [edi], al
adc edx, 0xffffffff
add edi, esi
mov dword [esp + 0xc], edx
mov dword [esp + 0x10], ecx
test edx, edx
jg 0x1001c694
jl 0x1001c72b
test ecx, ecx
jne 0x1001c694
mov eax, dword [ebp + 0xc]
sub eax, dword [esp + 0x10]
mov ecx, dword [ebp + 0x10]
sbb ecx, edx
mov edx, ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
lea esi, [ebx + 0x2c]
mov edi, ecx
mov edx, dword [eax]
test edx, edx
je 0x1001c786
mov eax, dword [esi]
mov eax, dword [eax]
test eax, eax
je 0x1001c786
mov edi, dword [esp + 0xc]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push edx
push edi
call fcn.10022b30
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [esp + 0x18], 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
lea esi, [ebx + 0x2c]
cmp dword [ebx + 0x4c], 0
je 0x1001c7f7
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x1001c7ac
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 [esi]
mov dword [eax], edx
mov esi, dword [esp + 0xc]
cmp edi, 0xfff
jbe 0x1001c7e2
nop dword [eax + eax]
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call fcn.1002c7ea
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x1001c7f7
cmp edi, eax
ja 0x1001c7c0
test edi, edi
je 0x1001c7f7
push dword [ebx + 0x4c]
push edi
push 1
push esi
call fcn.1002c7ea
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 0x1001e040
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100437c0
mov eax, dword fs:[0]
push eax
sub esp, 0xc
push ebx
push esi
push edi
mov eax, dword [0x10054054]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x18], eax
push 8
mov dword [ebp - 0x18], eax
mov dword [eax], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
call fcn.10021490
mov esi, eax
xorps xmm0, xmm0
movq qword [esi], xmm0
push 1
mov dword [ebp - 4], 0
call fcn.10020561
mov dword [esi + 4], eax
add esp, 8
mov eax, dword [ebp - 0x10]
lea ecx, [eax + 0x18]
lea edx, [eax + 0x24]
lea edi, [eax + 0x14]
mov dword [eax + 0x34], esi
lea ebx, [eax + 4]
mov dword [eax + 0xc], ebx
lea esi, [eax + 8]
mov dword [eax + 0x20], ecx
mov dword [eax + 0x2c], edx
mov dword [eax + 0x10], esi
mov dword [eax + 0x1c], edi
add eax, 0x28
mov dword [ebp - 0x14], ebx
mov ebx, dword [ebp - 0x10]
mov dword [ebp - 0x18], eax
mov dword [ebx + 0x30], eax
mov ebx, dword [ebp - 0x14]
mov dword [esi], 0
mov dword [ecx], 0
mov dword [eax], 0
mov eax, dword [ebp - 0x10]
mov dword [ebx], 0
mov ebx, dword [ebp - 0x10]
mov dword [edi], 0
mov dword [edx], 0
mov dword [eax + 0x20], ecx
mov dword [ebx], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
mov byte [ebx + 0x48], 0
mov byte [ebx + 0x3d], 0
mov ebx, dword [ebp - 0x14]
mov dword [eax + 0xc], ebx
mov ebx, dword [ebp - 0x10]
mov dword [eax + 0x2c], edx
mov dword [eax + 0x10], esi
mov dword [eax + 0x1c], edi
mov eax, dword [ebp - 0x18]
mov dword [ebx + 0x30], eax
mov ebx, dword [ebp - 0x14]
mov dword [esi], 0
mov dword [ecx], 0
mov ecx, dword [0x10056e58]
mov dword [eax], 0
mov eax, dword [ebp - 0x10]
mov dword [ebx], 0
mov dword [edi], 0
mov dword [edx], 0
mov edx, dword [0x10056e5c]
mov dword [eax + 0x4c], 0
mov dword [eax + 0x40], ecx
mov dword [eax + 0x44], edx
mov dword [eax + 0x38], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x10032626
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x10048298
push 0x10048290
push str.FlsAlloc
push 0x1e
call fcn.10032493
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1003265a
push dword [ebp + 8]
mov ecx, esi
call dword [0x100441f8]
call esi
jmp 0x10032660
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x100326a4
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x100482a8
push 0x100482a0
push str.FlsGetValue
push 0x20
call fcn.10032493
mov esi, eax
add esp, 0x10
test esi, esi
je 0x100326db
push dword [ebp + 8]
mov ecx, esi
call dword [0x100441f8]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x10032bf6
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.10032a67
Function at 0x1003541f
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.10022490
mov eax, dword [0x10054054]
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.1002ffbd
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x10035461
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x100355bd
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.100421e0
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 + 0x10055b38]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.10034fb4
mov ecx, dword [esi*4 + 0x10055b38]
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 0x100355b6
cmp eax, dword [edi + ecx + 0x24]
jne 0x100355b6
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 0x100355b6
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10034fb4
add esp, 0x14
test edx, edx
jl 0x100355b6
jg 0x1003552c
test eax, eax
jb 0x100355b6
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x100355b6
jl 0x10035546
cmp dword [ebp - 0x1008], eax
ja 0x100355b6
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x10035564
test ebx, ebx
je 0x1003559d
cmp ecx, edi
jae 0x1003559d
mov al, byte [ecx]
cmp al, 0xd
jne 0x1003557e
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1003558a
cmp byte [ecx + 1], 0xa
jne 0x1003558a
inc ecx
jmp 0x1003558a
movzx eax, al
movsx eax, byte [eax + 0x100542d8]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x10035564
cmp edx, ebx
jne 0x10035564
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x100355bb
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.10021451
leave
ret
Function at 0x1003565c
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 + 0x10055b38]
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 0x1003569c
cmp byte [ebx], 0xa
jne 0x1003569c
or byte [eax + edi + 0x28], 4
jmp 0x100356a1
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1003579f
mov al, byte [edx]
cmp al, 0x1a
je 0x10035781
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x100356d0
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x100356f5
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x100356ff
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 0x100356b2
jmp 0x1003579f
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 0x1003577c
cmp dword [ebp - 0xc], 0
je 0x1003577c
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x10055b38]
test byte [eax + edi + 0x28], 0x48
je 0x10035756
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x10035741
mov byte [esi], dl
jmp 0x10035752
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x10055b38]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x1003579f
cmp byte [ebp - 1], 0xa
jne 0x10035765
cmp esi, ebx
jne 0x10035765
mov byte [esi], 0xa
jmp 0x1003579e
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.10034fd2
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1003579f
mov byte [esi], 0xd
jmp 0x1003579e
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x10055b38]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003579b
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1003579f
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x100357a8
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 + 0x10055b38]
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 0x100357eb
cmp word [esi], dx
jne 0x100357eb
or byte [edi + eax + 0x28], 4
jmp 0x100357f0
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 0x10035943
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 0x10035923
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x10035832
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x10035868
cmp eax, edx
jae 0x10035874
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 0x1003580a
jmp 0x10035943
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 0x1003591f
cmp dword [ebp - 0x14], 0
je 0x1003591f
mov eax, dword [ebx*4 + 0x10055b38]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x100358f7
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x100358c0
mov word [esi], cx
jmp 0x100358f3
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x10055b38]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x10055b38]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x10055b38]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x10035943
pop ebx
cmp word [ebp - 4], bx
jne 0x10035908
cmp esi, dword [ebp + 0xc]
jne 0x10035908
mov word [esi], bx
jmp 0x10035940
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.10034fd2
add esp, 0x10
cmp word [ebp - 4], bx
je 0x10035943
push 0xd
jmp 0x1003593c
mov ecx, dword [ebx*4 + 0x10055b38]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003593a
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x10035943
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 0x1003a251
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 0x1003a2ee
push ebx
push esi
call fcn.1003a21a
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.10039021
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x1003a29b
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003a2ed
push edi
push eax
call fcn.1002f0cc
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x1003a2bb
call fcn.1002f092
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x1003a2ec
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.10039021
add esp, 0x20
test eax, eax
jne 0x1003a2da
push edi
call fcn.1002f092
jmp 0x1003a2e2
push ebx
call fcn.1002f092
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 0x10041598
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.10041514
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10041710
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10041710
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x100416bf
jg 0x100415f1
test eax, eax
je 0x100416b5
push 1
push 0x1000
call fcn.10032195
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x10041617
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x100416ac
push 0x8000
push ebx
call fcn.1003eada
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 0x10041643
jg 0x1004163e
cmp ecx, 0x1000
jb 0x10041643
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.10034bcb
add esp, 0x10
cmp eax, 0xffffffff
je 0x10041688
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 0x1004163e
jl 0x1004166f
test ecx, ecx
jne 0x10041630
push dword [ebp - 0xc]
push ebx
call fcn.1003eada
push esi
call fcn.1002f092
add esp, 0xc
xor edi, edi
jmp 0x10041721
cmp byte [edi + 0x24], 0
je 0x1004169f
cmp dword [edi + 0x20], 5
jne 0x1004169f
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x100416aa
mov edi, dword [edi + 0x18]
jmp 0x100416ac
xor edi, edi
push esi
call fcn.1002f092
pop ecx
jmp 0x10041721
test ecx, ecx
jg 0x10041681
jl 0x100416bf
test eax, eax
jae 0x10041681
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10034fd2
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x100416e2
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x10041681
jmp 0x10041719
push ebx
call fcn.1003e81a
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x10041681
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 0x10041721
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x1004171e
mov edi, dword [edi + 0x18]
jmp 0x10041721
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.10034fd2
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret

Function at 0x10042100
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1004212d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1004212d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x401040
Capabilities:
Create directory
Get common file path

Disassembly:
push edi
lea edi, [esp + 8]
and esp, 0xfffffff8
push dword [edi - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
lea ebx, [ebp - 0x218]
sub esp, 0x224
mov dword [ebp - 0x21c], eax
mov dword [esp + 4], ebx
mov dword [esp], 0x104
call dword [sym.imp.kernel32.dll_GetTempPathW]
sub esp, 8
test eax, eax
je 0x40110c
mov esi, dword [sym.imp.ucrtbase.dll_malloc]
mov dword [esp], 0xc
call esi
mov edi, eax
test eax, eax
je 0x40110c
mov dword [esp], 0x230
call esi
mov dword [edi + 8], eax
test eax, eax
je 0x401140
mov esi, dword [sym.imp.kernel32.dll_GetTempFileNameW]
jmp 0x4010ce
mov dword [esp + 4], 0
mov eax, dword [edi + 8]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CreateDirectoryW]
sub esp, 8
test eax, eax
jne 0x401110
mov eax, dword [edi + 8]
mov ecx, dword [section..bss]
lea edx, [ecx + 1]
mov dword [section..bss], edx
mov dword [esp + 0xc], eax
mov dword [esp + 8], edx
mov dword [esp + 4], 0x40a000
mov dword [esp], ebx
call esi
sub esp, 0x10
test eax, eax
jne 0x4010b0
mov eax, dword [edi + 8]
mov ebx, dword [sym.imp.ucrtbase.dll_free]
mov dword [esp], eax
call ebx
mov dword [esp], edi
call ebx
xor eax, eax
jmp 0x401134
mov esi, dword [ebp - 0x21c]
mov eax, dword [esi + 0xc]
lea ebx, [esi + 8]
movd xmm0, ebx
movd xmm1, eax
punpckldq xmm0, xmm1
movq qword [edi], xmm0
mov dword [eax], edi
mov eax, dword [edi + 8]
mov dword [esi + 0xc], edi
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll_free]
xor eax, eax
jmp 0x401134