joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403040
Capabilities:
Access peb ldr_data
Delete file
Extract resource via kernel32 functions

Disassembly:
push 0xffffffffffffffff
push 0x408417
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
mov eax, dword [esp + 0x24]
push ebx
push esi
push eax
mov dword [esp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x24]
push ecx
push edx
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push 0xffffffffffffffff
push 0
mov ecx, 0x40d778
mov esi, eax
call sub.MFC42u.DLL_CStringArray::SetSize
lea eax, [esp + 8]
push esi
push eax
call fcn.00401da0
add esp, 8
push 0x40d778
push ecx
lea edx, [esp + 0x34]
mov ebx, 1
mov ecx, esp
mov dword [esp + 0x30], esp
push edx
mov dword [esp + 0x24], ebx
mov word [esp + 0x3a], 0
mov word [esp + 0x38], bx
call sub.MFC42u.DLL_CString::CString
push ecx
lea eax, [esp + 0x14]
mov ecx, esp
mov dword [esp + 0x30], esp
push eax
mov byte [esp + 0x28], 2
call sub.MFC42u.DLL_CString::CString_3
mov byte [esp + 0x24], bl
call fcn.00401670
mov esi, dword [esp + 0x2c]
add esp, 0xc
mov ecx, esi
push ebx
push ebx
call sub.MFC42u.DLL_CString::CString_4
mov dword [esp + 0xc], ebx
lea ecx, [esp + 8]
mov byte [esp + 0x18], 0
call fcn.00407b42
mov ecx, dword [esp + 0x10]
mov eax, esi
pop esi
mov dword fs:[0], ecx
pop ebx
add esp, 0x14
ret

Function at 0x404fa0
Capabilities:
Delete file
Extract resource via kernel32 functions
Write file on windows

Disassembly:
push ebx
push esi
mov esi, dword [esp + 0x14]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push eax
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
push edi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
push 0
push 0
push 2
push 0
push 0
push 0x40000000
push esi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x404ff7
pop edi
pop esi
xor eax, eax
pop ebx
ret
lea edx, [esp + 0x18]
push 0
push edx
push edi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x405018
pop edi
pop esi
pop ebx
ret
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov eax, 1
pop ebx
ret
Function at 0x405030
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x64
push ebx
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
mov ebp, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push str.Wtsapi32.dll
mov esi, eax
mov dword [esp + 0x10], 0
call ebp
test eax, eax
je 0x40518d
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.WTSQueryUserToken
push eax
call ebx
test eax, eax
je 0x40518d
lea ecx, [esp + 0xc]
push ecx
push esi
call eax
test eax, eax
je 0x40518d
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_ImpersonateLoggedOnUser]
test eax, eax
je 0x40518d
mov ecx, dword [esp + 0xc]
lea eax, [esp + 0x14]
push eax
push 1
push 1
push 0
push 0x2000000
push ecx
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x40517c
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x30]
rep stosd dword es:[edi], eax
push str.Userenv.dll
mov dword [esp + 0x34], 0x44
mov dword [esp + 0x3c], str.winsta0default
mov edi, 0x20
mov dword [esp + 0x18], eax
call ebp
mov esi, eax
test esi, esi
je 0x40511f
push str.CreateEnvironmentBlock
push esi
call ebx
test eax, eax
je 0x405118
mov edx, dword [esp + 0x18]
push 0
lea ecx, [esp + 0x18]
push edx
push ecx
call eax
test eax, eax
je 0x405110
mov edi, 0x420
jmp 0x405118
mov dword [esp + 0x14], 0
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push str.mssys.exe
lea edx, [esp + 0x20]
push 0x40d79c
push edx
call sub.MFC42u.DLL_operator_1
lea ecx, [esp + 0x20]
mov eax, dword [eax]
lea edx, [esp + 0x30]
push ecx
mov ecx, dword [esp + 0x18]
push edx
mov edx, dword [esp + 0x20]
push 0
push ecx
push edi
push 0
push 0
push 0
push 0
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
lea ecx, [esp + 0x1c]
mov esi, eax
call fcn.00407b42
test esi, esi
pop edi
jne 0x405171
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.ADVAPI32.dll_RevertToSelf]
mov ecx, dword [esp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
Function at 0x406b70
Capabilities:
Shutdown system

Disassembly:
sub esp, 0x14
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp eax, 0x80000000
jae 0x406bd2
lea eax, [esp]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x406bdc
lea ecx, [esp + 8]
push ecx
push str.SeShutdownPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
mov eax, dword [esp]
push 0
push 0
lea edx, [esp + 0xc]
push 0
push edx
push 0
push eax
mov dword [esp + 0x1c], 1
mov dword [esp + 0x28], 2
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
push 0
push 6
call dword [sym.imp.USER32.dll_ExitWindowsEx]
add esp, 0x14
ret
Function at 0x500819f
Capabilities:
Hash data with crc32

Disassembly:
push esi
push edi
mov esi, ecx
push 4
xor edx, edx
pop ecx
push 8
mov dword [esi], edx
pop edi
mov eax, dword [esi]
test al, 1
je 0x50081bc
shr eax, 1
xor eax, 0xedb88320
jmp 0x50081be
shr eax, 1
dec edi
mov dword [esi], eax
jne 0x50081ad
mov dword [ecx + esi], eax
add ecx, 4
inc edx
cmp ecx, 0x404
jb 0x50081a8
mov ecx, esi
call fcn.050081de
mov eax, esi
pop edi
pop esi
ret

Function at 0x50081e5
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 8]
mov edx, dword [esp + 4]
push esi
mov esi, eax
dec eax
test esi, esi
je 0x500821a
push ebx
push edi
lea esi, [eax + 1]
mov eax, dword [ecx]
movzx ebx, byte [edx]
mov edi, eax
and edi, 0xff
xor edi, ebx
shr eax, 8
mov edi, dword [ecx + edi*4 + 4]
xor edi, eax
inc edx
dec esi
mov dword [ecx], edi
jne 0x50081fa
pop edi
pop ebx
pop esi
ret 8

Function at 0x5008281
Capabilities:
Get memory capacity

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push esi
push edi
mov edi, dword [ebp + 0xc]
mov esi, ecx
mov ecx, dword [ebp + 8]
push edi
mov dword [esi], ecx
call fcn.05008231
lea eax, [ebp - 0x20]
mov dword [esi + 4], edi
push eax
mov dword [ebp - 0x20], 0x20
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatus]
mov eax, dword [ebp - 0x10]
pop edi
sub eax, dword [ebp - 0xc]
mov dword [esi + 8], eax
and dword [esi + 0xc], 0
mov eax, esi
pop esi
leave
ret 8

Function at 0x50082c2
Capabilities:
Get memory capacity

Disassembly:
mov eax, 0x504d5b8
call fcn.05040548
sub esp, 0x24
push ebx
push esi
push edi
lea eax, [ebp - 0x30]
mov dword [ebp - 0x10], esp
mov esi, ecx
push eax
mov dword [ebp - 0x30], 0x20
call dword [sym.imp.KERNEL32.dll_GlobalMemoryStatus]
mov ecx, dword [ebp - 0x20]
xor edx, edx
sub ecx, dword [ebp - 0x1c]
sub ecx, dword [esi + 8]
sbb edx, dword [esi + 0xc]
js 0x5008338
jg 0x50082fe
test ecx, ecx
jb 0x5008338
mov eax, dword [esi + 4]
xor ebx, ebx
cmp edx, ebx
lea edi, [eax + eax*2]
jg 0x5008338
jl 0x5008310
cmp ecx, edi
ja 0x5008338
cmp eax, ecx
jae 0x500832c
and dword [ebp - 4], 0
sub ecx, eax
push ecx
mov ecx, dword [esi]
call fcn.05008231
jmp 0x5008338
jbe 0x5008338
sub eax, ecx
mov ecx, dword [esi]
push eax
call fcn.05008265
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret

Function at 0x500aad2
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x500aae4
xor al, al
ret
shr eax, 4
and eax, 1
ret

Function at 0x500aaeb
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push esi
call fcn.0500aad2
test al, al
pop ecx
je 0x500aaff
mov al, 1
pop esi
ret
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x500ab1c
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
neg eax
sbb eax, eax
pop esi
neg eax
ret
xor al, al
pop esi
ret
Function at 0x500ae7d
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
push 0x505fca4
and byte [ebx], 0
and byte [eax], 0
push edi
call fcn.0500ae1f
pop ecx
test al, al
pop ecx
je 0x500aece
lea eax, [ebp - 0x104]
push eax
push edi
call fcn.0500af0f
pop ecx
test al, al
pop ecx
je 0x500af05
push esi
push 0x41
pop ecx
lea esi, [ebp - 0x104]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp + 8]
mov byte [ebx], 1
pop esi
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x500af05
mov ecx, dword [ebp + 0x10]
shr eax, 4
and al, 1
mov byte [ecx], al
je 0x500af09
push edi
call fcn.05041440
cmp byte [eax + edi - 1], 0x5c
pop ecx
je 0x500af09
push 0x505fc08
push edi
call fcn.0500a7cb
pop ecx
test al, al
pop ecx
jne 0x500af09
xor al, al
jmp 0x500af0b
mov al, 1
pop edi
pop ebx
leave
ret

Function at 0x500b24d
Capabilities:
Get common file path

Disassembly:
push 0x103
push dword [esp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jne 0x500b263
xor al, al
ret
cmp dword [esp + 4], 0
mov eax, str.Color_
je 0x500b274
mov eax, str._spooldriverscolor_
push eax
push dword [esp + 0xc]
call fcn.0500a7cb
pop ecx
pop ecx
ret
Function at 0x5011b5b
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x134
push ebx
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
push edi
lea eax, [ebp - 0xc]
mov edi, 0x20019
xor ebx, ebx
push eax
push edi
push ebx
push str.SOFTWARE
push 0x80000002
mov byte [ebp - 1], bl
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x18], ebx
call esi
test eax, eax
je 0x5011ba4
mov dword [ebp - 0xc], ebx
jmp 0x5011ce7
lea eax, [ebp - 0x10]
push eax
push edi
push ebx
push str.Adobe
push dword [ebp - 0xc]
call esi
test eax, eax
je 0x5011bc0
mov dword [ebp - 0x10], ebx
jmp 0x5011ce7
lea eax, [ebp - 0x14]
push eax
push edi
push ebx
push str.Color
push dword [ebp - 0x10]
call esi
test eax, eax
je 0x5011bdc
mov dword [ebp - 0x14], ebx
jmp 0x5011ce7
lea eax, [ebp - 8]
push eax
push edi
push ebx
push str.Monitor
push dword [ebp - 0x14]
call esi
test eax, eax
je 0x5011bf8
mov dword [ebp - 8], ebx
jmp 0x5011ce7
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x24], ebx
push eax
lea eax, [ebp - 0x134]
push eax
lea eax, [ebp - 0x20]
push eax
push ebx
push str.Primary_Monitor
mov dword [ebp - 0x1c], 0x104
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x5011c3e
cmp dword [ebp - 0x20], 4
jne 0x5011c3e
mov eax, dword [ebp - 0x134]
cmp eax, 0x3e7
mov dword [ebp - 0x24], eax
ja 0x5011ce7
push dword [ebp - 0x24]
lea eax, [ebp - 0x30]
push str.Monitor_u
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x18]
push eax
push edi
lea eax, [ebp - 0x30]
push ebx
push eax
push dword [ebp - 8]
call esi
test eax, eax
je 0x5011c9f
mov dword [ebp - 0x18], ebx
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 8], ebx
je 0x5011c79
push dword [ebp - 8]
call esi
cmp dword [ebp - 0x14], ebx
je 0x5011c83
push dword [ebp - 0x14]
call esi
cmp dword [ebp - 0x10], ebx
je 0x5011c8d
push dword [ebp - 0x10]
call esi
cmp dword [ebp - 0xc], ebx
je 0x5011c97
push dword [ebp - 0xc]
call esi
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
leave
ret
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0x104
push eax
lea eax, [ebp - 0x134]
push eax
lea eax, [ebp - 0x20]
push eax
push ebx
push str.Monitor_Profile
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x5011ce7
cmp dword [ebp - 0x20], 1
jne 0x5011ce7
lea eax, [ebp - 0x134]
push eax
push dword [ebp + 8]
call fcn.0500a79d
pop ecx
test al, al
pop ecx
je 0x5011ce7
mov byte [ebp - 1], 1
cmp dword [ebp - 0x18], ebx
je 0x5011c69
push dword [ebp - 0x18]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call esi
jmp 0x5011c6f
Function at 0x502b604
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
mov eax, 0x504f05c
call fcn.05040548
mov eax, 0x1414
call fcn.05041d40
mov ecx, dword [ebp + 8]
push ebx
push esi
xor esi, esi
push edi
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x20], ecx
call fcn.0500a674
mov dword [ebp - 4], esi
mov dword [ebp - 0x18], esi
mov eax, dword [ebp - 0x18]
push 0xf
xor edx, edx
pop ecx
div ecx
and dword [ebp - 0x14], 0
lea ecx, [ebp - 0x41e]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x14]
push 0xf
xor edx, edx
pop esi
div esi
xor esi, esi
mov ebx, eax
mov al, byte [ebp - 0x1c]
push 0xf
mov byte [ecx - 1], al
mov eax, esi
xor edx, edx
pop edi
div edi
mov byte [ecx], bl
add esi, 0xff
mov edi, 0xff0
add ecx, 4
cmp esi, edi
mov byte [ecx - 3], al
jb 0x502b656
add dword [ebp - 0x14], 0xff
cmp dword [ebp - 0x14], edi
jb 0x502b648
mov ebx, dword [ebp + 8]
push 0
push 0x5058595a
mov esi, pe_nt_image_headers32
push 0x706c6162
lea eax, [ebp - 0x1420]
push esi
push eax
lea eax, [ebp - 0x420]
mov ecx, ebx
push eax
call fcn.05012525
mov eax, dword [ebx + 4]
lea ecx, [ebp - 0xc20]
push esi
push ecx
mov eax, dword [eax + 0x58]
lea ecx, [ebp - 0x420]
push ecx
push eax
call dword [eax + 0x74]
add esp, 0x10
xor ecx, ecx
movzx edx, word [ebp + ecx - 0xc1e]
movzx eax, word [ebp + ecx - 0x141e]
sub eax, edx
jns 0x502b6e6
neg eax
movzx edx, word [ebp + ecx - 0xc1c]
mov esi, eax
movzx eax, word [ebp + ecx - 0x141c]
sub eax, edx
jns 0x502b6fe
neg eax
movzx ebx, word [ebp + ecx - 0xc1a]
mov edx, eax
movzx eax, word [ebp + ecx - 0x141a]
sub eax, ebx
jns 0x502b716
neg eax
cmp dword [ebp - 0x10], esi
jge 0x502b71e
mov dword [ebp - 0x10], esi
cmp dword [ebp - 0x10], edx
jge 0x502b726
mov dword [ebp - 0x10], edx
cmp dword [ebp - 0x10], eax
jge 0x502b72e
mov dword [ebp - 0x10], eax
add ecx, 8
cmp ecx, 0x800
jb 0x502b6d0
cmp dword [ebp - 0x10], 0xa
ja 0x502b76c
add dword [ebp - 0x18], 0xff
cmp dword [ebp - 0x18], edi
jb 0x502b631
mov ecx, dword [ebp + 8]
or dword [ebp - 4], 0xffffffff
call fcn.0500a69a
mov al, 1
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
mov ecx, dword [ebp + 8]
or dword [ebp - 4], 0xffffffff
call fcn.0500a69a
xor al, al
jmp 0x502b75d
Function at 0x401050
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4452d8
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x45c3a4]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, dword [ebp + 0xc]
lea ecx, [ebp - 0x2c]
call fcn.00405da0
mov dword [ebp - 4], 0
cmp dword [eax + 0x14], 8
jb 0x401098
mov eax, dword [eax]
push eax
push 0x44d9e8
push str.Current_Working_Directory___s_
push 0x462e98
call fcn.004025d0
add esp, 0x10
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x18], 8
jb 0x4010c8
push dword [ebp - 0x2c]
call fcn.0041b8e3
add esp, 4
lea ecx, [ebp - 0x2c]
call fcn.00405cb0
cmp dword [eax + 0x14], 8
jb 0x4010d8
mov eax, dword [eax]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
cmp dword [ebp - 0x18], 8
mov esi, eax
jb 0x4010f2
push dword [ebp - 0x2c]
call fcn.0041b8e3
add esp, 4
test esi, esi
je 0x40113f
lea ecx, [ebp - 0x2c]
call fcn.00405da0
mov dword [ebp - 4], 1
cmp dword [eax + 0x14], 8
jb 0x40110d
mov eax, dword [eax]
push eax
push 0x44d9e8
push str.New_Working_Directory___s_
push 0x462e98
call fcn.004025d0
add esp, 0x10
mov dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x18], 8
jb 0x40115d
push dword [ebp - 0x2c]
call fcn.0041b8e3
add esp, 4
jmp 0x40115d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CAppMain::InitInstance
push str.Failed_to_set_working_directory._LastError__0x_08X_
push 0x462e98
call fcn.00402460
add esp, 0x10
push edi
push dword [ebp + 8]
mov ecx, 0x45f494
call fcn.00401fc0
test al, al
jne 0x40118d
push str.CAppMain::InitInstance
push str.Invalid_command_line
push 0x462e98
call fcn.00402460
add esp, 0xc
xor al, al
jmp 0x40123f
mov eax, dword [0x45f49c]
dec eax
cmp eax, 4
ja case.default.0x401198
jmp dword [eax*4 + 0x40128c]
call fcn.004012a0
test al, al
setne al
jmp 0x40123f
call fcn.00401580
test al, al
setne al
jmp 0x40123f
call fcn.00401580
test al, al
jne case.0x401198.1
jmp 0x40123f
call fcn.00401980
test al, al
setne al
jmp 0x40123f
call fcn.00401d50
test al, al
setne al
jmp 0x40123f
mov dword [ebp - 4], 2
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x1c], 0
call fcn.00408c20
sub esp, 8
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 3
call fcn.00408ce0
push str.CAppMain::InitInstance
push str.Exiting_service...
push 0x462e98
call fcn.00402460
add esp, 0xc
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x44], vtable.CKOSService.0
call fcn.00409df0
push dword [ebp - 0x1c]
call fcn.0041b8e3
add esp, 4
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0041b8d4
mov esp, ebp
pop ebp
ret 8
Function at 0x402760
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x445588
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x45c3a4]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
push 0xffffffffffffffff
lea eax, [ecx + 0x1c]
push 0
push eax
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x18], 0xf
mov dword [ebp - 0x1c], 0
mov byte [ebp - 0x2c], 0
call fcn.00403c10
push 0xffffffffffffffff
push 0
push esi
lea ecx, [ebp - 0x2c]
mov dword [ebp - 4], 0
call fcn.00402df0
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x4027db
push 2
push 0x44e2f0
lea ecx, [ebp - 0x2c]
call fcn.00402ef0
cmp dword [ebp - 0x18], 0x10
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [ebp - 0x18], 0x10
jb 0x4027fe
push dword [ebp - 0x2c]
call fcn.0041b8e3
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0041b8d4
mov esp, ebp
pop ebp
ret 4

Function at 0x402820
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4455b8
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x45c3a4]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
xor eax, eax
push 0xffffffffffffffff
push eax
mov word [ebp - 0x2c], ax
lea eax, [ecx + 0x34]
push eax
lea ecx, [ebp - 0x2c]
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], 0
call fcn.004036a0
push 0xffffffffffffffff
push 0
push esi
lea ecx, [ebp - 0x2c]
mov dword [ebp - 4], 0
call fcn.00403020
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x40289c
push 2
push 0x44e2f4
lea ecx, [ebp - 0x2c]
call fcn.00403130
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
cmp dword [ebp - 0x18], 8
jb 0x4028bf
push dword [ebp - 0x2c]
call fcn.0041b8e3
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0041b8d4
mov esp, ebp
pop ebp
ret 4
Function at 0x405da0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x214
mov eax, dword [0x45c3a4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
xor eax, eax
push 0x208
push eax
mov word [ebp - 0x210], ax
lea eax, [ebp - 0x20e]
push eax
mov esi, ecx
mov dword [ebp - 0x214], 0
call fcn.00427e80
add esp, 0xc
lea eax, [ebp - 0x210]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
add eax, eax
cmp eax, 0x20a
jae 0x405e6f
xor ecx, ecx
mov word [ebp + eax - 0x210], cx
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov word [esi], ax
cmp word [ebp - 0x210], ax
jne 0x405e30
xor ecx, ecx
jmp 0x405e4f
lea ecx, [ebp - 0x210]
lea edx, [ecx + 2]
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405e40
sub ecx, edx
sar ecx, 1
push ecx
lea eax, [ebp - 0x210]
push eax
mov ecx, esi
call fcn.00403a10
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.0041b8d4
mov esp, ebp
pop ebp
ret
call fcn.0041c98b
int3

Function at 0x406600
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, ecx
test esi, esi
je 0x40667f
cmp word [esi], 0
je 0x40667f
push esi
call fcn.004066f0
test al, al
jne 0x40662b
mov eax, 0x31
pop edi
pop esi
pop ecx
pop ebp
ret 4
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [edi], eax
test eax, eax
jne 0x406650
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
cmp eax, 2
setne cl
lea eax, [ecx + 0x32]
pop edi
pop esi
pop ecx
pop ebp
ret 4
push 0xffff
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 4], eax
test eax, eax
jne 0x406676
mov ecx, edi
call fcn.00406540
mov eax, 0x34
pop edi
pop esi
pop ecx
pop ebp
ret 4
xor eax, eax
pop edi
pop esi
pop ecx
pop ebp
ret 4
pop edi
mov eax, 0x30
pop esi
pop ecx
pop ebp
ret 4
Function at 0x407960
Capabilities:
Initialize winhttp library

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
cmp dword [esi + 8], 0
je 0x4079a7
mov eax, dword [esi + 0x10]
push edi
mov edi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
test eax, eax
je 0x407984
push eax
call edi
mov dword [esi + 0x10], 0
mov eax, dword [esi + 0xc]
test eax, eax
je 0x407995
push eax
call edi
mov dword [esi + 0xc], 0
mov eax, dword [esi + 8]
test eax, eax
je 0x4079a6
push eax
call edi
mov dword [esi + 8], 0
pop edi
mov eax, dword [ebp + 8]
cmp dword [eax + 0x14], 8
jb 0x4079b2
mov eax, dword [eax]
push 0
push 0
push 0
push 0
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov dword [esi + 8], eax
test eax, eax
setne al
pop esi
pop ebp
ret 4
Function at 0x407eb0
Capabilities:
Prepare http request

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ecx
cmp dword [esi + 0xc], 0
jne 0x407ec3
xor al, al
pop esi
pop ebp
ret 0x10
mov eax, dword [esi + 0x10]
test eax, eax
je 0x407ed8
push eax
call dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
mov dword [esi + 0x10], 0
cmp byte [ebp + 0x14], 0
mov ecx, dword [ebp + 0xc]
mov edx, 0x100
mov eax, 0x800100
cmovne edx, eax
cmp dword [ecx + 0x14], 8
jb 0x407ef4
mov ecx, dword [ecx]
mov eax, dword [ebp + 8]
cmp dword [eax + 0x14], 8
jb 0x407eff
mov eax, dword [eax]
push edx
push 0
push 0
push 0
push ecx
push eax
push dword [esi + 0xc]
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov dword [esi + 0x10], eax
test eax, eax
je 0x407ebc
mov dword [esi + 0x28], 0
mov dword [esi + 0x20], 0
mov dword [esi + 0x24], 0
mov al, 1
pop esi
pop ebp
ret 0x10