joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x140029720]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x140029730]
mov dword [rax], 1
mov rax, qword [0x140029740]
mov dword [rax], 1
mov rax, qword [0x1400296c0]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x140029710]
mov dword [0x14002e020], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010b0
mov ecx, 2
call sym.__set_app_type
call dbg.__p__fmode
mov rdx, qword [0x140029820]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg.__p__commode
mov rdx, qword [0x140029800]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x140029670]
cmp dword [rax], 1
je 0x1400010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001110
cmp dx, 0x20b
jne 0x14000105a
cmp dword [rax + 0x84], 0xe
jbe 0x14000105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x14000105a
mov rcx, qword [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x14000105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x14000105a

Function at 0x140002820
Capabilities:
Write file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rbp, qword [dbg.__acrt_iob_func]
xor ebx, ebx
mov r12, rcx
mov rdi, rdx
test rdx, rdx
jle 0x140002862
nop
mov rsi, qword [r12 + rbx*8]
mov ecx, 1
add rbx, 1
call rbp
xor r8d, r8d
mov rcx, rax
mov rdx, rsi
call sym.writeWindows__systemZio_205
cmp rbx, rdi
jne 0x140002840
mov ecx, 1
call rbp
mov r8d, 1
mov edx, 1
lea rcx, [0x14002717c]
mov r9, rax
call sym.fwrite
mov ecx, 1
call rbp
mov rcx, rax
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp sym.fflush

Function at 0x1400029a0
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x28
xor r8d, r8d
mov rsi, rcx
mov rbx, rdx
test rdx, rdx
je 0x1400029bf
mov rcx, rdx
call sym.strlen
mov r8, rax
mov rcx, rbx
mov r9, rsi
mov edx, 1
call sym.fwrite
mov rcx, rsi
add rsp, 0x28
pop rbx
pop rsi
jmp sym.fflush

Function at 0x140002a70
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x20
mov ecx, 2
call qword [dbg.__acrt_iob_func]
mov r8d, 0x4b
mov edx, 1
lea rcx, str._GC__cannot_register_thread_local_variable__too_many_thread_local_variables
mov rbx, rax
mov r9, rax
call sym.fwrite
mov rcx, rbx
call sym.fflush
mov ecx, 1
call sym.exit
nop
Function at 0x14001bcc0
Capabilities:
Encode data using xor

Disassembly:
mov r10, rcx
mov r9, rdx
test rdx, rdx
je 0x14001bd1b
mov rcx, qword [rcx]
mov r8, qword [r10 + 8]
cmp rdx, 0xffffffffffffffff
je 0x14001bd20
mov rax, 0xffffffffffffffff
xor edx, edx
div r9
lea rax, [rcx + r8]
xor r8, rcx
ror rcx, 9
mov r11, r8
xor rcx, r8
ror r8, 0x1c
shl r11, 0xe
xor rcx, r11
mov r11, rdx
add r11, rax
jb 0x14001bce4
mov qword [r10], rcx
xor edx, edx
lea rcx, [r9 + 1]
div rcx
mov qword [r10 + 8], r8
mov r9, rdx
mov rax, r9
ret
lea r9, [rcx + r8]
xor r8, rcx
ror rcx, 9
mov rax, r8
xor rcx, r8
ror r8, 0x1c
shl rax, 0xe
mov qword [r10 + 8], r8
xor rcx, rax
mov rax, r9
mov qword [r10], rcx
ret

Function at 0x14001bd50
Capabilities:
Encode data using xor

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
mov rsi, qword [rdx]
mov rbp, qword [rdx + 8]
mov rbx, rsi
mov rdi, rcx
cmp rsi, rbp
jle 0x14001bd76
lea rcx, [0x1400289c0]
call sym.failedAssertImpl__systemZassertions_56
mov r8, rbp
sub r8, rsi
je 0x14001bdcf
mov r9, qword [rdi]
mov rcx, qword [rdi + 8]
cmp r8, 0xffffffffffffffff
je 0x14001bde0
mov rax, 0xffffffffffffffff
xor edx, edx
div r8
lea rax, [r9 + rcx]
xor rcx, r9
ror r9, 9
mov rbx, rdx
mov r10, rcx
xor r9, rcx
ror rcx, 0x1c
shl r10, 0xe
xor r9, r10
add rbx, rax
jb 0x14001bd97
add r8, 1
xor edx, edx
mov qword [rdi], r9
div r8
mov qword [rdi + 8], rcx
lea rbx, [rdx + rsi]
mov rax, rbx
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rax, r9
mov rdx, r9
add r9, rcx
xor rax, rcx
ror rdx, 9
lea rbx, [r9 + rsi]
mov r8, rax
xor rdx, rax
ror rax, 0x1c
shl r8, 0xe
mov qword [rdi + 8], rax
mov rax, rbx
xor rdx, r8
mov qword [rdi], rdx
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret

Function at 0x14001be20
Capabilities:
Encode data using xor

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, qword [rcx]
mov rdi, qword [rcx + 8]
mov rbx, rsi
cmp rdi, rsi
jge 0x14001be42
lea rcx, [0x1400289c0]
call sym.failedAssertImpl__systemZassertions_56
sub rdi, rsi
mov r8, rdi
je 0x14001bea9
mov r9, qword [0x1400411b0]
mov rcx, qword [0x1400411b8]
cmp rdi, 0xffffffffffffffff
je 0x14001beb8
mov rax, 0xffffffffffffffff
xor edx, edx
div rdi
lea rax, [rcx + r9]
xor rcx, r9
ror r9, 9
mov rdi, rdx
mov r10, rcx
xor r9, rcx
ror rcx, 0x1c
shl r10, 0xe
xor r9, r10
add rdi, rax
jb 0x14001be6a
add r8, 1
xor edx, edx
mov qword [0x1400411b0], r9
div r8
mov qword [0x1400411b8], rcx
lea rbx, [rdx + rsi]
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
mov rax, r9
mov rdx, r9
add r9, rcx
xor rax, rcx
ror rdx, 9
lea rbx, [r9 + rsi]
mov r8, rax
xor rdx, rax
ror rax, 0x1c
shl r8, 0xe
mov qword [0x1400411b8], rax
mov rax, rbx
xor rdx, r8
mov qword [0x1400411b0], rdx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
Function at 0x14001edb0
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, 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 rsi, qword [rsp + 0x28]
mov ecx, 2
call dbg.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sym.vfprintf
call sym.abort
nop
nop dword [rax]

Function at 0x14001ee20
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140041284]
mov rbx, rcx
test esi, esi
jle 0x14001ef50
mov rax, qword [0x140041288]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x14001ee6b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x14001eef5
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x14001ee50
mov rcx, rbx
call dbg.__mingw_GetSectionForAddress
mov rdi, rax
test rax, rax
je 0x14001ef72
mov rax, qword [0x140041288]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call dbg._GetPEImageBase
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140041288]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x14001ef57
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14001eeee
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x14001ef00
add dword [0x140041284], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
mov eax, 4
cmove r8d, eax
add rbx, qword [0x140041288]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14001eeee
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 esi, esi
jmp 0x14001ee78
mov rax, qword [0x140041288]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call dbg.__report_error
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x14001f4e0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x1400412e0]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400412c0]
test rbx, rbx
je 0x14001f53c
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x14001f533
test rsi, rsi
je 0x14001f533
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x14001f518
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x14001f750
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x14001f768
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x14001f770
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x14001f780
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
movzx r8d, word [rcx + 6]
lea rax, [rcx + rax + 0x18]
test r8w, r8w
je 0x14001f7cd
lea ecx, [r8 - 1]
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax + rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp rdx, r8
jb 0x14001f7c4
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x14001f7cf
add rax, 0x28
cmp rax, r9
jne 0x14001f7b0
xor eax, eax
ret

Function at 0x14001f7d0
Capabilities:
Parse pe header

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, rcx
call sym.strlen
cmp rax, 8
ja 0x14001f860
mov rdx, qword [0x1400296c0]
xor ebx, ebx
cmp word [rdx], 0x5a4d
jne 0x14001f84e
movsxd rax, dword [rdx + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
jne 0x14001f84e
cmp word [rax + 0x18], 0x20b
jne 0x14001f84e
movzx edx, word [rax + 0x14]
lea rbx, [rax + rdx + 0x18]
movzx edx, word [rax + 6]
test dx, dx
je 0x14001f860
lea eax, [rdx - 1]
lea rax, [rax + rax*4]
lea rdi, [rbx + rax*8 + 0x28]
jmp 0x14001f839
add rbx, 0x28
cmp rbx, rdi
je 0x14001f860
mov r8d, 8
mov rdx, rsi
mov rcx, rbx
call sym.strncmp
test eax, eax
jne 0x14001f830
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
xor ebx, ebx
mov rax, rbx
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret

Function at 0x14001f870
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x1400296c0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x14001f890
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x14001f898
ret
cmp word [r8 + 0x18], 0x20b
jne 0x14001f890
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x14001f8ed
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x14001f8e4
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x14001f890
add rax, 0x28
cmp rax, r9
jne 0x14001f8d0
xor eax, eax
ret

Function at 0x14001f8f0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x1400296c0]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x14001f90f
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x14001f918
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x14001f90f
movzx ecx, word [rax + 6]
mov eax, ecx
ret
Function at 0x14001f930
Capabilities:
Parse pe header

Disassembly:
mov r8, qword [0x1400296c0]
xor eax, eax
cmp word [r8], 0x5a4d
jne 0x14001f950
movsxd rdx, dword [r8 + 0x3c]
add rdx, r8
cmp dword [rdx], 0x4550
je 0x14001f958
ret
cmp word [rdx + 0x18], 0x20b
jne 0x14001f950
movzx eax, word [rdx + 0x14]
movzx r8d, word [rdx + 6]
lea rax, [rdx + rax + 0x18]
test r8w, r8w
je 0x14001f9a0
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea rdx, [rax + rdx*8 + 0x28]
nop dword [rax]
test byte [rax + 0x27], 0x20
je 0x14001f997
test rcx, rcx
je 0x14001f950
sub rcx, 1
add rax, 0x28
cmp rax, rdx
jne 0x14001f988
xor eax, eax
ret

Function at 0x14001f9b0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x1400296c0]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14001f9cf
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x14001f9d8
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret

Function at 0x14001f9f0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x1400296c0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x14001fa10
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x14001fa18
ret
cmp word [r8 + 0x18], 0x20b
jne 0x14001fa10
sub rcx, rdx
movzx r9d, word [r8 + 6]
movzx edx, word [r8 + 0x14]
lea rdx, [r8 + rdx + 0x18]
test r9w, r9w
je 0x14001fa10
lea eax, [r9 - 1]
lea rax, [rax + rax*4]
lea r9, [rdx + rax*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rdx + 0xc]
mov rax, r8
cmp rcx, r8
jb 0x14001fa64
add eax, dword [rdx + 8]
cmp rcx, rax
jb 0x14001fa70
add rdx, 0x28
cmp r9, rdx
jne 0x14001fa50
xor eax, eax
ret
mov eax, dword [rdx + 0x24]
not eax
shr eax, 0x1f
ret

Function at 0x14001fa80
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov r11, qword [0x1400296c0]
xor r9d, r9d
cmp word [r11], 0x5a4d
jne 0x14001faa2
movsxd r8, dword [r11 + 0x3c]
add r8, r11
cmp dword [r8], 0x4550
je 0x14001fab0
mov rax, r9
ret
cmp word [r8 + 0x18], 0x20b
jne 0x14001faa2
mov eax, dword [r8 + 0x90]
test eax, eax
je 0x14001faa2
movzx edx, word [r8 + 0x14]
movzx r10d, word [r8 + 6]
lea rdx, [r8 + rdx + 0x18]
test r10w, r10w
je 0x14001faa2
lea r8d, [r10 - 1]
lea r8, [r8 + r8*4]
lea r10, [rdx + r8*8 + 0x28]
nop word cs:[rax + rax]
mov r9d, dword [rdx + 0xc]
mov r8, r9
cmp rax, r9
jb 0x14001fb05
add r8d, dword [rdx + 8]
cmp rax, r8
jb 0x14001fb18
add rdx, 0x28
cmp rdx, r10
jne 0x14001faf0
xor r9d, r9d
mov rax, r9
ret
add rax, r11
jmp 0x14001fb27
sub ecx, 1
add rax, 0x14
mov r8d, dword [rax + 4]
test r8d, r8d
jne 0x14001fb37
mov edx, dword [rax + 0xc]
test edx, edx
je 0x14001fb0e
test ecx, ecx
jg 0x14001fb20
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
ret
Function at 0x401010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x00405590]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x004055a0]
mov dword [rax], 1
mov rax, qword [0x004055b0]
mov dword [rax], 1
mov rax, qword [0x00405580]
mov dword [rax], 1
mov rax, qword [0x00405470]
cmp word [rax], 0x5a4d
jne 0x401067
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x4010c0
mov rax, qword [0x00405570]
mov dword [0x0040800c], 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 [0x00405530]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x00405420]
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 0x401de0
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 0x401e50
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x00408614]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x401ff8
mov rax, qword [0x00408618]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x401e9c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x401f27
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x401e80
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
je 0x402032
mov rax, qword [0x00408618]
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 [0x00408618]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x402041
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x401f20
sub eax, 4
and eax, 0xfffffffb
jne 0x401fb0
add dword [0x00408614], 1
cmp ebx, 8
jae 0x401f58
test bl, 4
jne 0x402000
test ebx, ebx
je 0x401f49
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x402020
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 0x401f49
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 0x401f8a
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 [0x00408618]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x401f20
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 0x401ea7
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x401f49
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x401f49
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
mov rax, qword [0x00408618]
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 0x402820
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x00408900]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x004088e0]
test rbx, rbx
je 0x402874
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 0x40286b
test r12, r12
je 0x40286b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x402850
lea rcx, [0x00408900]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x402aa0
Capabilities:
Parse pe header

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

Function at 0x402ac0
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 0x402b05
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 0x402afc
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x402b07
add rax, 0x28
cmp rax, r9
jne 0x402ae8
xor eax, eax
ret

Function at 0x402bb0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x00405470]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x402c29
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402c29
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 0x402c26
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 0x402c1d
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x402c29
add r8, 0x28
cmp r8, r9
jne 0x402c08
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x402d10
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x00405470]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x402d7f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402d7f
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 0x402d7d
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 0x402d74
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x402d88
add rax, 0x28
cmp rax, r9
jne 0x402d60
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x402da0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x00405470]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x402e18
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402e18
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x402e18
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x402e18
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 0x402e0c
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x402e20
add rdx, 0x28
cmp rdx, r10
jne 0x402df8
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x402e30
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x402e3e
mov edx, dword [rax + 0xc]
test edx, edx
je 0x402e15
test r8d, r8d
jg 0x402e28
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret
Function at 0x140052a10
Capabilities:
Get hostname

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0x48
mov dword [rsp + 0x20], 0
mov dword [rsp + 0x24], 0x10
lea rdx, [rsp + 0x24]
lea rcx, [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GetComputerNameA]
test eax, eax
je 0x140052a5e
lea rdx, [rsp + 0x28]
mov rcx, qword [rsp + 0x50]
call fcn.140005e80
mov eax, dword [rsp + 0x20]
or eax, 1
mov dword [rsp + 0x20], eax
mov rax, qword [rsp + 0x50]
jmp 0x140052a7f
lea rdx, str.Unknown_Computer_Name
mov rcx, qword [rsp + 0x50]
call fcn.140005e80
mov eax, dword [rsp + 0x20]
or eax, 1
mov dword [rsp + 0x20], eax
mov rax, qword [rsp + 0x50]
add rsp, 0x48
ret