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

Disassembly:
push esi
push 0x40a374
call fcn.00402966
push 0x40a368
call fcn.00402966
push 7
push 0x40a360
push 0x40a354
call fcn.00401420
push 0x32
push 0x40a348
push 0x40a354
call fcn.00401420
push 7
push 0x40a360
push 0x40a33c
call fcn.00401420
push 0x24
push 0x40a330
push 0x40a33c
call fcn.00401420
mov esi, dword [sym.imp.KERNEL32.dll_WinExec]
add esp, 0x38
push 0
push 0x40a2f0
call esi
push 0
push 0x40a2b0
call esi
pop esi
ret

Function at 0x401930
Capabilities:
Accept command line arguments
Create process on windows
Hide graphical window

Disassembly:
sub esp, 0x54
mov eax, dword [0x40a464]
mov ecx, dword [0x40a468]
mov edx, dword [0x40a46c]
push esi
mov dword [esp + 4], eax
mov ax, word [0x40a470]
push edi
push 0x40b108
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], edx
mov word [esp + 0x18], ax
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
inc eax
push eax
call fcn.00401ba0
mov eax, dword [esp + 0x6c]
add esp, 8
test eax, eax
jne 0x401acb
mov esi, dword [esp + 0x60]
push 0x7f00
push 0
mov dword [esp + 0x3c], 3
mov dword [esp + 0x40], 0x4017a0
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], 0
mov dword [esp + 0x4c], esi
call dword [sym.imp.USER32.dll_LoadIconA]
push 0x7f00
push 0
mov dword [esp + 0x50], eax
call dword [sym.imp.USER32.dll_LoadCursorA]
push 2
mov dword [esp + 0x50], eax
call dword [sym.imp.GDI32.dll_GetStockObject]
lea edx, [esp + 0x34]
lea ecx, [esp + 8]
push edx
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], 0
mov dword [esp + 0x5c], ecx
call dword [sym.imp.USER32.dll_RegisterClassA]
test ax, ax
je 0x401acb
push 0
push esi
push 0
push 0
push 0
push 0
push 0
push 0
push 0xcf0000
lea eax, [esp + 0x2c]
push 0x40a44c
push eax
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 1
push 0xfa
push 0x258
push 1
mov esi, eax
call edi
sub eax, 0xfa
cdq
sub eax, edx
sar eax, 1
push eax
push 0
call edi
sub eax, 0x258
cdq
sub eax, edx
sar eax, 1
push eax
push esi
call dword [sym.imp.USER32.dll_MoveWindow]
mov ecx, dword [esp + 0x6c]
push ecx
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_UpdateWindow]
mov esi, dword [sym.imp.USER32.dll_GetMessageA]
push 0
push 0
lea edx, [esp + 0x20]
push 0
push edx
call esi
test eax, eax
je 0x401aae
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
push ebx
mov ebx, dword [sym.imp.USER32.dll_DispatchMessageA]
lea eax, [esp + 0x1c]
push eax
call edi
lea ecx, [esp + 0x1c]
push ecx
call ebx
push 0
push 0
lea edx, [esp + 0x24]
push 0
push edx
call esi
test eax, eax
jne 0x401a8e
pop ebx
mov eax, dword [0x40b188]
test eax, eax
je 0x401ad5
push 0
push 0x40a260
push 0x40a414
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop edi
xor eax, eax
pop esi
add esp, 0x54
ret 0x10
push 3
call fcn.00402a18
push 0x40a374
call fcn.00402992
mov edi, dword [sym.imp.KERNEL32.dll_WinExec]
add esp, 8
xor esi, esi
push 1
push 0x40a400
call edi
cmp eax, 0x1f
ja 0x401b12
push 0x3e8
call fcn.00401be0
add esp, 4
inc esi
cmp esi, 0xa
jl 0x401af1
pop edi
mov eax, 1
pop esi
add esp, 0x54
ret 0x10
Function at 0x401be0
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0x1c
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
push edi
call esi
mov edi, eax
call esi
mov ebx, dword [esp + 0x2c]
sub eax, edi
cmp eax, ebx
jge 0x401c1b
push ebp
mov ebp, dword [sym.imp.USER32.dll_PeekMessageA]
push 1
push 0
push 0
lea eax, [esp + 0x1c]
push 0
push eax
call ebp
call esi
sub eax, edi
cmp eax, ebx
jl 0x401c03
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1c
ret

Function at 0x405f5d
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x40a6c8
cmp edx, dword [eax]
je 0x405f7f
add eax, 8
inc ecx
cmp eax, 0x40a758
jl 0x405f70
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x40a6c8]
jne 0x4060ad
mov eax, dword [0x40b1a8]
cmp eax, 1
je 0x406087
test eax, eax
jne 0x405fb0
cmp dword [0x40a48c], 1
je 0x406087
cmp edx, 0xfc
je 0x4060ad
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x405fe7
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.004075e0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00406270
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x40602a
lea eax, [ebp - 0x1a4]
push eax
call fcn.00406270
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x409674
push edi
call fcn.00407ce0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.004075e0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.004075f0
lea eax, [ebp - 0xa0]
push 0x409654
push eax
call fcn.004075f0
push dword [esi + 0x40a6cc]
lea eax, [ebp - 0xa0]
push eax
call fcn.004075f0
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00407c50
add esp, 0x2c
pop edi
jmp 0x4060ad
lea eax, [ebp + 8]
lea esi, [esi + 0x40a6cc]
push 0
push eax
push dword [esi]
call fcn.00406270
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 0x401ae0
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
mov dword [0x40406c], eax
push str.Riched32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push 0
mov ecx, dword [ebp + 8]
push ecx
push 0
push 0
push 0
push 0x80000000
push 0
push 0x80000000
push 0xcf0000
push str.mifedount
push str.Deltapo
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x401b33
xor eax, eax
jmp 0x401b4e
push 0
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.USER32.dll_UpdateWindow]
mov eax, 1
mov esp, ebp
pop ebp
ret
Function at 0x40197d
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov eax, dword [esp + 8]
mov dword [0x4040d0], eax
xor eax, eax
mov ebp, esp
mov ecx, 0xa
push eax
dec ecx
jne 0x401990
push esp
mov dword [ebp - 0x24], 0x4016f4
mov eax, dword [0x4040d0]
mov dword [ebp - 0x18], eax
mov dword [ebp - 4], str.solienty
call dword [sym.imp.USER32.dll_RegisterClassA]
xor eax, eax
push eax
push dword [0x4040d0]
push eax
push eax
push 0x190
push 0x2b2
push 0x640
push 0x9c4
push 0
push str.absent
push str.solienty
push eax
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x4040d8], eax
push 0
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
xor eax, eax
push eax
push eax
push eax
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x401a2f
mov esi, dword [sym.imp.USER32.dll_TranslateMessage]
mov edi, dword [sym.imp.USER32.dll_DispatchMessageA]
lea eax, [ebp - 0x1c]
push eax
call esi
lea ecx, [ebp - 0x1c]
push ecx
call edi
xor eax, eax
push eax
push eax
push eax
lea edx, [ebp - 0x1c]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
jne 0x401a10
pop ebp
ret 0x10

Function at 0x4025ad
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x406330
cmp edx, dword [eax]
je 0x4025cf
add eax, 8
inc ecx
cmp eax, 0x4063c0
jl 0x4025c0
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x406330]
jne 0x4026fd
mov eax, dword [0x40873c]
cmp eax, 1
je 0x4026d7
test eax, eax
jne 0x402600
cmp dword [0x406284], 1
je 0x4026d7
cmp edx, 0xfc
je 0x4026fd
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x402637
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00402b90
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00402d40
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x40267a
lea eax, [ebp - 0x1a4]
push eax
call fcn.00402d40
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x405418
push edi
call fcn.004043e0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00402b90
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00402ba0
lea eax, [ebp - 0xa0]
push 0x4053f8
push eax
call fcn.00402ba0
push dword [esi + 0x406334]
lea eax, [ebp - 0xa0]
push eax
call fcn.00402ba0
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00404354
add esp, 0x2c
pop edi
jmp 0x4026fd
lea eax, [ebp + 8]
lea esi, [esi + 0x406334]
push 0
push eax
push dword [esi]
call fcn.00402d40
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 0x4014b9
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push dword [ebp + 8]
mov esi, ecx
lea ecx, [esi + 8]
call fcn.0040801c
push dword [ebp + 0xc]
lea edi, [esi + 0xc]
mov ecx, edi
call fcn.004016f2
push 0x5c
mov ecx, edi
call fcn.0040178f
cmp dword [0x419724], 3
mov dword [0x4196a8], esi
jne 0x401521
push dword [0x4196f0]
call fcn.00401bfb
imul eax, eax, 0x3e8
pop ecx
mov dword [esi + 0x30], eax
mov ecx, 0x3e8
cmp eax, ecx
jae 0x401512
mov dword [esi + 0x30], ecx
lea eax, [ebp + 8]
xor edi, edi
push eax
push edi
push esi
push 0x401630
jmp 0x401534
lea eax, [ebp + 8]
xor edi, edi
push eax
push edi
push esi
mov dword [0x4196b0], edi
push 0x4015d5
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp dword [0x41971c], 2
mov dword [0x4196ac], eax
jne 0x401553
cmp dword [0x419724], 3
jne 0x401558
call fcn.00406eb5
push 0xffffffffffffffff
push dword [0x4196ac]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x4196b0]
mov dword [0x41972c], edi
cmp eax, edi
je 0x4015ab
mov ecx, eax
dec ecx
je 0x40159f
dec ecx
je 0x40159b
dec ecx
je 0x401597
push eax
push 0x14
push edi
call fcn.00406d83
add esp, 0xc
mov eax, 0x80004005
pop edi
pop esi
leave
ret 8
push 0x12
jmp 0x4015a1
push 0x13
jmp 0x4015a1
push 0x11
push edi
call fcn.00406d83
pop ecx
pop ecx
jmp 0x40158c
cmp dword [0x419730], edi
jne 0x40158c
lea eax, [ebp - 4]
push eax
push dword [0x4196ac]
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
test eax, eax
je 0x40158c
cmp dword [ebp - 4], edi
jne 0x40158c
xor eax, eax
jmp 0x401591

Function at 0x401aa5
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x250
push esi
mov esi, dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x401ac2
xor eax, eax
jmp 0x401b11
mov eax, dword [0x419720]
test eax, eax
je 0x401afe
cmp eax, 2
jne 0x401b0e
lea eax, [ebp - 0x250]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
je 0x401afe
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
push dword [ebp + 0xc]
lea eax, [ebp - 0x23c]
push eax
call dword [sym.imp.KERNEL32.dll_CompareFileTime]
test eax, eax
jge 0x401b0e
push esi
call fcn.004024f2
neg eax
sbb eax, eax
pop ecx
neg eax
dec eax
jmp 0x401b11
push 1
pop eax
pop esi
leave
ret

Function at 0x401b14
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push 0
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x401b47
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x401b44
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x401b47
test al, 0x10
jne 0x401b47
xor eax, eax
ret
push 1
pop eax
ret
Function at 0x401b4b
Capabilities:
Query environment variable

Disassembly:
mov eax, 0x411db8
call fcn.00411950
sub esp, 0xc
push ebx
push esi
push edi
xor ebx, ebx
push 0xf
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
call fcn.00401838
cmp dword [ebp - 0x10], 1
mov dword [ebp - 4], ebx
jg 0x401b83
push 2
lea ecx, [ebp - 0x18]
call fcn.00401838
mov edi, dword [ebp + 8]
mov esi, dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push 1
push dword [ebp - 0x18]
mov eax, dword [edi]
push eax
call esi
cmp eax, ebx
je 0x401bdf
lea ebx, [eax + 1]
cmp ebx, dword [ebp - 0x10]
jl 0x401bae
lea eax, [ebx + 1]
lea ecx, [ebp - 0x18]
push eax
call fcn.00401838
mov eax, dword [edi]
push ebx
push dword [ebp - 0x18]
push eax
call esi
mov ecx, dword [ebp - 0x18]
xor esi, esi
xor eax, eax
cmp word [ecx], si
je 0x401bcd
mov edx, ecx
inc eax
inc edx
inc edx
cmp word [edx], si
jne 0x401bc5
mov word [ecx + eax*2], si
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x18]
mov ecx, edi
push eax
call fcn.00401751
push dword [ebp - 0x18]
or dword [ebp - 4], 0xffffffff
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
pop edi
mov ecx, dword [ebp - 0xc]
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x402287
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenW]
push esi
push edi
push dword [ebp + 8]
call ebx
lea esi, [eax + eax + 2]
mov dword [ebp - 4], eax
push esi
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
push esi
mov esi, dword [ebp + 8]
mov edi, eax
push esi
push edi
call sub.MSVCRT.dll_memcpy
mov eax, dword [ebp - 4]
add esp, 0x10
lea ecx, [eax + eax]
mov ax, word [ecx + esi - 2]
cmp ax, 0x5c
je 0x4022cf
cmp ax, 0x2f
jne 0x4022d8
and word [ecx + edi - 2], 0
dec dword [ebp - 4]
push edi
call ebx
mov esi, eax
push edi
call fcn.00401b14
test eax, eax
pop ecx
jne 0x40233c
test esi, esi
jle 0x402307
lea eax, [edi + esi*2]
mov cx, word [eax]
cmp cx, 0x2f
je 0x402305
cmp cx, 0x5c
je 0x402305
dec esi
dec eax
dec eax
test esi, esi
jg 0x4022ef
test esi, esi
je 0x402310
and word [edi + esi*2], 0
jmp 0x4022dd
cmp dword [ebp - 4], 2
mov ecx, dword [ebp + 8]
jne 0x402335
mov ax, word [ecx]
or al, 0x20
cmp ax, 0x61
jb 0x402335
cmp ax, 0x7a
ja 0x402335
cmp word [ecx + 2], 0x3a
je 0x4023c6
push ecx
push 0xc
push 0
jmp 0x4023ba
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x4023aa
lea eax, [ebp - 0xc]
push eax
push edi
call fcn.00401aa5
pop ecx
test eax, eax
pop ecx
je 0x4023aa
jmp 0x4023c2
cmp esi, dword [ebp - 4]
jge 0x4023c6
mov eax, dword [ebp - 4]
lea ebx, [edi + esi*2]
sub eax, esi
inc eax
push eax
mov eax, dword [ebp + 8]
lea eax, [eax + esi*2]
push eax
push ebx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
cmp word [ebx], 0
je 0x402389
inc esi
lea ecx, [edi + esi*2]
mov ax, word [ecx]
test ax, ax
je 0x4023a5
cmp ax, 0x5c
je 0x4023a5
cmp word [ecx], 0x2f
je 0x4023a5
inc esi
inc ecx
inc ecx
jmp 0x40238c
and word [edi + esi*2], 0
push edi
call fcn.00401b14
test eax, eax
pop ecx
jne 0x402363
push edi
push 0xc
push 1
call fcn.00406d83
add esp, 0xc
xor eax, eax
jmp 0x4023c9
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4023ce
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
mov eax, 0x411ea4
call fcn.00411950
sub esp, 0x25c
push ebx
push esi
push edi
lea ecx, [ebp - 0x18]
push dword [ebp + 8]
call fcn.00402c9c
and dword [ebp - 4], 0
push 0x418060
lea ecx, [ebp - 0x18]
call fcn.00402cfd
lea eax, [ebp - 0x268]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov esi, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4024b5
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpW]
push dword [ebp + 8]
lea ecx, [ebp - 0x18]
call fcn.004016f2
push 0x5c
lea ecx, [ebp - 0x18]
call fcn.0040178f
lea eax, [ebp - 0x23c]
lea ecx, [ebp - 0x18]
push eax
call fcn.00402cfd
test byte [ebp - 0x268], 0x10
je 0x402480
lea eax, [ebp - 0x23c]
push 0x41805c
push eax
call ebx
test eax, eax
je 0x402498
lea eax, [ebp - 0x23c]
push 0x418054
push eax
call ebx
test eax, eax
je 0x402498
push dword [ebp - 0x18]
call fcn.004023ce
pop ecx
jmp 0x402494
push 0
push dword [ebp - 0x18]
call esi
test eax, eax
je 0x4024d2
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x4024d2
lea eax, [ebp - 0x268]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x402424
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
push 0
push dword [ebp + 8]
call esi
test eax, eax
je 0x4024d2
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x4024d2
push 1
pop esi
jmp 0x4024d4
xor esi, esi
push dword [ebp - 0x18]
or dword [ebp - 4], 0xffffffff
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
mov eax, esi
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x4024f2
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x402508
push 1
pop eax
pop esi
ret
test al, 0x10
jne 0x402526
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x402522
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
pop esi
ret
xor eax, eax
pop esi
ret
push esi
call fcn.004023ce
pop ecx
pop esi
ret
Function at 0x4030b7
Capabilities:
Identify system language via api

Disassembly:
mov eax, dword [0x4180c0]
push esi
xor esi, esi
test eax, eax
je 0x4030d9
mov ecx, 0x4180c0
cmp eax, dword [esp + 8]
je 0x4030d9
mov eax, dword [ecx + 0xc]
add ecx, 0xc
inc esi
test eax, eax
jne 0x4030c8
mov ax, word [0x418228]
cmp ax, 0xffff
jne 0x4030f1
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
mov word [0x418228], ax
cmp ax, 0x419
jne 0x403105
lea eax, [esi + esi*2]
mov eax, dword [eax*4 + 0x4180c8]
test eax, eax
jne 0x40310f
lea eax, [esi + esi*2]
mov eax, dword [eax*4 + 0x4180c4]
pop esi
ret

Function at 0x4031fe
Capabilities:
Get common file path

Disassembly:
mov eax, 0x411f88
call fcn.00411950
sub esp, 0x2a4
push ebx
push esi
push edi
push 3
call fcn.004030b7
push 2
mov dword [0x419718], eax
call fcn.004030b7
push 5
mov dword [0x419714], eax
call fcn.004030b7
push 0x15
mov dword [0x419710], eax
call fcn.004030b7
push 0x16
mov dword [0x41970c], eax
call fcn.004030b7
push 0x17
mov dword [0x419708], eax
call fcn.004030b7
xor edi, edi
add esp, 0x18
mov dword [0x419704], eax
mov dword [0x4196fc], edi
mov dword [0x419700], edi
xor ebx, ebx
mov esi, 0x4196b8
push edi
lea eax, [ebp - 0x2b0]
push ebx
push eax
push edi
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40332b
push ebx
lea eax, [ebp - 0xa4]
push str.7zSfxFolder_02d
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea ecx, [ebp - 0x24]
call fcn.00403344
lea eax, [ebp - 0xa4]
lea ecx, [ebp - 0x24]
push eax
mov dword [ebp - 4], edi
call fcn.004016f2
lea eax, [ebp - 0x2b0]
lea ecx, [ebp - 0x18]
push eax
call fcn.004016f2
lea eax, [ebp - 0x24]
mov ecx, esi
push eax
call fcn.00402e3a
mov edi, 0x418e54
cmp dword [edi - 4], ebx
jne 0x403301
push dword [edi]
lea ecx, [ebp - 0x24]
call fcn.004016f2
lea eax, [ebp - 0x2b0]
lea ecx, [ebp - 0x18]
push eax
call fcn.004016f2
lea eax, [ebp - 0x24]
mov ecx, esi
push eax
call fcn.00402e3a
add edi, 8
cmp edi, str.MyDocs
jb 0x4032d8
push dword [ebp - 0x18]
mov dword [ebp - 4], 1
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
push dword [ebp - 0x24]
or dword [ebp - 4], 0xffffffff
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
xor edi, edi
pop ecx
inc ebx
cmp ebx, 0x40
jl 0x403271
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x40338c
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
mov eax, 0x411fc7
call fcn.00411950
sub esp, 0x18
push ebx
push esi
push edi
xor ebx, ebx
push 0xf
lea ecx, [ebp - 0x24]
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
call fcn.00401838
cmp dword [ebp - 0x1c], 2
push 1
pop edi
mov dword [ebp - 4], edi
jg 0x4033ca
push 3
lea ecx, [ebp - 0x24]
call fcn.00401838
push dword [ebp - 0x24]
mov esi, dword [sym.imp.KERNEL32.dll_GetTempPathW]
push edi
call esi
mov ecx, dword [ebp - 0x24]
mov word [ecx], bx
xor ecx, ecx
cmp eax, ebx
mov dword [ebp - 0x20], ecx
jbe 0x40341d
lea edi, [eax + 1]
cmp edi, dword [ebp - 0x1c]
jl 0x4033f9
lea eax, [edi + 1]
lea ecx, [ebp - 0x24]
push eax
call fcn.00401838
push dword [ebp - 0x24]
push edi
call esi
mov eax, dword [ebp - 0x24]
xor ecx, ecx
cmp word [eax], bx
je 0x403413
mov edx, eax
inc ecx
inc edx
inc edx
cmp word [edx], bx
jne 0x40340b
push 1
mov word [eax + ecx*2], bx
mov dword [ebp - 0x20], ecx
pop edi
lea eax, [ecx + 0xf]
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], eax
lea esi, [ecx + ecx]
jmp 0x40342e
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp - 0x1c]
jl 0x40343d
inc eax
lea ecx, [ebp - 0x24]
push eax
call fcn.00401838
push dword [ebp - 0x10]
mov eax, dword [ebp - 0x24]
add eax, esi
push dword [ebp + 0xc]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov ecx, dword [ebp - 0x24]
add esp, 0xc
xor eax, eax
cmp word [ecx], bx
je 0x403466
mov edx, ecx
inc eax
inc edx
inc edx
cmp word [edx], bx
jne 0x40345e
mov word [ecx + eax*2], bx
push dword [ebp - 0x24]
mov dword [ebp - 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x403487
inc dword [ebp - 0x10]
cmp dword [ebp - 0x10], 0xfff
jl 0x40342b
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x24]
push eax
call fcn.004016b8
mov dword [ebp - 0x18], edi
push dword [ebp - 0x24]
mov byte [ebp - 4], bl
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [ebp + 8]
pop ecx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x4034ea
Capabilities:
Set environment variable

Disassembly:
mov eax, 0x411fdc
call fcn.00411950
sub esp, 0xc
push esi
xor esi, esi
cmp dword [0x4196c0], esi
jle 0x40354e
mov eax, dword [0x4196c4]
lea ecx, [ebp - 0x18]
mov eax, dword [eax + esi*4]
add eax, 0xc
push eax
call fcn.004016b8
and dword [ebp - 4], 0
lea eax, [ebp - 0x18]
push eax
call fcn.004034cf
mov eax, dword [0x4196c4]
pop ecx
push dword [ebp - 0x18]
mov eax, dword [eax + esi*4]
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push dword [ebp - 0x18]
or dword [ebp - 4], 0xffffffff
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
inc esi
pop ecx
cmp esi, dword [0x4196c0]
jl 0x403502
mov ecx, dword [ebp - 0xc]
pop esi
mov dword fs:[0], ecx
leave
ret