joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140081a0c
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r14
push r15
mov eax, 0x1140
call fcn.1401a62f0
sub rsp, rax
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x1130], rax
xor edi, edi
mov ebp, edx
mov rsi, rcx
test rcx, rcx
jne 0x140081a50
xor eax, eax
jmp 0x140081b95
lea rbx, [rcx + 0x18]
mov rcx, qword [rcx]
call fcn.1401a892c
cmp rax, qword [rsi + 0x1018]
je 0x140081a49
cmp ebp, 0x20
je 0x140081a7c
mov eax, 0x3c
cmp ebp, 0x40
lea r14d, [rax + 0xc]
cmovne r14d, eax
jmp 0x140081a82
mov r14d, 0x40
mov r9, qword [rsi]
mov r15d, 1
mov edx, r15d
mov r8, r14
mov rcx, rbx
call fcn.1401ae3cc
cmp eax, r14d
jl 0x140081a49
mov ecx, dword [rbx]
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, dword [rbx + 4]
mov dword [rbx], eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, dword [rbx + 8]
mov dword [rbx + 4], eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rbx + 8], eax
mov rcx, qword [rsi]
call fcn.1401a892c
movsxd rcx, dword [rbx + 4]
add rax, rcx
mov qword [rbx - 8], rax
mov eax, 0xff8
sub eax, r14d
cmp dword [rbx + 4], eax
jg 0x140081a49
movsxd r8, dword [rbx + 4]
lea rcx, [r14 + rbx]
mov r9, qword [rsi]
mov edx, r15d
call fcn.1401ae3cc
cmp eax, dword [rbx + 4]
jne 0x140081a49
mov ebp, dword [rbx + 8]
lea rcx, [rsp + 0x20]
call fcn.14009a890
test ebp, ebp
jle 0x140081b59
mov r12d, 0x1000
mov r9, qword [rsi]
lea rcx, [rsp + 0x130]
mov eax, ebp
cmp ebp, r12d
mov rdx, r15
cmovg eax, r12d
movsxd r8, eax
call fcn.1401ae3cc
mov r14, rax
test eax, eax
jle 0x140081b59
movsxd r8, r14d
lea rdx, [rsp + 0x130]
lea rcx, [rsp + 0x20]
call fcn.14009a920
sub ebp, r14d
test ebp, ebp
jg 0x140081b17
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x100]
call fcn.14009a870
cmp dword [rbx + 8], edi
jle 0x140081b92
lea rcx, [rbx + 0xc]
mov r8d, 0x30
lea rdx, [rsp + 0x100]
call fcn.1401a71d0
test eax, eax
cmove rdi, rbx
mov rax, rdi
jmp 0x140081b95
mov rax, rbx
mov rcx, qword [rsp + 0x1130]
xor rcx, rsp
call fcn.1401a5d00
lea r11, [rsp + 0x1140]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret
Function at 0x140082058
Capabilities:
Check if file exists

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
push rsi
sub rsp, 0x40
and qword [rax - 0x18], 0
xor r9d, r9d
mov dword [rax - 0x20], 0x80
mov rsi, rcx
test r8d, r8d
jne 0x140082105
test edx, edx
mov edx, 0xc0000000
je 0x140082091
mov dword [rax - 0x28], 5
jmp 0x14008209c
mov r8d, 3
mov dword [rsp + 0x20], r8d
mov r8d, 1
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbx, rax
cmp rax, 0xffffffffffffffff
jne 0x1400820ea
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x1400820ea
and qword [rsp + 0x30], 0
lea r8d, [rax - 1]
mov dword [rsp + 0x28], 0x80
xor r9d, r9d
mov edx, 0xc0000000
mov dword [rsp + 0x20], 1
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbx, rax
mov edx, 2
mov rcx, rbx
call fcn.1401b6980
cmp eax, 0xffffffff
je 0x140082146
lea rdx, str.wbN
jmp 0x14008213a
mov r8d, 3
mov edx, 0x80000000
mov dword [rsp + 0x20], r8d
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14008214f
xor edx, edx
mov rcx, rax
call fcn.1401b6980
cmp eax, 0xffffffff
je 0x140082146
lea rdx, [0x1402311c0]
mov ecx, eax
call fcn.1401b6408
test rax, rax
jne 0x140082151
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov rbx, qword [rsp + 0x50]
add rsp, 0x40
pop rsi
ret

Function at 0x1400823b4
Capabilities:
Read file on windows

Disassembly:
push rbx
push rsi
push rdi
push r14
sub rsp, 0x78
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov rsi, r9
mov r14, rcx
test rcx, rcx
jne 0x1400823df
xor eax, eax
jmp 0x14008248f
cmp r8d, 1
jle 0x1400823f4
lea ecx, [r8 - 1]
movsxd rax, ecx
cmp byte [rax + rdx], 0
cmove r8d, ecx
mov rcx, qword [r14 + 0x1010]
mov r9d, r8d
and dword [rsp + 0x20], 0
mov r8, rdx
xor edx, edx
call fcn.14007e110
test rax, rax
je 0x140082418
mov rbx, qword [rax + 0x28]
jmp 0x14008241a
xor ebx, ebx
test rbx, rbx
je 0x1400823d8
test rsi, rsi
je 0x14008248d
mov edi, dword [rsp + 0xc0]
cmp edi, dword [rbx]
jl 0x14008248d
mov rdx, qword [rbx + 0x38]
xor r8d, r8d
mov rcx, qword [r14]
call fcn.1401a8f24
test eax, eax
jne 0x1400823d8
movsxd r8, dword [rbx]
lea edx, [rax + 1]
mov r9, qword [r14]
mov rcx, rsi
call fcn.1401ae3cc
test rax, rax
je 0x1400823d8
mov edx, dword [rbx]
lea r8, [rsp + 0x30]
mov rcx, rsi
call fcn.1400774d0
lea rdx, [rbx + 4]
mov r8d, 0x30
lea rcx, [rsp + 0x30]
call fcn.1401a71d0
test eax, eax
jne 0x1400823d8
cmp edi, dword [rbx]
jle 0x14008248d
movsxd rcx, dword [rbx]
mov byte [rcx + rsi], al
mov eax, dword [rbx]
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.1401a5d00
add rsp, 0x78
pop r14
pop rdi
pop rsi
pop rbx
ret
Function at 0x1400826d4
Capabilities:
Copy file
Delete file

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x50
xor esi, esi
mov rdi, rcx
test rcx, rcx
jne 0x1400826ff
lea eax, [rcx + 1]
jmp 0x1400827e9
mov rcx, qword [rcx + 8]
lea r8, str..tmp
or edx, 0xffffffff
mov r9d, edx
call fcn.14007e978
xor r8d, r8d
mov rcx, rax
mov rbp, rax
lea ebx, [r8 + 1]
mov edx, ebx
call fcn.140082058
mov r14, rax
test rax, rax
je 0x1400827df
mov rcx, qword [rdi + 0x1010]
lea r8, [rsp + 0x30]
and dword [rdi + 0x1020], esi
lea rdx, [0x14007df9c]
mov qword [rsp + 0x28], rax
xor r9d, r9d
lea rax, [0x14008256c]
mov qword [rsp + 0x20], rdi
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x20]
mov qword [rsp + 0x30], rcx
mov rcx, qword [rcx]
mov qword [rsp + 0x40], rax
call fcn.14007e5c0
cmp dword [rdi + 0x1020], esi
jne 0x1400827dd
mov rcx, qword [rdi]
call fcn.1401a8b70
mov rcx, r14
call fcn.1401a8b70
mov rdx, qword [rdi + 8]
xor r8d, r8d
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
mov rcx, rbp
cmove esi, ebx
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
mov rcx, qword [rdi + 8]
xor r8d, r8d
xor edx, edx
call fcn.140082058
mov qword [rdi], rax
test rax, rax
je 0x1400827db
mov rcx, rax
call fcn.1401a892c
mov qword [rdi + 0x1018], rax
jmp 0x1400827dd
mov esi, ebx
mov ebx, esi
mov rcx, rbp
call fcn.1401ad038
mov eax, ebx
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x78]
add rsp, 0x50
pop r14
ret
Function at 0x14008616c
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
or r9d, 0xffffffff
mov r10, rcx
test edx, edx
je 0x1400861a1
movsx r8d, byte [r10]
mov eax, r9d
xor r8, rax
mov ecx, r9d
movzx eax, r8b
inc r10
shr ecx, 8
lea r8, [0x1402364f0]
mov r9d, dword [r8 + rax*4]
xor r9d, ecx
sub edx, 1
jne 0x140086177
not r9d
mov eax, r9d
ret
Function at 0x14008f5fc
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov rdi, rcx
mov rbx, r9
movsx ecx, byte [rcx + 1]
sub ecx, 1
je 0x14008f6c6
cmp ecx, 1
jne 0x14008f6f0
lea edx, [rcx + 0xb]
mov dword [rsp + 0x20], 0x2112a442
mov r9d, edx
lea rcx, [rsp + 0x24]
call section..text
xor eax, eax
mov qword [rbx], rax
mov qword [rbx + 8], rax
mov qword [rbx + 0x10], rax
mov dword [rbx + 0x18], eax
mov eax, reloc.WS2_32.dll_socket
mov word [rbx], ax
lea ecx, [rax - 7]
call qword [sym.imp.WS2_32.dll_htonl]
xor edx, edx
mov r8, rdi
cmp eax, 0x10
jne 0x14008f6a6
lea rax, [rsp + 0x20]
mov r9, rbx
sub r8, rax
lea rax, [rsp + 0x20]
sub r9, rax
lea rcx, [rsp + 0x20]
add rcx, rdx
inc rdx
mov al, byte [r8 + rcx + 4]
xor al, byte [rcx]
mov byte [r9 + rcx + 8], al
cmp rdx, 0x10
jl 0x14008f687
jmp 0x14008f6f0
lea rcx, [rbx + 0x17]
sub r8, rbx
mov al, byte [r8 + rcx - 4]
xor al, byte [rsp + rdx + 0x20]
inc rdx
mov byte [rcx], al
dec rcx
cmp rdx, 0x10
jl 0x14008f6ad
jmp 0x14008f6f0
mov ecx, dword [rdi + 4]
call qword [sym.imp.WS2_32.dll_ntohl]
xor ecx, ecx
xor eax, 0x2112a442
mov qword [rbx], rcx
mov qword [rbx + 8], rcx
mov ecx, 2
mov word [rbx], cx
mov ecx, eax
call qword [sym.imp.WS2_32.dll_htonl]
mov dword [rbx + 4], eax
movzx ecx, word [rdi + 2]
call qword [sym.imp.WS2_32.dll_ntohs]
mov ecx, 0x2112
xor cx, ax
call qword [sym.imp.WS2_32.dll_htons]
mov word [rbx + 2], ax
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
mov rbx, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
Function at 0x14008f724
Capabilities:
Encode data using xor

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r14
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov rdi, rcx
mov rbp, r8
movzx ecx, word [rcx + 2]
mov rsi, rdx
call qword [sym.imp.WS2_32.dll_ntohs]
movzx ecx, ax
xor ebx, ebx
mov eax, 0x2112
mov byte [rsi], bl
xor cx, ax
lea r14d, [rbx + 2]
cmp word [rdi], r14w
setne al
inc al
mov byte [rsi + 1], al
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsi + 2], ax
movzx eax, word [rdi]
cmp eax, r14d
je 0x14008f824
cmp eax, 0x17
jne 0x14008f842
lea edx, [rbx + 0xc]
mov dword [rsp + 0x20], 0x2112a442
mov r9d, edx
lea rcx, [rsp + 0x24]
mov r8, rbp
call section..text
lea ebp, [rbx + 0x10]
mov ecx, ebp
call qword [sym.imp.WS2_32.dll_htonl]
cmp eax, ebp
jne 0x14008f7d9
lea rdx, [rsp + 0x20]
mov r8d, ebp
sub rdx, rdi
lea rcx, [rdi + 8]
mov al, byte [rdx + rcx - 8]
xor byte [rcx], al
inc rcx
sub r8, 1
jne 0x14008f7c8
jmp 0x14008f80a
lea r8, [rdi + 0x17]
mov rcx, rbx
mov rdx, r8
mov al, byte [rsp + rcx + 0x20]
xor al, byte [rdx]
dec rdx
mov byte [rsp + rcx + 0x30], al
inc rcx
cmp rcx, rbp
jl 0x14008f7e3
mov al, byte [rsp + rbx + 0x30]
inc rbx
mov byte [r8], al
dec r8
cmp rbx, rbp
jl 0x14008f7f8
lea r8, [rdi + 8]
mov r9, rbp
lea rcx, [rsi + 4]
mov rdx, rbp
call section..text
mov ebx, reloc.WS2_32.dll_sendto
jmp 0x14008f842
mov ecx, dword [rdi + 4]
call qword [sym.imp.WS2_32.dll_ntohl]
xor eax, 0x2112a442
mov ecx, eax
call qword [sym.imp.WS2_32.dll_htonl]
mov dword [rsi + 4], eax
mov ebx, 8
mov eax, ebx
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
add rsp, 0x50
pop r14
pop rdi
pop rsi
pop rbp
pop rbx
ret

Function at 0x140090124
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rdi
mov qword [rsp + 0x18], r14
xor r10d, r10d
mov r9d, r8d
mov r11, rdx
test rdx, rdx
je 0x1400901b3
or r8d, 0xffffffff
lea r14, [0x1402360f0]
cmp r9d, 8
jb 0x140090188
mov ebx, r9d
shr rbx, 3
mov edi, 8
movzx ecx, byte [r11]
mov eax, r8d
xor rcx, rax
inc r11
shr eax, 8
movzx edx, cl
mov r8d, dword [r14 + rdx*4]
xor r8d, eax
sub rdi, 1
jne 0x14009015e
add r9d, 0xfffffff8
sub rbx, 1
jne 0x140090159
test r9d, r9d
je 0x1400901ad
movzx ecx, byte [r11]
mov eax, r8d
xor rcx, rax
inc r11
shr eax, 8
movzx edx, cl
mov r8d, dword [r14 + rdx*4]
xor r8d, eax
add r9d, 0xffffffff
jne 0x14009018d
not r8d
mov r10d, r8d
mov rbx, qword [rsp + 8]
mov eax, r10d
mov rdi, qword [rsp + 0x10]
mov r14, qword [rsp + 0x18]
ret
Function at 0x14009228c
Capabilities:
Access firewall settings via inetfwmgr

Disassembly:
mov qword [rsp + 8], rcx
push rbp
push rbx
push rsi
push rdi
push r15
mov rbp, rsp
sub rsp, 0x40
xor ebx, ebx
lea rax, [rbp - 8]
and qword [rbp - 8], rbx
lea r9, [0x1402abba8]
and qword [rbp - 0x10], rbx
lea rcx, [0x1402abb88]
and qword [rbp + 0x48], rbx
mov rdi, rdx
and qword [rbp + 0x30], rbx
lea r15d, [rbx + 1]
and qword [rbp + 0x40], rbx
mov r8d, r15d
xor edx, edx
mov qword [rsp + 0x20], rax
xor esi, esi
call qword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
js 0x1400923cf
mov rcx, qword [rbp - 8]
lea rdx, [rbp - 0x10]
mov rax, qword [rcx]
call qword [rax + gethostname]
test eax, eax
js 0x1400923cf
mov rcx, qword [rbp - 0x10]
lea rdx, [rbp + 0x48]
mov rax, qword [rcx]
call qword [rax + gethostname]
test eax, eax
js 0x1400923cf
mov rcx, qword [rbp + 0x48]
lea rdx, [rbp + 0x40]
mov rax, qword [rcx]
call qword [rax + 0xa0]
test eax, eax
js 0x1400923cf
lea rax, [rbp + 0x30]
mov r8d, r15d
lea r9, [0x1402abbc8]
mov qword [rsp + 0x20], rax
xor edx, edx
lea rcx, [0x1402abb98]
call qword [sym.imp.ole32.dll_CoCreateInstance]
test eax, eax
js 0x1400923cf
mov rcx, rdi
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rdi, rax
test rax, rax
je 0x1400923cf
mov rcx, qword [rbp + 0x30]
mov rdx, rax
mov r8, qword [rcx]
call qword [r8 + 0x50]
test eax, eax
js 0x1400923b8
lea rcx, [0x1402abb38]
call qword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov rcx, rax
mov rbx, rax
call qword [sym.imp.OLEAUT32.dll_VariantInit]
test eax, eax
je 0x1400923b8
mov rcx, qword [rbp + 0x30]
mov rdx, rbx
mov r8, qword [rcx]
call qword [r8 + 0x40]
test eax, eax
js 0x1400923b8
mov rcx, qword [rbp + 0x40]
mov rdx, qword [rbp + 0x30]
mov rax, qword [rcx]
call qword [rax + 0x40]
test eax, eax
cmovns esi, r15d
mov rcx, rdi
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
test rbx, rbx
je 0x1400923cf
mov rcx, rbx
call qword [sym.imp.OLEAUT32.dll_SysStringLen]
mov rcx, qword [rbp + 0x30]
test rcx, rcx
je 0x1400923de
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov rcx, qword [rbp + 0x40]
test rcx, rcx
je 0x1400923ed
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov rcx, qword [rbp + 0x48]
test rcx, rcx
je 0x1400923fc
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_recv]
mov rcx, qword [rbp - 0x10]
test rcx, rcx
je 0x14009240b
mov rdx, qword [rcx]
call qword [rdx + reloc.WS2_32.dll_recv]
mov rcx, qword [rbp - 8]
test rcx, rcx
je 0x14009241a
mov rdx, qword [rcx]
call qword [rdx + reloc.WS2_32.dll_recv]
mov eax, esi
add rsp, 0x40
pop r15
pop rdi
pop rsi
pop rbx
pop rbp
ret
Function at 0x140092b38
Capabilities:
Get token membership

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x80
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rbp - 8], rax
and dword [rbp - 0x10], 0
lea rax, [rbp - 0x18]
mov qword [rsp + 0x50], rax
lea rcx, [rbp - 0x10]
and dword [rsp + 0x48], 0
mov r9d, 0x220
and dword [rsp + 0x40], 0
mov r8d, 0x20
and dword [rsp + 0x38], 0
mov dl, 2
and dword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
mov word [rbp - 0xc], 0x500
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov dword [rbp - 0x20], eax
test eax, eax
je 0x140092bc6
mov rdx, qword [rbp - 0x18]
lea r8, [rbp - 0x20]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
neg eax
sbb ecx, ecx
and dword [rbp - 0x20], ecx
mov rcx, qword [rbp - 0x18]
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [rbp - 0x20]
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.1401a5d00
add rsp, 0x80
pop rbp
ret

Function at 0x140092bdc
Capabilities:
Create process on windows

Disassembly:
push rbx
sub rsp, 0x210
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x200], rax
mov rbx, rcx
lea rdx, [rsp + 0x90]
xor ecx, ecx
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x140092c65
xor edx, edx
mov dword [rsp + 0x20], reloc.WS2_32.dll_WSASetLastError
lea rcx, [rsp + 0x24]
lea r8d, [rdx + 0x6c]
call fcn.1401a72b0
and qword [rsp + 0x28], 0
lea rax, str.runas
mov qword [rsp + 0x30], rax
lea rcx, [rsp + 0x20]
lea rax, [rsp + 0x90]
mov dword [rsp + 0x50], 1
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x40], rbx
call qword [sym.imp.SHELL32.dll_ShellExecuteExA]
jmp 0x140092c67
xor eax, eax
mov rcx, qword [rsp + 0x200]
xor rcx, rsp
call fcn.1401a5d00
add rsp, 0x210
pop rbx
ret
Function at 0x140093288
Capabilities:
Create service
Modify service
Persist via windows service

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push rbp
lea rbp, [rax - 0x3d8]
sub rsp, 0x4d0
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rbp + 0x3c0], rax
xor edx, edx
xor ecx, ecx
lea r8d, [rdx + 2]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
xor ebx, ebx
mov rdi, rax
test rax, rax
je 0x1400933ea
mov r8d, 0x400
lea rdx, [rbp - 0x40]
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x1400933e1
mov qword [rsp + 0x60], rbx
lea rax, [rbp - 0x40]
mov qword [rsp + 0x58], rbx
lea r8, str.Mesh_Agent_background_service
mov qword [rsp + 0x50], rbx
lea rdx, str.Mesh_Agent
mov qword [rsp + 0x48], rbx
mov r9d, 0xf01ff
mov qword [rsp + 0x40], rbx
mov rcx, rdi
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], ebx
mov dword [rsp + 0x28], 2
mov dword [rsp + 0x20], 0x110
call qword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov rsi, rax
test rax, rax
je 0x1400933e1
lea rax, str.Remote_monitoring_and_management_service.
mov rcx, rsi
lea r8, [rsp + 0x78]
mov qword [rsp + 0x78], rax
lea edx, [rbx + 1]
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
mov dword [rsp + 0x70], ebx
lea r8, [rsp + 0x70]
mov ebx, 3
mov rcx, rsi
mov edx, ebx
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
mov eax, 0xea60
mov dword [rbp - 0x58], 1
xor edx, edx
mov dword [rbp - 0x54], eax
lea r8d, [rbx + 0x25]
mov dword [rbp - 0x4c], eax
lea rcx, [rbp - 0x80]
mov dword [rbp - 0x44], eax
mov dword [rbp - 0x50], 1
mov dword [rbp - 0x48], 1
call fcn.1401a72b0
lea rax, [rbp - 0x58]
mov dword [rbp - 0x80], 0x15180
lea r8, [rbp - 0x80]
mov qword [rbp - 0x60], rax
lea edx, [rbx - 1]
mov dword [rbp - 0x68], ebx
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
mov rcx, rsi
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, ebx
mov rcx, qword [rbp + 0x3c0]
xor rcx, rsp
call fcn.1401a5d00
lea r11, [rsp + 0x4d0]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret
Function at 0x140093414
Capabilities:
Delete service
Query service status

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov rdi, rcx
xor ebx, ebx
xor edx, edx
xor ecx, ecx
lea r8d, [rbx + 1]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov rsi, rax
test rax, rax
je 0x1400934ab
mov r8d, 0x10004
mov rdx, rdi
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov rdi, rax
test rax, rax
je 0x1400934a2
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x140093499
cmp dword [rsp + 0x24], 1
jne 0x140093494
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
je 0x140093499
mov ebx, 1
jmp 0x140093499
mov ebx, 2
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, ebx
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
mov rbx, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x70]
add rsp, 0x50
pop rdi
ret

Function at 0x1400934cc
Capabilities:
Query service status

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
xor ebx, ebx
xor edx, edx
xor ecx, ecx
lea r8d, [rbx + 1]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov rdi, rax
test rax, rax
je 0x14009354c
lea r8d, [rbx + 4]
mov rcx, rax
lea rdx, str.Mesh_Agent
call qword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov rsi, rax
test rax, rax
je 0x14009353e
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
mov rcx, rsi
cmovne ebx, dword [rsp + 0x24]
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x140093543
mov ebx, 0x64
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, ebx
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
Function at 0x14009356c
Capabilities:
Query service status
Start service

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
xor ebx, ebx
xor edx, edx
xor ecx, ecx
lea edi, [rbx + 0x14]
mov r8d, edi
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov rsi, rax
test rax, rax
je 0x140093606
mov r8d, edi
lea rdx, str.Mesh_Agent
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov rdi, rax
test rax, rax
je 0x1400935fd
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x1400935f4
cmp dword [rsp + 0x24], 1
jne 0x1400935ef
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_StartServiceA]
cmp eax, 1
jne 0x1400935f4
mov ebx, eax
jmp 0x1400935f4
mov ebx, 2
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, ebx
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret

Function at 0x140093628
Capabilities:
Query service status
Stop service

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x50
mov rax, qword [0x1402ccee0]
xor rax, rsp
mov qword [rsp + 0x40], rax
xor ebx, ebx
xor edx, edx
xor ecx, ecx
lea edi, [rbx + 0x24]
mov r8d, edi
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov rsi, rax
test rax, rax
je 0x1400936cb
mov r8d, edi
lea rdx, str.Mesh_Agent
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov rdi, rax
test rax, rax
je 0x1400936c2
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
test eax, eax
je 0x1400936b9
cmp dword [rsp + 0x24], 1
je 0x1400936b9
lea r8, [rsp + 0x20]
mov rcx, rdi
lea edx, [rbx + 1]
call qword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x1400936b9
mov ecx, 0xbb8
call qword [sym.imp.KERNEL32.dll_Sleep]
mov ebx, 1
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, ebx
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1401a5d00
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
Function at 0x1400936ec
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
push rsi
push rdi
push r14
sub rsp, 0xe0
mov edi, 1
mov dword [rsp + 0x70], WSAGetLastError
mov ebp, edx
mov rbx, rcx
xor edx, edx
lea rcx, [rsp + 0x78]
lea r8d, [rdi + 0x5f]
lea esi, [rdi + 0x31]
call fcn.1401a72b0
lea rax, [rsp + 0x50]
xor r14d, r14d
mov qword [rsp + 0x48], rax
xor r9d, r9d
lea rax, [rsp + 0x70]
xor r8d, r8d
mov qword [rsp + 0x40], rax
mov rdx, rbx
mov qword [rsp + 0x38], r14
xor ecx, ecx
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], 0x8000000
mov dword [rsp + 0x20], edi
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x1400937bf
test ebp, ebp
je 0x1400937a7
mov ecx, 0x64
call qword [sym.imp.KERNEL32.dll_Sleep]
mov rcx, qword [rsp + 0x50]
lea rdx, [rsp + 0x110]
call qword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
cmp dword [rsp + 0x110], 0x103
mov edi, eax
cmove edi, r14d
test edi, edi
jne 0x1400937a7
mov ecx, esi
dec esi
test ecx, ecx
jg 0x14009376c
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
lea r11, [rsp + 0xe0]
mov rbx, qword [r11 + 0x20]
mov rbp, qword [r11 + 0x28]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret