joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14003173c
Capabilities:
Enumerate pe sections

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
movsxd r8, dword [0x14000003c]
lea rsi, [0x140000000]
add r8, rsi
mov rbx, rdx
mov rdi, rcx
cmp dword [r8 + 0x84], 0xd
jbe 0x1400317b4
mov r10d, dword [r8 + 0xf0]
xor r9d, r9d
test r10d, r10d
je 0x1400317b4
movzx ecx, word [r8 + 0x14]
movzx r11d, word [r8 + 6]
add rcx, 0x18
mov r10d, dword [r10 + rsi + 0xc]
add rcx, r8
test r11d, r11d
je 0x1400317b4
mov eax, dword [rcx + 0xc]
cmp r10d, eax
jb 0x1400317a8
mov edx, dword [rcx + 8]
add eax, edx
cmp r10d, eax
jb 0x1400317c6
inc r9d
add rcx, 0x28
cmp r9d, r11d
jb 0x140031796
xor eax, eax
mov rbx, qword [rsp + 8]
mov rsi, qword [rsp + 0x10]
mov rdi, qword [rsp + 0x18]
ret
mov dword [rdi], edx
mov eax, dword [rcx + 0x24]
mov dword [rbx], eax
mov eax, dword [rcx + 0xc]
add rax, rsi
jmp 0x1400317b6

Function at 0x140033300
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x14003334a
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x14003334a
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x14003334a
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x14003334a
cmp dword [rcx + 0x84], 0xe
jbe 0x14003334a
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x14003334c
xor al, al
add rsp, 0x28
ret

Function at 0x14003c094
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x14003bdf8

Function at 0x140045fb0
Capabilities:
Parse pe header

Disassembly:
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140045fd8
movsxd rdx, dword [rcx + 0x3c]
add rdx, rcx
cmp dword [rdx], 0x4550
jne 0x140045fd8
xor eax, eax
mov ecx, 0x20b
cmp word [rdx + 0x18], cx
sete al
ret
xor eax, eax
ret

Function at 0x140006878
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [0x140008090]
test rax, rax
je 0x1400068c2
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x1400068c2
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x1400068c2
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x1400068c2
cmp dword [rcx + 0x84], 0xe
jbe 0x1400068c2
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x1400068c4
xor al, al
add rsp, 0x28
ret
Function at 0x1403545c0
Capabilities:
Terminate process

Disassembly:
cld
pop r11
jmp 0x1403545cd
inc rsi
mov byte [rdi], dl
inc rdi
mov dl, byte [rsi]
add ebx, ebx
jne 0x1403545dd
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jb 0x1403545c5
lea eax, [rcx + 1]
jmp 0x1403545eb
dec eax
call r11
adc eax, eax
call r11
adc eax, eax
add ebx, ebx
jne 0x1403545fe
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
mov dl, byte [rsi]
jae 0x1403545e4
sub eax, 3
jb 0x14035461e
shl eax, 8
movzx edx, dl
or eax, edx
inc rsi
xor eax, 0xffffffff
je 0x14035466d
sar eax, 1
movsxd rbp, eax
jb 0x140354654
jmp 0x14035462c
add ebx, ebx
jne 0x14035462a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x140354654
inc ecx
add ebx, ebx
jne 0x14035463a
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jb 0x140354654
call r11
adc ecx, ecx
add ebx, ebx
jne 0x14035464d
mov ebx, dword [rsi]
sub rsi, 0xfffffffffffffffc
adc ebx, ebx
jae 0x14035463c
add ecx, 2
jmp 0x140354659
call r11
adc ecx, ecx
cmp rbp, 0xfffffffffffffb00
adc ecx, 2
call fcn.140354582
jmp 0x1403545cd
pop rsi
pop rdi
pop rax
mov dword [rdi], eax
mov rdi, rsi
push rsi
mov rdi, rsi
mov rsi, 0x216e00
mov dl, 0x1d
push rbx
push rdi
lea rcx, [rdi + rsi - 3]
pop rsi
push rsi
pop rbx
jmp 0x1403546bd
cmp rsi, rcx
jae 0x1403546c5
push rsi
pop rsi
lodsb al, byte [rsi]
cmp al, 0x80
jb 0x1403546a4
cmp al, 0x8f
ja 0x1403546a4
cmp byte [rsi - 2], 0xf
je 0x1403546aa
sub al, 0xe8
cmp al, 1
ja 0x14035468e
cmp rsi, rcx
jae 0x1403546c5
push rsi
lodsd eax, dword [rsi]
sub al, dl
jne 0x140354694
pop rdi
bswap eax
sub eax, edi
add eax, ebx
stosd dword [rdi], eax
cmp rsi, rcx
jae 0x1403546c5
lodsb al, byte [rsi]
jmp 0x1403546a4
pop rbx
pop rsi
sub rsp, 0x28
lea rdi, [rsi + 0x350000]
mov eax, dword [rdi]
or eax, eax
je 0x14035472e
mov ebx, dword [rdi + 4]
lea rcx, [rax + rsi + 0x36dc68]
add rbx, rsi
add rdi, 8
call qword [sym.imp.KERNEL32.DLL_LoadLibraryA]
xchg rbp, rax
mov al, byte [rdi]
inc rdi
or al, al
je 0x1403546d2
jns 0x140354707
movzx rdx, word [rdi]
add rdi, 2
jmp 0x140354711
mov rcx, rdi
mov rdx, rdi
dec eax
repne scasb al, byte [rdi]
mov rcx, rbp
call qword [sym.imp.KERNEL32.DLL_GetProcAddress]
or rax, rax
je 0x140354728
mov qword [rbx], rax
add rbx, 8
jmp 0x1403546f2
jmp qword [sym.imp.KERNEL32.DLL_ExitProcess]
add rsp, 0x28
add rdi, 4
lea rbx, [rsi - 4]
xor eax, eax
mov al, byte [rdi]
inc rdi
or eax, eax
je 0x140354772
cmp al, 0xef
ja 0x14035475a
add rbx, rax
mov rax, qword [rbx]
bswap rax
add rax, rsi
mov qword [rbx], rax
jmp 0x14035473a
and al, 0xf
shl eax, 0x10
mov ax, word [rdi]
add rdi, 2
or eax, eax
jne 0x140354749
mov eax, dword [rdi]
add rdi, 4
jmp 0x140354749
mov rbp, qword [sym.imp.KERNEL32.DLL_VirtualProtect]
lea rdi, [rsi - 0x1000]
mov ebx, 0x1000
push rax
mov r9, rsp
mov r8d, 4
mov rdx, rbx
mov rcx, rdi
sub rsp, 0x20
call rbp
lea rax, [rdi + 0x277]
and byte [rax], 0x7f
and byte [rax + 0x28], 0x7f
lea r9, [rsp + 0x20]
mov r8, qword [r9]
mov rdx, rbx
mov rcx, rdi
call rbp
add rsp, 0x28
pop rbp
pop rdi
pop rsi
pop rbx
lea rax, [rsp - 0x80]
push 0
cmp rsp, rax
jne 0x1403547c6
sub rsp, 0xffffffffffffff80
jmp 0x14014eb04
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x004044f0]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x00404500]
mov dword [rax], 1
mov rax, qword [0x00404510]
mov dword [rax], 1
mov rax, qword [0x004044e0]
mov dword [rax], 1
mov rax, qword [0x004043d0]
cmp word [rax], 0x5a4d
jne 0x401067
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x4010c0
mov rax, qword [0x004044d0]
mov dword [0x0040700c], ecx
mov eax, dword [rax]
test eax, eax
jne 0x4010b0
mov ecx, 1
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x00404490]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x00404380]
cmp dword [rax], 1
je 0x4010f0
xor eax, eax
add rsp, 0x28
ret
mov ecx, 2
call sym.__set_app_type
jmp 0x401084
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x401108
cmp dx, 0x20b
jne 0x401067
cmp dword [rax + 0x84], 0xe
jbe 0x401067
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x401067
lea rcx, [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401067
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x401067

Function at 0x401a70
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call dbg.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call dbg.__acrt_iob_func
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sym.vfprintf
call sym.abort
nop
nop word [rax + rax]
Function at 0x401ae0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x00407614]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x401c88
mov rax, qword [0x00407618]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x401b2c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x401bb7
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x401b10
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
je 0x401cc2
mov rax, qword [0x00407618]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call dbg._GetPEImageBase
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x00407618]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x401cd1
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x401bb0
sub eax, 4
and eax, 0xfffffffb
jne 0x401c40
add dword [0x00407614], 1
cmp ebx, 8
jae 0x401be8
test bl, 4
jne 0x401c90
test ebx, ebx
je 0x401bd9
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x401cb0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x401bd9
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x401c1a
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
add rdi, qword [0x00407618]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x401bb0
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
nop dword [rax]
xor edi, edi
jmp 0x401b37
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x401bd9
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x401bd9
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
mov rax, qword [0x00407618]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call dbg.__report_error
nop
nop dword [rax]
Function at 0x4024b0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00407900]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x004078e0]
test rbx, rbx
je 0x402504
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x4024fb
test r12, r12
je 0x4024fb
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x4024e0
lea rcx, [0x00407900]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x402730
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
jne 0x402740
jmp sym._ValidateImageBase.part.0
xor eax, eax
ret

Function at 0x402750
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x402795
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x40278c
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x402797
add rax, 0x28
cmp rax, r9
jne 0x402778
xor eax, eax
ret

Function at 0x402840
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x004043d0]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x4028b9
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x4028b9
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x4028b6
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x4028ad
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x4028b9
add r8, 0x28
cmp r8, r9
jne 0x402898
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x4029a0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x004043d0]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x402a0f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402a0f
movsxd rax, dword [r9 + 0x3c]
mov rcx, r8
sub rcx, r9
add r9, rax
movzx eax, word [r9 + 0x14]
movzx edx, word [r9 + 6]
lea rax, [r9 + rax + 0x18]
test edx, edx
je 0x402a0d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x402a04
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x402a18
add rax, 0x28
cmp rax, r9
jne 0x4029f0
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x402a30
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x004043d0]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x402aa8
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402aa8
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x402aa8
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x402aa8
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x402a9c
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x402ab0
add rdx, 0x28
cmp rdx, r10
jne 0x402a88
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x402ac0
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x402ace
mov edx, dword [rax + 0xc]
test edx, edx
je 0x402aa5
test r8d, r8d
jg 0x402ab8
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret
Function at 0x140001350
Capabilities:
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r15
sub rsp, 0x30
mov rax, qword gs:[0x30]
mov rbx, qword [rax + 8]
xor esi, esi
xor eax, eax
lock cmpxchg qword [0x140003638], rbx
je 0x14000139c
cmp rax, rbx
jne 0x14000138f
mov ebx, 1
mov esi, ebx
jmp 0x1400013a1
mov ecx, 0x3e8
call qword [sym.imp.api_ms_win_core_synch_l1_2_0.dll_Sleep]
jmp 0x140001374
mov ebx, 1
mov eax, dword [0x140003640]
cmp eax, ebx
jne 0x1400013b7
mov ecx, 0x1f
call sub.msvcrt.dll__amsg_exit
jmp 0x14000141c
mov eax, dword [0x140003640]
test eax, eax
jne 0x140001416
mov dword [0x140003640], ebx
lea r15, [0x1400022d8]
lea rdi, [0x1400022c0]
mov qword [rsp + 0x28], rdi
mov dword [rsp + 0x20], eax
cmp rdi, r15
jae 0x140001408
test eax, eax
jne 0x14000140c
cmp qword [rdi], 0
je 0x1400013fd
mov rax, qword [rdi]
mov rcx, qword [0x1400022a0]
call rcx
mov dword [rsp + 0x20], eax
add rdi, 8
mov qword [rsp + 0x28], rdi
jmp 0x1400013de
test eax, eax
je 0x14000141c
mov eax, 0xff
jmp 0x1400014f8
mov dword [0x140003044], ebx
mov eax, dword [0x140003640]
cmp eax, ebx
jne 0x140001443
lea rdx, [0x1400022b8]
lea rcx, [0x1400022a8]
call sub.msvcrt.dll__initterm
mov dword [0x140003640], 2
test esi, esi
jne 0x140001450
xor eax, eax
xchg qword [0x140003638], rax
cmp qword [0x140003648], 0
je 0x140001484
lea rcx, [0x140003648]
call fcn.140001700
test eax, eax
je 0x140001484
xor r8d, r8d
lea edx, [r8 + 2]
xor ecx, ecx
mov rax, qword [0x140003648]
mov r9, qword [0x1400022a0]
call r9
mov r8, qword [0x140003058]
mov rdx, qword [0x140003050]
mov ecx, dword [0x140003048]
call fcn.1400011ec
mov dword [0x140003040], eax
cmp dword [0x140003060], 0
jne 0x1400014b4
mov ecx, eax
call qword [sym.imp.msvcrt.dll_exit]
cmp dword [0x140003044], 0
jne 0x1400014c9
call qword [sym.imp.msvcrt.dll__cexit]
mov eax, dword [0x140003040]
jmp 0x1400014f8
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
mov rdi, qword [rsp + 0x50]
add rsp, 0x30
pop r15
ret
sub rsp, 0x28
call fcn.140164000
add rsp, 0x28
jmp 0x140001350

Function at 0x1400015ec
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x18
xor edx, edx
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x140001638
mov eax, 0x5a4d
cmp word [rcx], ax
jne 0x140001630
cmp dword [rcx + 0x3c], edx
jl 0x140001630
cmp dword [rcx + 0x3c], 0x10000000
jae 0x140001630
movsxd rax, dword [rcx + 0x3c]
add rax, rcx
mov qword [rsp], rax
cmp dword [rax], 0x4550
cmovne rax, rdx
mov rdx, rax
mov qword [rsp], rax
jmp 0x140001638
mov rax, rdx
add rsp, 0x18
ret
Function at 0x1400014c0
Capabilities:
Get session user name

Disassembly:
mov dword [rsp + 8], ecx
sub rsp, 0x38
call sub.kernel32.dll_GetProcessHeap
mov r8d, 0x104
mov edx, 8
mov rcx, rax
call sub.kernel32.dll_HeapAlloc
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0x104
cmp qword [rsp + 0x28], 0
jne 0x1400014f9
xor eax, eax
jmp 0x14000153a
lea r8, [rsp + 0x20]
mov rdx, qword [rsp + 0x28]
mov ecx, dword [rsp + 0x40]
call sub.secur32.dll_GetUserNameExW
movzx eax, al
test eax, eax
je 0x140001524
mov rcx, qword [rsp + 0x28]
call sub.user32.dll_CharLowerW
mov rax, qword [rsp + 0x28]
jmp 0x14000153a
call sub.kernel32.dll_GetProcessHeap
mov r8, qword [rsp + 0x28]
xor edx, edx
mov rcx, rax
call sub.kernel32.dll_HeapFree
xor eax, eax
add rsp, 0x38
ret

Function at 0x1400042c0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x38
mov dword [0x140008b34], 1
mov dword [0x140008b38], 1
mov dword [0x140008b3c], 1
mov dword [0x140008b48], 1
lea rax, [0x140000000]
mov qword [rsp + 0x18], rax
mov rax, qword [rsp + 0x18]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x14000430e
xor eax, eax
jmp 0x1400043ef
mov rax, qword [rsp + 0x18]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rsp + 0x18]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x20], rax
mov rax, qword [rsp + 0x20]
cmp dword [rax], 0x4550
je 0x14000433b
xor eax, eax
jmp 0x1400043ef
mov rax, qword [rsp + 0x20]
add rax, 0x18
mov qword [rsp + 0x10], rax
mov rax, qword [rsp + 0x10]
movzx eax, word [rax]
mov dword [rsp], eax
cmp dword [rsp], 0x10b
je 0x14000436b
cmp dword [rsp], 0x20b
je 0x1400043a7
jmp 0x1400043ed
mov rax, qword [rsp + 0x10]
cmp dword [rax + 0x5c], 0xe
ja 0x14000437a
xor eax, eax
jmp 0x1400043ef
mov eax, 8
imul rax, rax, 0xe
mov rcx, qword [rsp + 0x10]
cmp dword [rcx + rax + 0x60], 0
je 0x140004399
mov dword [rsp + 4], 1
jmp 0x1400043a1
mov dword [rsp + 4], 0
mov eax, dword [rsp + 4]
jmp 0x1400043ef
mov rax, qword [rsp + 0x10]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x28]
cmp dword [rax + 0x6c], 0xe
ja 0x1400043c0
xor eax, eax
jmp 0x1400043ef
mov eax, 8
imul rax, rax, 0xe
mov rcx, qword [rsp + 0x28]
cmp dword [rcx + rax + 0x70], 0
je 0x1400043df
mov dword [rsp + 8], 1
jmp 0x1400043e7
mov dword [rsp + 8], 0
mov eax, dword [rsp + 8]
jmp 0x1400043ef
xor eax, eax
add rsp, 0x38
ret

Function at 0x140005000
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x38
mov eax, dword [0x140008b78]
test eax, eax
jne 0x140005010
jmp 0x14000507e
lea rcx, [0x140008b50]
call sub.kernel32.dll_EnterCriticalSection
mov rax, qword [0x140008b80]
mov qword [rsp + 0x20], rax
cmp qword [rsp + 0x20], 0
je 0x140005072
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax]
call sub.kernel32.dll_TlsGetValue
mov qword [rsp + 0x28], rax
call sub.kernel32.dll_GetLastError
test eax, eax
jne 0x140005062
cmp qword [rsp + 0x28], 0
je 0x140005062
mov rax, qword [rsp + 0x20]
mov rax, qword [rax + 8]
mov rcx, qword [rsp + 0x28]
call rax
mov rax, qword [rsp + 0x20]
mov rax, qword [rax + 0x10]
mov qword [rsp + 0x20], rax
jmp 0x140005028
lea rcx, [0x140008b50]
call sub.kernel32.dll_LeaveCriticalSection
add rsp, 0x38
ret
Function at 0x1400022c0
Capabilities:
Write file on windows

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
mov ecx, 2
call fcn.140057660
lea rcx, str.Main_Usage:_n
mov edx, 0xc
mov r8d, 1
mov r9, rax
call fcn.14005f3f0
xor ebx, ebx
lea r14, str._gen__old_in___new_in___patch_out_
lea rsi, str.__courgette__s_n
mov rdi, qword [rbx + r14]
mov ecx, 2
call fcn.140057660
mov rcx, rax
mov rdx, rsi
mov r8, rdi
call fcn.140002250
add rbx, 8
cmp rbx, 0x20
jne 0x1400022fd
mov ecx, 2
call fcn.140057660
lea rcx, str.Diagnosis_Usage:_n
mov edx, 0x11
mov r8d, 1
mov r9, rax
call fcn.14005f3f0
xor ebx, ebx
lea r14, str._supported__exec_file_in_
lea rsi, str.__courgette__s_n
mov rdi, qword [rbx + r14]
mov ecx, 2
call fcn.140057660
mov rcx, rax
mov rdx, rsi
mov r8, rdi
call fcn.140002250
add rbx, 8
cmp rbx, 0x28
jne 0x140002357
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret

Function at 0x14000d690
Capabilities:
Accept command line arguments

Disassembly:
push rsi
push rdi
push rbx
sub rsp, 0x60
movdqa xmmword [rsp + 0x50], xmm6
mov rax, qword [0x140091028]
xor rax, rsp
mov qword [rsp + 0x48], rax
cmp qword [0x140091df8], 0
je 0x14000d6bd
xor esi, esi
jmp 0x14000d7de
mov ecx, 0x30
call fcn.140051f60
mov rsi, rax
mov ecx, 0x20
call fcn.140051f60
mov qword [rsi], rax
lea rcx, [rax + 0x20]
mov qword [rsi + 0x10], rcx
mov edx, 7
movq xmm6, rdx
pslldq xmm6, 8
movdqu xmmword [rax + 0x10], xmm6
mov word [rax], 0
mov qword [rsi + 8], rcx
mov qword [rsi + 0x20], 0
mov ecx, 0x60
call fcn.140051f60
mov qword [rax], rax
mov qword [rax + 8], rax
mov qword [rax + 0x10], rax
mov word [rax + 0x18], 0x101
mov qword [rsi + 0x18], rax
mov qword [rsi + 0x28], 1
mov qword [0x140091df8], rsi
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
mov rdi, rax
movdqu xmmword [rsp + 0x38], xmm6
mov word [rsp + 0x28], 0
mov rcx, rax
call fcn.140063970
mov rbx, rax
cmp rax, 7
jbe 0x14000d76b
lea rcx, [rsp + 0x28]
mov rdx, rbx
mov r9, rdi
call fcn.14000f850
jmp 0x14000d78a
mov qword [rsp + 0x38], rbx
mov r8, rbx
add r8, rbx
lea rcx, [rsp + 0x28]
mov rdx, rdi
call fcn.140056460
mov word [rsp + rbx*2 + 0x28], 0
lea rdx, [rsp + 0x28]
mov rcx, rsi
call fcn.14000d810
mov rax, qword [rsp + 0x40]
cmp rax, 8
jb 0x14000d7db
mov rcx, qword [rsp + 0x28]
lea rdx, [rax + rax]
add rdx, 2
cmp rdx, 0x1000
jb 0x14000d7d6
mov rdx, rcx
add rdx, 0xfffffffffffffff8
mov rcx, qword [rcx - 8]
sub rdx, rcx
cmp rdx, 0x20
jae 0x14000d7fa
add rax, rax
add rax, 0x29
mov rdx, rax
call fcn.140051fb0
mov sil, 1
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.140051fd0
mov eax, esi
movaps xmm6, xmmword [rsp + 0x50]
add rsp, 0x60
pop rbx
pop rdi
pop rsi
ret
call fcn.14005ca40
ud2
Function at 0x14000d810
Capabilities:
Accept command line arguments

Disassembly:
push rsi
push rdi
sub rsp, 0x58
mov rax, rdx
mov rsi, rcx
mov rcx, qword [0x140091028]
xor rcx, rsp
mov qword [rsp + 0x50], rcx
mov ecx, 7
movq xmm0, rcx
pslldq xmm0, 8
movdqu xmmword [rsp + 0x40], xmm0
mov word [rsp + 0x30], 0
lea rdi, [rsp + 0x30]
mov edx, 3
mov rcx, rax
mov r8, rdi
call fcn.140024890
cmp qword [rsp + 0x40], 0
je 0x14000d8a2
mov dword [rsp + 0x2c], 0
cmp qword [rsp + 0x48], 7
jbe 0x14000d879
mov rdi, qword [rsp + 0x30]
lea rdx, [rsp + 0x2c]
mov rcx, rdi
call qword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov rdi, rax
mov edx, dword [rsp + 0x2c]
mov rcx, rsi
mov r8, rax
call fcn.14000d380
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rax, qword [rsp + 0x48]
cmp rax, 8
jb 0x14000d8e6
mov rcx, qword [rsp + 0x30]
lea rdx, [rax + rax]
add rdx, 2
cmp rdx, 0x1000
jb 0x14000d8e1
mov rdx, rcx
add rdx, 0xfffffffffffffff8
mov rcx, qword [rcx - 8]
sub rdx, rcx
cmp rdx, 0x20
jae 0x14000d8fb
add rax, rax
add rax, 0x29
mov rdx, rax
call fcn.140051fb0
mov rcx, qword [rsp + 0x50]
xor rcx, rsp
call fcn.140051fd0
nop
add rsp, 0x58
pop rdi
pop rsi
ret
call fcn.14005ca40
ud2