joyce8/EMBER2024-capa huggingface dataset:
Function at 0x412d70
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
mov ebx, 0x1000
push dword [ebp + 0xc]
push 0x1000
call fcn.004135a0
mov esi, eax
mov edi, esi
push dword [ebp + 8]
push dword [0x432550]
call fcn.004130f2
mov dword [ebp - 8], eax
or eax, eax
je 0x412e8f
mov byte [ebp - 1], 0
mov eax, dword [ebp - 8]
cmp dword [eax + 4], 0
je 0x412dc8
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 8]
call fcn.00412eb0
mov dword [ebp - 0xc], eax
jmp 0x412dde
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [ebp - 8]
push dword [eax]
call sub.KERNEL32.dll_ReadFile
cmp byte [ebp - 1], 0
je 0x412dea
mov al, byte [ebp - 1]
mov byte [edi], al
inc edi
mov eax, edi
sub eax, esi
cmp eax, ebx
jl 0x412e11
add ebx, 0x1000
mov eax, edi
sub eax, esi
mov dword [ebp - 0x10], eax
push dword [ebp + 0xc]
push ebx
call fcn.004135a0
mov esi, eax
mov eax, dword [ebp - 0x10]
mov edi, eax
add edi, esi
movsx eax, byte [ebp - 1]
or eax, eax
je 0x412e2d
cmp dword [ebp - 0xc], 0
je 0x412e2d
cmp eax, 0xd
je 0x412e2d
cmp eax, 0xa
jne 0x412da8
cmp byte [ebp - 1], 0
je 0x412e8f
dec edi
cmp byte [ebp - 1], 0xd
jne 0x412e8f
mov eax, dword [ebp - 8]
cmp dword [eax + 4], 0
je 0x412e53
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 8]
call fcn.00412eb0
jmp 0x412e69
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [ebp - 8]
push dword [eax]
call sub.KERNEL32.dll_ReadFile
cmp byte [ebp - 1], 0xa
je 0x412e8f
mov eax, dword [ebp - 8]
cmp dword [eax + 4], 0
je 0x412e7f
add eax, 0xc
inc dword [eax]
jmp 0x412e8f
push 1
push 0
push 0xffffffffffffffff
mov eax, dword [ebp - 8]
push dword [eax]
call sub.KERNEL32.dll_SetFilePointer
mov byte [edi], 0
mov eax, edi
sub eax, esi
mov edx, ebx
sub edx, eax
push edx
call fcn.00413610
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x412eb0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0x10]
cmp dword [edi + 0x14], 0
jne 0x412ed5
push edi
call fcn.00412a80
mov dword [edi + 0x14], 1
and dword [edi + 0xc], 0
cmp dword [edi + 0xc], esi
jl 0x412f2a
mov eax, dword [edi + 0x10]
sub eax, dword [edi + 0xc]
mov ebx, eax
add ebx, dword [edi + 4]
mov eax, esi
cmp eax, 1
je 0x412ef8
cmp eax, 2
je 0x412f01
cmp eax, 4
je 0x412f0c
jmp 0x412f15
mov eax, dword [ebp + 0xc]
mov dl, byte [ebx]
mov byte [eax], dl
jmp 0x412f22
mov eax, dword [ebp + 0xc]
mov dx, word [ebx]
mov word [eax], dx
jmp 0x412f22
mov eax, dword [ebp + 0xc]
mov edx, dword [ebx]
mov dword [eax], edx
jmp 0x412f22
push esi
push ebx
push dword [ebp + 0xc]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [edi + 0xc], esi
mov dword [ebp - 4], esi
jmp 0x412fa9
mov ebx, dword [edi + 0xc]
push ebx
mov eax, dword [edi + 0x10]
sub eax, dword [edi + 0xc]
add eax, dword [edi + 4]
push eax
push dword [ebp + 0xc]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
mov eax, ebx
add eax, dword [ebp + 0xc]
mov dword [ebp + 0xc], eax
sub esi, ebx
cmp esi, dword [edi + 8]
jl 0x412f69
push 0
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 0xc]
push dword [edi]
call sub.KERNEL32.dll_ReadFile
and dword [edi + 0xc], 0
jmp 0x412fa9
push 0
lea eax, [ebp - 4]
push eax
push dword [edi + 8]
push dword [edi + 4]
push dword [edi]
call sub.KERNEL32.dll_ReadFile
mov eax, dword [ebp - 4]
mov dword [edi + 0xc], eax
mov eax, dword [ebp - 4]
mov dword [edi + 0x10], eax
cmp esi, dword [edi + 0xc]
jle 0x412f90
mov esi, dword [edi + 0xc]
push esi
push dword [edi + 4]
push dword [ebp + 0xc]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [edi + 0xc], esi
mov eax, ebx
add eax, esi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x412fc0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0x10]
and dword [ebp - 4], 0
cmp dword [edi + 0x14], 1
jne 0x412fe3
and dword [edi + 0x14], 0
mov eax, dword [edi + 8]
mov dword [edi + 0xc], eax
cmp dword [edi + 0xc], esi
jle 0x413044
mov eax, dword [edi + 8]
sub eax, dword [edi + 0xc]
add eax, dword [edi + 4]
mov dword [ebp - 8], eax
mov eax, esi
cmp eax, 1
je 0x413007
cmp eax, 2
je 0x413013
cmp eax, 4
je 0x413021
jmp 0x41302d
mov eax, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dl, byte [edx]
mov byte [eax], dl
jmp 0x41303c
mov eax, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov dx, word [edx]
mov word [eax], dx
jmp 0x41303c
mov eax, dword [ebp - 8]
mov edx, dword [ebp + 0xc]
mov edx, dword [edx]
mov dword [eax], edx
jmp 0x41303c
push esi
push dword [ebp + 0xc]
push dword [ebp - 8]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [edi + 0xc], esi
mov dword [ebp - 4], esi
jmp 0x41307e
push edi
call fcn.00412a80
cmp esi, dword [edi + 8]
jl 0x413062
push 0
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 0xc]
push dword [edi]
call sub.KERNEL32.dll_WriteFile
jmp 0x41307e
push esi
push dword [ebp + 0xc]
mov eax, dword [edi + 8]
sub eax, dword [edi + 0xc]
add eax, dword [edi + 4]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
sub dword [edi + 0xc], esi
mov dword [ebp - 4], esi
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x4025a9
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
lea ecx, [ebp - 0xc]
call fcn.00411486
lea ecx, [ebp - 0x18]
call fcn.00411486
push 0x3c
xor esi, esi
lea eax, [ebp - 0x54]
push esi
push eax
call fcn.00416940
mov ebx, dword [ebp + 0xc]
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov ecx, 0x740
mov dword [ebp - 0x54], 0x3c
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x50], ecx
mov dword [ebp - 0x38], 0xa
test bl, 1
je 0x402601
mov ecx, 0x8740
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x50], ecx
test bl, 2
mov eax, str.runas
cmove eax, dword [ebp - 0x48]
mov dword [ebp - 0x48], eax
and ebx, 0x10000
jne 0x402621
or ecx, 0x100
mov dword [ebp - 0x50], ecx
mov eax, dword [0x430e6c]
push 5
push eax
mov dword [ebp - 0x4c], eax
call dword [sym.imp.USER32.dll_ShowWindow]
push dword [ebp - 0x4c]
call dword [sym.imp.USER32.dll_BringWindowToTop]
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
call fcn.00404cf6
pop ecx
pop ecx
push eax
lea ecx, [ebp - 0x18]
call fcn.004115b8
cmp dword [ebp - 8], esi
je 0x402689
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x54]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x40268c
test ebx, ebx
jne 0x402680
push 0xffffffffffffffff
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
inc esi
push dword [ebp - 0x18]
call fcn.00419919
push dword [ebp - 0xc]
call fcn.00419919
pop ecx
pop ecx
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x402900
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push dword [ebp + 8]
mov esi, ecx
call fcn.0040323d
xor edi, edi
mov dword [0x430e5c], esi
lea eax, [ebp - 4]
mov dword [0x430e64], edi
push eax
push edi
push esi
push 0x402cd8
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edx, eax
mov dword [0x430e60], edx
test edx, edx
je 0x402960
cmp dword [0x430e98], 2
je 0x402951
call fcn.004083b9
mov edx, dword [0x430e60]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [0x430e60]
mov eax, dword [0x430e64]
mov dword [0x430ffc], edi
test eax, eax
je 0x4029a2
cmp eax, 1
je 0x402996
cmp eax, 2
je 0x402992
cmp eax, 3
je 0x40298e
cmp eax, 0x67
jle 0x402988
cmp eax, 0x6b
jle 0x402a06
push eax
push 0x14
push edi
jmp 0x4029fe
push 0x12
jmp 0x402998
push 0x13
jmp 0x402998
push 0x11
push edi
call fcn.00409ae1
pop ecx
pop ecx
jmp 0x402a06
mov ecx, edi
mov dword [ebp + 8], ecx
cmp dword [0x431000], ecx
jne 0x402a06
test edx, edx
je 0x4029cd
lea eax, [ebp + 8]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov ecx, dword [ebp + 8]
test eax, eax
je 0x4029cd
test ecx, ecx
jne 0x4029cd
xor eax, eax
jmp 0x402a0b
mov edx, 0x80070000
mov eax, ecx
and eax, edx
cmp eax, edx
je 0x4029df
push ecx
push 0x21
jmp 0x40298b
movzx eax, cx
cmp eax, 0xe
jne 0x4029f0
cmp dword [0x430e9c], 0xffffffff
je 0x402a06
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 8]
push 0x22
push 1
call fcn.00409ae1
add esp, 0xc
mov eax, 0x80004005
pop edi
pop esi
leave
ret 4
Function at 0x403769
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebx
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], eax
mov edi, eax
call fcn.0041144f
xor esi, esi
lea ecx, [ebp - 0x18]
push esi
call fcn.00404031
push 0x2f
mov ebx, eax
mov eax, dword [ebp + 8]
pop ecx
push 0x5c
pop edx
movzx eax, word [eax + edi*2 - 2]
cmp ax, dx
je 0x4037af
cmp ax, cx
jne 0x4037e3
xor eax, eax
mov word [ebx + edi*2 - 2], ax
dec edi
mov dword [ebp - 4], edi
jmp 0x4037e3
test edi, edi
jle 0x4037db
push 0x2f
pop ecx
push 0x5c
pop edx
movzx eax, word [ebx + edi*2]
cmp ax, cx
je 0x4037d9
cmp ax, dx
je 0x4037d9
dec edi
test edi, edi
jg 0x4037c6
test edi, edi
je 0x403838
xor eax, eax
mov word [ebx + edi*2], ax
push ebx
call fcn.004057e3
pop ecx
test eax, eax
je 0x4037bc
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x403817
lea eax, [ebp - 0xc]
push eax
push ebx
call fcn.00404399
pop ecx
pop ecx
test eax, eax
jne 0x4038bc
push ebx
call fcn.004057e3
pop ecx
test eax, eax
jne 0x4038b2
push ebx
push 0xc
push 1
call fcn.00409ae1
add esp, 0xc
jmp 0x4038bc
cmp dword [ebp - 4], 2
mov ecx, dword [ebp + 8]
jne 0x403859
mov ax, word [ecx]
or ax, 0x20
sub ax, 0x61
cmp ax, 0x19
ja 0x403859
cmp word [ecx + 2], 0x3a
je 0x4038b9
push ecx
jmp 0x403827
sub eax, edi
lea esi, [ebx + edi*2]
inc eax
push eax
mov eax, dword [ebp + 8]
lea eax, [eax + edi*2]
push eax
push esi
call fcn.00416aa0
xor ecx, ecx
lea eax, [edi + 1]
add esp, 0xc
cmp word [esi], cx
cmove eax, edi
mov edi, eax
jmp 0x403896
movzx eax, cx
push 0x5c
pop ecx
cmp ax, cx
je 0x4038a1
push 0x2f
pop ecx
cmp ax, cx
je 0x4038a1
inc edi
movzx eax, word [ebx + edi*2]
mov ecx, eax
test ax, ax
jne 0x403882
xor eax, eax
push ebx
mov word [ebx + edi*2], ax
call fcn.004057e3
pop ecx
test eax, eax
je 0x4038cc
mov eax, dword [ebp - 4]
cmp edi, eax
jl 0x40385c
xor esi, esi
inc esi
push dword [ebp - 0x18]
call fcn.00419919
pop ecx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
push ebx
push 0xc
push 1
call fcn.00409ae1
add esp, 0xc
xor esi, esi
jmp 0x4038bc
Function at 0x403be2
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov ecx, edi
call fcn.00411486
push 2
mov ecx, edi
call fcn.00404031
push eax
push 1
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, eax
xor ebx, ebx
mov eax, dword [edi]
xor ecx, ecx
mov dword [edi + 4], ebx
mov word [eax], cx
test esi, esi
je 0x403c39
inc esi
mov ecx, edi
push esi
call fcn.00404031
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, dword [edi]
push esi
call fcn.00404eab
pop ecx
xor ecx, ecx
mov dword [edi + 4], eax
mov word [esi + eax*2], cx
mov esi, dword [edi + 4]
mov dword [ebp + 8], esi
lea eax, [esi + 0xf]
push eax
mov ecx, edi
call fcn.00404031
push ebx
push dword [ebp + 0xc]
lea eax, [eax + esi*2]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov esi, dword [edi]
push esi
call fcn.00404eab
add esp, 0x10
mov dword [edi + 4], eax
xor ecx, ecx
mov word [esi + eax*2], cx
push dword [edi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x403c88
mov esi, dword [ebp + 8]
inc ebx
lea eax, [esi + 0xf]
cmp ebx, 0xfff
jl 0x403c42
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x403c8f
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set current directory
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
push ebx
push esi
push dword [ebp + 8]
lea ecx, [ebp - 0xc]
call fcn.0041144f
push 0x426ba8
lea ecx, [ebp - 0xc]
call fcn.00411756
lea eax, [ebp - 0x25c]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
xor esi, esi
cmp ebx, 0xffffffff
je 0x403d6b
push dword [ebp + 8]
lea ecx, [ebp - 0xc]
call fcn.004115b8
push 0x5c
lea ecx, [ebp - 0xc]
call fcn.004018e1
lea eax, [ebp - 0x230]
push eax
lea ecx, [ebp - 0xc]
call fcn.00411756
test byte [ebp - 0x25c], 0x10
je 0x403d33
push 0x426bb0
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x403d4e
push 0x426bb4
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x403d4e
push dword [ebp - 0xc]
call fcn.00403c8f
pop ecx
jmp 0x403d4a
push esi
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403d95
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x403d95
lea eax, [ebp - 0x25c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x403ccf
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
push dword [0x430ed8]
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403d95
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x403d95
xor esi, esi
inc esi
push dword [ebp - 0xc]
call fcn.00419919
pop ecx
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x403da4
Capabilities:
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x250
cmp dword [0x431010], 0
jne 0x403e04
lea eax, [ebp - 0x250]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
je 0x403e04
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
test byte [ebp - 0x250], 0x10
jne 0x403df9
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403df5
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
leave
ret
xor eax, eax
leave
ret
push dword [ebp + 8]
call fcn.00403c8f
pop ecx
leave
ret
xor eax, eax
inc eax
leave
ret
Function at 0x4041e0
Capabilities:
Get geographical location
Query environment variable

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x4300c0]
sub esp, 0xa0
push esi
push edi
xor edi, edi
mov esi, edi
jmp 0x404207
cmp eax, dword [ebp + 8]
je 0x40420b
inc esi
mov eax, esi
shl eax, 4
mov eax, dword [eax + 0x4300c0]
test eax, eax
jne 0x4041f6
shl esi, 4
cmp dword [esi + 0x4300c0], edi
jne 0x404220
mov eax, 0x426a08
jmp 0x404395
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
push dword [ebp + 8]
mov dword [ebp - 8], eax
lea eax, [ebp - 0x60]
push str.SfxString_d
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x60]
push edi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
mov dword [ebp - 4], edi
call ebx
push 2
pop edx
test eax, eax
jne 0x4042ca
xor ecx, ecx
lea eax, [edi + 2]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00419910
pop ecx
mov ecx, dword [ebp - 4]
mov edi, eax
inc ecx
lea eax, [ebp - 0x60]
push ecx
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, dword [ebp - 4]
ja 0x4042c3
call ebx
test eax, eax
jne 0x4042c3
mov eax, dword [esi + 0x4300cc]
test eax, eax
je 0x4042bb
push edi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x4042c3
push 2
pop eax
push eax
push dword [esi + 0x4300cc]
call fcn.00419902
pop ecx
mov dword [esi + 0x4300cc], edi
jmp 0x4042c9
mov dword [esi + 0x4300cc], edi
jmp 0x4042ca
push edi
call fcn.00419919
pop ecx
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [esi + 0x4300cc]
test eax, eax
jne 0x404394
mov ebx, dword [esi + 0x4300c4]
cmp dword [esi + 0x4300c8], eax
je 0x404302
call fcn.0040478c
cmp eax, dword [0x426db0]
jne 0x404302
mov ebx, dword [esi + 0x4300c8]
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
xor ecx, ecx
push 2
pop edx
lea edi, [eax + 1]
lea eax, [edi + 2]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00419910
pop ecx
mov ecx, dword [0x4300bc]
mov dword [esi + 0x4300cc], eax
cmp ecx, 0xffffffff
jne 0x404379
and dword [0x4300bc], 0
lea eax, [ebp - 0xa0]
push 0x1f
push eax
movzx eax, word [0x430e68]
push 0x1004
push eax
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jle 0x404373
lea eax, [ebp - 0xa0]
push eax
call fcn.0041b100
pop ecx
mov ecx, eax
mov dword [0x4300bc], ecx
jmp 0x404379
mov ecx, dword [0x4300bc]
lea eax, [edi + 1]
push eax
push dword [esi + 0x4300cc]
push edi
push ebx
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov eax, dword [esi + 0x4300cc]
pop ebx
pop edi
pop esi
leave
ret
Function at 0x40478c
Capabilities:
Identify system language via api

Disassembly:
mov dx, word [0x430e68]
test dx, dx
jne 0x4047f6
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
mov cx, ax
mov word [0x430e68], ax
mov edx, 0x3ff
and cx, dx
cmp cx, 9
je 0x4047b9
movzx eax, ax
ret
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
mov ecx, 0x409
cmp ax, cx
jne 0x4047ef
push esi
mov esi, dword [0x426db0]
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLCID]
movzx edx, word [0x430e68]
cmp eax, esi
movzx ecx, si
cmove edx, ecx
mov word [0x430e68], dx
pop esi
jmp 0x4047f6
mov dx, word [0x430e68]
movzx eax, dx
ret

Function at 0x40493f
Capabilities:
Get token membership

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
mov word [ebp - 0xc], 0x500
lea eax, [ebp - 4]
mov dword [ebp - 8], ebx
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea eax, [ebp - 0x10]
mov dword [ebp - 4], ebx
push eax
mov dword [ebp - 0x10], ebx
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x404992
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
push ebx
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [ebp - 8]
pop ebx
leave
ret

Function at 0x404c1a
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
push ebx
push esi
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
movzx ecx, word [0x430e68]
mov edi, eax
mov ebx, dword [sym.imp.KERNEL32.dll_FindResourceExA]
push ecx
push dword [ebp + 0xc]
push dword [ebp + 8]
push edi
call ebx
mov esi, eax
test esi, esi
jne 0x404c5e
push 0x409
push dword [ebp + 0xc]
push dword [ebp + 8]
push edi
call ebx
mov esi, eax
test esi, esi
je 0x404c84
mov ebx, dword [ebp + 0x10]
test ebx, ebx
je 0x404c6f
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebx], eax
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x404c84
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
jmp 0x404cf1
cmp dword [0x430e74], 0
jne 0x404cef
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SetProcessPreferredUILanguages
push dword [0x430eb8]
mov dword [0x430e74], 1
call edi
movzx ecx, word [0x430e68]
xor ebx, ebx
push ebx
push 0x409
push ebx
push ecx
mov esi, eax
lea eax, [ebp - 0x40]
push str._04X_c_04X_c
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x18
test esi, esi
jne 0x404ce6
push str.SetThreadPreferredUILanguages
push dword [0x430eb8]
call edi
mov esi, eax
test esi, esi
je 0x404cef
push ebx
lea eax, [ebp - 0x40]
push eax
push 4
call esi
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x404dc3
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push 1
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ecx, dword [ebp + 8]
mov edi, eax
call fcn.00411486
mov ecx, dword [ebp + 8]
lea esi, [edi + 2]
push esi
call fcn.00404031
lea eax, [edi + 1]
mov edi, dword [ebp + 8]
push eax
push esi
mov ecx, edi
call fcn.00404031
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov esi, dword [edi]
push esi
call fcn.00404eab
pop ecx
mov dword [edi + 4], eax
xor ecx, ecx
mov word [esi + eax*2], cx
mov eax, edi
pop edi
pop esi
leave
ret

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

Disassembly:
push ebp
mov ebp, esp
push esi
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x405825
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, 0xb7
cmp eax, esi
je 0x405810
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x405828
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x405825
test al, 0x10
jne 0x405825
push esi
jmp 0x405806
xor eax, eax
inc eax
pop esi
pop ebp
ret
Function at 0x405a7a
Capabilities:
Create process on windows
Get disk information
Self delete
Set file attributes
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
sub esp, 0x30
push ebx
push edi
push 0x3a
pop edx
cmp word [eax + 2], dx
jne 0x405bfc
movzx ecx, word [eax + 4]
push esi
push 0x5c
pop esi
cmp cx, si
je 0x405aa8
cmp ecx, 0x2f
jne 0x405bfb
mov ax, word [eax]
mov word [ebp - 0xc], ax
xor eax, eax
mov word [ebp - 6], ax
lea eax, [ebp - 0xc]
push eax
mov word [ebp - 0xa], dx
mov word [ebp - 8], si
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x405bf8
lea eax, [ebp - 0x24]
push str.7ZSfx_03x.cmd
push eax
call fcn.00403be2
pop ecx
pop ecx
xor eax, eax
push eax
push 0x80
push 2
push eax
push eax
push 0x40000000
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x405bef
lea ecx, [ebp - 0x18]
call fcn.00411486
push str.:Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.004115b8
mov ebx, str.del__
lea ecx, [ebp - 0x18]
push ebx
call fcn.00411756
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411718
mov esi, 0x427c74
lea ecx, [ebp - 0x18]
push esi
call fcn.00411756
push str.if_exist__
lea ecx, [ebp - 0x18]
call fcn.00411756
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411718
push str.__goto_Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.00411756
push ebx
lea ecx, [ebp - 0x18]
call fcn.00411756
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411718
push esi
lea ecx, [ebp - 0x18]
call fcn.00411756
mov esi, dword [ebp - 0x14]
lea eax, [ebp - 0x18]
push 1
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.00405873
add esp, 0xc
lea ecx, [ebp - 4]
xor ebx, ebx
push ebx
push ecx
push esi
push dword [eax]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0x30]
mov esi, eax
call fcn.00419919
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x405c07
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 0x14]
jne 0x405c07
push ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
push ebx
push ebx
push dword [ebp - 0x24]
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
push dword [ebp - 0x18]
call fcn.00419919
pop ecx
push dword [ebp - 0x24]
call fcn.00419919
pop ecx
mov eax, dword [ebp + 8]
pop esi
push eax
call fcn.00419919
pop ecx
pop edi
pop ebx
leave
ret
push dword [ebp - 0x24]
call fcn.00403da4
push dword [ebp - 0x18]
call fcn.00419919
push dword [ebp - 0x24]
call fcn.00419919
add esp, 0xc
jmp 0x405bf8