joyce8/EMBER2024-capa huggingface dataset:
Function at 0x404b00
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x424e4e
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x433610]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor edi, edi
mov dword [ebp - 0x14], edi
cmp esi, edi
je 0x404b43
mov eax, dword [esi]
mov edx, dword [eax]
lea ecx, [ebp - 0x14]
push ecx
push 0x427470
push esi
call edx
mov eax, dword [ebp - 0x14]
push eax
lea ecx, [ebp - 0x10]
mov dword [ebp - 4], edi
mov dword [ebp - 0x10], edi
call fcn.00402b00
cmp eax, edi
jge 0x404b5f
push eax
call fcn.004010d0
mov eax, dword [ebp - 0x10]
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x10], edi
mov dword [esi + 0x38], eax
call fcn.00402500
mov eax, dword [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
cmp eax, edi
je 0x404b86
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [esi + 0x3c]
push eax
call dword [sym.imp.KERNEL32.DLL_ResetEvent]
mov eax, dword [esi + 0x30]
cmp eax, edi
je 0x404ba1
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov dword [esi + 0x30], edi
lea eax, [esi + 0x34]
push eax
push edi
push esi
push 0x404380
push edi
push edi
call dword [sym.imp.KERNEL32.DLL_CreateThread]
mov dword [esi + 0x30], eax
cmp eax, edi
jne 0x404c46
mov ecx, dword [esi + 0x38]
mov dword [ebp - 0x14], ecx
mov ebx, 1
mov dword [ebp - 4], ebx
call fcn.00401260
mov esi, eax
test byte [0x434778], bl
jne 0x404c00
or dword [0x434778], ebx
mov ecx, 0x434744
mov byte [ebp - 4], 2
call fcn.00408630
push 0x426160
call fcn.00417f35
add esp, 4
mov byte [ebp - 4], bl
mov ecx, 0x434744
call fcn.00409030
cmp eax, edi
je 0x404c2a
push esi
lea edx, [ebp - 0x1c]
push str.BitsJob:_failed_to_start_worker_thread__0x_x_
push edx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], 0xfffffffe
call fcn.00408ee0
add esp, 0xc
lea ecx, [ebp - 0x14]
call fcn.00402500
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor eax, eax
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 0x406210
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x424e4e
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x433610]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor edi, edi
mov dword [ebp - 0x14], edi
cmp esi, edi
je 0x406253
mov eax, dword [esi]
mov edx, dword [eax]
lea ecx, [ebp - 0x14]
push ecx
push 0x427470
push esi
call edx
mov eax, dword [ebp - 0x14]
push eax
lea ecx, [ebp - 0x10]
mov dword [ebp - 4], edi
mov dword [ebp - 0x10], edi
call fcn.00402b00
cmp eax, edi
jge 0x40626f
push eax
call fcn.004010d0
mov eax, dword [ebp - 0x10]
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x10], edi
mov dword [esi + 0x30], eax
call fcn.00402500
mov eax, dword [ebp - 0x14]
mov dword [ebp - 4], 0xffffffff
cmp eax, edi
je 0x406296
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [esi + 0x34]
push eax
call dword [sym.imp.KERNEL32.DLL_ResetEvent]
mov eax, dword [esi + 0x28]
cmp eax, edi
je 0x4062b1
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov dword [esi + 0x28], edi
lea eax, [esi + 0x2c]
push eax
push edi
push esi
push 0x406140
push edi
push edi
call dword [sym.imp.KERNEL32.DLL_CreateThread]
mov dword [esi + 0x28], eax
cmp eax, edi
jne 0x406356
mov ecx, dword [esi + 0x30]
mov dword [ebp - 0x14], ecx
mov ebx, 1
mov dword [ebp - 4], ebx
call fcn.00401260
mov esi, eax
test byte [0x434778], bl
jne 0x406310
or dword [0x434778], ebx
mov ecx, 0x434744
mov byte [ebp - 4], 2
call fcn.00408630
push 0x426160
call fcn.00417f35
add esp, 4
mov byte [ebp - 4], bl
mov ecx, 0x434744
call fcn.00409030
cmp eax, edi
je 0x40633a
push esi
lea edx, [ebp - 0x1c]
push str.InstallerJob:_failed_to_start_worker_thread__0x_x_
push edx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], 0xfffffffe
call fcn.00408ee0
add esp, 0xc
lea ecx, [ebp - 0x14]
call fcn.00402500
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor eax, eax
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 0x4064c0
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.DLL_TryEnterCriticalSection]
lea esi, [ecx + 4]
push esi
call edi
test eax, eax
je 0x4064e0
pop edi
mov al, 1
pop esi
mov esp, ebp
pop ebp
ret 4
push ebx
call dword [sym.imp.KERNEL32.DLL_GetTickCount]
mov ebx, dword [sym.imp.KERNEL32.DLL_Sleep]
mov dword [ebp - 4], eax
push 0
call ebx
push esi
call edi
test eax, eax
jne 0x406514
call dword [sym.imp.KERNEL32.DLL_GetTickCount]
sub eax, dword [ebp - 4]
cmp eax, dword [ebp + 8]
jb 0x4064f0
pop ebx
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret 4
pop ebx
pop edi
mov al, 1
pop esi
mov esp, ebp
pop ebp
ret 4
Function at 0x4065a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
mov eax, dword [esi + 0xc]
test eax, eax
je 0x406654
push 0x3e8
push eax
call dword [sym.imp.KERNEL32.DLL_WaitForSingleObject]
test eax, eax
je 0x4065cd
cmp eax, 0x80
jne 0x406654
mov eax, dword [esi + 8]
push ebx
push edi
push 2
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
mov edi, dword [ebp + 8]
mov eax, dword [edi + 4]
mov ebx, dword [sym.imp.KERNEL32.DLL_WriteFile]
mov dword [ebp - 4], 0
test eax, eax
je 0x406610
push 0
lea ecx, [ebp - 4]
push ecx
push eax
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
mov edx, dword [edi + 4]
add eax, eax
push eax
mov eax, dword [esi + 8]
push edx
push eax
call ebx
mov eax, dword [edi + 8]
test eax, eax
je 0x406631
push 0
lea ecx, [ebp - 4]
push ecx
push eax
call dword [sym.imp.KERNEL32.DLL_lstrlenW]
mov edx, dword [edi + 8]
add eax, eax
push eax
mov eax, dword [esi + 8]
push edx
push eax
call ebx
mov edx, dword [esi + 8]
push 0
lea ecx, [ebp - 4]
push ecx
push 4
push 0x428538
push edx
call ebx
mov esi, dword [esi + 0xc]
pop edi
pop ebx
test esi, esi
je 0x406654
push esi
call dword [sym.imp.KERNEL32.DLL_ReleaseMutex]
pop esi
mov esp, ebp
pop ebp
ret 4

Function at 0x408410
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x424fd8
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x433610]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [0x4335d8]
mov edx, dword [eax + 0xc]
mov ecx, 0x4335d8
call edx
add eax, 0x10
mov dword [ebp - 0x10], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 8]
mov edx, dword [eax + 4]
push ecx
push edx
lea eax, [ebp - 0x10]
push 0x428610
push eax
mov dword [ebp - 4], 0
call fcn.00403440
mov esi, dword [ebp - 0x10]
add esp, 0x10
push esi
call dword [sym.imp.KERNEL32.DLL_OutputDebugStringW]
lea eax, [esi - 0x10]
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x408499
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret 4
Function at 0x408860
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4250e3
mov eax, dword fs:[0]
push eax
sub esp, 0x8c
mov eax, dword [0x433610]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor ebx, ebx
push ebx
push 0x80
push 4
push ebx
push 3
mov esi, ecx
mov eax, dword [esi + 4]
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov dword [esi + 8], eax
cmp eax, 0xffffffff
jne 0x4088bd
mov dword [esi + 8], ebx
xor al, al
jmp 0x408982
call dword [sym.imp.KERNEL32.DLL_GetLastError]
cmp eax, 0xb7
je 0x4088e3
mov ecx, dword [esi + 8]
push ebx
lea eax, [ebp - 0x78]
push eax
push 2
push 0x42744c
push ecx
mov dword [ebp - 0x78], ebx
call dword [sym.imp.KERNEL32.DLL_WriteFile]
mov dword [ebp - 0x94], ebx
mov byte [ebp - 0x90], bl
mov dword [ebp - 0x8c], 2
mov dword [ebp - 0x98], vtable.ATL::CDacl.0
mov dword [ebp - 0x88], ebx
mov dword [ebp - 0x84], ebx
mov dword [ebp - 0x80], ebx
mov dword [ebp - 0x7c], ebx
lea edx, [ebp - 0x70]
push edx
mov dword [ebp - 4], ebx
call fcn.004074f0
add esp, 4
push ebx
push 0xc0010000
push eax
lea ecx, [ebp - 0x98]
mov byte [ebp - 4], 1
call fcn.00408260
lea ecx, [ebp - 0x70]
mov byte [ebp - 0x71], al
mov byte [ebp - 4], bl
call fcn.004073d0
cmp byte [ebp - 0x71], bl
je 0x408975
mov esi, dword [esi + 8]
cmp esi, ebx
je 0x408975
push ebx
lea ecx, [ebp - 0x98]
call fcn.004068b0
push eax
push ebx
push ebx
push 4
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_SetSecurityInfo]
push eax
call dword [sym.imp.KERNEL32.DLL_SetLastError]
lea ecx, [ebp - 0x98]
call fcn.004084b0
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00418330
mov esp, ebp
pop ebp
ret

Function at 0x409840
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
lea edi, [eax + 4]
test edi, edi
je 0x40989e
mov esi, dword [ebp + 0xc]
add esi, 4
je 0x40989e
cmp byte [eax + 0x48], 0
je 0x40989e
mov ebx, dword [sym.imp.ADVAPI32.dll_IsValidSid]
push edi
call ebx
test eax, eax
setne al
test al, al
je 0x40989e
mov eax, dword [ebp + 0xc]
cmp byte [eax + 0x48], 0
je 0x40989e
push esi
call ebx
test eax, eax
setne al
test al, al
je 0x40989e
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
setne al
pop edi
xor ecx, ecx
test al, al
pop esi
sete al
pop ebx
pop ebp
ret
xor al, al
pop edi
xor ecx, ecx
test al, al
pop esi
sete al
pop ebx
pop ebp
ret
Function at 0x40a0a0
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
xor eax, eax
mov ebx, ecx
push esi
push edi
mov dword [ebp - 8], eax
cmp dword [ebx + 4], eax
jle 0x40a11c
mov dword [ebp - 4], eax
mov eax, dword [ebx]
add eax, dword [ebp - 4]
lea esi, [eax + 4]
test esi, esi
je 0x40a10c
mov edi, dword [ebp + 8]
add edi, 4
je 0x40a10c
cmp byte [eax + 0x48], 0
je 0x40a10c
push esi
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
test al, al
je 0x40a10c
mov eax, dword [ebp + 8]
cmp byte [eax + 0x48], 0
je 0x40a10c
push edi
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
test al, al
je 0x40a10c
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
setne al
test al, al
jne 0x40a128
mov eax, dword [ebp - 8]
add dword [ebp - 4], 0x60
inc eax
mov dword [ebp - 8], eax
cmp eax, dword [ebx + 4]
jl 0x40a0b8
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ebp - 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x40a990
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x425436
mov eax, dword fs:[0]
push eax
sub esp, 0x430
mov eax, dword [0x433610]
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 ecx, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x430], ecx
call fcn.00401a60
xor eax, eax
push 0x206
push eax
lea ecx, [ebp - 0x21e]
push ecx
mov word [ebp - 0x220], ax
call fcn.00417cb0
add esp, 0xc
lea edx, [ebp - 0x220]
push edx
push 0x104
call dword [sym.imp.KERNEL32.DLL_GetLogicalDriveStringsW]
test eax, eax
je 0x40aac9
cmp word [ebp - 0x220], 0
mov eax, dword [0x428838]
mov cx, word [0x42883c]
mov dword [ebp - 0x18], eax
mov word [ebp - 0x14], cx
lea esi, [ebp - 0x220]
je 0x40aac1
mov dx, word [esi]
xor eax, eax
push 0x206
push eax
lea ecx, [ebp - 0x426]
push ecx
mov word [ebp - 0x18], dx
mov word [ebp - 0x428], ax
call fcn.00417cb0
add esp, 0xc
push 0x104
lea edx, [ebp - 0x428]
push edx
lea eax, [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.DLL_QueryDosDeviceW]
test eax, eax
je 0x40aac9
lea eax, [ebp - 0x428]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40aa76
sub eax, edx
sar eax, 1
mov edi, eax
mov eax, dword [ebx]
push edi
lea ecx, [ebp - 0x428]
push ecx
push eax
call fcn.00418d3c
add esp, 0xc
test eax, eax
je 0x40aae7
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40aaa3
sub eax, edx
sar eax, 1
cmp word [esi + eax*2 + 2], cx
lea esi, [esi + eax*2 + 2]
jne 0x40aa2e
push 0xf
call dword [sym.imp.KERNEL32.DLL_SetLastError]
xor al, al
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.00418330
mov esp, ebp
pop ebp
ret
mov eax, dword [ebx]
sub eax, 0x10
push eax
call fcn.00401b50
add eax, 0x10
add esp, 4
mov dword [ebp - 0x42c], eax
mov esi, dword [eax - 0xc]
mov ebx, 1
lea edx, [ebp - 0x42c]
mov dword [ebp - 4], 0
mov dword [ebp - 0x43c], edx
mov dword [ebp - 0x434], esi
cmp dword [eax - 4], ebx
jle 0x40ab32
push esi
mov ecx, edx
call fcn.00401740
mov eax, dword [ebp - 0x42c]
mov dword [ebp - 0x438], eax
lea ecx, [eax + edi*2]
mov eax, dword [ebp - 0x430]
push ecx
lea edx, [ebp - 0x18]
push edx
push str._s_s
push eax
mov byte [ebp - 4], bl
call fcn.00403440
add esp, 0x10
mov byte [ebp - 4], 0
mov eax, esi
cmp esi, 0xffffffff
jne 0x40ab75
mov eax, dword [ebp - 0x42c]
mov ecx, dword [eax - 8]
push ecx
push eax
call fcn.00417d2a
add esp, 8
test eax, eax
js 0x40abc3
mov ecx, dword [ebp - 0x42c]
cmp eax, dword [ecx - 8]
jg 0x40abc3
mov dword [ecx - 0xc], eax
mov edx, dword [ebp - 0x42c]
xor ecx, ecx
mov word [edx + eax*2], cx
mov eax, dword [ebp - 0x42c]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40abbc
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, bl
jmp 0x40aacb
push 0x80070057
call fcn.004010d0
int3
Function at 0x40abd0
Capabilities:
Get process image filename

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x425470
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
mov eax, dword [0x433610]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
push eax
push 0
push 0x400
call dword [sym.imp.KERNEL32.DLL_OpenProcess]
mov esi, eax
mov dword [ebp - 0x14], esi
mov dword [ebp - 4], 0
test esi, esi
je 0x40acc7
mov edx, dword [0x4335d8]
mov eax, dword [edx + 0xc]
mov ecx, 0x4335d8
call eax
lea ecx, [eax + 0x10]
mov dword [ebp - 0x10], ecx
mov eax, dword [ecx - 8]
mov edx, 1
mov byte [ebp - 4], dl
sub edx, dword [ecx - 4]
sub eax, 0x208
or eax, edx
jge 0x40ac59
push 0x208
lea ecx, [ebp - 0x10]
call fcn.00401af0
mov ecx, dword [ebp - 0x10]
push 0x208
push ecx
push esi
call sub.PSAPI.DLL_GetProcessImageFileNameW
test eax, eax
mov eax, dword [ebp - 0x10]
mov ecx, dword [eax - 8]
push ecx
push eax
sete bl
call fcn.00417d2a
add esp, 8
test eax, eax
js 0x40ad29
mov ecx, dword [ebp - 0x10]
cmp eax, dword [ecx - 8]
jg 0x40ad29
mov dword [ecx - 0xc], eax
mov edx, dword [ebp - 0x10]
xor ecx, ecx
mov word [edx + eax*2], cx
test bl, bl
je 0x40acda
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
mov byte [ebp - 4], cl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40acc0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp - 0x10]
push edx
call fcn.0040a990
mov bl, al
mov eax, dword [ebp - 0x10]
add eax, 0xfffffff0
add esp, 8
mov byte [ebp - 4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ad0f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.004010d0
int3
Function at 0x40cd80
Capabilities:
Access the windows event log

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x208
mov eax, dword [0x433610]
xor eax, ebp
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp + 0x10]
push eax
push ecx
push 0xff
lea edx, [ebp - 0x204]
push pe_nt_image_headers32
push edx
call fcn.00417bd3
xor eax, eax
add esp, 0x14
lea ecx, [ebp - 0x204]
mov word [ebp - 6], ax
mov dword [ebp - 0x208], ecx
cmp dword [esi + 0x260], eax
jne 0x40cddd
mov edx, ecx
push edx
call fcn.00418f4d
add esp, 4
add esi, 0x40
push esi
push 0
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceW]
mov esi, eax
test esi, esi
je 0x40ce12
push 0
lea eax, [ebp - 0x208]
push eax
push 0
push 1
push 0
push 0
push 0
push 4
push esi
call dword [sym.imp.ADVAPI32.dll_ReportEventW]
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00418330
mov esp, ebp
pop ebp
ret

Function at 0x40da10
Capabilities:
Access the windows event log

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42578c
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x433610]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
lea edi, [ecx + 0x40]
push edi
push 0
call dword [sym.imp.ADVAPI32.dll_RegisterEventSourceW]
mov esi, eax
test esi, esi
jne 0x40dac7
mov eax, 1
test byte [0x434778], al
jne 0x40da7e
or dword [0x434778], eax
mov ecx, 0x434744
mov dword [ebp - 4], esi
call fcn.00408630
push 0x426160
call fcn.00417f35
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, 0x434744
call fcn.00409030
test eax, eax
je 0x40db5a
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], 0xfffffffe
call dword [sym.imp.KERNEL32.DLL_GetLastError]
push eax
push edi
lea eax, [ebp - 0x14]
push str.Service:_failed_to_RegisterEventSource_name_s__0x_x_
push eax
call fcn.00408ee0
add esp, 0x10
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 0x18]
mov edi, dword [ebp + 0x10]
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
push 0
push ecx
push 0
push edx
push 0
push edi
push ebx
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_ReportEventW]
test eax, eax
jne 0x40db53
mov eax, 1
test byte [0x434778], al
jne 0x40db20
or dword [0x434778], eax
mov ecx, 0x434744
mov dword [ebp - 4], eax
call fcn.00408630
push 0x426160
call fcn.00417f35
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov ecx, 0x434744
call fcn.00409030
test eax, eax
je 0x40db53
movzx edx, word [ebp + 8]
push edi
movzx ecx, bx
push ecx
push edx
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x1c]
push str.Service:_failed_to_ReportEvent_type_d_category_d_message_d
push eax
mov dword [ebp - 0x18], 0xfffffffe
call fcn.00408ee0
add esp, 0x14
push esi
call dword [sym.imp.ADVAPI32.dll_DeregisterEventSource]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
Function at 0x40dc10
Capabilities:
Create service

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa10
mov eax, dword [0x433610]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0xf003f
xor edi, edi
push edi
push edi
mov ebx, ecx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, eax
test esi, esi
je 0x40dc69
push 1
lea eax, [ebx + 0x40]
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
test eax, eax
je 0x40dc5a
push eax
mov edi, 1
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test edi, edi
jne 0x40dda4
push 0x104
lea ecx, [ebp - 0x20e]
push ecx
push 0
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameW]
test eax, eax
je 0x40dd0a
cmp eax, 0x104
je 0x40dd0a
mov edx, 0x22
mov word [ebp - 0x210], dx
mov ecx, edx
xor edx, edx
push 0xf003f
push edx
push edx
mov word [ebp + eax*2 - 0x20e], cx
mov word [ebp + eax*2 - 0x20c], dx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov esi, eax
test esi, esi
jne 0x40dd1d
push 0x400
lea eax, [ebp - 0xa10]
push eax
push 0xd80a
call fcn.0040cc80
add esp, 0xc
test eax, eax
jne 0x40dcf5
push str.Could_not_open_Service_Manager
lea ecx, [ebp - 0xa10]
push 0x400
push ecx
call fcn.0040c9e0
add esp, 0xc
push 0
add ebx, 0x40
push ebx
lea edx, [ebp - 0xa10]
push edx
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00418330
mov esp, ebp
pop ebp
ret
push 0
push 0
push str.RPCSS
push 0
push 0
lea eax, [ebp - 0x210]
push eax
push 1
push 3
push 0x10
push 0xf01ff
lea edi, [ebx + 0x40]
push edi
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_CreateServiceW]
test eax, eax
jne 0x40dd98
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push 0x400
lea ecx, [ebp - 0xa10]
push ecx
push 0xd80b
call fcn.0040cc80
add esp, 0xc
test eax, eax
jne 0x40dd89
push str.Could_not_start_service
lea edx, [ebp - 0xa10]
push 0x400
push edx
call fcn.0040c9e0
add esp, 0xc
push 0
push edi
lea eax, [ebp - 0xa10]
push eax
jmp 0x40dd02
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push eax
call edi
push esi
call edi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
mov eax, 1
pop ebx
call fcn.00418330
mov esp, ebp
pop ebp
ret