joyce8/EMBER2024-capa huggingface dataset:
Function at 0x409881
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x41a344]
jne 0x40988b
repz ret
jmp fcn.0040e3ac

Function at 0x4125dc
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x41a344]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.0040c1a2
and dword [ebp - 0x14], 0
cmp dword [0x43e5ec], 0
mov dword [ebp - 0x18], eax
jne 0x41268f
push 0x403764
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x412737
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x403758
push ebx
call edi
test eax, eax
je 0x412737
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push 0x403748
push ebx
mov dword [0x43e5ec], eax
call edi
push eax
call esi
push 0x403734
push ebx
mov dword [0x43e5f0], eax
call edi
push eax
call esi
push 0x403718
push ebx
mov dword [0x43e5f4], eax
call edi
push eax
call esi
mov dword [0x43e5fc], eax
test eax, eax
je 0x41268f
push 0x403700
push ebx
call edi
push eax
call esi
mov dword [0x43e5f8], eax
mov eax, dword [0x43e5f8]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x4126e8
cmp dword [0x43e5fc], ecx
je 0x4126e8
push eax
call esi
push dword [0x43e5fc]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x4126e8
test ebx, ebx
je 0x4126e8
call edi
test eax, eax
je 0x4126df
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x4126df
test byte [ebp - 8], 1
jne 0x4126e8
or dword [ebp + 0x10], 0x200000
jmp 0x41271b
mov eax, dword [0x43e5f0]
cmp eax, dword [ebp - 0x18]
je 0x41271b
push eax
call esi
test eax, eax
je 0x41271b
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x41271b
mov eax, dword [0x43e5f4]
cmp eax, dword [ebp - 0x18]
je 0x41271b
push eax
call esi
test eax, eax
je 0x41271b
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x43e5ec]
call esi
test eax, eax
je 0x412737
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x412739
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00409881
leave
ret
Function at 0x414590
Capabilities:
Delete directory
Delete file
Get disk information
Read .ini file

Disassembly:
mov eax, 0x1400
call fcn.00413bb0
cmp dword [0x4a3ed0], 0x37
jne 0x414621
push 0
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
push 0
push 0
push 0
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetNamedPipeHandleStateA]
push 0x403f68
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0
lea eax, [esp + 0x804]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0x40402c
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
lea ecx, [esp]
push ecx
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
push 0
push 0
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_SetTapePosition]
call dword [sym.imp.KERNEL32.dll_DebugBreak]
push 0
lea edx, [esp + 0xc04]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_FindNextVolumeMountPointW]
mov eax, dword [0x4a3ed4]
mov edx, dword [0x4a35b4]
mov cl, byte [eax + esi + 0x38d6]
mov byte [edx + esi], cl
add esp, 0x1400
ret
Function at 0x409f15
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x439bcc]
jne 0x409f1f
repz ret
jmp fcn.00412d0a

Function at 0x40bafb
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x439bcc]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.004059b8
and dword [ebp - 0x14], 0
cmp dword [0x459d40], 0
mov dword [ebp - 0x18], eax
jne 0x40bbae
push 0x402adc
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x40bc56
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x402ad0
push ebx
call edi
test eax, eax
je 0x40bc56
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push 0x402ac0
push ebx
mov dword [0x459d40], eax
call edi
push eax
call esi
push 0x402aac
push ebx
mov dword [0x459d44], eax
call edi
push eax
call esi
push 0x402a90
push ebx
mov dword [0x459d48], eax
call edi
push eax
call esi
mov dword [0x459d50], eax
test eax, eax
je 0x40bbae
push 0x402a78
push ebx
call edi
push eax
call esi
mov dword [0x459d4c], eax
mov eax, dword [0x459d4c]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x40bc07
cmp dword [0x459d50], ecx
je 0x40bc07
push eax
call esi
push dword [0x459d50]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x40bc07
test ebx, ebx
je 0x40bc07
call edi
test eax, eax
je 0x40bbfe
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x40bbfe
test byte [ebp - 8], 1
jne 0x40bc07
or dword [ebp + 0x10], 0x200000
jmp 0x40bc3a
mov eax, dword [0x459d44]
cmp eax, dword [ebp - 0x18]
je 0x40bc3a
push eax
call esi
test eax, eax
je 0x40bc3a
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x40bc3a
mov eax, dword [0x459d48]
cmp eax, dword [ebp - 0x18]
je 0x40bc3a
push eax
call esi
test eax, eax
je 0x40bc3a
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x459d40]
call esi
test eax, eax
je 0x40bc56
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x40bc58
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00409f15
leave
ret

Function at 0x414790
Capabilities:
Delete file
Get uefi variable

Disassembly:
sub esp, 0x818
cmp dword [0x4d54ac], 0x37
jne 0x4147f8
push 0
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessId]
push 0
call dword [sym.imp.KERNEL32.dll_IsDBCSLeadByte]
push 0
lea eax, [esp + 0x1c]
push eax
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetFirmwareEnvironmentVariableW]
lea ecx, [esp]
push ecx
push 0
lea edx, [esp + 0xc]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_ReadConsoleInputA]
push 0
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push 0
lea eax, [esp + 0x41c]
push eax
push 0x403410
call dword [sym.imp.KERNEL32.dll_FindFirstVolumeMountPointA]
mov ecx, dword [0x4d58c0]
mov eax, dword [0x4d4f90]
mov dl, byte [ecx + esi + 0x38d6]
mov byte [eax + esi], dl
add esp, 0x818
ret
Function at 0x2c02bc0
Capabilities:
Encode data using xor

Disassembly:
xor al, al
cmp dword [esp + 8], 0
push ebp
mov ebp, dword [esp + 8]
je 0x2c02c57
test ebp, ebp
je 0x2c02c57
mov eax, ebp
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x2c02be0
sub eax, edx
push ebx
sar eax, 1
shr eax, 1
push esi
mov ebx, eax
push edi
lea edi, [ebx + 2]
push edi
call fcn.02c0374f
mov esi, eax
add esp, 4
test esi, esi
je 0x2c02c52
push edi
push 0
push esi
call fcn.02c06370
push esi
push ebp
mov eax, ebx
call fcn.02c020d0
add esp, 0x14
xor eax, eax
test ebx, ebx
jbe 0x2c02c2b
xor byte [eax + esi], bl
inc eax
cmp eax, ebx
jb 0x2c02c23
mov ecx, dword [esp + 0x18]
lea eax, [ebx + ebx]
push eax
push ecx
push ebx
push esi
push 0
push 0
call dword [0x2c0f018]
push esi
mov bl, 1
call fcn.02c0574e
add esp, 4
pop edi
pop esi
mov al, bl
pop ebx
pop ebp
ret
pop edi
pop esi
xor al, al
pop ebx
pop ebp
ret
Function at 0x4043e0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49bf17
mov eax, dword fs:[0]
push eax
sub esp, 0x214
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0x220], esi
mov dword [ebp - 0x21c], 0
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
push 0x208
push eax
mov dword [ebp - 4], eax
lea eax, [ebp - 0x218]
push eax
mov dword [ebp - 0x21c], 1
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemWow64DirectoryW]
test eax, eax
je 0x40448d
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404480
jmp 0x4044db
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x78
jne 0x4044ee
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x4044ee
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
lea ecx, [ecx]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4044d0
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, esi
call fcn.00404580
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
Function at 0x40cbc0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49c990
mov eax, dword fs:[0]
push eax
sub esp, 0x234
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x21c]
mov ebx, dword [ebp + 0xc]
push 0x20a
push 0
mov dword [ebp - 0x224], esi
push eax
mov dword [ebp - 0x224], ebx
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov eax, ebx
cmp dword [ebx + 0x14], 8
jb 0x40cc20
mov eax, dword [ebx]
push 0x104
lea ecx, [ebp - 0x21c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ecx, eax
mov dword [ebp - 0x240], ecx
test ecx, ecx
je 0x40cdce
cmp ecx, 0x104
ja 0x40cc8c
xor eax, eax
mov dword [esi], 0
lea ecx, [ebp - 0x21c]
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
lea edx, [ecx + 2]
mov word [esi], ax
lea ecx, [ecx]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40cc70
sub ecx, edx
lea eax, [ebp - 0x21c]
sar ecx, 1
push ecx
push eax
jmp 0x40cded
lea eax, [ecx + 1]
mov dword [ebp - 0x234], 0
xor edi, edi
mov dword [ebp - 0x220], eax
xor ebx, ebx
mov dword [ebp - 0x230], edi
mov dword [ebp - 0x22c], edi
mov dword [ebp - 0x228], ebx
test eax, eax
je 0x40cd45
cmp eax, 0x7fffffff
ja 0x40ce12
push eax
lea ecx, [ebp - 0x230]
call fcn.00401c70
mov ecx, dword [ebp - 0x220]
mov edi, eax
mov dword [ebp - 0x238], 0
mov dword [ebp - 0x23c], edi
mov dword [ebp - 0x230], edi
lea edx, [ecx + ecx]
lea ecx, [ebp - 0x234]
mov ax, word [ecx]
lea ebx, [edx + edi]
lea ecx, [ebp - 0x238]
mov dword [ebp - 0x228], ebx
cmp ax, word [ecx]
mov ecx, dword [ebp - 0x220]
jne 0x40cd26
push edx
push 0
push edi
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
jmp 0x40cd37
xor eax, eax
shr ecx, 1
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
mov edi, dword [ebp - 0x23c]
mov ecx, dword [ebp - 0x240]
mov eax, ebx
mov dword [ebp - 0x22c], eax
mov eax, dword [ebp - 0x224]
mov dword [ebp - 4], 0
cmp dword [eax + 0x14], 8
jb 0x40cd5a
mov eax, dword [eax]
push ecx
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ecx, edi
mov dword [esi], 0
xor eax, eax
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40cd81
sub ecx, edx
sar ecx, 1
push ecx
push edi
mov ecx, esi
call fcn.00404580
test edi, edi
je 0x40cdf4
sub ebx, edi
mov eax, edi
and ebx, 0xfffffffe
cmp ebx, 0x1000
jb 0x40cdc2
mov edi, dword [edi - 4]
add ebx, 0x23
sub eax, edi
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40cdc2
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ebx
push edi
call fcn.0049995e
add esp, 8
jmp 0x40cdf4
xor eax, eax
mov dword [esi], 0
push eax
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
push 0x4a9810
mov ecx, esi
call fcn.00404580
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
call fcn.00401c60
int3
Function at 0x4102f0
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49cfc0
mov eax, dword fs:[0]
push eax
push esi
push edi
mov eax, dword [0x4ce4bc]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword [esi + 0x2c]
cmp eax, dword [esi + 0x30]
mov edx, dword [esi + 0x34]
mov edi, edx
sbb ecx, ecx
mov dword [ebp - 4], 0
and ecx, 0xfffffffc
xor al, al
push edx
mov ecx, dword [ecx + esi + 0x30]
rep stosb byte es:[edi], al
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov eax, dword [esi + 0x1c]
mov ecx, dword [esi + 0x20]
cmp eax, ecx
mov edx, dword [esi + 0x24]
mov edi, edx
cmovb ecx, eax
mov dword [ebp - 4], 1
xor al, al
rep stosb byte es:[edi], al
push edx
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov ecx, dword [esi + 0xc]
add esp, 8
test ecx, ecx
je 0x41036c
mov eax, dword [ecx]
push 1
call dword [eax]
test byte [ebp + 8], 1
je 0x41037d
push 0x40
push esi
call fcn.0049995e
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 4
Function at 0x4137c0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x41387c
cmp byte [esi + 0x3d], 0
je 0x41387c
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x41386a
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 0x413831
sub eax, 1
je 0x413835
sub eax, 2
jne 0x41386a
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x413853
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 0x41386a
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.0049996c
mov esp, ebp
pop ebp
ret
Function at 0x413bd0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49d695
mov eax, dword fs:[0]
push eax
sub esp, 0x34
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
xor ebx, ebx
mov ecx, dword [ebp + 0xc]
xor esi, esi
mov dword [ebp - 0x40], edi
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x34], ebx
lea eax, [ebp - 0x2c]
mov dword [ebp - 4], esi
push eax
push ecx
mov dword [ebp - 0x2c], esi
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov dword [ebp - 0x30], eax
test eax, eax
jne 0x413c3b
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov eax, edi
jmp 0x413d5b
xor edi, edi
cmp dword [ebp - 0x2c], edi
jle 0x413d46
jmp 0x413c50
mov edx, dword [eax + edi*4]
test edx, edx
je 0x413d39
xor eax, eax
mov dword [ebp - 0x28], 0
mov word [ebp - 0x28], ax
mov eax, edx
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 7
lea ebx, [eax + 2]
jmp 0x413c80
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x413c80
sub eax, ebx
lea ecx, [ebp - 0x28]
sar eax, 1
push eax
push edx
call fcn.00404580
mov byte [ebp - 4], 1
cmp esi, dword [ebp - 0x34]
je 0x413cec
mov eax, dword [ebp - 0x28]
mov edx, 7
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov dword [esi], eax
mov eax, dword [ebp - 0x24]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x20]
mov dword [esi + 8], eax
mov eax, dword [ebp - 0x1c]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x18]
mov dword [esi + 0x10], eax
mov eax, dword [ebp - 0x14]
mov dword [esi + 0x14], eax
xor eax, eax
add esi, 0x18
mov word [ebp - 0x28], ax
mov dword [ebp - 0x38], esi
jmp 0x413cff
lea eax, [ebp - 0x28]
push eax
push esi
lea ecx, [ebp - 0x3c]
call fcn.00401680
mov esi, dword [ebp - 0x38]
mov edx, dword [ebp - 0x14]
mov byte [ebp - 4], 0
cmp edx, 8
jb 0x413d36
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x413d2c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x413d77
push edx
push ecx
call fcn.0049995e
add esp, 8
mov eax, dword [ebp - 0x30]
inc edi
cmp edi, dword [ebp - 0x2c]
jl 0x413c50
mov ebx, dword [ebp - 0x3c]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 0x40]
mov ecx, dword [ebp - 0x34]
mov dword [eax], ebx
mov dword [eax + 4], esi
mov dword [eax + 8], ecx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
Function at 0x413d80
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49d6cd
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x28]
mov edi, dword [ebp + 8]
push esi
push eax
call fcn.00411eb0
lea eax, [ebp - 0x28]
mov dword [ebp - 4], 0
push eax
call fcn.00413e50
add esp, 0xc
test eax, eax
jne 0x413dd5
xor esi, esi
jmp 0x413df2
cmp dword [esi + 0x14], 8
jb 0x413ddd
mov esi, dword [esi]
cmp dword [edi + 0x14], 8
jb 0x413de5
mov edi, dword [edi]
push dword [ebp + 0x10]
push esi
push edi
call dword [sym.imp.KERNEL32.dll_CopyFileW]
mov esi, eax
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x413e2e
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x413e24
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x413e24
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push edx
push ecx
call fcn.0049995e
add esp, 8
mov eax, esi
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.0049996c
mov esp, ebp
pop ebp
ret
Function at 0x413e50
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x49d70d
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
mov eax, esi
cmp dword [esi + 0x14], 8
jb 0x413e86
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x413f48
cmp dword [esi + 0x14], 8
mov eax, esi
jb 0x413ea0
mov eax, dword [esi]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x413f48
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x413f48
lea eax, [ebp - 0x28]
push esi
push eax
call fcn.00411eb0
add esp, 8
cmp dword [ebp - 0x18], 0
mov dword [ebp - 4], 0
je 0x413f67
lea eax, [ebp - 0x28]
push eax
call fcn.00413e50
add esp, 4
test eax, eax
je 0x413f67
cmp dword [esi + 0x14], 8
jb 0x413ef8
mov esi, dword [esi]
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x413f12
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x413f67
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x413f48
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x413f3e
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x413f93
push edx
push ecx
call fcn.0049995e
add esp, 8
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x413fa3
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x413f99
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x413f99
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push edx
push ecx
call fcn.0049995e
add esp, 8
xor eax, eax
jmp 0x413f4d
Function at 0x4164f0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x4ce4bc]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x416520
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
mov eax, dword [eax]
test eax, eax
je 0x416550
mov edx, dword [esi + 0x30]
mov edx, dword [edx]
add edx, eax
cmp eax, edx
jae 0x416550
call dword [sym.imp.MSVCP140.dll_protected:_char____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void_]
pop esi
mov byte [eax], bl
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
push edi
je 0x41664b
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x416579
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 0x4165ad
push dword [esi + 0x4c]
movsx eax, bl
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret 4
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x28], bl
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x27]
push eax
lea eax, [ebp - 0x28]
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 0x41660c
sub eax, 1
je 0x41660c
sub eax, 2
jne 0x41664b
push dword [esi + 0x4c]
push dword [ebp - 0x28]
call fcn.0040e180
add esp, 8
or ecx, 0xffffffff
test al, al
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x41662a
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 0x41664b
lea eax, [ebp - 0x28]
mov byte [esi + 0x3d], 1
cmp dword [ebp - 0x30], eax
je 0x41664b
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0049996c
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.0049996c
mov esp, ebp
pop ebp
ret 4