joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404d50
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x413660
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x41d014]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x10], eax
push 8
mov dword [eax], 0x416eb8
call fcn.0041004e
mov esi, eax
push 1
mov dword [ebp - 4], 0
call fcn.0040f9b4
mov dword [esi + 4], eax
add esp, 8
mov eax, dword [ebp - 0x10]
lea edi, [eax + 0x14]
lea ecx, [eax + 0x18]
lea edx, [eax + 0x24]
mov dword [eax + 0x34], esi
lea ebx, [eax + 4]
mov dword [eax + 0xc], ebx
lea esi, [eax + 8]
mov dword [eax + 0x10], esi
mov dword [eax + 0x1c], edi
mov dword [eax + 0x20], ecx
mov dword [eax + 0x2c], edx
add eax, 0x28
mov dword [ebp - 0x14], ebx
mov ebx, dword [ebp - 0x10]
mov dword [ebx + 0x30], eax
mov ebx, dword [ebp - 0x14]
mov dword [esi], 0
mov dword [ecx], 0
mov dword [eax], 0
mov eax, dword [ebp - 0x10]
mov dword [ebx], 0
mov dword [edi], 0
mov dword [edx], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x410a37
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [0x415084]
test eax, eax
je 0x410a76
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x410a76
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x410a76
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x410a76
cmp dword [ecx + 0x74], 0xe
jbe 0x410a76
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x4131d0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4131fd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4131fd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x41e000
Capabilities:
Parse pe header
Read file on windows

Disassembly:
sub esp, 0x40
lea eax, [esp + 0x44]
lea ecx, [esp]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
push ebp
push esi
mov esi, dword [esp + 0x50]
push edi
push 0
push eax
push 0x40
push ecx
push esi
call ebx
test eax, eax
je 0x41e175
cmp dword [esp + 0x54], 0x40
jne 0x41e175
cmp word [esp + 0x10], 0x5a4d
jne 0x41e175
mov edx, dword [esp + 0x4c]
mov ebp, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push 0
push edx
push esi
call ebp
cmp eax, 0xffffffff
je 0x41e175
lea eax, [esp + 0x54]
push 0
push eax
push 0xf8
push 0x424960
push esi
call ebx
test eax, eax
je 0x41e175
cmp dword [esp + 0x54], 0xf8
jne 0x41e175
cmp dword [0x424960], 0x4550
jne 0x41e175
mov eax, dword [0x424976]
test ah, 0x20
jne 0x41e175
mov edx, dword [0x424a80]
xor eax, eax
mov ax, word [0x424966]
add eax, edx
lea eax, [eax + eax*4]
shl eax, 3
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
test eax, eax
mov dword [0x424a58], eax
je 0x41e175
push 1
push 0
push 0
push esi
call ebp
mov dword [0x424a6c], eax
xor eax, eax
mov ax, word [0x424966]
mov edx, dword [0x424a58]
lea ecx, [esp + 0x54]
push 0
lea edi, [eax + eax*4]
push ecx
shl edi, 3
push edi
push edx
push esi
call ebx
test eax, eax
je 0x41e175
cmp dword [esp + 0x54], edi
jne 0x41e175
push 1
push 0
push 0
push esi
call ebp
mov ecx, dword [0x424a80]
lea ecx, [ecx + ecx*4]
lea edx, [eax + ecx*8]
mov eax, dword [0x4249b4]
cmp edx, eax
ja 0x41e175
mov edi, dword [0x424a58]
mov ecx, dword [0x424988]
mov eax, dword [edi + 0x10]
mov edx, dword [edi + 0xc]
add eax, edx
cmp ecx, eax
jae 0x41e175
xor eax, eax
push 2
mov ax, word [0x424966]
push 0
push 0
push esi
lea ecx, [eax + eax*4]
mov ebx, dword [edi + ecx*8 - 0x18]
lea edi, [edi + ecx*8]
call ebp
mov edx, dword [edi - 0x14]
add edx, ebx
cmp eax, edx
jne 0x41e175
cmp dword [edi - 0x20], ebx
ja 0x41e175
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x40
ret
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x40
ret
Function at 0x420769
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x424190
cmp edx, dword [eax]
je 0x42078b
add eax, 8
inc ecx
cmp eax, 0x424220
jl 0x42077c
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x424190]
jne 0x4208b9
mov eax, dword [0x424bb0]
cmp eax, 1
je 0x420893
test eax, eax
jne 0x4207bc
cmp dword [0x4240e4], 1
je 0x420893
cmp edx, 0xfc
je 0x4208b9
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4207f3
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00421670
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00421490
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x420836
lea eax, [ebp - 0x1a4]
push eax
call fcn.00421490
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x42345c
push edi
call fcn.00421f00
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00421670
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00421680
lea eax, [ebp - 0xa0]
push 0x42343c
push eax
call fcn.00421680
push dword [esi + 0x424194]
lea eax, [ebp - 0xa0]
push eax
call fcn.00421680
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00421e75
add esp, 0x2c
pop edi
jmp 0x4208b9
lea eax, [ebp + 8]
lea esi, [esi + 0x424194]
push 0
push eax
push dword [esi]
call fcn.00421490
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 0x401cf0
Capabilities:
Encode data using xor
Get file size
Read file on windows

Disassembly:
sub esp, 0x24
push esi
mov esi, dword [esp + 0x2c]
lea eax, [esp + 4]
mov dword [esp + 4], 0
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
test eax, eax
je 0x401dd1
test eax, 0xfff
jne 0x401dd1
mov eax, dword [esp + 4]
test eax, eax
jne 0x401dd1
xor ecx, ecx
push 2
mov dword [esp + 0xc], ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], ecx
push ecx
push 0xfffffffffffffff0
push esi
mov dword [esp + 0x24], ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea edx, [esp + 0x2c]
push 0
push edx
lea eax, [esp + 0x10]
push 0x10
push eax
push esi
mov dword [esp + 0x40], 0
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401dd1
xor eax, eax
mov cl, byte [eax + 0x416940]
mov dl, byte [esp + eax + 8]
xor cl, dl
mov byte [esp + eax + 0x18], cl
inc eax
cmp eax, 0x10
jl 0x401d6c
lea eax, [esp + 0x24]
mov edx, str..SJZ
mov ecx, dword [eax]
mov eax, dword [edx]
cmp ecx, eax
jne 0x401d9d
mov eax, 1
pop esi
add esp, 0x24
ret
lea edx, [esp + 0x18]
push 0x41de38
lea eax, [esp + 0xc]
push edx
push eax
call fcn.004016b0
lea edx, [esp + 0x30]
mov ecx, str..SJZ
add esp, 0xc
mov eax, dword [edx]
mov edx, dword [ecx]
sub eax, edx
pop esi
neg eax
sbb eax, eax
and al, 0xfe
add eax, 2
add esp, 0x24
ret
xor eax, eax
pop esi
add esp, 0x24
ret

Function at 0x401de0
Capabilities:
Encode data using xor
Read file on windows
Write file on windows

Disassembly:
mov eax, 0x2008
call fcn.00408060
mov eax, dword [esp + 0x200c]
push ebx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
xor ebx, ebx
push edi
push ebx
push ebx
push ebx
push eax
call esi
mov ecx, dword [esp + 0x201c]
push ebx
push ebx
push ebx
push ecx
call esi
mov edi, dword [esp + 0x2020]
mov ecx, dword [esp + 0x2018]
lea edx, [esp + 0xc]
push ebx
push edx
lea eax, [esp + 0x1c]
push 0x1000
push eax
push ecx
mov dword [esp + 0x20], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401ecf
cmp dword [esp + 0xc], 0x1000
jb 0x401edb
xor esi, esi
cmp edi, 1
jne 0x401e78
xor eax, eax
lea edx, [esi + eax]
mov cl, byte [esp + edx + 0x14]
mov dl, byte [eax + 0x416940]
xor cl, dl
lea edx, [esi + eax]
inc eax
cmp eax, 0x10
mov byte [esp + edx + 0x1014], cl
jl 0x401e57
jmp 0x401e97
cmp edi, 2
jne 0x401e97
lea eax, [esp + esi + 0x1014]
push 0x41de38
lea ecx, [esp + esi + 0x18]
push eax
push ecx
call fcn.004016b0
add esp, 0xc
add esi, 0x10
cmp esi, 0x1000
jl 0x401e50
mov ecx, dword [esp + 0x201c]
lea edx, [esp + 0x10]
push ebx
push edx
lea eax, [esp + 0x101c]
push 0x1000
push eax
push ecx
mov dword [esp + 0x24], ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x401e16
pop edi
pop esi
xor al, al
pop ebx
add esp, 0x2008
ret
pop edi
pop esi
mov al, 1
pop ebx
add esp, 0x2008
ret
Function at 0x401ef0
Capabilities:
Get file size
Read file on windows

Disassembly:
sub esp, 8
push esi
mov esi, dword [esp + 0x10]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 2
push 0
push 0xffffffffffffffe7
push esi
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], 0
call edi
lea eax, [esp + 0xc]
push 0
push eax
lea ecx, [esp + 0x10]
push 4
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401f65
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ecx, dword [esp + 8]
test ecx, ecx
jl 0x401f65
add eax, 0xfffffc18
cmp ecx, eax
jg 0x401f65
push 0
push 0
push ecx
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
pop edi
pop esi
setne al
add esp, 8
ret
pop edi
xor al, al
pop esi
add esp, 8
ret
Function at 0x401287
Capabilities:
Get graphical window text

Disassembly:
push ebp
lea ebp, [esp - 0x70]
sub esp, 0xe8
push ebx
push esi
mov esi, dword [ebp + 0x78]
push edi
push dword [ebp + 0x7c]
mov edi, dword [sym.imp.USER32.dll_GetDlgItem]
push dword [esi + 0x18]
call edi
push 9
push dword [esi + 0x18]
mov dword [ebp + 0x6c], eax
call edi
mov dword [ebp + 0x78], eax
push 0x64
lea eax, [ebp - 0x78]
push eax
push dword [ebp + 0x6c]
xor ebx, ebx
mov word [ebp - 0x78], bx
call dword [sym.imp.USER32.dll_GetWindowTextW]
lea eax, [ebp - 0x78]
push eax
push dword [ebp + 0x78]
call dword [sym.imp.USER32.dll_SetWindowTextW]
lea eax, [ebp + 0x64]
push eax
push dword [esi + 0x18]
mov dword [ebp + 0x64], ebx
mov dword [ebp + 0x68], ebx
call dword [sym.imp.USER32.dll_ClientToScreen]
xor eax, eax
lea edi, [ebp + 0x54]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp + 0x54]
push eax
push dword [ebp + 0x6c]
call dword [sym.imp.USER32.dll_GetWindowRect]
mov ecx, dword [ebp + 0x58]
mov eax, dword [ebp + 0x54]
mov edi, dword [ebp + 0x60]
mov esi, dword [ebp + 0x5c]
push 4
sub edi, ecx
sub ecx, dword [ebp + 0x68]
push edi
sub esi, eax
sub eax, dword [ebp + 0x64]
push esi
push ecx
push eax
push ebx
push dword [ebp + 0x78]
mov dword [ebp + 0x54], eax
mov dword [ebp + 0x58], ecx
call dword [sym.imp.USER32.dll_SetWindowPos]
push 1
push edi
push esi
push dword [ebp + 0x58]
push dword [ebp + 0x54]
push dword [ebp + 0x78]
call dword [sym.imp.USER32.dll_MoveWindow]
push ebx
push dword [ebp + 0x6c]
call dword [sym.imp.USER32.dll_ShowWindow]
pop edi
pop esi
pop ebx
add ebp, 0x70
leave
ret

Function at 0x402d86
Capabilities:
Acquire debug privileges

Disassembly:
xor eax, eax
cmp byte [esp + 4], al
push esi
mov esi, ecx
mov byte [esi], al
je 0x402db6
test byte [0x4d8d74], 4
jne 0x402db6
push eax
push 2
mov byte [esi], 1
or byte [0x4d8d74], 4
push str.SeDebugPrivilege
call fcn.004130be
add esp, 0xc
mov eax, esi
pop esi
ret 4
Function at 0x403980
Capabilities:
Get common file path
Query environment variable

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0xc]
mov eax, dword [esi]
push edi
xor edi, edi
test eax, eax
je 0x403998
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
lea eax, [edi + 0x2d0]
push eax
mov ecx, esi
call fcn.004441e6
test edi, edi
jg 0x403a23
mov eax, dword [esi]
and word [eax], 0
mov eax, dword [esi]
mov ebx, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push ebp
mov ebp, 0x208
push ebp
push eax
push 0x4bcd44
call ebx
mov edi, eax
test edi, edi
jg 0x403a12
mov eax, dword [esi]
push ebp
push eax
push 0x4bcd38
call ebx
mov edi, eax
test edi, edi
jg 0x403a12
push 0
push 0x24
push dword [esi]
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
test edi, edi
jle 0x403a22
mov eax, dword [esi]
push 0x4bcd2c
lea eax, [eax + edi*2]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
add edi, 5
test edi, edi
jle 0x403a22
mov eax, dword [esi]
mov word [eax + edi*2], 0x5c
mov eax, dword [esi]
inc edi
and word [eax + edi*2], 0
pop ebp
push dword [esi]
mov ebx, 0x4d80e0
mov ecx, ebx
call fcn.0041cf16
test edi, edi
jle 0x403a41
push dword [esi]
call fcn.004a96f0
test eax, eax
pop ecx
jne 0x403a6f
push 0
push 0x24
push dword [esi]
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push str.TEMP_
push dword [esi]
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push dword [esi]
mov ecx, ebx
call fcn.0041cf16
push dword [esi]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
mov eax, edi
pop edi
pop esi
pop ebx
ret
Function at 0x403e62
Capabilities:
Get geographical location
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
and word [ebp - 0x44], 0
push 0x20
lea eax, [ebp - 0x44]
push eax
push str.LC_ALL
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp word [ebp - 0x44], 0
jne 0x403e98
push 0x20
lea eax, [ebp - 0x44]
push eax
push 0xb
push 0x800
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
cmp word [ebp - 0x44], 0
lea eax, [ebp - 0x44]
jne 0x403ea7
mov eax, 0x4bcf3c
push eax
mov ecx, 0x4d7c8c
call fcn.0044cff1
push dword [0x4d7c8c]
call fcn.00444d77
cmp eax, 1
pop ecx
jle 0x403ec9
mov word [0x4db018], ax
leave
ret

Function at 0x404023
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push edi
mov edi, dword [sym.imp.USER32.dll_GetLastInputInfo]
lea eax, [ebp - 8]
xor ebx, ebx
push eax
mov dword [ebp - 8], 8
mov dword [ebp - 4], ebx
call edi
mov eax, dword [ebp - 4]
mov ecx, eax
sub ecx, dword [0x4d7c40]
test ecx, ecx
jle 0x404056
mov dword [0x4d7c40], eax
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
mov dword [0x4d7c40], eax
jmp 0x40408e
lea eax, [ebp - 8]
push eax
mov dword [ebp - 4], ebx
call edi
call esi
mov ecx, eax
sub ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 8]
jb 0x404086
sub eax, dword [0x4d7c40]
cmp eax, dword [ebp + 8]
jae 0x404096
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp byte [0x4d62d4], bl
jg 0x404066
mov eax, dword [ebp - 4]
mov ecx, eax
sub ecx, dword [0x4d7c40]
pop esi
test ecx, ecx
jle 0x4040ab
mov dword [0x4d7c40], eax
xor eax, eax
cmp byte [0x4d62d4], bl
pop edi
setg al
pop ebx
leave
ret

Function at 0x404280
Capabilities:
Terminate process

Disassembly:
cmp byte [0x4d62d4], 2
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x14
pop esi
je 0x404297
push esi
call edi
cmp dword [0x4d7c50], 0
je 0x4042b2
push 0x1e
pop esi
jmp 0x4042b2
cmp dword [0x4d7c44], 0
je 0x4042b5
push 0xa
call edi
dec esi
jns 0x4042a5
mov eax, dword [0x4d7c44]
test eax, eax
pop edi
pop esi
je 0x4042d3
push 0
push eax
mov dword [0x4d7c44], 0
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov byte [0x4d62d4], 0xff
ret
Function at 0x4042db
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 0xc]
mov esi, 0x8000004
push 0x64
push ebx
push esi
push ebx
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov edi, eax
cmp edi, ebx
mov byte [ebp - 1], 1
je 0x40431c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40432d
mov byte [ebp - 1], bl
jmp 0x40432d
push dword [ebp + 0xc]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_OpenFileMappingA]
mov edi, eax
cmp edi, ebx
je 0x404369
push ebx
push ebx
push ebx
push 6
push edi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
push edi
mov dword [0x4d7c58], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x4d7c58]
cmp eax, ebx
je 0x404369
cmp byte [ebp - 1], bl
je 0x404364
push 0x64
push ebx
push eax
call fcn.004aa0a0
mov eax, dword [0x4d7c58]
add esp, 0xc
mov ecx, dword [ebp + 8]
mov dword [eax], ecx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x405a60
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
xor edi, edi
cmp dword [ebp + 8], edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x10], edi
jne 0x405a7c
lea ebx, [ebp - 0x14]
cmp dword [ebp + 0xc], edi
mov esi, dword [ebp + 0xc]
jne 0x405a9a
cmp dword [ebp + 8], edi
lea esi, [ebp - 0x10]
je 0x405c25
push dword [ebx]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push 0x26c
mov ecx, ebx
call fcn.004441e6
push esi
call fcn.00403980
mov edi, eax
lea eax, [edi + 1]
push eax
push dword [esi]
mov dword [ebp - 0x18], edi
push dword [ebx]
call fcn.0040561e
add esp, 0x10
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
and dword [ebp - 4], 0
and dword [ebp - 0xc], 0
mov dword [ebp - 8], 0xc7
jmp 0x405add
mov edi, dword [ebp - 0x18]
cmp dword [ebp + 8], 0
je 0x405b88
mov eax, dword [ebx]
lea eax, [eax + edi*2]
push 0x4bd294
mov dword [ebp - 0x1c], eax
call fcn.00440360
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
add edi, eax
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push dword [ebp + 0x14]
push str.pecmd__s._lu._lu_s_
push dword [ebp - 0x1c]
call dword [sym.imp.USER32.dll_wsprintfW]
mov eax, dword [ebx]
add esp, 0x18
xor edi, edi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x405b47
push edi
push edi
push 5
mov ecx, 0x4d80e0
call fcn.00415bb5
dec dword [ebp - 8]
jns 0x405ada
jmp 0x405c01
cmp dword [ebp + 0xc], edi
mov dword [ebp - 0xc], 1
je 0x405c25
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
lea eax, [edi + 1]
push eax
push dword [ebx]
mov dword [ebp + 8], eax
push dword [esi]
call fcn.0040561e
mov eax, dword [esi]
mov word [eax + edi*2], 0x5c
mov eax, dword [ebp + 8]
mov ecx, dword [esi]
add esp, 0xc
and word [ecx + eax*2], 0
jmp 0x405b8a
mov eax, edi
and dword [ebp + 8], 0
add eax, eax
mov dword [ebp + 0xc], eax
push dword [ebp + 0x18]
mov edi, dword [esi]
push dword [ebp + 8]
add edi, dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push dword [ebp + 0x14]
push str.pecmd__s._lu._lu_s
push edi
call dword [sym.imp.USER32.dll_wsprintfW]
mov eax, dword [esi]
add esp, 0x18
xor edi, edi
push edi
push 0x80
push 1
push edi
push edi
push 0x40000000
push eax
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x1c], edi
call fcn.0040569f
cmp eax, edi
mov dword [ebp - 4], eax
jne 0x405bfc
push edi
push edi
push 5
mov ecx, 0x4d80e0
call fcn.00415bb5
inc dword [ebp + 8]
cmp dword [ebp + 8], 0xc8
jl 0x405b93
mov eax, dword [esi]
and word [eax], di
cmp dword [ebp - 0xc], edi
jne 0x405c06
mov eax, dword [ebx]
mov word [eax], di
mov eax, dword [ebp + 0x10]
cmp eax, edi
je 0x405c14
mov ecx, dword [ebp - 4]
mov dword [eax], ecx
jmp 0x405c22
cmp dword [ebp - 4], edi
je 0x405c22
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [ebp - 4]
lea ecx, [ebp - 0x10]
call fcn.0043dd41
lea ecx, [ebp - 0x14]
call fcn.0043dd41
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x405c3c
Capabilities:
Get common file path
Get startup folder

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x12c
push ebx
push esi
push edi
push str.PECMD:MSGSVR:HWND
xor ebx, ebx
push ebx
call fcn.004042db
pop ecx
pop ecx
call fcn.00403e62
mov byte [0x4d7c32], 1
call fcn.00404022
call fcn.0043fbde
push str.TaskbarButtonCreated
call dword [sym.imp.USER32.dll_RegisterWindowMessageW]
push ebx
push 0x24
pop edi
mov dword [0x4d7c34], eax
push edi
lea eax, [ebp - 0x12c]
push eax
push ebx
mov byte [ebp - 0x12c], bl
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
push str.System32Kernel32
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push str.user32
mov dword [0x4d7fe0], eax
mov dword [ebp - 4], eax
call esi
push str.GDI32
mov dword [0x4d7fdc], eax
call esi
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x4bd344
push dword [ebp - 4]
mov dword [0x4d7fe4], eax
call esi
push 7
pop ecx
mov dword [ebp - 0x28], edi
push str.GetNativeSystemInfo
push dword [ebp - 4]
mov dword [0x4d7be4], eax
xor eax, eax
mov dword [ebp - 0x24], ebx
lea edi, [ebp - 0x20]
rep stosd dword es:[edi], eax
call esi
cmp eax, ebx
je 0x405d14
lea ecx, [ebp - 0x28]
push ecx
call eax
call fcn.00440aaa
shrd eax, edx, 0x10
shr edx, 0x10
cmp word [ebp - 0x28], bx
je 0x405d64
cmp eax, 0x50000
jbe 0x405d64
push str.Wow64RevertWow64FsRedirection
push dword [ebp - 4]
call esi
push str.Wow64DisableWow64FsRedirection
push dword [ebp - 4]
mov dword [0x4d7c2c], eax
call esi
cmp dword [0x4d7c2c], ebx
mov dword [0x4d7c28], eax
jne 0x405d59
mov dword [0x4d7c28], ebx
mov bl, 1
mov word [0x4d7c14], 0x100
movsx eax, bl
push str.bX64
push eax
mov esi, 0x4d80e0
push esi
mov byte [0x4d7c31], bl
call fcn.00446768
push str.ptrlen
push 4
push esi
call fcn.00446768
push str.WM_TASKBARBUTTONCREATED
push dword [0x4d7c34]
push esi
call fcn.00446768
add esp, 0x24
pop edi
pop esi
pop ebx
leave
ret
Function at 0x405da4
Capabilities:
Query environment variable
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x78
mov dword [ebp - 8], eax
lea ecx, [eax + 8]
push ebx
mov bx, word [eax]
mov dword [ebp - 8], ecx
mov ax, word [ecx]
call fcn.0040f4c7
test al, al
jne 0x405dc8
inc ecx
inc ecx
mov dword [ebp - 8], ecx
push 0x63
lea eax, [ebp - 0x78]
push eax
push str.DEBUGMDG
mov byte [ebp - 0x78], 0
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
cmp byte [ebp - 0x78], 0x31
jne 0x405dea
mov byte [0x4d7c3c], 1
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push dword [ebp - 8]
and dword [ebp - 0x10], 0
lea ecx, [ebp - 0x14]
mov dword [0x4d7c40], eax
call fcn.0044cf2d
lea ecx, [ebp - 0xc]
call fcn.004441a1
push 1
push 0
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 0x14]
mov ecx, 0x4d80e0
call fcn.004538d5
push dword [ebp - 0xc]
lea ecx, [ebp - 0x10]
call fcn.0044cff1
mov eax, dword [ebp - 0x10]
lea ecx, [ebp - 0xc]
mov dword [ebp - 8], eax
call fcn.0043dd41
lea ecx, [ebp - 0x14]
call fcn.0043dd41
mov ecx, dword [ebp - 8]
call fcn.004040ba
push str._InstallService
mov edi, eax
push 0xf
pop esi
mov dword [ebp - 8], edi
call fcn.00402d57
test al, al
pop ecx
pop edi
pop esi
je 0x405e8b
push 0x1e
push str._Service
push dword [ebp - 8]
mov byte [ebp - 1], 0x49
call fcn.00413fe3
mov ecx, dword [ebp - 8]
add esp, 0xc
add ecx, 0x1e
call fcn.004040ba
mov dword [ebp - 8], eax
jmp 0x405ea6
push 8
lea eax, [ebp - 8]
push eax
push 0x4bd3cc
call fcn.004460ea
add esp, 0xc
test al, al
je 0x405f05
mov byte [ebp - 1], 0x53
cmp bx, 0x22
jne 0x405ee0
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edx, dword [ebp - 8]
lea ecx, [edx + eax*2 - 2]
cmp ecx, edx
jbe 0x405ee0
mov ax, word [ecx]
call fcn.0040f4c7
test al, al
je 0x405ed2
dec ecx
dec ecx
cmp ecx, edx
ja 0x405ec0
cmp ecx, edx
jbe 0x405ee0
cmp word [ecx], 0x22
jne 0x405ee0
and word [ecx], 0
sub dword [ebp - 8], 2
movsx ax, byte [ebp - 1]
mov ecx, dword [ebp - 8]
mov word [ecx], ax
sub dword [ebp - 8], 2
mov eax, dword [ebp - 8]
mov word [eax], 0x7e
push dword [ebp - 8]
call fcn.0040f334
jmp 0x405f25
push 0xe
lea eax, [ebp - 8]
push eax
push str._RemoveService
call fcn.004460ea
add esp, 0xc
test al, al
pop ebx
je 0x405f2e
push dword [ebp - 8]
call fcn.004061c1
pop ecx
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
lea ecx, [ebp - 0x10]
call fcn.0043dd41
xor eax, eax
leave
ret