joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1403629b0
Capabilities:
Log keystrokes via polling

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x40
mov r14, rcx
xor ebx, ebx
call qword [sym.imp.USER32.dll_GetFocus]
lea rdx, str.PB_WindowID
mov rcx, r14
xor ebp, ebp
mov rdi, rax
call qword [sym.imp.USER32.dll_GetPropW]
mov rsi, rax
lea eax, [rbx + 9]
test rsi, rsi
je 0x140362a72
lea rdx, [rsp + 0x68]
mov rcx, r14
call qword [sym.imp.USER32.dll_GetWindowThreadProcessId]
test eax, eax
je 0x140362bb3
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [rsp + 0x68], eax
jne 0x140362bb3
mov rcx, qword [0x1403764c0]
lea rdx, [rsi - 1]
call fcn.14036b17c
mov ebp, 1
cmp dword [rax + 0x20], 0
mov rbx, rax
jle 0x140362bb3
mov rax, qword [rax + 8]
movsxd r8, dword [rbx + 0x20]
xor edx, edx
xor ecx, ecx
lea r10d, [rbp + 8]
cmp word [rcx + rax + 2], r10w
jne 0x140362a63
mov r9d, 0xfa01
cmp word [rcx + rax + 4], r9w
je 0x140362bac
inc rdx
add rcx, 6
cmp rdx, r8
jl 0x140362a49
mov eax, r10d
mov sil, pe_nt_image_headers64
test rdi, rdi
je 0x140362b45
mov ecx, eax
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
je 0x140362b45
mov ecx, 0x11
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
jne 0x140362b45
mov ecx, 0x10
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
jne 0x140362b45
mov ecx, 0x12
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
jne 0x140362b45
lea rdx, [rsp + 0x20]
mov r8d, 0x10
mov rcx, rdi
call qword [sym.imp.USER32.dll_GetClassNameW]
test ebp, ebp
jne 0x140362b45
lea r8d, [rbp + 5]
lea rdx, str.RichE
lea rcx, [rsp + 0x20]
call sub.msvcrt.dll_wcsncmp
test eax, eax
je 0x140362b11
lea r8d, [rbp + 4]
lea rdx, str.RICHE
lea rcx, [rsp + 0x20]
call sub.msvcrt.dll_wcsncmp
test eax, eax
jne 0x140362b30
xor r9d, r9d
xor r8d, r8d
mov edx, 0x44e
mov rcx, rdi
call qword [sym.imp.USER32.dll_SendMessageW]
bt rax, 0xb
jae 0x140362bbd
lea rdx, str.Scintilla
lea rcx, [rsp + 0x20]
call sub.msvcrt.dll_wcscmp
test eax, eax
je 0x140362bbd
test r14, r14
je 0x140362b87
mov ecx, 0x11
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
jne 0x140362b7a
mov ecx, 0x10
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
jne 0x140362b7a
mov ecx, 0x12
call qword [sym.imp.USER32.dll_GetKeyState]
test sil, al
je 0x140362b87
mov edx, 1
mov rcx, r14
call fcn.140362bd4
test rdi, rdi
je 0x140362ba1
lea rdx, str.PB_Hotkey
mov rcx, rdi
call qword [sym.imp.USER32.dll_GetPropW]
test rax, rax
jne 0x140362bbd
test rbx, rbx
je 0x140362bbd
mov rax, qword [rbx + 0x10]
jmp 0x140362bbf
xor ebp, ebp
jmp 0x140362a6f
mov eax, 9
jmp 0x140362a72
xor eax, eax
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x70]
add rsp, 0x40
pop r14
pop rdi
pop rsi
ret
Function at 0x140369870
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rbx, rcx
mov esi, 0x40
mov ecx, esi
call fcn.14036c300
mov rdx, rbx
mov rcx, rax
mov rdi, rax
call fcn.14036cd64
or rdx, 0xffffffffffffffff
inc rdx
cmp word [rdi + rdx*2], 0
jne 0x1403698a0
sub esi, edx
mov ecx, esi
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
jmp 0x14036c440
mov dword [rsp + 8], ecx
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x20], rax
mov eax, dword [rsp + 0x40]
shl eax, 1
cdqe
mov rcx, qword [rsp + 0x20]
mov rcx, qword [rcx + 0x10]
sub rcx, rax
mov rax, rcx
mov rcx, qword [rsp + 0x20]
mov qword [rcx + 0x10], rax
add rsp, 0x38
ret

Function at 0x140369bd8
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140376860], eax
add rsp, 0x28
ret

Function at 0x14036af40
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rsi, rcx
mov ecx, dword [0x1403761b0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x14036afc1
mov r8, qword [0x1403761a8]
mov rcx, qword [0x140375dc8]
lea edx, [rax + 8]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x1403761b0]
mov rdx, rax
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rbx, qword [0x1403761a0]
jmp 0x14036afad
mov rdx, qword [rbx + 0x18]
test rdx, rdx
je 0x14036afaa
mov rcx, qword [rbx + 0x10]
add rcx, rdi
call rdx
mov rbx, qword [rbx]
test rbx, rbx
jne 0x14036af98
lea rcx, [0x14036aea4]
mov rdx, rdi
call fcn.14036cf04
mov rbx, qword [rsp + 0x30]
lea rax, [rdi + rsi]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
Function at 0x14036afd8
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
mov ebx, ecx
mov rbp, r8
mov rdi, rdx
and ecx, 7
je 0x14036b002
mov eax, 8
sub eax, ecx
add ebx, eax
mov rcx, qword [0x1403761a8]
test rcx, rcx
jne 0x14036b045
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov rcx, qword [0x140375dc8]
movsxd r8, ebx
mov edx, 8
mov dword [0x1403761b0], eax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x1403761b0]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [0x1403761a8]
mov rsi, rcx
movsxd rax, ebx
add rcx, rax
mov qword [0x1403761a8], rcx
mov ecx, dword [0x1403761b0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r9, qword [0x1403761a8]
mov rcx, qword [0x140375dc8]
mov r8, rax
mov edx, 8
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov ecx, dword [0x1403761b0]
mov rdx, rax
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test rdi, rdi
jne 0x14036b099
test rbp, rbp
je 0x14036b0c0
lea rcx, [0x1403761a0]
mov edx, 0x28
call fcn.14036bc60
mov qword [rax], rsi
mov qword [rax + 8], rdi
mov qword [rax + 0x10], rbp
test rdi, rdi
je 0x14036b0c0
lea rcx, [rbx + rsi]
call rdi
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rax, rsi
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

Function at 0x14036bcc8
Capabilities:
Set console window title

Disassembly:
mov edx, 2
jmp 0x14036bcc8
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
cmp dword [0x140371022], 0
mov edi, edx
mov rbx, rcx
jne 0x14036bce6
call qword [sym.imp.KERNEL32.dll_AllocConsole]
mov ecx, 0xfffffff6
mov dword [0x140374648], edi
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ecx, 0xfffffff5
mov qword [0x140376980], rax
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ecx, 0xfffffff4
mov qword [0x1403769a0], rax
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov rcx, qword [0x1403769a0]
lea rdx, [0x1403769c0]
mov qword [0x1403769e0], rax
call qword [sym.imp.KERNEL32.dll_GetConsoleScreenBufferInfo]
mov edi, 1
lea rcx, [0x14036bca4]
mov edx, edi
call qword [sym.imp.KERNEL32.dll_SetConsoleCtrlHandler]
test rbx, rbx
je 0x14036bd58
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_SetConsoleTitleW]
lea rcx, [0x140376a00]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [0x140376a40]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov rbx, qword [rsp + 0x30]
mov rax, rdi
add rsp, 0x20
pop rdi
ret
Function at 0x14036bdf0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
xor edi, edi
mov esi, r8d
mov rbx, rdx
mov rbp, rcx
test r9d, r9d
je 0x14036be67
mov rcx, qword [0x140375dc8]
add esi, 2
xor edx, edx
lea eax, [rsi + 1]
movsxd r8, eax
add r8, r8
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
test rax, rax
je 0x14036be67
mov rcx, rax
test rbx, rbx
je 0x14036be58
mov rdx, rbx
call sub.msvcrt.dll_wcscpy
lea rdx, [0x14036f354]
mov rcx, rdi
call sub.msvcrt.dll_wcscat
jmp 0x14036be64
lea rdx, [0x14036f354]
call sub.msvcrt.dll_wcscpy
mov rbx, rdi
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x58]
mov r8d, esi
mov rdx, rbx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_WriteConsoleW]
test eax, eax
jne 0x14036bef1
mov eax, dword [0x140374648]
cmp eax, 2
je 0x14036bebc
cmp eax, 0x18
je 0x14036beb2
and qword [rsp + 0x20], 0
lea r8d, [rsi + rsi]
lea r9, [rsp + 0x58]
mov rdx, rbx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x14036bef1
mov rcx, rbx
call fcn.14036d200
jmp 0x14036bec4
mov rcx, rbx
call fcn.14036d2e0
mov rcx, rax
mov rbx, rax
call sub.msvcrt.dll_strlen
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x58]
mov r8, rax
mov rdx, rbx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, rbx
call fcn.14036d1f0
test rdi, rdi
je 0x14036bf08
mov rcx, qword [0x140375dc8]
mov r8, rdi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x14036bf20
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
xor r8d, r8d
mov edx, 0x1000
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x140376a80], rax
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x14037464c], eax
call fcn.14036c520
add rsp, 0x28
ret

Function at 0x14036bf90
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x48
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x20], eax
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 0x10]
mov qword [rsp + 0x30], rax
mov ecx, dword [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, qword [rsp + 0x30]
add rsp, 0x48
ret
Function at 0x14036c040
Capabilities:
Get thread local storage value

Disassembly:
mov dword [rsp + 0x10], edx
mov qword [rsp + 8], rcx
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x28], rax
movsxd rax, dword [rsp + 0x48]
mov rcx, qword [rsp + 0x28]
mov rcx, qword [rcx + 0x10]
sub rcx, rax
mov rax, rcx
mov dword [rsp + 0x20], eax
mov rax, qword [rsp + 0x40]
cmp qword [rax], 0
jne 0x14036c0a6
movsxd rax, dword [rsp + 0x20]
add rax, 0xa
mov r8, rax
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rcx, qword [rsp + 0x40]
mov qword [rcx], rax
jmp 0x14036c0d1
movsxd rax, dword [rsp + 0x20]
add rax, 0xa
mov r9, rax
mov rax, qword [rsp + 0x40]
mov r8, qword [rax]
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rcx, qword [rsp + 0x40]
mov qword [rcx], rax
movsxd rax, dword [rsp + 0x20]
xor edx, edx
mov ecx, 2
div rcx
movsxd rcx, dword [rsp + 0x48]
mov rdx, qword [rsp + 0x28]
add rcx, qword [rdx]
mov r8d, eax
mov rdx, rcx
mov rax, qword [rsp + 0x40]
mov rcx, qword [rax]
call fcn.14036c5f0
movsxd rax, dword [rsp + 0x48]
mov rcx, qword [rsp + 0x28]
mov qword [rcx + 0x10], rax
add rsp, 0x38
ret

Function at 0x14036c190
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x20]
mov rax, qword [rax + 0x10]
add rax, 2
mov rcx, qword [rsp + 0x20]
mov qword [rcx + 0x10], rax
add rsp, 0x38
ret

Function at 0x14036c210
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x28
cmp dword [0x14037464c], 0xffffffff
jne 0x14036c23f
call fcn.14036bf20
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdx, rax
lea rcx, [0x14036c1c0]
call fcn.14036cf04
jmp 0x14036c270
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
test rax, rax
jne 0x14036c270
call fcn.14036c520
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdx, rax
lea rcx, [0x14036c1c0]
call fcn.14036cf04
add rsp, 0x28
ret
Function at 0x14036c300
Capabilities:
Get thread local storage value

Disassembly:
mov dword [rsp + 0x10], edx
mov dword [rsp + 8], ecx
sub rsp, 0x48
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x28], rax
cmp dword [rsp + 0x58], 0xffffffff
jne 0x14036c330
mov rax, qword [rsp + 0x28]
mov eax, dword [rax + 0x10]
mov dword [rsp + 0x58], eax
movsxd rax, dword [rsp + 0x50]
mov rcx, qword [rsp + 0x28]
mov rcx, qword [rcx + 0x10]
lea rax, [rcx + rax*2]
mov dword [rsp + 0x20], eax
movsxd rax, dword [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov rcx, qword [rcx + 8]
sub rcx, 4
cmp rax, rcx
jl 0x14036c3a2
mov eax, dword [rsp + 0x20]
add eax, 0x4000
cdqe
mov rcx, qword [rsp + 0x28]
mov qword [rcx + 8], rax
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 8]
add rax, 0xa
mov r9, rax
mov rax, qword [rsp + 0x28]
mov r8, qword [rax]
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rcx, qword [rsp + 0x28]
mov qword [rcx], rax
jmp 0x14036c400
mov rax, qword [rsp + 0x28]
cmp qword [rax + 8], 0x100000
jle 0x14036c400
cmp dword [rsp + 0x20], 0x100000
jge 0x14036c3c3
mov dword [rsp + 0x20], 0x100000
movsxd rax, dword [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov qword [rcx + 8], rax
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 8]
add rax, 0xa
mov r9, rax
mov rax, qword [rsp + 0x28]
mov r8, qword [rax]
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rcx, qword [rsp + 0x28]
mov qword [rcx], rax
movsxd rax, dword [rsp + 0x58]
mov rcx, qword [rsp + 0x28]
add rax, qword [rcx]
mov qword [rsp + 0x30], rax
movsxd rax, dword [rsp + 0x58]
movsxd rcx, dword [rsp + 0x50]
lea rax, [rax + rcx*2]
mov rcx, qword [rsp + 0x28]
mov qword [rcx + 0x10], rax
mov rax, qword [rsp + 0x30]
add rsp, 0x48
ret

Function at 0x14036c440
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rbx, rcx
mov esi, 0x40
mov ecx, esi
call fcn.14036c300
mov rdx, rbx
mov rcx, rax
mov rdi, rax
call fcn.14036cd64
or rdx, 0xffffffffffffffff
inc rdx
cmp word [rdi + rdx*2], 0
jne 0x1403698a0
sub esi, edx
mov ecx, esi
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
jmp 0x14036c440
mov dword [rsp + 8], ecx
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x20], rax
mov eax, dword [rsp + 0x40]
shl eax, 1
cdqe
mov rcx, qword [rsp + 0x20]
mov rcx, qword [rcx + 0x10]
sub rcx, rax
mov rax, rcx
mov rcx, qword [rsp + 0x20]
mov qword [rcx + 0x10], rax
add rsp, 0x38
ret
Function at 0x14036c480
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x20]
mov rax, qword [rax]
cmp qword [rsp + 0x40], rax
jb 0x14036c4db
mov rax, qword [rsp + 0x20]
mov rax, qword [rax]
mov rcx, qword [rsp + 0x20]
add rax, qword [rcx + 0x10]
cmp qword [rsp + 0x40], rax
ja 0x14036c4db
mov rax, qword [rsp + 0x20]
mov rax, qword [rax]
mov rcx, qword [rsp + 0x40]
sub rcx, rax
mov rax, rcx
inc rax
jmp 0x14036c4dd
xor eax, eax
add rsp, 0x38
ret

Function at 0x14036c4f0
Capabilities:
Get thread local storage value

Disassembly:
mov dword [rsp + 8], ecx
sub rsp, 0x38
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x20], rax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0x20]
mov rcx, qword [rcx]
lea rax, [rcx + rax - 1]
add rsp, 0x38
ret

Function at 0x14036c520
Capabilities:
Set thread local storage value

Disassembly:
sub rsp, 0x38
mov r8d, 0x18
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rsp + 0x20], rax
mov r8d, 0x10
xor edx, edx
mov rcx, qword [0x140376a80]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rcx, qword [rsp + 0x20]
mov qword [rcx], rax
mov rax, qword [rsp + 0x20]
mov qword [rax + 8], 0x10
mov rax, qword [rsp + 0x20]
mov qword [rax + 0x10], 0
mov rdx, qword [rsp + 0x20]
mov ecx, dword [0x14037464c]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
add rsp, 0x38
ret
Function at 0x14036cf04
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x40
cmp dword [0x140376270], 0
mov r14, rdx
mov r15, rcx
lea rbx, [0x140376280]
jne 0x14036cf51
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov rcx, rbx
mov dword [0x1403762a8], eax
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov dword [0x140376270], 1
mov ecx, dword [0x1403762a8]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbp, rax
test rax, rax
jne 0x14036d026
mov rcx, qword [0x140375dc8]
lea edx, [rax + 8]
lea r8d, [rax + 0x28]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rbp, rax
test rax, rax
je 0x14036d051
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x140376278]
test rax, rax
je 0x14036cfa1
mov qword [rax], rbp
mov rcx, rbx
mov qword [rbp + 8], rax
mov qword [0x140376278], rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
and dword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
lea r9, [rbp + 0x20]
mov r8, rdi
mov rcx, rax
mov rdx, rbx
mov dword [rsp + 0x20], 0x100000
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov rdx, qword [rbp + 0x20]
lea rcx, [rbp + 0x18]
lea r8, [0x14036d06c]
mov r9, rbp
mov dword [rsp + 0x28], 8
or dword [rsp + 0x20], 0xffffffff
call qword [sym.imp.KERNEL32.dll_RegisterWaitForSingleObject]
mov ecx, dword [0x1403762a8]
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [0x140375dc8]
xor edx, edx
lea r8d, [rdx + 0x18]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
test rax, rax
je 0x14036d051
mov qword [rax + 8], r15
mov qword [rax + 0x10], r14
mov rcx, qword [rbp + 0x10]
mov qword [rax], rcx
mov qword [rbp + 0x10], rax
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x70]
add rsp, 0x40
pop r15
pop r14
pop rdi
ret
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x004075f0]
xor edx, edx
mov dword [rax], 1
mov rax, qword [0x00407600]
mov dword [rax], 1
mov rax, qword [0x00407610]
mov dword [rax], 1
mov rax, qword [0x004075e0]
mov dword [rax], 1
mov rax, qword [0x004074d0]
cmp word [rax], 0x5a4d
je 0x4010b0
mov rax, qword [0x004075d0]
mov dword [0x0040a008], edx
mov eax, dword [rax]
test eax, eax
je 0x4010a0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x00407590]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._setargv
mov rax, qword [0x00407460]
cmp dword [rax], 1
je 0x4010f0
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x401075
movsxd rcx, dword [rax + 0x3c]
add rax, rcx
cmp dword [rax], 0x4550
jne 0x401058
movzx ecx, word [rax + 0x18]
cmp cx, 0x10b
je 0x401103
cmp cx, 0x20b
jne 0x401058
cmp dword [rax + 0x84], 0xe
jbe 0x401058
mov ecx, dword [rax + 0xf8]
xor edx, edx
test ecx, ecx
setne dl
jmp 0x401058
lea rcx, [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401058
mov r8d, dword [rax + 0xe8]
xor edx, edx
test r8d, r8d
setne dl
jmp 0x401058

Function at 0x4015ce
Capabilities:
Log keystrokes via application hook

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x30
mov r9d, 0
mov r8d, 0
lea rdx, [sym.HookCallback_int__unsigned_long_long__long_long_]
mov ecx, 0xd
mov rax, qword [sym.imp.USER32.dll_SetWindowsHookExW]
call rax
mov qword [0x0040a040], rax
mov rax, qword [0x0040a040]
test rax, rax
sete al
test al, al
je 0x401647
lea rax, str.Failed_to_install_hook_
mov qword [rbp - 8], rax
lea rax, str.Error
mov qword [rbp - 0x10], rax
mov rdx, qword [rbp - 0x10]
mov rax, qword [rbp - 8]
mov r9d, 0x10
mov r8, rdx
mov rdx, rax
mov ecx, 0
mov rax, qword [sym.imp.USER32.dll_MessageBoxW]
call rax
nop
add rsp, 0x30
pop rbp
ret
Function at 0x401a59
Capabilities:
Hide graphical window

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x20
mov edx, 0
lea rcx, str.ConsoleWindowClass
mov rax, qword [sym.imp.USER32.dll_FindWindowA]
call rax
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.USER32.dll_ShowWindow]
call rax
nop
add rsp, 0x20
pop rbp
ret

Function at 0x4027d0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x0040a984]
test esi, esi
mov rbx, rcx
mov rbp, rdx
mov rdi, r8
jle 0x402958
mov rax, qword [0x0040a988]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp rbx, rdx
jb 0x40281c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp rbx, rdx
jb 0x4028a5
add ecx, 1
add rax, 0x28
cmp ecx, esi
jne 0x402800
mov rcx, rbx
call sym.__mingw_GetSectionForAddress
test rax, rax
mov r12, rax
je 0x40298d
mov rax, qword [0x0040a988]
lea rsi, [rsi + rsi*4]
shl rsi, 3
add rax, rsi
mov qword [rax + 0x20], r12
mov dword [rax], 0
call sym._GetPEImageBase
mov ecx, dword [r12 + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x0040a988]
mov qword [rax + rsi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x402970
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x40289e
sub eax, 0x40
and eax, 0xffffffbf
jne 0x402900
add dword [0x0040a984], 1
cmp edi, 8
jae 0x4028d3
test dil, 4
jne 0x402944
test edi, edi
je 0x4028c8
movzx eax, byte [rbp]
test dil, 2
mov byte [rbx], al
jne 0x40295f
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov eax, edi
sub edi, 1
mov rdx, qword [rbp + rax - 8]
cmp edi, 8
mov qword [rbx + rax - 8], rdx
jb 0x4028c8
and edi, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov rcx, qword [rbp + rdx]
cmp eax, edi
mov qword [rbx + rdx], rcx
jb 0x4028ec
jmp 0x4028c8
add rsi, qword [0x0040a988]
mov r8d, 0x40
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r9, rsi
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x40289e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
mov eax, dword [rbp]
mov edi, edi
mov dword [rbx], eax
mov eax, dword [rbp + rdi - 4]
mov dword [rbx + rdi - 4], eax
jmp 0x4028c8
xor esi, esi
jmp 0x402827
mov edi, edi
movzx eax, word [rbp + rdi - 2]
mov word [rbx + rdi - 2], ax
jmp 0x4028c8
mov rax, qword [0x0040a988]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [r12 + 8]
mov r8, qword [rax + rsi + 0x18]
call sym.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call sym.__report_error
nop
nop dword [rax]