joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40595e
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
pushal
call 0x40596d
pop dword [ebp - 0x4c]
mov eax, 0xc0f17be4
add eax, 0x3f4edd89
sub dword [ebp - 0x4c], eax
mov dword [ebp - 0x5c], 0xcfbf9a38
add dword [ebp - 0x5c], 0x7e92ab13
mov dword [ebp - 0x58], 0x19208f12
sub dword [ebp - 0x58], 0xe6ed42cd
mov dword [ebp - 0x54], 0x2ddca640
add dword [ebp - 0x54], 0x1e6f9dee
mov dword [ebp - 0x50], 0x6c68e3f1
add dword [ebp - 0x50], 0x93971c0f
lea eax, [ebp - 0x5c]
push eax
mov eax, sym.imp.kernel32.dll_GetModuleHandleA
add eax, dword [ebp - 0x4c]
call dword [eax]
mov dword [ebp - 0x5c], 0x8506b60a
add dword [ebp - 0x5c], 0xef6bb34c
mov dword [ebp - 0x58], 0x9ac65dae
add dword [ebp - 0x58], 0xa6a603c7
mov dword [ebp - 0x54], 0x737bdef2
sub dword [ebp - 0x54], 0x100c7286
mov dword [ebp - 0x50], 0x9eb59db9
sub dword [ebp - 0x50], 0x9eb59db9
lea ebx, [ebp - 0x5c]
push ebx
push eax
mov eax, 0xf03373da
sub eax, 0xeff302da
add eax, dword [ebp - 0x4c]
call dword [eax]
push 0x40
push 0x1000
push 0x3ad77
push 0
call eax
mov ecx, 0xd576621f
add ecx, 0x2a89f661
xor esi, esi
add esi, eax
mov edx, 0x410000
add edx, dword [ebp - 0x4c]
mov ebx, 0xc7b58b4b
mov edi, dword [edx]
xor dword [ebp - 0x30], 0x68d90214
sub edi, ebx
mov dword [esi], edi
xor dword [ebp - 0x18], 0x871f809c
add esi, 0x11d67249
sub esi, 0x11d67245
add edx, 4
loop 0x405a80
add eax, 0x154d3
mov ebx, eax
add eax, 5
mov ecx, 0x400000
add ecx, dword [ebp - 0x4c]
call ebx
leave
ret

Function at 0x4065b0
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x40c17c]
jne 0x4065ba
repz ret
jmp fcn.00406941
Function at 0x433005
Capabilities:
Encode data using xor

Disassembly:
pushal
nop
mov eax, section..text
nop
push 4
nop
nop
nop
nop
nop
nop
nop
nop
pop edi
nop
cmp eax, 0
nop
nop
nop
je 0x433072
nop
nop
nop
mov ebx, 0x40de38
nop
nop
nop
nop
mov ecx, ebx
nop
nop
sub ecx, eax
nop
nop
nop
xor edx, edx
nop
nop
nop
nop
nop
nop
push eax
nop
nop
nop
nop
mov eax, ecx
nop
nop
nop
div edi
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
nop
nop
pop eax
nop
nop
mov esi, 0x1cb56222
nop
nop
nop
nop
xor dword [eax], esi
nop
nop
add eax, edi
nop
nop
nop
nop
loop 0x433060
nop
nop
nop
mov eax, section..data
nop
cmp eax, 0
nop
nop
nop
je 0x4330d2
nop
nop
nop
nop
nop
mov ebx, 0x4304d8
mov ecx, ebx
nop
nop
nop
nop
nop
nop
nop
sub ecx, eax
nop
nop
nop
nop
nop
xor edx, edx
nop
nop
nop
push eax
nop
nop
nop
nop
mov eax, ecx
nop
nop
nop
nop
div edi
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
nop
nop
pop eax
nop
nop
mov esi, 0x5a8a0be5
nop
nop
xor dword [eax], esi
nop
nop
nop
add eax, edi
nop
nop
nop
nop
nop
nop
nop
nop
loop 0x4330c0
nop
nop
popal
nop
nop
nop
jmp 0x431219

Function at 0x401219
Capabilities:
Terminate process

Disassembly:
mov eax, dword fs:[0]
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40301c
push 0x40109a
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
push eax
fnstcw word [esp]
or word [esp], 0x300
fldcw word [esp]
add esp, 4
push 0
push 0
push 0x403028
push 0x403024
push 0x403020
call sub.CRTDLL.DLL___GetMainArgs
push dword [0x403028]
push dword [0x403024]
push dword [0x403020]
mov dword [0x403014], esp
call fcn.0040129c
add esp, 0x18
xor ecx, ecx
mov dword [ebp - 4], ecx
push eax
call sub.CRTDLL.DLL_exit
leave
ret

Function at 0x503b67
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
mov ecx, ebp
push ebp
mov ebp, esp
mov dword [0x505076], ecx
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [0x505298], eax
mov dword [0x505220], 0x5032dd
mov dword [0x50521c], 2
jmp 0x503b97
mov dword [0x505224], 0
mov dword [0x505228], 0
mov dword [0x505218], 0x30
push 0
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
mov dword [0x50522c], eax
mov dword [0x505240], 0x504088
mov dword [0x505238], 0xf
mov dword [0x50506e], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadIconA]
mov dword [0x505230], eax
mov dword [0x505244], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorA]
mov dword [0x505234], eax
push 0x505218
call dword [sym.imp.user32.dll_RegisterClassExA]
push 0
push dword [0x50506e]
push 0
push 0
push 0x1e5
push 0x21e
push 0xffffe52a
push 0xfffff588
push 0x40000
push str.wait
push str.aroka
push 0
call dword [sym.imp.user32.dll_CreateWindowExA]
mov dword [0x505290], eax
push 5
push dword [0x505290]
call dword [sym.imp.user32.dll_ShowWindow]
push dword [0x505290]
call dword [sym.imp.user32.dll_UpdateWindow]
jmp 0x503c6a
push 0
push 0
push 0
push 0x505248
call dword [sym.imp.user32.dll_GetMessageA]
or eax, eax
je 0x503c97
push 0x505248
call dword [sym.imp.user32.dll_TranslateMessage]
push 0x505248
call dword [sym.imp.user32.dll_DispatchMessageA]
jmp 0x503c6a
mov eax, dword [0x505250]
jmp 0x503ca4
call 0x502b16
ret
Function at 0x406de0
Capabilities:
Hide graphical window

Disassembly:
push 0
mov eax, dword [0x40a930]
push eax
call sub.user32.dll_ShowWindow
push 0xffffffffffffffec
mov eax, dword [0x40a930]
push eax
call sub.user32.dll_GetWindowLongA
or eax, 0x80
push eax
push 0xffffffffffffffec
mov eax, dword [0x40a930]
push eax
call sub.user32.dll_SetWindowLongA
push 5
mov eax, dword [0x40a930]
push eax
call sub.user32.dll_ShowWindow
ret

Function at 0x401a1f
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
call sub.kernel32.dll_GetCommandLineA
mov dword [0x4050c0], eax
mov ecx, ebp
add ecx, 8
mov dword [0x405058], ecx
mov dword [0x4050c4], 0x30
mov dword [0x4050c8], 3
mov dword [0x4050d0], 0
mov dword [0x4050d4], 0
mov dword [0x4050cc], 0x4031ad
mov eax, 0xffff0000
mov ebx, section..text
and ebx, eax
mov dword [0x405050], ebx
mov dword [0x4050d8], ebx
mov dword [0x4050e4], 0xf
mov dword [0x4050ec], 0x4045ef
push 0x7f00
push 0
call sub.user32.dll_LoadIconA
mov dword [0x4050dc], eax
mov dword [0x4050f0], eax
push 0x7f00
push 0
call sub.user32.dll_LoadCursorA
mov dword [0x4050e0], eax
push 0x4050c4
call sub.user32.dll_RegisterClassExA
push 0
push dword [0x405050]
push 0
push 0
push 0x2bc
push 0x1f4
push 0xa0
push 0x12c
push 0x40000
push str.form
push str.wind
push 0
call sub.user32.dll_CreateWindowExA
mov dword [0x4050b8], eax
push 0
push dword [0x4050b8]
call sub.user32.dll_ShowWindow
push dword [0x4050b8]
call sub.user32.dll_UpdateWindow
push 0
push 0
push 0
push 0x4050f4
call sub.user32.dll_GetMessageA
or eax, eax
je 0x401b43
push 0x4050f4
call sub.user32.dll_TranslateMessage
push 0x4050f4
call sub.user32.dll_DispatchMessageA
jmp 0x401b19
lea ecx, [0x405050]
mov eax, dword [0x4050fc]
mov edi, dword [0x405154]
add edi, eax
call edi
ret

Function at 0x430002
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
call 0x43000c
pop eax
nop
nop
nop
nop
nop
nop
add eax, 0x403d6a
sub eax, 0x403d10
nop
nop
nop
mov ebx, dword [eax]
nop
nop
nop
nop
mov ecx, dword [eax + 4]
nop
nop
nop
mov edx, dword [eax + 8]
nop
nop
xor dword [ebx], edx
nop
nop
nop
nop
add ebx, 4
nop
nop
nop
nop
nop
nop
cmp ebx, ecx
jl 0x430030
nop
nop
nop
nop
nop
nop
add eax, 0xc
nop
nop
nop
cmp dword [eax], 0
nop
nop
nop
nop
nop
jne 0x43001e
nop
nop
nop
nop
nop
popal
jmp loc.00401219
Function at 0x402916
Capabilities:
Clear file content
Write file on windows

Disassembly:
push pe_nt_image_headers32
mov eax, 0x57821a
call fcn.0054d2bd
mov edi, dword [ebp + 0xc]
xor eax, eax
mov ebx, dword [ebp + 8]
push eax
push eax
push 2
push eax
push eax
push 0x40000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x40296b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040db42
push eax
push edi
push str.Error_creating_text_database_file_n___s:_n_s_n_nPlease_ensure_the_path_exists_and_you_have_permission_to_write_it.
push 0x30
push ebx
call fcn.0040fe1f
add esp, 0x18
xor al, al
jmp 0x402a74
push str.Time_Stamp
lea eax, [ebp - 0x114]
push 0x588a54
push eax
call fcn.00401bb0
add esp, 0xc
lea eax, [ebp - 0x118]
push 0
push eax
lea eax, [ebp - 0x114]
push eax
call fcn.00552ef0
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
pop ecx
push eax
lea eax, [ebp - 0x114]
push eax
push esi
call edi
xor ebx, ebx
cmp dword [0x5eb8b0], ebx
jle 0x402a51
push dword [ebx*8 + 0x5e9974]
lea eax, [ebp - 0x11c]
push eax
call fcn.0040388c
pop ecx
pop ecx
and dword [ebp - 4], 0
mov ecx, dword [eax]
test ecx, ecx
je 0x4029df
call fcn.00403419
jmp 0x4029e1
xor eax, eax
push eax
lea eax, [ebp - 0x114]
push 0x588a54
push eax
call fcn.00401bb0
or dword [ebp - 4], 0xffffffff
add esp, 0xc
mov ecx, dword [ebp - 0x11c]
test ecx, ecx
je 0x402a10
call fcn.00403761
and dword [ebp - 0x11c], 0
push 0
lea eax, [ebp - 0x118]
push eax
push 1
push 0x588b4c
push esi
call edi
push 0
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x114]
push eax
call fcn.00552ef0
pop ecx
push eax
lea eax, [ebp - 0x114]
push eax
push esi
call edi
inc ebx
cmp ebx, dword [0x5eb8b0]
jl 0x4029b9
push 0
lea ecx, [ebp - 0x118]
push ecx
push 2
push 0x588b50
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
call fcn.0054d26c
ret

Function at 0x403950
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x41c
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x41c]
push edi
push 0x104
xorps xmm0, xmm0
push eax
movlpd qword [ebp - 0xc], xmm0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x214]
push str._sMSJET40.DLL
push eax
call fcn.00401bce
xor edi, edi
lea eax, [ebp - 0xc]
push edi
push edi
push edi
push eax
lea eax, [ebp - 0x214]
push eax
call fcn.0040535d
add esp, 0x20
test al, al
jne 0x4039e4
lea eax, [ebp - 0x41c]
push eax
lea eax, [ebp - 0x214]
push str._sMSJET35.DLL
push eax
call fcn.00401bce
push edi
push edi
push edi
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x214]
push eax
call fcn.0040535d
add esp, 0x20
mov cx, word [ebp - 0xc]
cmp cx, 4
jae 0x403a0b
movzx eax, word [ebp - 0xa]
push eax
movzx eax, cx
push eax
push str.Database_support_requires_that_JET_4.0_or_later_be_installed._n_JET__d._d_detected._
push 0x30
push esi
call fcn.0040fe1f
add esp, 0x14
xor al, al
jmp 0x403a0d
mov al, 1
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0054d24a
leave
ret
Function at 0x403a1b
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x224
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x20c]
push esi
push edi
push 0x208
push 0
push eax
call fcn.0054ee80
and dword [ebp - 0x220], 0
lea edi, [ebp - 0x21c]
xor eax, eax
add esp, 0xc
cmp byte [ebp + 0xc], 0
stosd dword es:[edi], eax
push 0x32
pop esi
stosd dword es:[edi], eax
push 0xa
stosd dword es:[edi], eax
stosd dword es:[edi], eax
pop eax
cmovne esi, eax
lea eax, [ebp - 0x220]
push eax
push 1
xor edi, edi
push edi
push str.SOFTWAREMicrosoftDataAccess
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 0x224]
mov dword [ebp - 0x224], 0x208
push eax
lea eax, [ebp - 0x20c]
push eax
push edi
push edi
push str.FullInstallVer
push dword [ebp - 0x220]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x220]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x214]
push eax
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x21c]
push eax
lea eax, [ebp - 0x20c]
push str._d._d._d._d
push eax
call fcn.00404137
add esp, 0x18
cmp dword [ebp - 0x21c], 2
jl 0x403b04
jne 0x403b00
cmp dword [ebp - 0x218], esi
jl 0x403b04
mov al, 1
jmp 0x403b25
push dword [ebp - 0x218]
push dword [ebp - 0x21c]
push esi
push 2
push str.Database_support_requires_that_MDAC_version__d._d_or_later_be_installed._n_MDAC__d._d_detected._
push 0x30
push ebx
call fcn.0040fe1f
add esp, 0x1c
xor al, al
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0054d24a
leave
ret
Function at 0x40535d
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x220
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 8]
mov eax, dword [ebp + 0x14]
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x210], ecx
mov dword [ebp - 0x218], eax
test edi, edi
je 0x405395
xor eax, eax
mov dword [edi + 4], eax
mov dword [edi], eax
test esi, esi
je 0x4053a0
xor eax, eax
mov dword [esi + 4], eax
mov dword [esi], eax
and dword [ebp - 0x214], 0
lea eax, [ebp - 0x214]
push eax
push ecx
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov dword [ebp - 0x214], eax
test eax, eax
jne 0x4053c5
xor al, al
jmp 0x4054de
push ebx
push eax
call fcn.0041917f
pop ecx
mov ebx, eax
push ebx
push dword [ebp - 0x214]
push 0
push dword [ebp - 0x210]
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x4054d4
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x21c]
push eax
push 0x588d60
push ebx
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x405454
mov ecx, dword [ebp - 0x21c]
test edi, edi
je 0x405431
mov ax, word [ecx + 0xa]
mov word [edi], ax
mov ax, word [ecx + 8]
mov word [edi + 2], ax
mov ax, word [ecx + 0xe]
mov word [edi + 4], ax
mov ax, word [ecx + 0xc]
mov word [edi + 6], ax
test esi, esi
je 0x405454
mov ax, word [ecx + 0x12]
mov word [esi], ax
mov ax, word [ecx + 0x10]
mov word [esi + 2], ax
mov ax, word [ecx + 0x16]
mov word [esi + 4], ax
mov ax, word [ecx + 0x14]
mov word [esi + 6], ax
mov esi, dword [ebp - 0x218]
test esi, esi
je 0x4054d4
xor eax, eax
mov word [esi], ax
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x218]
push eax
push str.VarFileInfoTranslation
push ebx
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x4054d4
mov ecx, dword [ebp - 0x218]
movzx eax, word [ecx + 2]
push eax
movzx eax, word [ecx]
push eax
lea eax, [ebp - 0x20c]
push str.StringFileInfo_04x_04xFileDescription
push eax
call fcn.00401bce
add esp, 0x10
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x20c]
push eax
push ebx
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x4054d4
push dword [ebp - 0x220]
push dword [ebp + 0x18]
push esi
call fcn.00552893
add esp, 0xc
push ebx
call fcn.00419175
pop ecx
mov al, 1
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0054d24a
leave
ret
Function at 0x408530
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 0x5c
pop edi
push edi
push dword [ebp + 8]
call fcn.0054efda
pop ecx
pop ecx
test eax, eax
je 0x408585
add eax, 2
jmp 0x408572
xor eax, eax
push eax
push dword [ebp + 8]
mov word [esi], ax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov word [esi], di
test eax, eax
jne 0x40856f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x408585
lea eax, [esi + 2]
push edi
push eax
call fcn.0054efda
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x40854c
mov al, 1
jmp 0x408587
xor al, al
pop edi
pop esi
pop ebp
ret
Function at 0x40966a
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
push esi
mov dword [ebp - 0x210], eax
lea eax, [ebp - 0x20c]
push 0x104
push eax
mov eax, dword [0x5ebc68]
add eax, 0x43c
mov dword [ebp - 0x214], ebx
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
lea eax, [ebp - 0x20c]
push 0x25
push eax
call fcn.0054efda
pop ecx
test eax, eax
lea eax, [ebp - 0x20c]
pop ecx
je 0x40970a
push 0x25
push eax
call fcn.0054f08a
push 0x25
lea esi, [eax + 2]
push esi
call fcn.0054efda
add esp, 0x10
test eax, eax
je 0x4096e7
xor ecx, ecx
mov word [eax], cx
mov eax, dword [0x5ebc68]
push esi
add eax, 0x43c
push eax
push str.You_have_selected__s_nas_the_path_for_the_output_bitmap__but_the_nenvironment_variable__s_is_not_defined._n_nUse_the_BitmapLocation_menu_item_to_select_a_new_path.
push 0x30
push ebx
call fcn.0040fe1f
add esp, 0x14
xor al, al
jmp 0x40978c
push edi
push eax
call fcn.00408530
pop ecx
push 0
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push edi
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov esi, eax
lea eax, [ebp - 0x20c]
push esi
push dword [ebp - 0x210]
push eax
push ebx
call fcn.00407569
add esp, 0x10
mov bl, al
push esi
call dword [sym.imp.GDI32.dll_DeleteDC]
push edi
xor esi, esi
push esi
call dword [sym.imp.USER32.dll_ReleaseDC]
pop edi
test bl, bl
je 0x409703
cmp byte [ebp + 0x10], 0
mov eax, dword [0x5ebc68]
je 0x409763
mov ecx, esi
jmp 0x40976f
mov ecx, dword [eax + 0x650]
mov esi, dword [eax + 0x64c]
push ecx
push esi
push dword [eax + 0x648]
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x214]
call fcn.00408bec
add esp, 0x14
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.0054d24a
leave
ret

Function at 0x40979a
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push esi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x4097f4
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4097f4
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edx, dword [ebp + 0x10]
lea ecx, [esi + eax]
and edx, 0xf
jbe 0x4097e4
cmp esi, ecx
jae 0x4097f4
movzx eax, word [esi]
lea esi, [esi + eax*2]
add esi, 2
sub edx, 1
jne 0x4097d2
cmp esi, ecx
jae 0x4097f4
xor eax, eax
cmp word [esi], ax
cmove esi, eax
mov eax, esi
jmp 0x4097f6
xor eax, eax
pop esi
pop ebp
ret
Function at 0x409959
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
mov esi, dword [ebp + 8]
push edi
xor edi, edi
cmp word [esi], di
jne 0x4099aa
call fcn.00409c8f
test al, al
je 0x4099aa
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], 0x58bccc
push eax
mov dword [ebp - 0xc], 0x409f3d
mov dword [ebp - 8], edi
mov dword [ebp - 4], edi
call dword [sym.imp.ADVAPI32.dll_StartServiceCtrlDispatcherW]
test eax, eax
jne 0x4099a3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x427
je 0x4099aa
push edi
call dword [sym.imp.KERNEL32.dll_ExitProcess]
cmp byte [ebp + 0xc], 0
je 0x4099cd
push esi
call fcn.00409d83
pop ecx
test al, al
jne 0x4099a3
push str.Unable_to_relaunch_as_a_service._n_nThis_operation_requires_that_BGInfo_be_run_under_an_Administrator_account.
push 0x10
push edi
call fcn.0040fe1f
add esp, 0xc
jmp 0x4099a3
pop edi
mov al, 1
pop esi
leave
ret
Function at 0x409c8f
Capabilities:
Compare security identifiers

Disassembly:
push 0x28
push 0x5d16a8
call fcn.0054d890
xor ebx, ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x38], ebx
mov byte [ebp - 0x25], bl
mov dword [ebp - 4], ebx
mov dword [ebp - 0x24], ebx
mov word [ebp - 0x20], 0x500
lea eax, [ebp - 0x34]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x12
push 1
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x409d37
lea eax, [ebp - 0x2c]
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x409d37
mov dword [ebp - 0x30], ebx
lea eax, [ebp - 0x30]
push eax
push ebx
push ebx
push 1
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
push dword [ebp - 0x30]
call fcn.0041917f
pop ecx
mov ebx, eax
mov dword [ebp - 0x38], ebx
test ebx, ebx
je 0x409d37
lea eax, [ebp - 0x30]
push eax
push dword [ebp - 0x30]
push ebx
push 1
push dword [ebp - 0x2c]
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x409d37
push dword [ebp - 0x34]
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
setne byte [ebp - 0x25]
mov dword [ebp - 4], 0xfffffffe
call fcn.00409d59
mov al, byte [ebp - 0x25]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x409d83
Capabilities:
Create service
Delete service
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x230
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x20c]
push esi
push edi
push 0x104
push eax
xor esi, esi
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0xf003f
push esi
push esi
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
push esi
push esi
push esi
push esi
push esi
mov edi, eax
lea eax, [ebp - 0x20c]
push eax
push 1
push 3
push pe_nt_image_headers32
push 0xf01ff
mov eax, 0x58bccc
push eax
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov esi, eax
test esi, esi
jne 0x409e01
push 0xf01ff
push 0x58bccc
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
and dword [ebp - 0x22c], 0
lea eax, [ebp - 0x230]
push eax
push 1
push esi
mov dword [ebp - 0x230], ebx
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test ebx, ebx
je 0x409e55
lea eax, [ebp - 0x228]
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
cmp dword [ebp - 0x224], 1
je 0x409e55
push 0xc8
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x409e31
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
mov ecx, dword [ebp - 4]
test ebx, ebx
pop edi
setne al
xor ecx, ebp
pop esi
pop ebx
call fcn.0054d24a
leave
ret
Function at 0x40a662
Capabilities:
Query environment variable
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x424
mov eax, dword [0x5e5620]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 0xc]
lea eax, [ebp - 0x20c]
push edi
mov edi, dword [ebp + 8]
mov ebx, 0x208
push ebx
push 0
push eax
call fcn.0054ee80
add esp, 0xc
mov dword [ebp - 0x418], ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp - 0x418]
xor ecx, ecx
mov dword [ebp - 0x420], ecx
push eax
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x424], ecx
push eax
push ecx
push ecx
push str.Wallpaper
push edi
mov dword [ebp - 0x41c], ecx
call ebx
lea eax, [ebp - 0x418]
mov dword [ebp - 0x418], 4
push eax
lea eax, [ebp - 0x420]
push eax
push 0
push 0
push str.WallpaperPos
push edi
call ebx
lea eax, [ebp - 0x418]
mov dword [ebp - 0x418], 4
push eax
lea eax, [ebp - 0x424]
push eax
push 0
push 0
push 0x58b82c
push edi
call ebx
push 0x104
lea eax, [ebp - 0x414]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
push dword [ebp + 0x10]
lea eax, [ebp - 0x414]
push eax
push edi
call fcn.0041435f
add esp, 0xc
test al, al
je 0x40a7c9
lea eax, [ebp - 0x418]
mov dword [ebp - 0x418], 4
push eax
lea eax, [ebp - 0x41c]
push eax
push 0
push 0
push str.WallpaperUser
push edi
call ebx
cmp dword [ebp - 0x41c], 0
je 0x40a7c7
lea eax, [ebp - 0x20c]
push eax
call fcn.00552a19
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
xor ebx, ebx
pop ecx
lea eax, [eax*2 + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push ebx
push str.Wallpaper
push edi
call esi
push 4
lea eax, [ebp - 0x420]
push eax
push 4
push ebx
push str.WallpaperPos
push edi
call esi
push 4
lea ecx, [ebp - 0x424]
push ecx
push 4
push ebx
push 0x58b82c
push edi
call esi
mov al, 1
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0054d24a
leave
ret