joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140005c30
Capabilities:
Initialize winsock library
Set socket configuration

Disassembly:
sub rsp, 0x1f8
mov rax, qword [0x140012008]
xor rax, rsp
mov qword [rsp + 0x1e0], rax
xor edx, edx
lea rcx, [rsp + 0x40]
mov r8d, 0x198
call sub.VCRUNTIME140.dll_memset
lea rdx, str.Starting_WSA
mov ecx, 4
call fcn.140005ad0
mov ecx, 0x202
lea rdx, [rsp + 0x40]
call qword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x140005cb6
mov ecx, eax
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
lea rdx, str.ERROR:_WSAStartup_failed:__s
xor ecx, ecx
mov r8, rax
call fcn.140005ad0
mov eax, 1
mov rcx, qword [rsp + 0x1e0]
xor rcx, rsp
call fcn.140009690
add rsp, 0x1f8
ret
mov qword [rsp + 0x200], rbx
lea rdx, str.Opening_socket
mov ecx, 4
mov qword [rsp + 0x1f0], rdi
call fcn.140005ad0
mov edx, 1
mov edi, 2
mov ecx, edi
lea r8d, [rdx + 5]
call qword [sym.imp.WS2_32.dll_socket]
mov rbx, rax
cmp rax, 0xffffffffffffffff
jne 0x140005d0d
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.ERROR:_socket___failed:__s
xor ecx, ecx
mov r8d, eax
call fcn.140005ad0
lea rdx, str.Setting_socket_to_non_blocking
mov dword [rsp + 0x20], 1
mov ecx, 4
call fcn.140005ad0
lea r8, [rsp + 0x20]
mov edx, 0x8004667e
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_ioctlsocket]
test eax, eax
je 0x140005d5a
mov r8d, eax
lea rdx, str.ERROR:_Could_not_set_socket_to_non_blocking:__d
xor ecx, ecx
call fcn.140005ad0
mov rax, 0xffffffffffffffff
jmp 0x140005e36
cmp dword [0x140012868], 0
lea rcx, str.127.0.0.1
mov qword [rsp + 0x30], 0
mov word [rsp + 0x28], di
je 0x140005d7f
lea rcx, str.0.0.0.0
call qword [sym.imp.WS2_32.dll_inet_addr]
mov ecx, 0x6987
mov dword [rsp + 0x2c], eax
call qword [sym.imp.WS2_32.dll_htons]
lea rdx, str.Binding_to_socket
mov ecx, 4
mov word [rsp + 0x2a], ax
call fcn.140005ad0
mov r8d, reloc.WS2_32.dll_recv
lea rdx, [rsp + 0x28]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
je 0x140005de8
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r9d, 0x6987
lea rdx, str.bind___failed._WSAGetLastError_returned_error_code__u._Is_another_process_using_TCP_port__d_
mov r8d, eax
xor ecx, ecx
call fcn.140005ad0
mov rax, 0xffffffffffffffff
jmp 0x140005e36
lea rdx, str.Starting_to_listen_on_socket
mov ecx, 4
call fcn.140005ad0
mov edx, 5
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_listen]
test eax, eax
je 0x140005e33
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov ecx, dword [rax]
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_strerror]
lea rdx, str.listen___failed:__s
xor ecx, ecx
mov r8, rax
call fcn.140005ad0
mov rax, 0xffffffffffffffff
jmp 0x140005e36
mov rax, rbx
mov rbx, qword [rsp + 0x200]
mov rdi, qword [rsp + 0x1f0]
mov rcx, qword [rsp + 0x1e0]
xor rcx, rsp
call fcn.140009690
add rsp, 0x1f8
ret
Function at 0x140009400
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push r14
push r15
sub rsp, 0x30
mov r15, rdx
mov qword [r8], 0
lea rdx, [0x14000eee4]
mov r14, r8
mov rbp, rcx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov rbx, rax
test rax, rax
jne 0x140009442
mov rbx, qword [rsp + 0x60]
add rsp, 0x30
pop r15
pop r14
pop rbp
ret
xor edx, edx
mov qword [rsp + 0x58], rdi
mov rcx, rbx
lea r8d, [rdx + 2]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_ftell]
mov rcx, rbx
movsxd rdi, eax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_rewind]
test rdi, rdi
jne 0x14000947d
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
xor eax, eax
jmp 0x1400094f1
lea rcx, [rdi + 1]
mov qword [rsp + 0x50], rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov esi, 1
mov r9, rbx
mov edx, esi
mov qword [r15], rax
mov rcx, rax
mov r8, rdi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp rax, rdi
je 0x1400094de
mov r9d, edi
mov qword [rsp + 0x20], rbp
lea r8, str.buffer_read_from_filename
mov ecx, esi
lea rdx, str._s:_ERROR:_couldnt_read__d_bytes_from__s
call fcn.140005ad0
mov rcx, qword [r15]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor esi, esi
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [rax], 5
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov eax, esi
mov qword [r14], rdi
mov rsi, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x60]
add rsp, 0x30
pop r15
pop r14
pop rbp
ret

Function at 0x140009510
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
mov dword [rax + 0x18], r8d
push rbx
sub rsp, 0x30
mov qword [rax + 8], 0
mov rbx, rdx
test rcx, rcx
je 0x1400095d4
test rdx, rdx
je 0x1400095d4
mov qword [rax + 0x10], rbp
lea r8, [rax + 0x18]
mov qword [rax + 0x20], rsi
lea rdx, [rax + 8]
mov qword [rax - 0x10], rdi
mov qword [rax - 0x18], r14
call qword [sym.imp.plist.dll_plist_to_xml]
mov ebp, dword [rsp + 0x50]
lea rdx, [0x14000ef34]
mov r14, qword [rsp + 0x40]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov rsi, rax
test rax, rax
je 0x1400095ab
mov edi, 1
mov r9, rax
mov edx, edi
mov r8d, ebp
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
mov rcx, rsi
mov rbx, rax
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
cmp rbx, rbp
je 0x1400095ad
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
mov dword [rax], 5
xor edi, edi
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov r14, qword [rsp + 0x20]
mov eax, edi
mov rdi, qword [rsp + 0x28]
mov rsi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
add rsp, 0x30
pop rbx
ret
xor eax, eax
add rsp, 0x30
pop rbx
ret
Function at 0x140001290
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x160
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x150], rax
mov rdi, rcx
mov qword [rsp + 0x38], rcx
lea rax, [rsp + 0x40]
xor ecx, ecx
xor r9d, r9d
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov edx, 0x1a
xor esi, esi
call qword [sym.imp.SHELL32.dll_SHGetFolderPathA]
xorps xmm0, xmm0
movups xmmword [rdi], xmm0
mov qword [rdi + 0x10], rsi
test eax, eax
js 0x14000141a
mov qword [rsp + 0x178], rbx
lea rax, [rsp + 0x40]
mov qword [rsp + 0x180], rbp
mov rbx, 0xffffffffffffffff
mov qword [rdi + 0x18], rsi
nop dword [rax + rax]
inc rbx
cmp byte [rax + rbx], sil
jne 0x140001310
movabs rbp, 0x7fffffffffffffff
cmp rbx, rbp
ja 0x14000142a
cmp rbx, 0xf
ja 0x140001357
mov r8, rbx
mov qword [rdi + 0x10], rbx
lea rdx, [rsp + 0x40]
mov qword [rdi + 0x18], 0xf
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
mov byte [rbx + rdi], sil
jmp 0x1400013e6
mov rax, rbx
or rax, 0xf
cmp rax, rbp
jbe 0x14000138c
movabs rax, 0x8000000000000000
add rax, 0x27
mov rcx, rax
call fcn.140004380
test rax, rax
je 0x1400013b8
lea rsi, [rax + 0x27]
and rsi, 0xffffffffffffffe0
mov qword [rsi - 8], rax
jmp 0x1400013c7
mov ecx, 0x16
mov rbp, rax
cmp rax, rcx
cmovb rbp, rcx
lea rcx, [rbp + 1]
test rcx, rcx
je 0x1400013c7
cmp rcx, 0x1000
jb 0x1400013bf
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x140001430
jmp 0x140001371
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140004380
mov rsi, rax
mov r8, rbx
mov qword [rdi], rsi
lea rdx, [rsp + 0x40]
mov qword [rdi + 0x10], rbx
mov rcx, rsi
mov qword [rdi + 0x18], rbp
call sub.VCRUNTIME140.dll_memcpy
mov byte [rsi + rbx], 0
mov rbx, qword [rsp + 0x178]
mov rax, rdi
mov rbp, qword [rsp + 0x180]
mov rcx, qword [rsp + 0x150]
xor rcx, rsp
call fcn.140004360
mov rsi, qword [rsp + 0x188]
add rsp, 0x160
pop rdi
ret
mov qword [rdi + 0x18], 0xf
mov rax, rdi
mov byte [rdi], sil
jmp 0x1400013f9
call fcn.1400011b0
int3
call fcn.140001110
int3
Function at 0x140002ec0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x140002eed
xor eax, eax
jmp 0x140003059
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x140002f27
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x140002f27
lea ecx, [r8 - 1]
mov dword [rax], ecx
mov eax, edi
mov rdx, qword [rbx + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 1]
mov qword [rdx], rcx
mov byte [r8], dil
jmp 0x140003059
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x14000304c
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x140002f6a
mov rcx, qword [rbx + 0x88]
mov rdx, qword [rbx + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rbx + 0x38]
mov qword [rax], rcx
mov rax, qword [rbx + 0x50]
mov dword [rax], edx
mov rcx, qword [rbx + 0x68]
test rcx, rcx
jne 0x140002f95
mov rdx, qword [rbx + 0x80]
movsx ecx, dil
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x140003051
lea rax, [rsp + 0x40]
mov byte [rsp + 0x50], dil
mov qword [rsp + 0x38], rax
lea rdx, [rbx + 0x74]
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x51]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x50]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__char_const____ptr64__char_const____ptr64__char_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140003004
sub eax, 1
je 0x140003004
cmp eax, 2
jne 0x14000304c
movsx ecx, byte [rsp + 0x50]
mov rdx, qword [rbx + 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x140003051
mov rsi, qword [rsp + 0x40]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x140003032
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x58]
mov r8, rsi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rsi, rax
jne 0x14000304c
lea rax, [rsp + 0x50]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x48], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x140003051
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140004360
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret
Function at 0x140003410
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x60
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rsp + 0x58], rax
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x1400034e3
cmp byte [rcx + 0x71], 0
je 0x1400034e3
mov rax, qword [rcx]
mov edx, 0xffffffff
mov qword [rsp + 0x78], rdi
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x1400034df
mov rcx, qword [rbx + 0x68]
lea rax, [rsp + 0x30]
lea rdx, [rbx + 0x74]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x58]
lea r8, [rsp + 0x38]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x1400034a4
sub eax, 1
je 0x1400034a8
cmp eax, 2
jne 0x1400034df
mov byte [rbx + 0x71], 0
mov al, 1
mov rdi, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140004360
add rsp, 0x60
pop rbx
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
sub rdi, rax
je 0x1400034d6
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x38]
mov r8, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rdi, rax
jne 0x1400034df
cmp byte [rbx + 0x71], 0
sete al
jmp 0x14000348c
xor al, al
jmp 0x14000348c
mov al, 1
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140004360
add rsp, 0x60
pop rbx
ret

Function at 0x140004ce0
Capabilities:
Parse pe header

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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
sub rsp, 0x20
mov rbp, rdx
mov esi, r8d
mov edx, 0x48
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
je 0x1400869f9
xor eax, eax
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
add rsp, 0x20
pop rsi
ret
lea rcx, [rbx + 0x18]
mov qword [rsp + 0x30], rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rcx, qword [rbx]
xor r9d, r9d
mov r8d, esi
mov rdx, rbp
call qword [sym.imp.WS2_32.dll_send]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, 0x48
mov rcx, rbx
mov esi, eax
call qword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
je 0x140086a3d
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_ExitThread]
lea rcx, [rbx + 0x18]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rdi, qword [rsp + 0x30]
mov eax, esi
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
add rsp, 0x20
pop rsi
ret
Function at 0x140096a64
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x20
mov r14d, ecx
call fcn.140096a20
mov rdx, qword [rax + 0x18]
mov rbp, qword [rdx + 0x20]
mov r11, rbp
mov rcx, r11
call fcn.140096a5c
mov r11, qword [r11]
mov r10, qword [rax + 0x30]
test r10, r10
je 0x140096aef
movsxd rax, dword [r10 + 0x3c]
mov ecx, dword [rax + r10 + 0x88]
test ecx, ecx
je 0x140096aef
lea rdi, [r10 + rcx]
mov ecx, dword [rdi + 0xc]
add rcx, r10
call fcn.140096a2c
mov esi, dword [rdi + 0x20]
xor ebx, ebx
add rsi, r10
mov r15d, eax
cmp dword [rdi + 0x18], ebx
jbe 0x140096aef
mov ecx, dword [rsi]
add rcx, r10
call fcn.140096a2c
add eax, r15d
cmp r14d, eax
je 0x140096b0f
inc ebx
add rsi, 4
cmp ebx, dword [rdi + 0x18]
jb 0x140096ad2
cmp r11, rbp
jne 0x140096a8f
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop rdi
ret
mov ecx, dword [rdi + 0x24]
add rcx, r10
movzx r8d, word [rcx + rbx*2]
mov ecx, dword [rdi + 0x1c]
add rcx, r10
mov eax, dword [rcx + r8*4]
add rax, r10
jmp 0x140096af6
Function at 0x140096f08
Capabilities:
Contain obfuscated stackstrings

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x70
mov rbx, rcx
mov ecx, 0x7bac0721
call fcn.140096a64
mov ecx, 0xf477a895
mov r13, rax
call fcn.140096a64
lea rcx, [rbp - 0x50]
mov qword [rbp + 0x40], rax
mov dword [rbp - 0x50], 0x6c64746e
xor r15d, r15d
mov dword [rbp - 0x4c], 0x6c642e6c
mov word [rbp - 0x48], WSAGetLastError
mov dword [rbp - 0x20], 0x526c7452
mov dword [rbp - 0x1c], 0x6c6c4165
mov dword [rbp - 0x18], 0x7461636f
mov dword [rbp - 0x14], 0x61654865
mov word [rbp - 0x10], WSAStartup
call fcn.140096b2c
mov rcx, rax
lea rdx, [rbp - 0x20]
call fcn.140096b4c
lea rcx, [rbp - 0x40]
mov qword [rbp + 0x48], rax
mov dword [rbp - 0x40], 0x6c64746e
mov dword [rbp - 0x3c], 0x6c642e6c
mov word [rbp - 0x38], WSAGetLastError
mov dword [rbp - 0x30], 0x416c7452
mov dword [rbp - 0x2c], 0x636f6c6c
mov dword [rbp - 0x28], 0x48657461
mov dword [rbp - 0x24], 0x706165
call fcn.140096b2c
mov rcx, rax
lea rdx, [rbp - 0x30]
call fcn.140096b4c
mov rcx, qword [rbx]
lea edi, [r15 + 1]
mov r12, qword [rbx + 8]
mov qword [rbp + 0x50], rax
cmp dword [rcx + 0x94], r15d
jbe 0x14009711b
mov esi, dword [rcx + 0x90]
lea edx, [rdi + 0x13]
add rsi, r12
mov rcx, rsi
call r13
test eax, eax
jne 0x14009711b
add rsi, 0x10
mov edi, 1
cmp dword [rsi - 4], r15d
je 0x14009711b
mov ecx, dword [rsi - 4]
mov rdx, qword [rbx + 0x38]
add rcx, r12
call qword [rbx + 0x20]
mov r14, rax
test rax, rax
je 0x140097118
mov ecx, dword [rbx + 0x18]
mov r15, qword [rbx + 0x10]
inc ecx
movsxd rdi, ecx
shl rdi, 3
call qword [rbp + 0x40]
mov rcx, rax
test r15, r15
je 0x14009705e
mov r9, rdi
mov r8, r15
xor edx, edx
call qword [rbp + 0x48]
jmp 0x140097069
mov r8, rdi
mov edx, 8
call qword [rbp + 0x50]
mov rcx, rax
test rax, rax
je 0x14009710a
mov qword [rbx + 0x10], rax
movsxd rax, dword [rbx + 0x18]
mov qword [rcx + rax*8], r14
inc dword [rbx + 0x18]
mov eax, dword [rsi - 0x10]
test eax, eax
jne 0x14009708d
mov eax, dword [rsi]
mov r15d, eax
mov edi, 1
add r15, r12
mov rax, qword [r15]
test rax, rax
je 0x1400970df
mov edi, dword [rsi]
add rdi, r12
mov r8, qword [rbx + 0x38]
mov rcx, r14
test rax, rax
jns 0x1400970b7
movzx edx, word [r15]
jmp 0x1400970c1
mov rdx, qword [r15]
add rdx, 2
add rdx, r12
call qword [rbx + 0x28]
mov qword [rdi], rax
test rax, rax
je 0x1400970fc
add r15, 8
add rdi, 8
mov rax, qword [r15]
test rax, rax
jne 0x1400970a5
lea edi, [rax + 1]
add rsi, 0x14
mov edx, reloc.WS2_32.dll_sendto
lea rcx, [rsi - 0x10]
call r13
xor r15d, r15d
test eax, eax
je 0x14009700e
jmp 0x14009711b
mov rdx, qword [rbx + 0x38]
xor edi, edi
mov rcx, r14
call qword [rbx + 0x30]
jmp 0x14009711b
mov rdx, qword [rbx + 0x38]
mov rcx, r14
call qword [rbx + 0x30]
xor edi, edi
jmp 0x14009711b
mov edi, r15d
mov rbx, qword [rsp + 0xc8]
mov eax, edi
add rsp, 0x70
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x140097178
Capabilities:
Contain obfuscated stackstrings
Parse pe header

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r9
push rbp
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x40
mov r15, rcx
mov ecx, 0x4faef192
call fcn.140096a64
mov ecx, 0x9e5a8833
mov r12, rax
call fcn.140096a64
mov ecx, 0xf477a895
mov rbx, rax
call fcn.140096a64
mov ecx, 0xc9f93d32
mov rdi, rax
call fcn.140096a64
lea rcx, [rbp - 0x20]
mov qword [rbp + 0x48], rax
mov dword [rbp - 0x20], 0x6c64746e
mov dword [rbp - 0x1c], 0x6c642e6c
mov word [rbp - 0x18], WSAGetLastError
mov dword [rbp - 0x10], 0x416c7452
mov dword [rbp - 0xc], 0x636f6c6c
mov dword [rbp - 8], 0x48657461
mov dword [rbp - 4], 0x706165
call fcn.140096b2c
mov rcx, rax
lea rdx, [rbp - 0x10]
call fcn.140096b4c
mov r13, rax
mov eax, 0x5a4d
cmp word [r15], ax
jne 0x140097295
movsxd rsi, dword [r15 + 0x3c]
add rsi, r15
cmp dword [rsi], 0x4550
jne 0x140097295
mov edx, dword [rsi + 0x50]
mov r9d, 4
mov rcx, qword [rsi + 0x30]
mov r8d, 0x3000
call rbx
mov r14, rax
test rax, rax
jne 0x14009726b
mov edx, dword [rsi + 0x50]
lea r9d, [rax + 4]
xor ecx, ecx
mov r8d, 0x3000
call rbx
mov r14, rax
test rax, rax
je 0x140097295
call rdi
mov edx, 8
mov rcx, rax
lea r8d, [rdx + 0x38]
call r13
xor r13d, r13d
mov rdi, rax
mov rcx, r14
test rax, rax
jne 0x1400972b5
xor edx, edx
mov r8d, 0x8000
call r12
xor eax, eax
lea r11, [rsp + 0x40]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
mov qword [rax + 8], r14
mov r9d, 4
mov qword [rax + 0x18], r13
mov r8d, 0x1000
mov qword [rax + 0x10], r13
lea rax, [0x140097138]
mov qword [rdi + 0x20], rax
lea rax, [0x140097140]
mov qword [rdi + 0x28], rax
lea rax, [0x140097148]
mov qword [rdi + 0x30], rax
mov qword [rdi + 0x38], r13
mov edx, dword [rsi + 0x54]
call rbx
mov r8d, dword [rsi + 0x54]
mov rdx, r15
mov rcx, rax
mov rbx, rax
call qword [rbp + 0x48]
movsxd rax, dword [r15 + 0x3c]
mov r8, rdi
add rax, rbx
mov rdx, rsi
mov qword [rdi], rax
mov rcx, r15
mov qword [rax + 0x30], r14
call fcn.140096b7c
mov rdx, r14
sub rdx, qword [rsi + 0x30]
je 0x140097334
mov rcx, rdi
call fcn.140096e6c
mov rcx, rdi
call fcn.140096f08
test eax, eax
je 0x140097295
mov rcx, rdi
call fcn.140096c70
mov rcx, rdi
call fcn.140096e20
mov rax, qword [rdi]
cmp dword [rax + 0x28], r13d
je 0x14009737c
mov eax, dword [rax + 0x28]
xor r8d, r8d
add rax, r14
mov rcx, r14
lea ebx, [r8 + 1]
mov edx, ebx
call rax
test eax, eax
je 0x140097295
mov dword [rdi + 0x1c], ebx
mov rax, rdi
jmp 0x140097297

Function at 0x14009744c
Capabilities:
Encode data using xor

Disassembly:
movsxd r8, edx
test edx, edx
jle 0x14009745f
xor byte [rcx], 0x3a
inc rcx
sub r8, 1
jne 0x140097453
mov eax, 1
ret
Function at 0x14012de80
Capabilities:
Resolve dns

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rcx, rdx
mov rdi, r8
mov rbx, rdx
call qword [sym.imp.WS2_32.dll_inet_addr]
mov eax, eax
mov esi, 0xffffffff
cmp rax, rsi
jne 0x14012dedb
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_gethostbyname]
test rax, rax
je 0x14012dec6
mov rax, qword [rax + 0x18]
mov rcx, qword [rax]
mov eax, dword [rcx]
cmp rax, rsi
jne 0x14012dedb
mov eax, 0xffffffff
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
mov dword [rdi + 4], eax
xor eax, eax
add rsp, 0x20
pop rdi
ret

Function at 0x14012e020
Capabilities:
Set socket configuration

Disassembly:
push rbx
sub rsp, 0x20
lea r8, [rsp + 0x38]
mov dword [rsp + 0x38], 1
mov edx, 0x8004667e
call qword [sym.imp.WS2_32.dll_ioctlsocket]
xor ebx, ebx
test eax, eax
setne bl
test eax, eax
je 0x14012e063
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.ioctlsocket_FIONBIO_1_failed_with_error__d_n
mov ecx, 1
mov r8d, eax
call fcn.1401319b0
mov eax, ebx
add rsp, 0x20
pop rbx
ret
Function at 0x14012e070
Capabilities:
Set socket configuration

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
push rdi
sub rsp, 0x70
xor ebx, ebx
mov rdi, rdx
mov rsi, rcx
cmp dword [rcx + 0x2d0], ebx
je 0x14012e183
lea r9, [rax + 8]
mov dword [rax + 8], 1
mov edx, 0xffff
mov dword [rax - 0x58], 4
lea r8d, [rbx + 8]
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jns 0x14012e0e9
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r8d, eax
lea rdx, str.setsockopt_SO_KEEPALIVE_1_failed_with_error__d_n
lea ecx, [rbx + 1]
call fcn.1401319b0
lea eax, [rbx + 1]
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
imul eax, dword [rsi + 0x2d0], 0x3e8
lea r8, [rsp + 0x58]
mov qword [rsp + 0x40], rbx
mov r9d, reloc.OLEAUT32.dll_VariantTimeToDosDateTime
mov qword [rsp + 0x38], rbx
mov edx, 0x98000004
mov rcx, rdi
mov dword [rsp + 0x58], 1
mov dword [rsp + 0x5c], eax
imul eax, dword [rsi + 0x2d8], 0x3e8
mov dword [rsp + 0x60], eax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], ebx
mov qword [rsp + 0x20], rbx
call qword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x14012e183
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov r9d, dword [rsp + 0x60]
lea rdx, str.WSAIoctl_SIO_KEEPALIVE_VALS_1__lu__lu_failed_with_error__d_n
mov r8d, dword [rsp + 0x5c]
mov ecx, 1
mov dword [rsp + 0x20], eax
call fcn.1401319b0
mov eax, 1
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
lea rcx, [0x1402eee94]
mov dword [rsp + 0x80], 1
call qword [sym.imp.WS2_32.dll_getprotobyname]
mov edx, 6
test rax, rax
je 0x14012e1a9
movsx edx, word [rax + 0x10]
lea r9, [rsp + 0x80]
mov dword [rsp + 0x20], 4
mov r8d, 1
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_setsockopt]
lea r8, [rsp + 0x98]
mov dword [rsp + 0x98], 1
mov edx, 0x8004667e
mov rcx, rdi
call qword [sym.imp.WS2_32.dll_ioctlsocket]
test eax, eax
setne bl
test eax, eax
je 0x14012e20c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.ioctlsocket_FIONBIO_1_failed_with_error__d_n
mov ecx, 1
mov r8d, eax
call fcn.1401319b0
lea r11, [rsp + 0x70]
mov eax, ebx
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret

Function at 0x14012e220
Capabilities:
Get socket status

Disassembly:
mov r11, rsp
sub rsp, 0x248
mov rcx, qword [rcx]
lea rdx, [rsp + 0x30]
xor eax, eax
mov qword [rsp + 0x38], rcx
mov qword [r11 + 8], rax
inc ecx
lea rax, [r11 + 8]
mov dword [rsp + 0x30], 1
xor r9d, r9d
mov qword [rsp + 0x20], rax
xor r8d, r8d
call qword [sym.imp.WS2_32.dll_select]
add rsp, 0x248
ret