joyce8/EMBER2024-capa huggingface dataset:
Function at 0x100137df
Capabilities:
Generate random numbers via winapi

Disassembly:
call fcn.100b0a27
sub byte [eax], al
add byte [eax - 0x64846fe], al
sub esp, dword [ebx + 0x14]
xchg esp, eax
or esi, dword [ebp + 0xd508a03]
sbb eax, 0x6e64b0a0
dec ebx
jae 0x1001385c
dec edi
lds esi, [edx - 0x7b1f398d]
out dx, al
out dx, eax
ljmp 0xfdb3
mov ebp, esp
push esi
xor esi, esi
cmp dword [0x10120740], 1
je 0x10013871
mov esi, 0x8000ffff
jmp 0x10013899
push dword [ebp + 8]
push dword [ebp + 0xc]
push dword [0x10120730]
call dword [sym.imp.ADVAPI32.dll_CryptGenRandom]
test eax, eax
jne 0x100138be
call dword [sym.imp.kernel32.dll_GetLastError]
push eax
call fcn.1005e4ef
mov esi, eax
test esi, esi
jge 0x100138be
mov eax, dword [0x1011faf4]
cmp eax, 0x1011faf4
je 0x100138be
test byte [eax + 0x3c], 2
je 0x100138be
push esi
push 0x100034d8
push 0xa
push dword [eax + 0x34]
push dword [eax + 0x30]
call fcn.1005e4ef
mov eax, esi
pop esi
pop ebp
ret 8
Function at 0x1005e4ef
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
pushal
call 0x1005e4fe
pop dword [ebp - 0x48]
mov eax, 0x7e609f2d
sub eax, 0x6e5aba2f
sub dword [ebp - 0x48], eax
push 0x40
push 0x1000
push 0x59bfc
push 0
mov eax, sym.imp.kernel32.dll_VirtualAlloc
add eax, dword [ebp - 0x48]
call dword [eax]
mov ecx, 0x7ecf1471
sub ecx, 0x7ecec5b2
xor esi, esi
add esi, eax
mov edx, 0x7e16ffda
add edx, 0x91fc7826
add edx, dword [ebp - 0x48]
mov ebx, 0xa374e931
add dword [ebp - 0x28], ebx
mov edi, dword [edx]
xor edi, ebx
xor dword [ebp - 0x44], ebx
mov dword [esi], edi
sub dword [ebp - 0x20], 0xe1e136e5
add esi, 0x26538fff
add esi, 0xd9ac7005
add edx, 0xe8ddc51
add edx, 0xf17223b3
loop 0x1005e554
add eax, 0x802f3f19
add eax, 0x7fd1eeb6
xor ebx, ebx
add ebx, eax
add eax, 5
mov ecx, 0x10000000
add ecx, dword [ebp - 0x48]
call ebx
leave
ret
Function at 0x100fb858
Capabilities:
Encode data using xor

Disassembly:
mov edi, edi
push ebx
mov ebx, esp
push ecx
push ecx
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [ebx + 0x1c]
mov dword [ebp - 0x1c], eax
xor eax, eax
push esi
mov esi, dword [ebx + 0x14]
inc eax
xor ecx, ecx
push edi
mov dword [ebp - 8], eax
cmp dword [0x1012ee8c], ecx
je 0x100fb8e8
movd mm0, eax
or eax, 0xffffffff
movd mm3, eax
movq mm1, mm0
cmp esi, ecx
je 0x100fb8de
mov eax, dword [ebx + 8]
mov ecx, dword [ebx + 0x10]
mov edx, dword [ebx + 0xc]
sub ecx, eax
sub edx, eax
mov edi, dword [ecx + eax]
movd mm2, edi
mov edi, dword [eax]
movq mm4, mm3
pxor mm2, mm4
movd mm4, edi
mov edi, dword [edx + eax]
paddq mm0, mm4
movq mm4, mm2
paddq mm0, mm4
psrlq mm0, 0x20
movd mm4, edi
paddq mm1, mm4
add eax, 4
dec esi
paddq mm1, mm2
psrlq mm1, 0x20
jne 0x100fb8aa
por mm0, mm1
movd eax, mm0
emms
jmp 0x100fb958
mov dword [ebp - 4], ecx
mov dword [ebp - 0x10], ecx
cmp esi, ecx
je 0x100fb950
mov eax, dword [ebx + 8]
mov ecx, dword [ebx + 0x10]
mov edx, dword [ebx + 0xc]
sub ecx, eax
sub edx, eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0xc], esi
jmp 0x100fb90d
mov ecx, dword [ebp - 0x14]
mov edx, dword [eax]
mov ecx, dword [ecx + eax]
mov esi, edx
sub esi, ecx
sub esi, dword [ebp - 4]
mov edi, edx
xor esi, edx
xor edi, ecx
or esi, edi
xor esi, edx
mov edx, dword [ebp - 0x18]
mov edx, dword [edx + eax]
shr esi, 0x1f
mov dword [ebp - 4], esi
mov esi, edx
sub esi, ecx
sub esi, dword [ebp - 0x10]
mov edi, edx
xor esi, edx
xor edi, ecx
or esi, edi
xor esi, edx
shr esi, 0x1f
mov ecx, esi
add eax, 4
dec dword [ebp - 0xc]
mov dword [ebp - 0x10], ecx
jne 0x100fb90a
and ecx, dword [ebp - 4]
xor eax, eax
inc eax
sub eax, ecx
test eax, eax
je 0x100fb974
push dword [ebp - 0x1c]
and dword [ebp - 8], 0
push 0
push 7
call fcn.1006412b
add dword cs:[eax], eax
ror byte [eax - 0x74dff1ca], 0x45
clc
mov eax, dword [ebp - 8]
pop edi
pop esi
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 0x18

Function at 0x4016ec
Capabilities:
Encode data using xor

Disassembly:
push 0x40177c
call sub.MSVBVM60.DLL_ThunRTMain
add byte [eax], al
add byte [eax], al
add byte [eax], al
xor byte [eax], al
add byte [eax], al
inc eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [edi - 0x12], dl
fldenv [0x4ec27161]
and dword [ecx], 0xd0c0d8f2
loope 0x4016f1
add byte [eax], al
add byte [eax], al
add byte [eax], al
add dword [eax], eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
push eax
jb 0x40179a
push 0x65
arpl word [ecx + esi], si
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [eax], al
add byte [esi], al
add byte [eax], al
add byte [eax + 0x1004056], dl
add byte [ecx], al
add byte [esp + eax*2 + 0x40], dl
add byte [eax], al
add byte [eax], al
add bh, bh
add byte [eax], al
add byte [eax], al
or al, byte [eax]
or dword [eax + eax], eax
add byte [eax], al
add byte [eax], al
add byte [eax], al
lodsb al, byte [esi]
inc eax
add byte [ecx + ebx + 0x40], dl
add byte [edi + 0x70f0], bl
invalid
Function at 0x401ea2
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x410284]
jne 0x401eac
repz ret
jmp fcn.00403e53

Function at 0x40560d
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
pushal
call 0x40561c
pop dword [ebp - 0xc]
mov eax, 0xb62222bc
sub eax, 0xb5e1cca0
sub dword [ebp - 0xc], eax
mov dword [ebp - 0x1c], 0xe24b04af
add dword [ebp - 0x1c], 0x6c07409c
mov dword [ebp - 0x18], 0x9c6bf005
add dword [ebp - 0x18], 0x95c75c40
mov dword [ebp - 0x14], 0x86d38770
add dword [ebp - 0x14], 0xc578bcbe
mov dword [ebp - 0x10], 0x44292a54
sub dword [ebp - 0x10], 0x44292a54
lea eax, [ebp - 0x1c]
push eax
mov eax, 0xdf827d3d
add eax, 0x20be5317
add eax, dword [ebp - 0xc]
call dword [eax]
mov dword [ebp - 0x1c], 0xbc2755bb
sub dword [ebp - 0x1c], 0x47b4ec65
mov dword [ebp - 0x18], 0x2f82fe44
sub dword [ebp - 0x18], 0xee169ccf
mov dword [ebp - 0x14], 0x96224ff1
sub dword [ebp - 0x14], 0x32b2e385
mov dword [ebp - 0x10], 0x124332ce
add dword [ebp - 0x10], 0xedbccd32
lea ebx, [ebp - 0x1c]
push ebx
push eax
mov eax, 0x457a8306
add eax, 0xbac64d46
add eax, dword [ebp - 0xc]
call dword [eax]
push 0x40
push 0x1000
push 0x35fff
push 0
call eax
mov ecx, 0x1188b4d0
add ecx, 0xee77851c
mov ebx, eax
mov esi, 0x1bcee5c8
add esi, 0xe472ca38
add esi, dword [ebp - 0xc]
mov edi, 0xec3dbd8e
sub edi, 0x2f24ae76
mov dword [ebp - 8], 0xb9b05789
mov edx, dword [esi]
sub dword [ebp - 8], 0x26175b97
xor edx, edi
sub dword [ebp - 8], 0xed7dcef1
mov dword [ebx], edx
add ebx, 0x1ddc9f08
add ebx, 0xe22360fc
add esi, 4
loop 0x40573e
add eax, 0x6638ba8c
add eax, 0x99c81ff7
xor ebx, ebx
add ebx, eax
add eax, 5
mov ecx, 0x400000
add ecx, dword [ebp - 0xc]
call ebx
leave
ret
Function at 0x402020
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
lea ecx, [ebp - 0xc]
call fcn.00401290
lea ecx, [ebp - 0x18]
call fcn.00401290
mov ebx, dword [ebp + 0xc]
xorps xmm0, xmm0
mov eax, dword [ebp + 0x10]
mov ecx, 0x740
movlpd qword [ebp - 0x50], xmm0
movlpd qword [ebp - 0x48], xmm0
mov dword [ebp - 0x40], 0
movlpd qword [ebp - 0x34], xmm0
movlpd qword [ebp - 0x2c], xmm0
movlpd qword [ebp - 0x24], xmm0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x54], 0x3c
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x50], ecx
mov dword [ebp - 0x38], 0xa
test bl, 1
je 0x402095
mov ecx, 0x8740
mov dword [ebp - 0x38], 0
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 0x4020b5
or ecx, 0x100
mov dword [ebp - 0x50], ecx
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
call fcn.004046e0
add esp, 8
lea ecx, [ebp - 0x18]
push eax
call fcn.00401b90
lea ecx, [ebp - 0xc]
call fcn.00401fd0
test eax, eax
je 0x402115
lea ecx, [ebp - 0xc]
call fcn.004012e0
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x44], eax
call fcn.004012e0
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x54]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x402132
test ebx, ebx
jne 0x40210c
push 0xffffffffffffffff
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, 1
lea ecx, [ebp - 0x18]
call fcn.00401650
lea ecx, [ebp - 0xc]
call fcn.00401650
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor esi, esi
jmp 0x40211a
Function at 0x402440
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push dword [ebp + 8]
mov esi, ecx
call fcn.00402cb0
lea eax, [ebp - 4]
mov dword [0x426508], esi
push eax
push 0
push esi
push 0x4026b0
push 0
push 0
mov dword [0x426510], 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [0x42650c], eax
pop esi
test eax, eax
je 0x4024a0
cmp dword [0x426538], 2
je 0x402492
call fcn.00407ea0
mov eax, dword [0x42650c]
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [0x42650c]
mov ecx, dword [0x426510]
mov dword [0x4265f4], 0
test ecx, ecx
je 0x402527
lea eax, [ecx - 1]
cmp eax, 0x69
ja case.0x4024c3.4
movzx eax, byte [eax + 0x4025c4]
jmp dword [eax*4 + 0x4025b0]
push 0x11
push 0
call fcn.004093a0
add esp, 8
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
push 0x12
push 0
call fcn.004093a0
add esp, 8
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
push 0x13
push 0
call fcn.004093a0
add esp, 8
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
push ecx
push 0x14
push 0
call fcn.004093a0
add esp, 0xc
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
xor ecx, ecx
mov dword [ebp + 8], ecx
cmp dword [0x4265f8], ecx
jne case.0x4024c3.104
test eax, eax
je 0x402556
lea ecx, [ebp + 8]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov ecx, dword [ebp + 8]
test eax, eax
je 0x402556
test ecx, ecx
jne 0x402556
xor eax, eax
mov esp, ebp
pop ebp
ret 4
mov eax, ecx
and eax, 0x80070000
cmp eax, 0x80070000
je 0x40257c
push ecx
push 0x21
push 0
call fcn.004093a0
add esp, 0xc
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
movzx eax, cx
cmp eax, 0xe
jne 0x40258d
cmp dword [0x42653c], 0xffffffff
je case.0x4024c3.104
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 8]
push 0x22
push 1
call fcn.004093a0
add esp, 0xc
mov eax, 0x80004005
mov esp, ebp
pop ebp
ret 4
Function at 0x4030c0
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push esi
lea ecx, [ebp - 0x1c]
mov dword [ebp - 4], eax
mov ebx, eax
call fcn.00401620
push 0
lea ecx, [ebp - 0x1c]
call fcn.00403c00
mov edi, eax
movzx eax, word [esi + ebx*2 - 2]
mov dword [ebp - 8], edi
cmp eax, 0x5c
je 0x4030ff
cmp eax, 0x2f
jne 0x40310a
xor eax, eax
mov word [edi + ebx*2 - 2], ax
dec ebx
mov dword [ebp - 4], ebx
push edi
mov esi, ebx
call fcn.00405160
add esp, 4
test eax, eax
jne 0x403152
nop dword [eax]
test esi, esi
jle 0x403139
movzx eax, word [edi + esi*2]
cmp eax, 0x2f
je 0x40313f
cmp eax, 0x5c
je 0x403137
dec esi
test esi, esi
jg 0x403124
test esi, esi
je 0x40320f
xor eax, eax
push edi
mov word [edi + esi*2], ax
call fcn.00405160
add esp, 4
test eax, eax
je 0x403120
lea eax, [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x40317c
lea eax, [ebp - 0x10]
push eax
push edi
call fcn.00403ff0
add esp, 8
test eax, eax
jne 0x40325c
push edi
call fcn.00405160
add esp, 4
test eax, eax
je 0x40324f
cmp esi, ebx
jge 0x4031f9
mov eax, dword [ebp - 4]
sub eax, esi
lea edi, [edi + esi*2]
inc eax
mov ebx, esi
push eax
mov eax, dword [ebp + 8]
lea eax, [eax + esi*2]
push eax
push edi
call fcn.0041c010
add esp, 0xc
lea esi, [ebx + 1]
cmp word [edi], 0
mov edi, dword [ebp - 8]
cmove esi, ebx
movzx eax, word [edi + esi*2]
mov ecx, eax
test ax, ax
je 0x4031df
movzx eax, cx
cmp eax, 0x5c
je 0x4031df
cmp eax, 0x2f
je 0x4031df
movzx eax, word [edi + esi*2 + 2]
inc esi
mov ecx, eax
test ax, ax
jne 0x4031c5
xor eax, eax
push edi
mov word [edi + esi*2], ax
call fcn.00405160
add esp, 4
test eax, eax
je 0x40324f
mov eax, dword [ebp - 4]
cmp esi, eax
jl 0x403194
lea ecx, [ebp - 0x1c]
mov esi, 1
call fcn.00401650
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 8]
cmp ebx, 2
jne 0x40322f
mov ax, word [ecx]
or ax, 0x20
sub ax, 0x61
cmp ax, 0x19
ja 0x40322f
cmp word [ecx + 2], 0x3a
je 0x4031f9
push ecx
push 0xc
push 1
call fcn.004093a0
add esp, 0xc
lea ecx, [ebp - 0x1c]
xor esi, esi
call fcn.00401650
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
push 0xc
push 1
call fcn.004093a0
add esp, 0xc
lea ecx, [ebp - 0x1c]
xor esi, esi
call fcn.00401650
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403640
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.00401290
push 2
mov ecx, edi
call fcn.00403c00
mov ebx, dword [sym.imp.KERNEL32.dll_GetTempPathW]
push eax
push 1
call ebx
push 0
mov ecx, edi
mov esi, eax
call fcn.00401b10
test esi, esi
je 0x403687
inc esi
mov ecx, edi
push esi
call fcn.00403c00
push eax
push esi
call ebx
mov ecx, edi
call fcn.00404b80
mov ecx, edi
call fcn.00401fd0
xor esi, esi
lea ebx, [eax + 0xf]
add eax, eax
mov dword [ebp + 8], eax
push ebx
mov ecx, edi
call fcn.00403c00
add eax, dword [ebp + 8]
push esi
push dword [ebp + 0xc]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
mov ecx, edi
call fcn.00404b80
mov ecx, edi
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4036d4
inc esi
cmp esi, 0xfff
jl 0x403698
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x403730
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
lea ecx, [ebp - 0xc]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
push edi
call fcn.00401620
push 0x4218e4
lea ecx, [ebp - 0xc]
call fcn.00412fb0
lea eax, [ebp - 0x25c]
push eax
lea ecx, [ebp - 0xc]
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x403827
mov esi, dword [sym.imp.KERNEL32.dll_lstrcmpW]
nop dword [eax]
push edi
lea ecx, [ebp - 0xc]
call fcn.00401b90
push 0x5c
lea ecx, [ebp - 0xc]
call fcn.00401660
lea eax, [ebp - 0x230]
push eax
lea ecx, [ebp - 0xc]
call fcn.00412fb0
test byte [ebp - 0x25c], 0x10
je 0x4037e2
push 0x4218ec
lea eax, [ebp - 0x230]
push eax
call esi
test eax, eax
je 0x40380a
push 0x4218f0
lea eax, [ebp - 0x230]
push eax
call esi
test eax, eax
je 0x40380a
lea ecx, [ebp - 0xc]
call fcn.004012e0
push eax
call fcn.00403730
add esp, 4
jmp 0x403806
push 0
lea ecx, [ebp - 0xc]
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403866
lea ecx, [ebp - 0xc]
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x403866
lea eax, [ebp - 0x25c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x403780
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, 0x42655c
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403866
push edi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x403866
lea ecx, [ebp - 0xc]
mov esi, 1
call fcn.00401650
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0xc]
xor esi, esi
call fcn.00401650
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403880
Capabilities:
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x250
lea eax, [ebp - 0x250]
push esi
mov esi, dword [ebp + 8]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
jne 0x4038aa
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
test byte [ebp - 0x250], 0x10
jne 0x4038da
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x4038d3
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
pop esi
mov esp, ebp
pop ebp
ret
xor eax, eax
pop esi
mov esp, ebp
pop ebp
ret
push esi
call fcn.00403730
add esp, 4
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x403e20
Capabilities:
Get geographical location
Query environment variable

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [0x426090]
sub esp, 0xa0
push esi
xor esi, esi
push edi
mov edi, dword [ebp + 8]
test eax, eax
je 0x403e54
nop dword [eax]
cmp eax, edi
je 0x403e54
inc esi
mov eax, esi
shl eax, 4
mov eax, dword [eax + 0x426090]
test eax, eax
jne 0x403e40
shl esi, 4
cmp dword [esi + 0x426090], 0
jne 0x403e6b
pop edi
mov eax, 0x4217d4
pop esi
mov esp, ebp
pop ebp
ret
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
push edi
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 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
mov dword [ebp - 4], edi
call ebx
mov edx, 2
test eax, eax
jne 0x403f13
xor ecx, ecx
lea eax, [edi + 2]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0041eca5
mov ecx, dword [ebp - 4]
add esp, 4
inc ecx
mov edi, eax
lea eax, [ebp - 0x60]
push ecx
push edi
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp eax, dword [ebp - 4]
ja 0x403f0a
call ebx
test eax, eax
jne 0x403f0a
mov eax, dword [esi + 0x42609c]
test eax, eax
je 0x403f02
push edi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x403f0a
push 2
push dword [esi + 0x42609c]
call fcn.0041ec92
add esp, 8
mov dword [esi + 0x42609c], edi
jmp 0x403f13
push edi
call fcn.0041eca0
add esp, 4
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [esi + 0x42609c]
test eax, eax
jne 0x403fe7
mov ebx, dword [esi + 0x426094]
cmp dword [esi + 0x426098], eax
je 0x403f4b
call fcn.00404450
cmp eax, dword [0x4219ec]
jne 0x403f4b
mov ebx, dword [esi + 0x426098]
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
xor ecx, ecx
mov edx, 2
lea edi, [eax + 1]
lea eax, [edi + 2]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0041eca5
mov ecx, dword [0x42608c]
add esp, 4
mov dword [esi + 0x42609c], eax
cmp ecx, 0xffffffff
jne 0x403fcc
push 0x1f
lea eax, [ebp - 0xa0]
mov dword [0x42608c], 0
push eax
movzx eax, word [0x426514]
push 0x1004
push eax
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jle 0x403fc6
lea eax, [ebp - 0xa0]
push eax
call dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll__wtol]
mov ecx, eax
add esp, 4
mov dword [0x42608c], ecx
jmp 0x403fcc
mov ecx, dword [0x42608c]
lea eax, [edi + 1]
push eax
push dword [esi + 0x42609c]
push edi
push ebx
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov eax, dword [esi + 0x42609c]
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x404450
Capabilities:
Identify system language via api

Disassembly:
mov dx, word [0x426514]
test dx, dx
jne 0x4044bc
call dword [sym.imp.KERNEL32.dll_GetUserDefaultUILanguage]
mov cx, ax
mov word [0x426514], ax
mov edx, 0x3ff
and cx, dx
cmp cx, 9
je 0x40447d
movzx eax, ax
ret
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
mov ecx, 0x409
cmp ax, cx
jne 0x4044b5
push esi
mov esi, dword [0x4219ec]
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLCID]
movzx edx, word [0x426514]
cmp eax, esi
movzx ecx, si
cmove edx, ecx
mov word [0x426514], dx
pop esi
movzx eax, dx
ret
mov dx, word [0x426514]
movzx eax, dx
ret

Function at 0x4047f0
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.00401290
mov ecx, dword [ebp + 8]
lea esi, [edi + 2]
push esi
call fcn.00403c00
lea ecx, [edi + 1]
push ecx
push esi
mov esi, dword [ebp + 8]
mov ecx, esi
call fcn.00403c00
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ecx, esi
call fcn.00404b80
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4051ab
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x40518a
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop ebp
ret
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4051ab
test al, 0x10
jne 0x4051ab
push 0xb7
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop ebp
ret
mov eax, 1
pop ebp
ret
Function at 0x405c50
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
sub esp, 0x30
lea ecx, [ebp + 8]
call fcn.004012e0
cmp word [eax + 2], 0x3a
jne 0x405e0c
movzx ecx, word [eax + 4]
cmp ecx, 0x5c
je 0x405c7b
cmp ecx, 0x2f
jne 0x405e0c
mov ax, word [eax]
mov word [ebp - 0xc], ax
xor eax, eax
mov word [ebp - 6], ax
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0xa], 0x5c003a
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x405e0c
push edi
lea eax, [ebp - 0x24]
push str.7ZSfx_03x.cmd
push eax
call fcn.00403640
add esp, 8
lea ecx, [ebp - 0x24]
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x405e03
push esi
lea ecx, [ebp - 0x18]
call fcn.00401290
push str.:Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.00401b90
push str.del__
lea ecx, [ebp - 0x18]
call fcn.00412fb0
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00412f70
push 0x42263c
lea ecx, [ebp - 0x18]
call fcn.00412fb0
push str.if_exist__
lea ecx, [ebp - 0x18]
call fcn.00412fb0
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00412f70
push str.__goto_Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.00412fb0
push str.del__
lea ecx, [ebp - 0x18]
call fcn.00412fb0
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x18]
call fcn.00412f70
push 0x42263c
lea ecx, [ebp - 0x18]
call fcn.00412fb0
push 0
lea eax, [ebp - 4]
push eax
lea ecx, [ebp - 0x18]
call fcn.00401fd0
push eax
push 1
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.00405220
add esp, 0xc
mov ecx, eax
call fcn.00402f00
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea ecx, [ebp - 0x30]
mov esi, eax
call fcn.00401650
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
pop esi
je 0x405dea
lea ecx, [ebp - 0x18]
call fcn.00401fd0
cmp dword [ebp - 4], eax
jne 0x405dea
push 0
lea ecx, [ebp + 8]
call fcn.004012e0
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push 0
push 0
push 0
lea ecx, [ebp - 0x24]
call fcn.004012e0
push eax
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
jmp 0x405dfb
lea ecx, [ebp - 0x24]
call fcn.004012e0
push eax
call fcn.00403880
add esp, 4
lea ecx, [ebp - 0x18]
call fcn.00401650
lea ecx, [ebp - 0x24]
call fcn.00401650
pop edi
lea ecx, [ebp + 8]
call fcn.00401650
mov esp, ebp
pop ebp
ret