joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4305b0
Capabilities:
Open clipboard
Read clipboard data

Disassembly:
sub esp, 0xc
push ebx
push ebp
push esi
push edi
mov edi, ecx
call fcn.0042ad60
test eax, eax
je 0x43069f
mov ecx, edi
call fcn.0042ad60
mov ecx, eax
call fcn.004282e0
test eax, eax
jne 0x43069f
push eax
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x43069f
mov eax, dword [0xabd700]
and eax, 0xffff
push eax
call dword [sym.imp.USER32.dll_GetClipboardData]
mov esi, eax
test esi, esi
jne 0x430612
call dword [sym.imp.USER32.dll_CloseClipboard]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret 0xc
lea ecx, [esp + 0x10]
mov ebp, dword [esp + 0x24]
push 1
push ecx
mov ecx, dword [edi + 0x44]
lea edx, [esp + 0x1c]
shr ecx, 4
lea eax, [esp + 0x20]
push edx
mov edx, dword [esp + 0x2c]
and ecx, 1
push eax
push ecx
push ebp
push edx
push esi
call dword [sym.imp.KERNEL32.dll_GlobalSize]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push eax
mov ecx, edi
call fcn.0042ad60
mov ecx, eax
call fcn.00428510
push esi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
call dword [sym.imp.USER32.dll_CloseClipboard]
mov ecx, dword [esp + 0x28]
mov eax, 1
cmp ecx, eax
jne 0x43069f
cmp ebx, eax
jne 0x43069f
cmp dword [esp + 0x10], eax
jne 0x430685
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0xcc]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov edx, dword [edi]
push eax
mov eax, dword [esp + 0x24]
push ecx
push ebp
push eax
mov ecx, edi
call dword [edx + 0xc0]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret 0xc
Function at 0x4332e0
Capabilities:
Access peb ldr_data

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x480228
push eax
mov dword fs:[0], esp
sub esp, 0x14
push ebx
push ebp
mov ebp, dword [esp + 0x30]
push esi
mov ebx, ecx
push edi
mov esi, dword [ebp]
mov ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x10]
dec ecx
cmp eax, ecx
jge 0x433319
inc eax
mov dword [esi + 0x10], eax
jmp 0x43342c
mov eax, dword [ebx + 0x3c]
mov ecx, dword [esi + 8]
cmp ecx, eax
jne 0x43332d
mov eax, 0xffffffc7
jmp 0x43342e
mov esi, dword [esi]
mov edx, dword [esi + 0x10]
mov ecx, dword [esi + 0xc]
cmp edx, ecx
jl 0x43333e
cmp dword [esi + 8], eax
jne 0x43332d
cmp dword [esi + 8], eax
jne 0x433357
mov eax, dword [esi + 0x10]
mov ecx, dword [esi + 0xc]
cmp eax, ecx
jl 0x433357
mov eax, 0xffffffc7
jmp 0x43342e
mov eax, dword [esi + 4]
xor edi, edi
cmp eax, edi
je 0x43336b
push eax
mov ecx, ebx
call fcn.00432b10
mov dword [esi + 4], edi
mov dword [ebp], esi
mov ecx, dword [esi + 0x10]
inc ecx
mov dword [esi + 0x10], ecx
lea ecx, [esp + 0x10]
call fcn.00402f20
mov dword [esp + 0x2c], edi
mov edi, dword [esp + 0x3c]
test edi, edi
jne 0x43339c
mov ecx, dword [ebx + 4]
mov edx, dword [ecx + 8]
lea ecx, [esp + 0x10]
push edx
call fcn.00402f40
mov edi, eax
mov eax, dword [esi + 8]
push edi
push eax
mov ecx, ebx
call fcn.00432280
test eax, eax
mov dword [esp + 0x38], eax
je 0x4333cf
lea ecx, [esp + 0x10]
mov dword [esp + 0x2c], 0xffffffff
mov dword [esp + 0x10], 0xa8c238
call fcn.00403120
mov eax, dword [esp + 0x38]
jmp 0x43342e
mov ecx, dword [esi + 0x10]
push ecx
push edi
mov ecx, ebx
call fcn.00433140
mov dl, byte [edi]
and dl, 1
cmp dl, 1
jne 0x433413
mov ecx, dword [esp + 0x34]
push ebp
push ecx
push edi
push eax
mov ecx, ebx
call fcn.00433160
mov esi, eax
test esi, esi
jne 0x433443
mov edx, dword [ebp]
push eax
push edi
mov ecx, ebx
mov dword [edx + 0x10], eax
call fcn.00433140
mov cl, byte [edi]
and cl, 1
cmp cl, 1
je 0x4333e5
lea ecx, [esp + 0x10]
mov dword [esp + 0x2c], 0xffffffff
mov dword [esp + 0x10], 0xa8c238
call fcn.00403120
xor eax, eax
mov ecx, dword [esp + 0x24]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x20
ret 0xc
lea ecx, [esp + 0x10]
mov dword [esp + 0x2c], 0xffffffff
mov dword [esp + 0x10], 0xa8c238
call fcn.00403120
mov eax, esi
jmp 0x43342e

Function at 0x436560
Capabilities:
Create thread

Disassembly:
push ecx
cmp dword [ecx + 0xcc], 1
je 0x4365c0
mov eax, dword [ecx + 0x1c]
test eax, eax
je 0x4365c0
mov eax, dword [ecx + 0xb0]
test eax, eax
je 0x4365c0
push esi
mov edx, 5
mov esi, dword [ecx + 0xbc]
cmp esi, edx
pop esi
je 0x4365c0
mov dword [ecx + 0xb4], eax
mov dword [ecx + 0x94], 0
mov dword [ecx + 0xbc], edx
lea eax, [esp]
push eax
push 0
push ecx
push 0x436600
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ecx
ret
Function at 0x43bc40
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x480858
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push esi
mov esi, ecx
lea eax, [esp + 0xc]
mov ecx, dword [esi + 0x1c]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
push 0
lea ecx, [esp + 0x20]
call fcn.004795c1
mov eax, dword [esi + 0xd0]
lea edx, [esp + 0x1c]
push eax
push eax
push edx
mov dword [esp + 0x44], 0
call fcn.0043b5e0
mov eax, dword [esi + 0x4c]
mov ecx, dword [esi + 0x48]
add eax, 0x64
add esp, 0xc
add ecx, 0x64
mov dword [esp + 8], eax
lea eax, [esp + 4]
mov dword [esp + 4], ecx
push eax
lea ecx, [esp + 0x20]
call fcn.004794ef
mov ecx, dword [esp + 4]
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0xc]
sub ecx, eax
add ecx, edx
mov eax, 0x88888889
imul ecx
add edx, ecx
push 1
sar edx, 4
mov ecx, edx
shr ecx, 0x1f
lea eax, [edx + ecx + 1]
xor edx, edx
test eax, eax
setl dl
dec edx
mov ecx, esi
and eax, edx
push eax
push 0
push 0
call fcn.00475db3
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 8]
sub ecx, eax
add ecx, edx
mov eax, 0x88888889
imul ecx
add edx, ecx
xor ecx, ecx
sar edx, 4
mov eax, edx
push 1
shr eax, 0x1f
lea eax, [edx + eax + 1]
test eax, eax
setl cl
dec ecx
and eax, ecx
mov ecx, esi
push eax
push 0
push 1
call fcn.00475db3
push 1
push 0
push 0
mov ecx, esi
call fcn.00475d5b
push 1
push 0
push 1
mov ecx, esi
call fcn.00475d5b
lea ecx, [esp + 0x1c]
mov dword [esp + 0x38], 0xffffffff
call fcn.00479633
mov ecx, dword [esp + 0x30]
pop esi
mov dword fs:[0], ecx
add esp, 0x38
ret

Function at 0x43bdc0
Capabilities:
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x480878
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2c
push esi
mov esi, ecx
push 0
lea ecx, [esp + 0x20]
call fcn.004795c1
push 0x3e8
lea eax, [esp + 0x20]
push 0x3e8
push eax
mov dword [esp + 0x44], 0
call fcn.0043b5e0
mov ecx, dword [esi + 0x48]
mov eax, dword [esi + 0x4c]
add ecx, 0x64
add esp, 0xc
mov dword [esp + 4], ecx
lea ecx, [esp + 4]
add eax, 0x96
push ecx
lea ecx, [esp + 0x20]
mov dword [esp + 0xc], eax
call fcn.004794ef
mov eax, dword [esi + 0x1c]
lea edx, [esp + 0xc]
push edx
push eax
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
sub eax, edx
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cdq
idiv dword [esp + 8]
mov edx, dword [esp + 0xc]
mov ecx, eax
mov eax, dword [esp + 0x14]
sub eax, edx
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cdq
idiv dword [esp + 4]
cmp dword [esp + 0x44], 1
jne 0x43be84
cmp dword [esp + 0x40], 1
jne 0x43be82
cmp ecx, eax
jge 0x43be84
mov eax, ecx
cmp eax, 0xc8
jge 0x43be90
mov eax, 0xc8
mov ecx, esi
mov dword [esi + 0xd0], eax
call fcn.0043bc40
mov ecx, dword [esi + 0x1c]
push 1
push 0
push ecx
call dword [sym.imp.USER32.dll_InvalidateRect]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x38], 0xffffffff
call fcn.00479633
mov ecx, dword [esp + 0x30]
pop esi
mov dword fs:[0], ecx
add esp, 0x38
ret 8
Function at 0x43c600
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push 0xffffffffffffffff
push 0x4808e3
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0xc], esi
call fcn.004741d4
lea edi, [esi + 0x64]
mov dword [esp + 0x18], 0
mov dword [edi + 4], 0
mov dword [edi], vtable.CBrush.0
mov eax, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
mov ecx, dword [esp + 0x30]
mov dword [esi + 0x3c], eax
mov eax, ebp
mov dword [esi], method.CEdit.virtual_0
mov dword [esi + 0x40], ecx
mov dword [esi + 0x44], 0
mov ecx, dword [eax]
lea edx, [esi + 0x48]
mov byte [esp + 0x18], 1
mov dword [edx], ecx
mov ecx, dword [eax + 4]
mov dword [edx + 4], ecx
mov ecx, dword [eax + 8]
mov dword [edx + 8], ecx
mov eax, dword [eax + 0xc]
mov ecx, dword [esp + 0x40]
mov dword [edx + 0xc], eax
mov eax, dword [esp + 0x44]
push eax
mov dword [esi + 0x5c], ecx
mov dword [esi + 0x60], eax
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
mov ecx, edi
call fcn.00479869
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x20]
push edx
push eax
push ebp
push 0x50800044
mov ecx, esi
call fcn.0047ad85
test eax, eax
je 0x43c71c
mov ecx, dword [esp + 0x3c]
call fcn.00479896
mov ecx, dword [esi + 0x1c]
mov ebp, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push eax
push 0x30
push ecx
mov dword [esi + 0x58], eax
call ebp
mov edi, dword [esp + 0x34]
test edi, edi
je 0x43c6e0
push edi
mov ecx, esi
call fcn.00476f03
mov ecx, esi
call fcn.0043c880
cmp dword [esp + 0x38], 1
jne 0x43c715
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esi + 0x1c]
push 0xffffffffffffffff
not ecx
dec ecx
push ecx
push 0xb1
push edx
call ebp
mov eax, dword [esi + 0x1c]
push 0
push 0
push 0xb7
push eax
call ebp
mov ecx, esi
call fcn.0047703e
mov ecx, dword [esp + 0x10]
mov eax, esi
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x10
ret 0x28
Function at 0x43f130
Capabilities:
Check for software breakpoints

Disassembly:
push esi
mov esi, dword [esp + 8]
cmp dword [esi + 0x10], 0xca
jne 0x43f163
push esi
call fcn.00442240
mov eax, dword [esi + 0x40]
add esp, 4
test eax, eax
je 0x43f15c
mov dword [esi + 0x10], 0xcf
mov eax, 1
pop esi
ret
mov dword [esi + 0x10], 0xcb
mov eax, dword [esi + 0x10]
cmp eax, 0xcb
jne 0x43f1e9
mov eax, dword [esi + 0x1b0]
mov ecx, dword [eax + 0x10]
test ecx, ecx
je 0x43f1d2
mov eax, dword [esi + 8]
test eax, eax
je 0x43f187
push esi
call dword [eax]
add esp, 4
mov ecx, dword [esi + 0x1b0]
push esi
call dword [ecx]
add esp, 4
test eax, eax
je 0x43f1ce
cmp eax, 2
je 0x43f1d2
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x43f17a
cmp eax, 3
je 0x43f1ad
cmp eax, 1
jne 0x43f17a
mov eax, dword [ecx + 4]
inc eax
mov dword [ecx + 4], eax
mov eax, dword [esi + 8]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 4]
cmp edx, ecx
jl 0x43f17a
mov edx, dword [esi + 0x13c]
add edx, ecx
mov dword [eax + 8], edx
jmp 0x43f17a
xor eax, eax
pop esi
ret
mov eax, dword [esi + 0x90]
push esi
mov dword [esi + 0x98], eax
call fcn.0043f210
add esp, 4
pop esi
ret
cmp eax, 0xcc
je 0x43f1f8
mov ecx, dword [esi]
push esi
call dword [ecx]
add esp, 4
push esi
call fcn.0043f210
add esp, 4
pop esi
ret

Function at 0x44d2c0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ecx
mov eax, dword [0xabd8f0]
xor edx, edx
cmp eax, edx
jne 0x44d2e6
xor eax, eax
mov byte [eax + 0xabd7f0], al
inc eax
cmp eax, 0x100
jl 0x44d2ce
mov dword [0xabd8f0], 1
mov eax, dword [esp + 0xc]
push ebx
mov ebx, dword [esp + 0x14]
push esi
push edi
mov ecx, 0x40
mov esi, 0xabd7f0
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
cmp eax, edx
mov byte [ebx + 0x100], dl
mov byte [ebx + 0x101], dl
jle 0x44d377
xor esi, esi
push ebp
mov byte [esp + 0x20], dl
xor ecx, ecx
mov edi, dword [esp + 0x20]
mov ebp, dword [esp + 0x18]
mov al, byte [esi + ebx]
and edi, 0xff
xor edx, edx
mov dl, byte [edi + ebp]
mov ebp, eax
and ebp, 0xff
add ecx, edx
add ecx, ebp
and ecx, 0x800000ff
jns 0x44d34a
dec ecx
or ecx, 0xffffff00
inc ecx
mov byte [esp + 0x10], cl
mov ecx, dword [esp + 0x10]
and ecx, 0xff
mov dl, byte [ecx + ebx]
mov byte [esi + ebx], dl
mov byte [ecx + ebx], al
lea eax, [edi + 1]
cdq
idiv dword [esp + 0x1c]
inc esi
cmp esi, 0x100
mov byte [esp + 0x20], dl
jl 0x44d318
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret
Function at 0x44d3f0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [ebp + 0x10]
push ebx
push esi
push edi
mov cl, byte [eax + 0x100]
mov dl, byte [eax + 0x101]
mov dword [ebp - 8], eax
mov byte [ebp - 1], cl
mov byte [ebp - 2], dl
xor ebx, ebx
mov bl, byte [ebp - 1]
xor edx, edx
mov dl, byte [ebp - 2]
mov esi, dword [ebp - 8]
mov edi, dword [ebp + 8]
xor eax, eax
mov ecx, dword [ebp + 0xc]
test ecx, ecx
jle 0x44d443
inc bl
mov al, byte [esi + ebx]
add dl, al
xchg byte [esi + edx], al
mov byte [esi + ebx], al
add al, byte [esi + edx]
mov al, byte [esi + eax]
xor byte [edi], al
inc edi
dec ecx
jne 0x44d42a
mov byte [ebp - 1], bl
mov byte [ebp - 2], dl
mov eax, dword [ebp + 0x10]
mov cl, byte [ebp - 1]
mov dl, byte [ebp - 2]
pop edi
pop esi
mov byte [eax + 0x100], cl
mov byte [eax + 0x101], dl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x453dc0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x480d7e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, dword [esp + 0x18]
push esi
push edi
mov edi, ecx
mov ecx, dword [esp + 0x1c]
push eax
push ecx
mov ecx, edi
mov dword [esp + 0x10], edi
call fcn.004546e0
push 0x10
mov dword [esp + 0x18], 0
mov dword [edi], 0xa8fe84
call fcn.00472963
mov esi, eax
add esp, 4
mov dword [esp + 0x20], esi
mov al, 1
test esi, esi
mov byte [esp + 0x14], al
je 0x453e53
push 4
mov byte [esi + 8], al
mov dword [esi], 0
mov dword [esi + 4], 0
call fcn.00472963
add esp, 4
mov dword [esp + 0x1c], eax
test eax, eax
mov byte [esp + 0x14], 2
je 0x453e4c
push 0
mov ecx, eax
call fcn.0044aef0
mov dword [esi + 0xc], eax
jmp 0x453e55
xor eax, eax
mov dword [esi + 0xc], eax
jmp 0x453e55
xor esi, esi
mov ecx, dword [esp + 0xc]
mov dword [edi + 0x30], esi
mov dword [edi + 0x34], 0
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x10
ret 8

Function at 0x474fc9
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x475001
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.0047307d
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.00473055
jmp 0x47500d
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4

Function at 0x4766bb
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x4766fd
call fcn.0047c175
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x4766fd
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x4766f4
xor eax, eax
jmp 0x476705
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0047670b
pop edi
pop esi
pop ebx
ret 4
Function at 0x47c6a5
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x47c6d3
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x47c6f1
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0047c60b
jmp 0x47c6f1
mov eax, dword [esi + 0x14]
test eax, eax
je 0x47c6f1
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.0047c60b
test edi, edi
mov eax, edi
jne 0x47c6db
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x401760
Capabilities:
Write file on windows

Disassembly:
push ecx
push esi
push 0x406f60
lea eax, [esp + 8]
push 0x407c10
push eax
call sub.MFC42.DLL_operator
mov eax, dword [eax]
push 0x406f5c
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
lea ecx, [esp + 4]
mov esi, eax
call sub.MFC42.DLL_CString::CString
test esi, esi
je 0x4017ce
push esi
push 0x1f20
push 1
push 0x40503c
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
cmp eax, 0x1f20
push esi
jne 0x4017c5
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov eax, 1
pop esi
pop ecx
ret
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
xor eax, eax
pop esi
pop ecx
ret

Function at 0x401f40
Capabilities:
Create service
Print debug messages
Start service

Disassembly:
mov ecx, dword [esp + 8]
sub esp, 0x104
lea eax, [esp]
push ebx
push 0
push eax
push 0x104
push ecx
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
lea edx, [esp + 4]
push edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebx, eax
test ebx, ebx
jne 0x401f9c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.OpenSCManager___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor eax, eax
pop ebx
add esp, 0x104
ret
push ebp
push esi
push edi
push str.OpenSCManager___Success___n
call fcn.004020c0
add esp, 4
mov edi, dword [esp + 0x118]
lea eax, [esp + 0x10]
push 0
push 0
push 0
push 0
push 0
push eax
push 1
push 3
push 1
push 0xf01ff
push edi
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jne 0x402042
call ebp
cmp eax, 0x3e5
je 0x402007
cmp eax, 0x431
je 0x402007
push eax
push str.CreateService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor edi, edi
jmp 0x4020a3
push str.CreateService___Faild__because_Service_is_ERROR_IO_PENDING_or_ERROR_SERVICE_EXISTS___n
call fcn.004020c0
add esp, 4
push 0xf01ff
push edi
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
jne 0x40203b
call ebp
push eax
push str.OpenService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor edi, edi
jmp 0x4020a3
push str.OpenService___Success___n
jmp 0x402047
push str.CreateService___Success___n
call fcn.004020c0
add esp, 4
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
test eax, eax
jne 0x40209e
call ebp
cmp eax, 0x3e5
je 0x402080
cmp eax, 0x420
je 0x402091
push eax
push str.StartService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor edi, edi
jmp 0x4020a3
push str.StartService___Faild_for_ERROR_IO_PENDING___n
call fcn.004020c0
add esp, 4
xor edi, edi
jmp 0x4020a3
push str.StartService___Faild_for_ERROR_SERVICE_ALREADY_RUNNING___n
call fcn.004020c0
add esp, 4
mov edi, 1
mov ebp, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test esi, esi
je 0x4020b0
push esi
call ebp
push ebx
call ebp
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x104
ret
Function at 0x4020c0
Capabilities:
Print debug messages

Disassembly:
push esi
push 0x2800
call sub.MFC42.DLL_operatornew
mov ecx, dword [esp + 0xc]
mov esi, eax
lea eax, [esp + 0x10]
push eax
push ecx
push 0x7fffffff
push esi
call dword [sym.imp.MSVCRT.dll__vsnprintf]
add esp, 0x14
push esi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push esi
call sub.MFC42.DLL_operatordelete
add esp, 4
pop esi
ret

Function at 0x402100
Capabilities:
Delete service
Stop service

Disassembly:
sub esp, 0x1c
push ebp
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebp, eax
test ebp, ebp
jne 0x402134
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.OpenSCManager___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor eax, eax
pop ebp
add esp, 0x1c
ret
push ebx
push esi
push edi
push str.OpenSCManager___Success___n
call fcn.004020c0
mov eax, dword [esp + 0x34]
add esp, 4
push 0xf01ff
push eax
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
jne 0x402173
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.OpenService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
xor ebx, ebx
jmp 0x4021e6
push str.OpenService___Success___n
call fcn.004020c0
add esp, 4
lea ecx, [esp + 0x10]
push ecx
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4021aa
call edi
push eax
push str.ControlService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
jmp 0x4021b7
push str.ControlService___Success___n
call fcn.004020c0
add esp, 4
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
jne 0x4021d4
call edi
push eax
push str.DeleteService___Faild__ErrorCode:_d_n
call fcn.004020c0
add esp, 8
jmp 0x4021e1
push str.DeleteService___Success___n
call fcn.004020c0
add esp, 4
mov ebx, 1
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test esi, esi
je 0x4021f3
push esi
call edi
push ebp
call edi
pop edi
mov eax, ebx
pop esi
pop ebx
pop ebp
add esp, 0x1c
ret
Function at 0x40153b
Capabilities:
Encode data using xor

Disassembly:
push 1
pop ecx
cmp dword [esp + 8], ecx
jl 0x40155b
mov eax, dword [esp + 4]
mov edx, ecx
and edx, 3
mov dl, byte [esp + edx + 0xc]
xor byte [eax], dl
inc ecx
inc eax
cmp ecx, dword [esp + 8]
jle 0x401548
ret

Function at 0x40155c
Capabilities:
Create directory
Get common file path
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x298
push ebx
push esi
push edi
lea eax, [ebp - 0x194]
push 0x104
push eax
push dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x10], ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push ebx
push 0x80
push 3
push ebx
push 1
lea eax, [ebp - 0x194]
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4015b8
mov dword [ebp - 4], str.Cant_open_file_
jmp 0x40191c
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 2
push ebx
push 0xfffffffffffffff8
push edi
call esi
cmp eax, 0x3e8
mov dword [ebp - 0xc], eax
jb 0x4018fe
lea eax, [ebp - 0x1c]
push ebx
push eax
lea eax, [ebp - 0x24]
push 8
push eax
push edi
mov dword [ebp - 0x1c], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401907
cmp dword [ebp - 0x1c], 8
jne 0x401907
mov eax, dword [ebp - 0x24]
cmp dword [ebp - 0x20], 0x829ab7a5
mov dword [ebp + 8], eax
jne 0x4018fe
cmp eax, 4
jl 0x4018fe
mov dword [ebp - 4], str.Failed_to_read_data_from_the_file_

Function at 0x405205
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x409688
cmp edx, dword [eax]
je 0x405227
add eax, 8
inc ecx
cmp eax, 0x409718
jl 0x405218
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x409688]
jne 0x405355
mov eax, dword [0x409a48]
cmp eax, 1
je 0x40532f
test eax, eax
jne 0x405258
cmp dword [0x4095d4], 1
je 0x40532f
cmp edx, 0xfc
je 0x405355
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40528f
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00403710
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00403810
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x4052d2
lea eax, [ebp - 0x1a4]
push eax
call fcn.00403810
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x4075d0
push edi
call fcn.00405b40
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00403710
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00403720
lea eax, [ebp - 0xa0]
push 0x4075b0
push eax
call fcn.00403720
push dword [esi + 0x40968c]
lea eax, [ebp - 0xa0]
push eax
call fcn.00403720
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00405ab7
add esp, 0x2c
pop edi
jmp 0x405355
lea eax, [ebp + 8]
lea esi, [esi + 0x40968c]
push 0
push eax
push dword [esi]
call fcn.00403810
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