joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1000b540
Capabilities:
Create process on windows
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x254
mov eax, dword [0x10025004]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x244], 0
mov eax, dword [ebp + 8]
mov dword [ebp - 0x24c], eax
mov dword [ebp - 0x23c], 0
push 0x22c
push 0
lea ecx, [ebp - 0x230]
push ecx
call fcn.1000dc70
add esp, 0xc
push 0
push 2
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov dword [ebp - 0x23c], eax
mov dword [ebp - 0x230], 0x22c
lea edx, [ebp - 0x230]
push edx
mov eax, dword [ebp - 0x23c]
push eax
call dword [sym.imp.KERNEL32.dll_Process32FirstW]
lea ecx, [ebp - 0x230]
push ecx
mov edx, dword [ebp - 0x23c]
push edx
call dword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
je 0x1000b6ca
mov eax, dword [ebp - 0x24c]
push eax
call fcn.10012898
add esp, 4
mov dword [ebp - 0x238], eax
lea ecx, [ebp - 0x20c]
push ecx
call fcn.10012898
add esp, 4
mov dword [ebp - 0x234], eax
mov edx, dword [ebp - 0x234]
mov ax, word [edx]
mov word [ebp - 0x23e], ax
mov ecx, dword [ebp - 0x238]
cmp ax, word [ecx]
jne 0x1000b660
cmp word [ebp - 0x23e], 0
je 0x1000b654
mov edx, dword [ebp - 0x234]
mov ax, word [edx + 2]
mov word [ebp - 0x240], ax
mov ecx, dword [ebp - 0x238]
cmp ax, word [ecx + 2]
jne 0x1000b660
add dword [ebp - 0x234], 4
add dword [ebp - 0x238], 4
cmp word [ebp - 0x240], 0
jne 0x1000b5fa
mov dword [ebp - 0x248], 0
jmp 0x1000b66b
sbb edx, edx
or edx, 1
mov dword [ebp - 0x248], edx
mov eax, dword [ebp - 0x248]
mov dword [ebp - 0x250], eax
cmp dword [ebp - 0x250], 0
je 0x1000b685
jmp 0x1000b5b4
mov ecx, dword [ebp - 0x228]
push ecx
push 0
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [ebp - 0x254], eax
lea edx, [ebp - 0x244]
push edx
push 0xf01ff
mov eax, dword [ebp - 0x254]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov ecx, dword [ebp - 0x23c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1000b5b4
cmp dword [ebp - 0x244], 0
jne 0x1000b6d7
xor eax, eax
jmp 0x1000b728
mov edx, dword [ebp + 0x18]
mov dword [edx], 0x44
mov eax, dword [ebp + 0x18]
mov ecx, dword [eax + 0x2c]
or ecx, 1
mov edx, dword [ebp + 0x18]
mov dword [edx + 0x2c], ecx
mov eax, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x18]
mov dx, word [ecx + 0x30]
mov word [eax + 0x30], dx
mov eax, dword [ebp + 0x1c]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
push 0
push 0
push 0x20
mov edx, dword [ebp + 0x14]
push edx
push 0
push 0
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp - 0x244]
push edx
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000b906
mov esp, ebp
pop ebp
ret
Function at 0x412310
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, edx
mov eax, ecx
xor edx, edx
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], edx
test ebx, ebx
je 0x41237e
push esi
push edi
nop dword [eax]
cmp dword [ebp + 0x1c], 0xf
lea esi, [ebp + 8]
mov eax, edx
mov ecx, 0x48a484
cmova esi, dword [ebp + 8]
add esi, edx
cmp dword [0x48a498], 0xf
cmova ecx, dword [0x48a484]
xor edx, edx
div dword [0x48a460]
mov al, byte [esi]
add edx, ecx
cmp dword [ebp + 0x1c], 0xf
lea ecx, [ebp + 8]
cmova ecx, dword [ebp + 8]
xor al, byte [edx]
mov edx, dword [ebp - 4]
mov byte [ecx + edx], al
inc edx
mov dword [ebp - 4], edx
cmp edx, ebx
jb 0x412330
mov eax, dword [ebp - 0xc]
pop edi
pop esi
movups xmm0, xmmword [ebp + 8]
pop ebx
movups xmmword [eax], xmm0
movq xmm0, qword [ebp + 0x18]
movq qword [eax + 0x10], xmm0
mov esp, ebp
pop ebp
ret

Function at 0x412c40
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x114
mov eax, dword [0x489400]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
lea eax, [ebp - 0x110]
mov esi, ecx
push eax
push 0x20019
push 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionApp_Pathschrome.exe
mov dword [ebp - 0x10c], esi
mov dword [ebp - 0x10c], esi
push reloc.WS2_32.dll_bind
mov dword [ebp - 0x10c], 0x104
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
jne 0x412cf8
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x108]
push eax
push 0
push 0
push 0
push dword [ebp - 0x110]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 0x110]
test eax, eax
jne 0x412cf6
call edi
xorps xmm0, xmm0
lea ecx, [ebp - 0x108]
movups xmmword [esi], xmm0
mov dword [esi + 0x10], 0
lea edx, [ecx + 1]
mov dword [esi + 0x14], 0
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x412ce0
sub ecx, edx
lea eax, [ebp - 0x108]
push ecx
push eax
jmp 0x412d93
call edi
lea eax, [ebp - 0x110]
push eax
push 0x20019
push 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionApp_Pathschrome.exe
push reloc.WS2_32.dll_accept
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x412d78
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x108]
push eax
push 0
push 0
push 0
push dword [ebp - 0x110]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 0x110]
test eax, eax
jne 0x412d76
call edi
xorps xmm0, xmm0
lea ecx, [ebp - 0x108]
movups xmmword [esi], xmm0
mov dword [esi + 0x10], 0
lea edx, [ecx + 1]
mov dword [esi + 0x14], 0
mov al, byte [ecx]
inc ecx
test al, al
jne 0x412d63
sub ecx, edx
lea eax, [ebp - 0x108]
push ecx
push eax
jmp 0x412d93
call edi
xorps xmm0, xmm0
movups xmmword [esi], xmm0
push 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
push 0x481059
mov ecx, esi
call fcn.0040d560
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
xor ecx, ebp
pop esi
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
Function at 0x414280
Capabilities:
Create process on windows
Create process suspended
Resume thread
Terminate process

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x2a8
mov eax, dword [0x489400]
xor eax, esp
mov dword [esp + 0x2a4], eax
push esi
push edi
push 0x44
lea eax, [esp + 0x5c]
mov dword [esp + 0x20], ecx
push 0
push eax
mov edi, edx
call sub.VCRUNTIME140.dll_memset
xorps xmm0, xmm0
mov dword [esp + 0x5c], 0
add esp, 0xc
movaps xmmword [esp + 0x20], xmm0
movaps xmmword [esp + 0x30], xmm0
lea eax, [esp + 0x58]
movq qword [esp + 0x40], xmm0
mov ecx, 0x44
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov byte [eax], 0
lea eax, [eax + 1]
sub ecx, 1
jne 0x4142e7
mov ecx, 0x10
lea eax, [esp + 0x20]
nop dword [eax + eax]
mov byte [eax], 0
lea eax, [eax + 1]
sub ecx, 1
jne 0x414300
push str.NtQueryInformationProcess
push str.ntdll.dll
mov dword [esp + 0x60], 0x44
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
test esi, esi
je 0x41448a
push dword [esp + 0x1c]
lea eax, [esp + 0xa4]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x5c]
push eax
push 0
push 0
push 0x8000004
push 0
push 0
push 0
lea eax, [esp + 0xc0]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x41448a
lea eax, [esp + 0x50]
push eax
push 0x18
lea eax, [esp + 0x38]
push eax
push 0
push dword [esp + 0x30]
call esi
test eax, eax
je 0x4143b1
push 1
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
xor eax, eax
pop edi
pop esi
mov ecx, dword [esp + 0x2a4]
xor ecx, esp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
mov edx, dword [esp + 0x34]
lea eax, [esp + 0x18]
mov ecx, dword [esp + 0x20]
push 0x1d8
push eax
call fcn.00414180
add esp, 8
test eax, eax
je 0x41438f
mov esi, dword [esp + 0x18]
lea eax, [esp + 0x14]
mov ecx, dword [esp + 0x20]
push 0x48
push eax
mov edx, dword [esi + 0x10]
call fcn.00414180
add esp, 8
test eax, eax
je 0x41438f
mov ecx, dword [esp + 0x20]
lea eax, [esp + 0x54]
mov dword [esp + 0x54], 0x1e
mov edx, dword [esi + 0x10]
push 4
push eax
add edx, 0x40
call fcn.00414220
add esp, 8
test eax, eax
je 0x41448a
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x20]
lea eax, [eax*2 + 1]
mov edx, dword [edx + 0x44]
push eax
push edi
call fcn.00414220
add esp, 8
test eax, eax
je 0x41438f
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push esi
push 0
call edi
mov esi, dword [sym.imp.KERNEL32.dll_HeapFree]
push eax
call esi
push dword [esp + 0x14]
push 0
call edi
push eax
call esi
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_ResumeThread]
cmp dword [ebp + 8], 1
jne 0x414478
push 0xffffffffffffffff
push dword [esp + 0x24]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [esp + 0x20]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [esp + 0x24]
call esi
mov ecx, dword [esp + 0x2ac]
xor eax, eax
pop edi
pop esi
xor ecx, esp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
Function at 0x4144a0
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2d0
mov eax, dword [0x489400]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
push 0x2c8
mov esi, eax
lea eax, [ebp - 0x2cc]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov dword [ebp - 0x2d0], 0x1003f
lea eax, [ebp - 0x2d0]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetThreadContext]
pop esi
test eax, eax
jne 0x414503
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x2cc], 0
jne 0x414527
cmp dword [ebp - 0x2c8], 0
jne 0x414527
cmp dword [ebp - 0x2c4], 0
jne 0x414527
cmp dword [ebp - 0x2c0], 0
je 0x4144f5
push 1
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3

Function at 0x414c30
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 0x414c5c
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 0x414c84
mov eax, dword [eax]
mov ecx, dword [eax]
jmp 0x414c8a
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 0x414cf2
jg 0x414ca1
test esi, esi
je 0x414cf2
test ecx, ecx
jl 0x414ced
jg 0x414cab
test eax, eax
je 0x414ced
cmp edi, ecx
jg 0x414cbf
jl 0x414cb5
cmp esi, eax
jae 0x414cbf
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 0x414cf5
mov ecx, dword [ebp + 8]
jmp 0x414cff
mov ecx, dword [ebp + 8]
test edi, edi
jl 0x414d19
jg 0x414cff
test esi, esi
je 0x414d19
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x414d19
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 0x414d30
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 4], esi
test eax, eax
jg 0x414d5c
jl 0x414d50
test ecx, ecx
jne 0x414d5c
pop esi
xor eax, eax
xor edx, edx
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x414d75
push eax
push ecx
push esi
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 esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
push edi
mov edi, ecx
mov eax, dword [eax]
mov dword [ebp - 8], eax
test eax, eax
je 0x414dc3
mov eax, dword [ebx + 0x2c]
lea edx, [ebx + 0x2c]
mov dword [ebp - 0xc], edx
mov eax, dword [eax]
test eax, eax
je 0x414dc9
mov edi, dword [ebp - 4]
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 - 4], 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
mov esi, dword [ebp - 4]
jmp 0x414dc9
lea eax, [ebx + 0x2c]
mov dword [ebp - 0xc], eax
cmp dword [ebx + 0x4c], 0
je 0x414e36
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x414df2
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 - 0xc]
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 0x414e24
nop
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 0x414e36
cmp edi, eax
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
ja 0x414e00
test edi, edi
je 0x414e36
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 0x4151c0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x489400]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x4151f0
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
push edi
mov ecx, dword [eax]
test ecx, ecx
je 0x41522c
mov edx, dword [esi + 0x30]
mov edi, dword [edx]
lea eax, [edi + ecx]
cmp ecx, eax
jae 0x41522c
lea ecx, [edi - 1]
mov eax, ebx
mov dword [edx], ecx
mov edx, dword [esi + 0x20]
pop edi
mov esi, dword [edx]
lea ecx, [esi + 1]
mov dword [edx], ecx
mov byte [esi], bl
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
je 0x415303
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x415254
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 0x415260
movsx eax, bl
jmp 0x415298
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 0x4152c2
sub eax, 1
je 0x4152c2
sub eax, 2
jne 0x415303
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
cmove ebx, ecx
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x4152e0
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 0x415303
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.0046dd2e
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.0046dd2e
mov esp, ebp
pop ebp
ret 4
Function at 0x415ad0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x489400]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x415b8c
cmp byte [esi + 0x3d], 0
je 0x415b8c
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x415b7a
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 0x415b41
sub eax, 1
je 0x415b45
sub eax, 2
jne 0x415b7a
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x415b63
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 0x415b7a
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.0046dd2e
mov esp, ebp
pop ebp
ret
Function at 0x41e640
Capabilities:
Encode data using xor
Hash data using djb2

Disassembly:
push esi
mov esi, dword [esp + 8]
test esi, esi
je 0x41e6ef
push esi
call fcn.00434190
add esp, 4
test al, al
jne 0x41e6ef
push ebx
push edi
mov edi, esi
xor ebx, ebx
lea ecx, [edi + 1]
mov al, byte [edi]
inc edi
test al, al
jne 0x41e667
sub edi, ecx
push edi
push 0x2e
push esi
call fcn.0043e490
add esp, 0xc
test eax, eax
je 0x41e69b
sub eax, esi
push eax
push 0x2e
push esi
call fcn.0043e490
mov ebx, eax
add esp, 0xc
test ebx, ebx
je 0x41e69d
inc ebx
mov ecx, esi
sub ecx, ebx
add edi, ecx
test ebx, ebx
cmovne esi, ebx
lea ebx, [esi + edi]
mov edi, 0x1505
cmp esi, ebx
jae 0x41e6ce
nop dword [eax]
mov al, byte [esi]
push eax
call fcn.004301c0
movsx ecx, al
inc esi
mov eax, edi
add esp, 4
shl eax, 5
add eax, edi
xor ecx, eax
mov edi, ecx
cmp esi, ebx
jb 0x41e6b0
mov eax, 0x4104105
mov esi, edi
mul edi
sub esi, edx
shr esi, 1
add esi, edx
shr esi, 5
mov ecx, esi
shl ecx, 6
sub ecx, esi
sub edi, ecx
mov eax, edi
pop edi
pop ebx
pop esi
ret
xor eax, eax
pop esi
ret
Function at 0x42ad60
Capabilities:
Write file on windows

Disassembly:
push edi
mov edi, dword [esp + 8]
cmp byte [edi + 0x68a], 0
je 0x42adff
cmp dword [edi + 0x194], 0
je 0x42adb7
push edi
call fcn.00419300
push 1
push edi
mov byte [esp + 0x14], al
call fcn.004197a0
push dword [edi + 0x144]
mov eax, dword [edi + 0x194]
push dword [esp + 0x24]
push dword [esp + 0x24]
push dword [esp + 0x24]
push edi
call eax
push dword [esp + 0x28]
push edi
call fcn.004197a0
add esp, 0x28
pop edi
ret
mov ecx, dword [esp + 0xc]
mov eax, ecx
sub eax, 0
je 0x42adcc
sub eax, 1
je 0x42adcc
sub eax, 1
jne 0x42adff
push dword [edi + 0x140]
lea eax, [ecx*2 + 0x4740f4]
push 1
add eax, ecx
push 2
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
push dword [edi + 0x140]
push 1
push dword [esp + 0x2c]
push dword [esp + 0x2c]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x20
pop edi
ret

Function at 0x42e390
Capabilities:
Get common file path

Disassembly:
push ecx
push ebx
push edi
push str.kernel32
xor edi, edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov ebx, eax
test ebx, ebx
jne 0x42e3aa
pop edi
pop ebx
pop ecx
ret
push ebp
push esi
push str.LoadLibraryExA
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, dword [esp + 0x18]
mov ebp, eax
push 0x474a34
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strpbrk]
add esp, 8
test eax, eax
je 0x42e3f3
test ebp, ebp
je 0x42e3e4
push 8
push 0
push esi
call ebp
pop esi
pop ebp
mov edi, eax
pop edi
pop ebx
pop ecx
ret
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
pop esi
pop ebp
mov edi, eax
pop edi
pop ebx
pop ecx
ret
test ebp, ebp
je 0x42e419
push str.AddDllDirectory
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x42e419
push 0x800
push 0
push esi
call ebp
pop esi
pop ebp
mov edi, eax
pop edi
pop ebx
pop ecx
ret
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edx, eax
mov dword [esp + 0x10], edx
test edx, edx
je 0x42e4cf
mov ecx, esi
lea ebx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x42e436
sub ecx, ebx
lea eax, [ecx + 1]
add eax, edx
push eax
call dword [section..data]
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x42e4c5
push dword [esp + 0x10]
push ebx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x42e4c5
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x42e468
sub ecx, edx
mov eax, 0x5c
mov word [ecx + ebx], ax
mov ecx, ebx
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x42e480
sub ecx, edx
sub ecx, esi
add ecx, ebx
nop dword [eax]
mov al, byte [esi]
lea esi, [esi + 1]
mov byte [ecx + esi - 1], al
test al, al
jne 0x42e490
test ebp, ebp
je 0x42e4bc
push 8
push 0
push ebx
call ebp
push ebx
mov edi, eax
call dword [0x489004]
add esp, 4
mov eax, edi
pop esi
pop ebp
pop edi
pop ebx
pop ecx
ret
push ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
push ebx
call dword [0x489004]
add esp, 4
pop esi
pop ebp
mov eax, edi
pop edi
pop ebx
pop ecx
ret