joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403893
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x98
mov eax, dword [0x43e3ac]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, 0x94
lea eax, [ebp - 0x98]
push esi
push 0
push eax
call fcn.004098d0
add esp, 0xc
mov dword [ebp - 0x98], esi
lea eax, [ebp - 0x98]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x94], 6
mov ecx, dword [ebp - 4]
sbb eax, eax
xor ecx, ebp
inc eax
pop esi
call fcn.004078da
leave
ret

Function at 0x40489f
Capabilities:
Access the windows event log

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x43e3ac]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, str.NAIMServInst
mov dword [0x440768], eax
push edi
xor ebx, ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceA]
push dword [0x440768]
mov esi, eax
lea eax, [ebp - 0x104]
push edi
push str._s_error:__d
push 0x100
push eax
call fcn.00401c6e
lea eax, [ebp - 0x104]
add esp, 0x14
mov dword [ebp - 0x10c], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x108], eax
test esi, esi
je 0x404928
push ebx
lea eax, [ebp - 0x10c]
push eax
push ebx
push 2
push ebx
push ebx
push ebx
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ReportEventA]
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004078da
leave
ret
Function at 0x404b07
Capabilities:
Delete directory
Enumerate files on windows

Disassembly:
push 0x174
mov eax, 0x42cf59
call fcn.00407999
mov esi, dword [ebp + 8]
push esi
call fcn.0040c7c0
pop ecx
cmp eax, 4
jb 0x404c87
push esi
lea ecx, [ebp - 0x40]
call fcn.00402782
and dword [ebp - 4], 0
mov edi, str..
push edi
call fcn.0040c7c0
pop ecx
push eax
push edi
lea ecx, [ebp - 0x40]
call fcn.004049b3
cmp dword [ebp - 0x2c], 0x10
lea ecx, [ebp - 0x180]
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x404b82
cmp dword [ebp - 0x2c], 0x10
lea eax, [ebp - 0x40]
cmovae eax, dword [ebp - 0x40]
push eax
push str.FindFirstFile___s_
jmp 0x404c6b
push esi
lea ecx, [ebp - 0x28]
call fcn.00402782
push 0x42e9a8
mov byte [ebp - 4], 1
call fcn.0040c7c0
pop ecx
push eax
push 0x42e9a8
lea ecx, [ebp - 0x28]
call fcn.004049b3
lea eax, [ebp - 0x154]
push eax
call fcn.0040c7c0
pop ecx
push eax
lea eax, [ebp - 0x154]
push eax
lea ecx, [ebp - 0x28]
call fcn.004049b3
test byte [ebp - 0x180], 0x14
je 0x404c1c
lea eax, [ebp - 0x154]
push 0x42e9ac
push eax
call fcn.00417dd0
pop ecx
pop ecx
test eax, eax
je 0x404c31
lea eax, [ebp - 0x154]
push 0x42e9b0
push eax
call fcn.00417dd0
pop ecx
pop ecx
test eax, eax
je 0x404c31
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
push str.Unexpected_directory_in_error_cleanup___s_
push str.Stub
call fcn.00401107
add esp, 0xc
jmp 0x404c31
cmp dword [ebp - 0x14], 0x10
lea eax, [ebp - 0x28]
push 0
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.00401875
pop ecx
pop ecx
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0
call fcn.00404835
lea eax, [ebp - 0x180]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x404b82
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x404c7f
push esi
push str.RemoveDirectory___s_
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Stub
call fcn.00401692
add esp, 0x10
lea ecx, [ebp - 0x40]
call fcn.00404835
call fcn.00407948
ret
Function at 0x404d92
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa48
mov eax, dword [0x43e3ac]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov ebx, 0x43f458
push ebx
call fcn.0040c7c0
push eax
lea eax, [ebp - 0x108]
push ebx
push eax
call fcn.0040c850
add esp, 0x10
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp byte [ebp + eax - 0x109], 0x5c
je 0x404dec
push 0x42e9a8
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x908]
push str._s.
push eax
call fcn.00401c53
add esp, 0xc
lea eax, [ebp - 0xa48]
push eax
lea eax, [ebp - 0x908]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x404e38
push str.FindFirstFile_failed
push str.Stub
call fcn.00401120
pop ecx
pop ecx
jmp 0x404f00
push edi
mov edi, str.Stub
test byte [ebp - 0xa48], 0x14
lea eax, [ebp - 0xa1c]
je 0x404e71
push 0x42e9ac
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x404eca
push 0x42e9b0
lea eax, [ebp - 0xa1c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
jmp 0x404eca
push eax
lea eax, [ebp - 0x108]
push eax
push 0x42e650
lea eax, [ebp - 0x508]
push 0x400
push eax
call fcn.00401bd7
add esp, 0x14
lea eax, [ebp - 0x508]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0x508]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x404eca
lea eax, [ebp - 0x508]
push eax
push str.Unable_to_delete_file__s
push edi
call fcn.00401120
add esp, 0xc
lea eax, [ebp - 0xa48]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x404e3e
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
push ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x404eff
push str.Unable_to_delete_temp_directory
push edi
call fcn.00401120
pop ecx
pop ecx
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.004078da
leave
ret
Function at 0x40669e
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push edi
push 0x2711
call fcn.00407926
mov edi, eax
test edi, edi
push 0x8e
setne bl
mov byte [ebp - 4], bl
push dword [ebp - 4]
call fcn.00405a20
add esp, 0xc
test edi, edi
je 0x40675e
push esi
push dword [ebp + 8]
mov esi, 0x2710
push esi
push 1
push edi
call fcn.00415ff8
add esp, 0x10
mov dword [ebp - 8], eax
cmp eax, esi
jne 0x406731
push dword [ebp + 0xc]
push esi
push 1
push edi
call fcn.0041669a
mov esi, eax
cmp esi, 0x2710
push 0x97
sete bl
mov byte [ebp - 4], bl
push dword [ebp - 4]
call fcn.00405a20
push dword [ebp + 8]
push 0x2710
push 1
push edi
call fcn.00415ff8
add esp, 0x28
cmp esi, dword [ebp - 8]
mov esi, 0x2710
je 0x4066e6
mov dword [ebp - 8], eax
pop esi
test bl, bl
je 0x40675e
push dword [ebp + 0xc]
push eax
push 1
push edi
call fcn.0041669a
cmp eax, dword [ebp - 8]
push 0x9e
sete bl
mov byte [ebp - 4], bl
push dword [ebp - 4]
call fcn.00405a20
add esp, 0x18
cmp dword [ebp + 0xc], 0
je 0x40676d
push dword [ebp + 0xc]
call fcn.00415d21
pop ecx
cmp dword [ebp + 8], 0
je 0x40677c
push dword [ebp + 8]
call fcn.00415d21
pop ecx
test bl, bl
je 0x4067a0
push dword [ebp + 0x14]
push dword [ebp + 0x10]
call fcn.00406f70
mov bl, al
mov byte [ebp - 4], bl
push 0x11c
push dword [ebp - 4]
call fcn.00405a20
add esp, 0x10
test edi, edi
je 0x4067ab
push edi
call fcn.0040792f
pop ecx
pop edi
mov al, bl
pop ebx
leave
ret

Function at 0x4069b4
Capabilities:
Access the windows event log

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
xor ebx, ebx
mov edi, 0x400
push 1
push edi
mov dword [ebp - 8], ebx
mov dword [ebp - 4], ebx
call fcn.004166d4
pop ecx
pop ecx
push edi
mov esi, eax
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push str.MsiInstaller
push ebx
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceA]
mov edi, eax
test edi, edi
je 0x406a19
push ebx
lea eax, [ebp - 8]
mov dword [ebp - 8], str.Trellix_Agent_installation_failed_because_this_operating_system_is_not_supported._Installation_action_invoked_from_:__2
push eax
push ebx
push 2
push ebx
push 0x2dbc
push ebx
push 1
push edi
mov dword [ebp - 4], esi
call dword [sym.imp.ADVAPI32.dll_ReportEventA]
push edi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
push esi
call fcn.004166df
pop ecx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x406a25
Capabilities:
Access the windows event log

Disassembly:
push 0x30
mov eax, 0x42d0d4
call fcn.00407999
mov eax, dword [ebp + 0x18]
lea ecx, [ebp + 8]
xor ebx, ebx
mov dword [ebp - 0x20], 0xf
cmp dword [ebp + 0x1c], 8
lea esi, [ebp + 8]
mov dword [ebp - 4], ebx
cmovae ecx, dword [ebp + 8]
cmovae esi, dword [ebp + 8]
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
lea edi, [ecx + eax*2]
mov dword [ebp - 0x14], ebx
mov eax, edi
mov dword [ebp - 0x34], ebx
sub eax, esi
mov dword [ebp - 0x24], ebx
sar eax, 1
lea ecx, [ebp - 0x34]
push eax
call fcn.00405d19
mov byte [ebp - 0x38], bl
lea ecx, [ebp - 0x34]
push dword [ebp - 0x38]
push edi
push esi
call fcn.00401f4b
push str.MsiInstaller
push ebx
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceA]
mov esi, eax
test esi, esi
je 0x406ad0
cmp dword [ebp - 0x20], 0x10
lea eax, [ebp - 0x1c]
push ebx
push eax
push ebx
push 3
push ebx
push 0x2dbc
push ebx
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x1c], str.Trellix_Agent_installation_failed_because_it_detected_the_following_products_as_incompatible_with_this_version_:__2___3
cmovae ecx, dword [ebp - 0x34]
push 1
push esi
mov dword [ebp - 0x18], str.MAR_____1000
mov dword [ebp - 0x14], ecx
call dword [sym.imp.ADVAPI32.dll_ReportEventA]
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov eax, dword [ebp - 0x20]
cmp eax, 0x10
jb 0x406b07
mov ecx, dword [ebp - 0x34]
inc eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], ecx
cmp eax, 0x1000
jb 0x406afe
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x38]
push eax
call fcn.0040395c
mov eax, dword [ebp - 0x3c]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x38]
push eax
push ecx
call fcn.00407918
pop ecx
pop ecx
lea ecx, [ebp + 8]
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], 0xf
mov byte [ebp - 0x34], bl
call fcn.0040485b
call fcn.00407948
ret

Function at 0x40cbab
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x40cbea
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x40cbea
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x40cbea
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x40cbea
cmp dword [ecx + 0x74], 0xe
jbe 0x40cbea
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x419723
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
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 + 0x441890]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x419763
cmp byte [ebx], 0xa
jne 0x419763
or byte [edi + eax + 0x28], 4
jmp 0x419768
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x419867
mov dl, byte [eax]
cmp dl, 0x1a
je 0x41984a
inc eax
cmp dl, 0xd
je 0x419794
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x4197ba
cmp eax, ecx
jae 0x4197c8
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x41977c
jmp 0x419867
push 0
lea eax, [ebp - 0x10]
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 0x419845
cmp dword [ebp - 0x10], 0
je 0x419845
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x441890]
test byte [eax + edi + 0x28], 0x48
je 0x41981f
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x41980a
mov byte [esi], dl
jmp 0x41981b
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x441890]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x419867
cmp byte [ebp - 1], 0xa
jne 0x41982e
cmp esi, ebx
jne 0x41982e
mov byte [esi], 0xa
jmp 0x419866
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.004196c5
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x419867
mov byte [esi], 0xd
jmp 0x419866
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x441890]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x419864
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x419867
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x419870
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x441890]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x4198b6
cmp word [ebx], dx
jne 0x4198b6
or byte [eax + edi + 0x28], 4
jmp 0x4198bb
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x419a1e
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x4199fe
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x4198fc
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x419932
cmp eax, edx
jae 0x419940
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
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 - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x4198d7
jmp 0x419a1e
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4199f9
cmp dword [ebp - 0x18], 0
je 0x4199f9
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x441890]
test byte [eax + edi + 0x28], 0x48
je 0x4199cf
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x419993
mov word [esi], cx
jmp 0x4199ca
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x441890]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x441890]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x441890]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x419a1e
pop eax
cmp word [ebp - 4], ax
jne 0x4199df
cmp esi, ebx
jne 0x4199df
mov word [esi], ax
jmp 0x419a1b
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.004196c5
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x419a1e
push 0xd
pop eax
jmp 0x4199da
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x441890]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x419a18
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x419a1e
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x420c8e
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.0042c720
mov eax, dword [0x43e3ac]
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.0041fca5
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x420cd0
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x420e2c
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.0042c5b0
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 + 0x441890]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.004196a7
mov ecx, dword [esi*4 + 0x441890]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x420e25
cmp eax, dword [ecx + edi + 0x24]
jne 0x420e25
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x420e25
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004196a7
add esp, 0x14
test edx, edx
jl 0x420e25
jg 0x420d9b
test eax, eax
jb 0x420e25
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x420e25
jl 0x420db5
cmp dword [ebp - 0x1008], eax
ja 0x420e25
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x420dd3
test ebx, ebx
je 0x420e0c
cmp ecx, edi
jae 0x420e0c
mov al, byte [ecx]
cmp al, 0xd
jne 0x420ded
lea eax, [edi - 1]
cmp ecx, eax
jae 0x420df9
cmp byte [ecx + 1], 0xa
jne 0x420df9
inc ecx
jmp 0x420df9
movzx eax, al
movsx eax, byte [eax + 0x43e500]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x420dd3
cmp edx, ebx
jne 0x420dd3
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x420e2a
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004078da
leave
ret

Function at 0x42210d
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4335b0
push 0x4335a8
push str.FlsAlloc
push 0x1f
call fcn.00421fd5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x422141
push dword [ebp + 8]
mov ecx, esi
call dword [0x42e200]
call esi
jmp 0x422147
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x42218b
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4335c0
push 0x4335b8
push str.FlsGetValue
push 0x21
call fcn.00421fd5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4221c2
push dword [ebp + 8]
mov ecx, esi
call dword [0x42e200]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x4221ca
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x4335c8
push 0x4335c0
push str.FlsSetValue
push 0x22
call fcn.00421fd5
mov esi, eax
add esp, 0x10
test esi, esi
je 0x422204
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x42e200]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]

Function at 0x4229d9
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]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.00422955
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x422b48
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x422b48
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x422afd
jg 0x422a35
test eax, eax
je 0x422af3
push 1
push 0x1000
call fcn.00420160
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x422a58
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x422aea
push 0x8000
push ebx
call fcn.0041b6e3
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x422a81
jg 0x422a7c
cmp ecx, 0x1000
jb 0x422a81
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.0041a98d
add esp, 0x10
cmp eax, 0xffffffff
je 0x422ac6
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 0x422a7c
jl 0x422aad
test ecx, ecx
jne 0x422a6e
push dword [ebp - 0xc]
push ebx
call fcn.0041b6e3
push esi
call fcn.0041eded
add esp, 0xc
xor ebx, ebx
jmp 0x422b56
cmp byte [edi + 0x24], 0
je 0x422add
cmp dword [edi + 0x20], 5
jne 0x422add
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x422ae8
mov ebx, dword [edi + 0x18]
jmp 0x422aea
xor ebx, ebx
push esi
call fcn.0041eded
pop ecx
jmp 0x422b56
test ecx, ecx
jg 0x422abf
jl 0x422afd
test eax, eax
jae 0x422abf
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.004196c5
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x422b1d
cmp byte [edi + 0x1c], 0
je 0x422abf
jmp 0x422b4e
push ebx
call fcn.004228eb
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x422abf
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x422b56
cmp byte [edi + 0x1c], 0
je 0x422b53
mov ebx, dword [edi + 0x18]
jmp 0x422b56
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.004196c5
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4241b0
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 0x42424d
push ebx
push esi
call fcn.00424179
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.00422c56
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x4241fa
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x42424c
push edi
push eax
call fcn.0041ee27
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x42421a
call fcn.0041eded
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x42424b
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.00422c56
add esp, 0x20
test eax, eax
jne 0x424239
push edi
call fcn.0041eded
jmp 0x424241
push ebx
call fcn.0041eded
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 0x42635f
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
call fcn.0041e639
mov esi, dword [ebp + 8]
mov edi, eax
push 2
lea eax, [ebp - 4]
mov ecx, esi
push eax
and ecx, 0x3ff
push 0x20000001
or ecx, 0x400
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x4263ce
cmp esi, dword [ebp - 4]
je 0x4263c9
cmp dword [ebp + 0xc], 0
je 0x4263c9
mov esi, dword [edi + 0x50]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x4263a6
push dword [edi + 0x50]
sub esi, ecx
sar esi, 1
call fcn.00425e9c
pop ecx
xor ecx, ecx
cmp eax, esi
setne cl
mov eax, ecx
jmp 0x4263d0
xor eax, eax
inc eax
jmp 0x4263d0
xor eax, eax
pop edi
pop esi
leave
ret