joyce8/EMBER2024-capa huggingface dataset:
Function at 0x8442fc
Capabilities:
Execute anti-debugging instructions

Disassembly:
cld
mov dh, byte [esp + 0x14]
pop word [esp + 0x26]
xchg byte [esp + 0x1a], ah
cmc
jmp 0x844052
pop word [esp + 0x21]
setl ah
sub esp, 7
not ah
rdtsc
neg ax
jmp 0x843ff3
mov dh, 7
rcl al, cl
btc ebp, ecx
mov byte [esp + 0xa], cl
setle dl
std
jmp 0x844009
mov dh, byte [esp + 0x16]
mov dh, ah
mov word [esp + 0x1c], bx
inc edx
add esp, 1
jmp 0x84409d
lea esp, [esp + 0xf]
rdtsc
pop edx
lea ebp, [esi*4]
bsf bp, di
xchg byte [esp + 0x13], dl
jmp 0x84403c
std
push word [esp + 0x26]
clc
mov dx, 0x9bcf
xchg bp, dx
mov ah, 0xce
jmp 0x84402b
lea edx, [edx + ebx]
setp al
push word [esp + 0x2f]
bswap ebp
jmp 0x844284
xchg dword [esp + 0x18], ebp
mov bp, word [esp + 0x15]
pushal
mov byte [esp + 0x11], ch
pop bp
mov eax, 0xd06a7189
jmp 0x844087
mov eax, dword [esp + 0x11]
bsr edx, edx
add esp, 0x11
bsr edx, ebx
mov ax, dx
rdtsc
call fcn.0084410b
dec dl
mov ax, word [esp]
stc
neg bp
call fcn.008442da
mov cl, 0x24
mov edx, 0xd1852cdd
mov dx, ax
mov eax, dword [esp]
pop bp
neg bp
setns dl
sete dl
jmp 0x84429b
push eax
lea edx, [edx + esi]
push si
jmp 0x844075

Function at 0x844586
Capabilities:
Execute anti-debugging instructions

Disassembly:
rdtsc
cmc
xchg word [esp + 2], ax
bswap eax
jmp 0x844570

Function at 0x84467d
Capabilities:
Execute anti-debugging instructions

Disassembly:
push dword [esp]
jmp 0x8446c1
btc edx, ecx
bsf eax, ebx
neg bp
mov word [esp], di
std
mov word [esp], ax
jmp 0x8446ab

Function at 0x844e75
Capabilities:
Access peb ldr_data
Parse pe header

Disassembly:
mov byte [esp + 0xa], ah
mov dword [esp + 0xc], edi
jmp 0x844eb2
lea esp, [esp + 0xc]

Function at 0x8516ef
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.0085176e
jae 0x8516fb
xor ecx, ecx
call fcn.0085176e
jae 0x851725
xor eax, eax
call fcn.0085176e
jae 0x851736
mov al, 0x10
call fcn.0085176e
adc al, al
jae 0x851717
jne 0x851763
stosb byte es:[edi], al
jmp 0x8516fc
call fcn.0085177a
dec ecx
loop 0x851742
mov eax, ebp
call fcn.00851778
jmp 0x851764
lodsb al, byte [esi]
shr eax, 1
je 0x85178a
adc ecx, 2
mov ebp, eax
jmp 0x851764
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.00851778
cmp eax, 0x7d00
jae 0x851762
cmp eax, 0x500
jae 0x851763
cmp eax, 0x7f
ja 0x851764
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x8516fc
pop ebp
ret 8

Function at 0x401a80
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x409008], 0x8088405
inc edx
mov dword [ebx + 0x409008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x406480
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
mov esi, eax
mov eax, dword [0x409214]
mov dword [eax], ecx
mov ebx, edx
test ebx, ebx
jle 0x4064a1
mov eax, 0xff
call fcn.00401a80
xor byte [esi], al
inc esi
dec ebx
jne 0x406491
pop esi
pop ebx
ret
Function at 0x407180
Capabilities:
Enumerate pe sections

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
xor edx, edx
push ebx
push esi
push edi
mov ecx, dword [eax + 0x3c]
add ecx, eax
movzx eax, word [ecx + 0x14]
movzx ebx, word [ecx + 6]
add eax, 0x18
add eax, ecx
test ebx, ebx
je 0x4071be
mov edi, dword [ebp + 0xc]
mov esi, dword [eax + 0xc]
cmp edi, esi
jb 0x4071b6
mov ecx, dword [eax + 8]
add ecx, esi
cmp edi, ecx
jb 0x4071c0
inc edx
add eax, 0x28
cmp edx, ebx
jb 0x4071a6
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x4072a0
Capabilities:
Parse pe header

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
je 0x4072b6
xor eax, eax
pop ebp
ret
mov ecx, dword [eax + 0x3c]
add ecx, eax
xor eax, eax
cmp dword [ecx], 0x4550
jne 0x4072d1
mov edx, 0x10b
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret

Function at 0x4340e0
Capabilities:
Inspect load icon resource

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov dword [ebp - 4], 0
jmp 0x4340f8
mov eax, dword [ebp - 4]
add eax, 1
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
cmp ecx, dword [ebp + 8]
jae 0x4341d6
mov edx, dword [ebp - 4]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.00434a50
add esp, 8
sar eax, 0xc
cmp eax, 3
jne 0x4341d1
mov dword [ebp - 0x10], 0xfff
mov dword [ebp - 0xc], 0x9922c
mov ecx, dword [ebp - 4]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.00434a50
add esp, 8
and eax, dword [ebp - 0x10]
add eax, 0x8702
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
mov dword [ebp - 0xc], 0x9922c
cmp dword [ebp - 4], 0
jne 0x4341aa
push 0x154b
push 0
call dword [sym.imp.USER32.dll_LoadIconW]
test eax, eax
je 0x4341aa
xor eax, eax
jmp 0x4341d6
mov eax, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x10]
add ecx, dword [eax]
mov edx, dword [ebp - 8]
mov eax, dword [ecx + edx - 0x8702]
add eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x18]
mov edx, dword [ebp + 0x10]
add edx, dword [ecx]
mov ecx, dword [ebp - 8]
mov dword [edx + ecx - 0x8702], eax
jmp 0x4340ef
mov esp, ebp
pop ebp
ret

Function at 0x434a50
Capabilities:
Inspect load icon resource

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov dword [ebp - 8], 0x240be8
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], 0x240be8
push 0x15b9
push 0
call dword [sym.imp.USER32.dll_LoadIconW]
test eax, eax
je 0x434a85
xor eax, eax
jmp 0x434a8f
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
movzx eax, word [eax + edx*2]
mov esp, ebp
pop ebp
ret
Function at 0x403560
Capabilities:
Delete file
Enumerate gui resources

Disassembly:
mov eax, dword [0x49d4dc]
mov ecx, dword [0x49a3e4]
sub esp, 0xc2c
push ebx
push ebp
shr eax, 3
push esi
push edi
test eax, eax
jbe 0x40364f
mov edi, dword [sym.imp.KERNEL32.dll_SetConsoleMode]
mov ebx, dword [sym.imp.KERNEL32.dll_WriteProfileSectionW]
mov ebp, dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov esi, dword [sym.imp.KERNEL32.dll_GetCommState]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], eax
cmp dword [0x49d4dc], 0x959
jne 0x403635
push 0
push 0
call edi
push 0
push 0
call ebx
push 0
call ebp
push 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_EnumCalendarInfoExA]
lea eax, [esp + 0x1c]
push eax
push 0
call esi
push 0
push 0
lea ecx, [esp + 0x40]
push ecx
call dword [sym.imp.KERNEL32.dll_AddConsoleAliasA]
push 0
push 0
call dword [sym.imp.KERNEL32.dll_SetStdHandle]
push 0
lea edx, [esp + 0x43c]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_EnumResourceTypesW]
push 0
push 0
call esi
push 0
push 0x402ca0
call dword [sym.imp.KERNEL32.dll_BeginUpdateResourceW]
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_OpenEventW]
mov eax, dword [esp + 0x14]
push eax
call fcn.004033b0
add dword [esp + 0x14], 8
sub dword [esp + 0x18], 1
jne 0x4035a0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc2c
ret
Function at 0x4071fc
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x430238]
jne 0x407206
repz ret
jmp fcn.0040c505

Function at 0x40cfff
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0040a718
and dword [ebp - 4], 0
cmp dword [0x433278], 0
mov ebx, eax
jne 0x40d0b0
push 0x4024a4
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x40d161
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x402498
push edi
call esi
test eax, eax
je 0x40d161
push eax
call fcn.0040a6a6
mov dword [esp], 0x402488
push edi
mov dword [0x433278], eax
call esi
push eax
call fcn.0040a6a6
mov dword [esp], 0x402474
push edi
mov dword [0x43327c], eax
call esi
push eax
call fcn.0040a6a6
mov dword [esp], 0x402458
push edi
mov dword [0x433280], eax
call esi
push eax
call fcn.0040a6a6
pop ecx
mov dword [0x433288], eax
test eax, eax
je 0x40d0b0
push 0x402440
push edi
call esi
push eax
call fcn.0040a6a6
pop ecx
mov dword [0x433284], eax
mov eax, dword [0x433284]
cmp eax, ebx
je 0x40d108
cmp dword [0x433288], ebx
je 0x40d108
push eax
call fcn.0040a721
push dword [0x433288]
mov esi, eax
call fcn.0040a721
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x40d108
test edi, edi
je 0x40d108
call esi
test eax, eax
je 0x40d0ff
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x40d0ff
test byte [ebp - 0xc], 1
jne 0x40d108
or dword [ebp + 0x10], 0x200000
jmp 0x40d141
mov eax, dword [0x43327c]
cmp eax, ebx
je 0x40d141
push eax
call fcn.0040a721
pop ecx
test eax, eax
je 0x40d141
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x40d141
mov eax, dword [0x433280]
cmp eax, ebx
je 0x40d141
push eax
call fcn.0040a721
pop ecx
test eax, eax
je 0x40d141
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x433278]
call fcn.0040a721
pop ecx
test eax, eax
je 0x40d161
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x40d163
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4038b0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
movzx eax, ax
mov dword [ebp + 8], eax
pop ebp
jmp fcn.00419d0d

Function at 0x403bb0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x403bc5
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x403c04
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
lea edx, [esi + eax]
and ecx, 0xf
jbe 0x403c00
lea ebx, [ebx]
cmp esi, edx
jae 0x403c04
movzx eax, word [esi]
lea esi, [esi + eax*2]
add esi, 2
dec ecx
jne 0x403bf0
cmp esi, edx
jb 0x403c09
xor eax, eax
pop esi
pop ebp
ret
xor eax, eax
cmp word [esi], ax
cmove esi, eax
mov eax, esi
pop esi
pop ebp
ret
Function at 0x405b90
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54eb00
mov eax, dword fs:[0]
push eax
sub esp, 0x14
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea eax, [ebp + 8]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x14], 0
push str._c_takeown__f
push eax
call fcn.00406dc0
push str.__icacls
push eax
lea eax, [ebp - 0x1c]
mov byte [ebp - 4], 1
push eax
call fcn.00404600
lea ecx, [ebp + 8]
mov byte [ebp - 4], 2
push ecx
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.00404400
push str.__grant_administrators:F
push eax
lea eax, [ebp - 0x14]
mov byte [ebp - 4], 3
push eax
call fcn.00404600
mov byte [ebp - 4], 2
or esi, 0xffffffff
mov edx, dword [ebp - 0x18]
add esp, 0x30
add edx, 0xfffffff0
mov eax, esi
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x405c37
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 1
mov ecx, esi
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405c57
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
mov ecx, esi
mov edx, dword [ebp - 0x20]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405c77
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 0
push 0
push dword [ebp - 0x14]
push 0x594020
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov edx, dword [ebp - 0x14]
mov ecx, esi
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405cac
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp + 8]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], esi
dec esi
test esi, esi
jg 0x405ccd
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret 4
Function at 0x406ea0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54ec58
mov eax, dword fs:[0]
push eax
sub esp, 0x234
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, dword [ebp + 8]
mov ecx, ebx
mov dword [ebp - 4], 0
mov dword [ebp - 0x23c], 0
push 0x593ed8
mov dword [ebp - 0x230], ebx
mov dword [ebp - 0x240], ebx
mov dword [ebx], 0
call fcn.00403af0
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x224]
push 0x593ed8
mov dword [ebp - 0x23c], 1
mov dword [ebp - 0x224], 0
call fcn.00403af0
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x220]
push 0x593ed8
mov dword [ebp - 0x220], 0
call fcn.00403af0
lea eax, [ebp - 0x22c]
mov byte [ebp - 4], 2
push eax
mov dword [ebp - 0x238], 0x10
mov dword [ebp - 0x234], 0xb
call dword [sym.imp.SHELL32.dll_SHGetMalloc]
test eax, eax
js 0x40702a
mov edi, dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
xor esi, esi
lea eax, [ebp - 0x228]
push eax
push dword [ebp + esi*4 - 0x238]
push 0
call edi
test eax, eax
js 0x407014
lea eax, [ebp - 0x21c]
push eax
push dword [ebp - 0x228]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
test eax, eax
je 0x407002
lea ecx, [ebp - 0x21c]
lea edx, [ecx + 2]
test esi, esi
jne 0x406fe0
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406fc0
sub ecx, edx
sar ecx, 1
push ecx
lea ecx, [ebp - 0x224]
jmp 0x406ff6
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406fe0
sub ecx, edx
sar ecx, 1
push ecx
lea ecx, [ebp - 0x220]
lea eax, [ebp - 0x21c]
push eax
call fcn.004039f0
mov eax, dword [ebp - 0x22c]
push dword [ebp - 0x228]
push eax
mov ecx, dword [eax]
call dword [ecx + 0x14]
inc esi
cmp esi, 2
jl 0x406f81
mov eax, dword [ebp - 0x22c]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov eax, dword [ebp - 0x220]
or edi, 0xffffffff
mov esi, dword [ebx]
sub esi, 0x10
lea edx, [eax - 0x10]
cmp edx, esi
je 0x40709a
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x407083
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x407083
push edx
call fcn.004038d0
mov dword [ebp - 0x234], eax
add esp, 4
mov eax, edi
lock xadd dword [ebx], eax
dec eax
test eax, eax
jg 0x407070
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov ebx, dword [ebp - 0x230]
mov eax, dword [ebp - 0x234]
add eax, 0x10
mov dword [ebx], eax
jmp 0x407094
push dword [eax - 0xc]
mov ebx, dword [ebp - 0x230]
mov ecx, ebx
push eax
call fcn.004039f0
mov eax, dword [ebp - 0x220]
lea edx, [eax - 0x10]
mov byte [ebp - 4], 1
lea eax, [edx + 0xc]
mov ecx, edi
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x4070b7
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 4], 0
mov esi, dword [ebp - 0x224]
add esi, 0xfffffff0
lea eax, [esi + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x4070d8
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret 8
Function at 0x407100
Capabilities:
Print debug messages
Query service status
Start service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 0x34
mov edi, ecx
push str.PcaSvc
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
test esi, esi
jne 0x407141
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
test eax, eax
je 0x4071b9
cmp dword [ebp - 0x1c], 1
jne 0x40718f
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceW]
test eax, eax
je 0x4071b9
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
cmp eax, 1
jne 0x40718f
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [ebp - 0x1c], 4
je 0x4071ae
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
cmp eax, 1
je 0x407174
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
pop ebx
pop edi
mov al, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret
push str.start_success
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
mov ecx, dword [ebp - 4]
xor al, al
pop ebx
pop edi
xor ecx, ebp
pop esi
call fcn.00532f97
mov esp, ebp
pop ebp
ret

Function at 0x4071e0
Capabilities:
Print debug messages
Query service status
Stop service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
push 0x34
mov edi, ecx
push str.PcaSvc
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov esi, eax
test esi, esi
jne 0x407221
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
test eax, eax
je 0x40728f
cmp dword [ebp - 0x1c], 4
jne 0x407271
lea eax, [ebp - 0x20]
push eax
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x40728f
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
cmp eax, 1
jne 0x407271
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [ebp - 0x1c], 1
je 0x407284
lea eax, [ebp - 0x20]
push eax
push esi
call ebx
cmp eax, 1
je 0x407256
pop ebx
pop edi
mov al, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret
push str.stop_success
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
mov ecx, dword [ebp - 4]
xor al, al
pop ebx
pop edi
xor ecx, ebp
pop esi
call fcn.00532f97
mov esp, ebp
pop ebp
ret
Function at 0x409c00
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff0
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54eefc
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x248
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x104
lea eax, [ebp - 0x220]
push 0
push eax
call fcn.00535230
add esp, 0xc
lea eax, [ebp - 0x220]
push 0
push 0x25
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea eax, [ebp - 0x220]
mov dword [ebp - 0x224], 0
push eax
lea ecx, [ebp - 0x224]
call fcn.00403af0
push 0x10
push str._spoolPRINTERS_
lea ecx, [ebp - 0x224]
mov dword [ebp - 4], 0
call fcn.004046e0
xorps xmm0, xmm0
lea ecx, [ebp - 0x250]
movdqa xmmword [ebp - 0x250], xmm0
movdqa xmmword [ebp - 0x240], xmm0
call fcn.00404910
push 0
push ecx
mov byte [ebp - 4], 1
mov ecx, esp
mov dword [ebp - 0x258], esp
push str..SHD
call fcn.00403af0
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x224]
push 1
push ecx
add eax, 0xfffffff0
mov esi, esp
push eax
call fcn.004038d0
add esp, 4
lea ecx, [ebp - 0x250]
add eax, 0x10
mov dword [esi], eax
mov byte [ebp - 4], 1
call fcn.00404ad0
push 0
push ecx
mov ecx, esp
mov dword [ebp - 0x254], esp
push str..SPL
call fcn.00403af0
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x224]
push 1
push ecx
add eax, 0xfffffff0
mov esi, esp
push eax
call fcn.004038d0
add esp, 4
lea ecx, [ebp - 0x250]
add eax, 0x10
mov dword [esi], eax
mov byte [ebp - 4], 1
call fcn.00404ad0
lea ecx, [ebp - 0x250]
mov byte [ebp - 4], 0
mov esi, eax
call fcn.00404a00
mov dword [ebp - 4], 0xffffffff
mov edi, dword [ebp - 0x224]
add edi, 0xfffffff0
lea ecx, [edi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409d87
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
Function at 0x409f70
Capabilities:
Query service status
Stop service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54ef68
mov eax, dword fs:[0]
push eax
sub esp, 0x28
mov eax, dword [0x5b41b0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0xf003f
push 0
push 0
mov dword [ebp - 4], 0
mov edi, 1
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, eax
test esi, esi
jne 0x409fd7
push ecx
mov ecx, esp
push str.OpenSCManager
call fcn.00403af0
mov ecx, edi
call fcn.00403e20
add esp, 4
xor edi, edi
jmp 0x40a050
push 0xf01ff
push dword [ebp + 8]
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov ebx, eax
test ebx, ebx
jne 0x40a007
push ecx
mov ecx, esp
push str.OpenService
call fcn.00403af0
mov ecx, edi
call fcn.00403e20
add esp, 4
xor edi, edi
jmp 0x40a050
lea eax, [ebp - 0x2c]
push eax
push ebx
call dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
cmp dword [ebp - 0x28], edi
je 0x40a044
lea eax, [ebp - 0x2c]
push eax
push 1
push ebx
call dword [sym.imp.ADVAPI32.dll_ControlService]
mov edi, eax
test edi, edi
jne 0x40a044
push ecx
mov ecx, esp
push 0x5946c4
call fcn.00403af0
lea ecx, [edi + 1]
call fcn.00403e20
add esp, 4
jmp 0x40a050
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push ebx
call esi
mov dword [ebp - 4], 0xffffffff
or ecx, 0xffffffff
mov esi, dword [ebp + 8]
add esi, 0xfffffff0
lea eax, [esi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x40a074
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00532f97
mov esp, ebp
pop ebp
ret