joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140011780
Capabilities:
Encode data using xor

Disassembly:
push rbx
sub rsp, 0x70
mov rax, qword [0x1400feb78]
xor rax, rsp
mov qword [rsp + 0x68], rax
mov rbx, rcx
xor edx, edx
mov ecx, 0x5c
call fcn.140005910
mov ecx, 0x5c
mov word [rsp + 0x40], ax
lea edx, [rcx - 0x5b]
call fcn.140005910
mov ecx, reloc.WLDAP32.dll_Ordinal_46
mov word [rsp + 0x42], ax
lea edx, [rcx - 0x2c]
call fcn.140005910
mov ecx, 0x5c
mov word [rsp + 0x44], ax
lea edx, [rcx - 0x59]
call fcn.140005910
mov ecx, 0x45
mov word [rsp + 0x46], ax
lea edx, [rcx - 0x41]
call fcn.140005910
mov ecx, 0x49
mov word [rsp + 0x48], ax
lea edx, [rcx - 0x44]
call fcn.140005910
mov ecx, 0x51
mov word [rsp + 0x4a], ax
lea edx, [rcx - 0x4b]
call fcn.140005910
mov ecx, 0x44
mov word [rsp + 0x4c], ax
lea edx, [rcx - 0x3d]
call fcn.140005910
mov ecx, 0x56
mov word [rsp + 0x4e], ax
lea edx, [rcx - 0x4e]
call fcn.140005910
xor ecx, ecx
mov word [rsp + 0x50], ax
lea edx, [rcx + 9]
call fcn.140005910
movzx ecx, word [0x140093414]
mov edx, 0xa
mov word [rsp + 0x52], ax
call fcn.140005910
movzx ecx, word [0x140093416]
mov edx, ntohl
mov word [rsp + 0x54], ax
call fcn.140005910
movzx ecx, word [0x140093418]
mov edx, recv
mov word [rsp + 0x56], ax
call fcn.140005910
movzx ecx, word [0x14009341a]
mov edx, reloc.WS2_32.dll_listen
mov word [rsp + 0x58], ax
call fcn.140005910
movzx ecx, word [reloc.WS2_32.dll_accept]
mov edx, reloc.WS2_32.dll_ntohl
mov word [rsp + 0x5a], ax
call fcn.140005910
movzx ecx, word [0x14009341e]
mov edx, reloc.WS2_32.dll_ntohs
mov word [rsp + 0x5c], ax
call fcn.140005910
movzx ecx, word [vtable.std::basic_ostream_char__struct_std::char_traits_char__.0]
mov edx, reloc.WS2_32.dll_recv
mov word [rsp + 0x5e], ax
call fcn.140005910
movzx ecx, word [0x140093422]
mov edx, reloc.WS2_32.dll_recvfrom
mov word [rsp + 0x60], ax
call fcn.140005910
movzx ecx, word [reloc.WS2_32.dll_accept]
mov edx, reloc.WS2_32.dll_select
mov word [rsp + 0x62], ax
call fcn.140005910
mov word [rsp + 0x64], ax
mov r9d, 0x133
xor eax, eax
mov word [rsp + 0x66], ax
xor r10d, r10d
nop
movsxd rcx, eax
lea rdx, [rsp + 0x40]
lea rdx, [rdx + rcx*2]
lea ecx, [r9 + rax]
inc eax
xor word [rdx], cx
cmp eax, 0x13
jb 0x140011920
mov qword [rsp + 0x30], r10
lea rcx, [rsp + 0x40]
xor r9d, r9d
mov dword [rsp + 0x28], r10d
mov edx, 0xc0000000
mov word [rsp + 0x66], r10w
mov dword [rsp + 0x20], 3
lea r8d, [r9 + 3]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov qword [rbx + 8], rax
mov rcx, qword [rsp + 0x68]
xor rcx, rsp
call fcn.140015810
add rsp, 0x70
pop rbx
ret
Function at 0x140013fb4
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
mov rdi, rdx
lea r8, [rsp + 0x60]
mov ebx, ecx
mov edx, 0x20000001
lea rcx, str._x_sys_default_locale
mov r9d, 2
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
mov r8d, ebx
mov ecx, 0x1300
neg eax
sbb r9d, r9d
and qword [rsp + 0x30], 0
and r9d, dword [rsp + 0x60]
xor edx, edx
and dword [rsp + 0x28], 0
mov dword [rsp + 0x60], r9d
mov qword [rsp + 0x20], rdi
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, eax
test eax, eax
je 0x140014038
mov r8, qword [rdi]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, reloc.WS2_32.dll_accept
cmp byte [rcx + rax], 0
je 0x140014038
dec r8
sub rdx, 1
jne 0x14001401e
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret

Function at 0x140016648
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140016692
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x140016692
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140016692
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x140016692
cmp dword [rcx + 0x84], 0xe
jbe 0x140016692
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x140016694
xor al, al
add rsp, 0x28
ret
Function at 0x14001e460
Capabilities:
Encode data using xor
Hash data using djb2

Disassembly:
push rdi
sub rsp, 0x20
mov rdi, rcx
test rcx, rcx
je 0x14001e54a
call fcn.14001e6b0
test al, al
jne 0x14001e54a
mov qword [rsp + 0x30], rbx
mov rbx, 0xffffffffffffffff
mov qword [rsp + 0x38], rbp
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x48], r14
xor r14d, r14d
mov esi, r14d
inc rbx
cmp byte [rdi + rbx], sil
jne 0x14001e4a0
mov r8, rbx
mov edx, reloc.WLDAP32.dll_Ordinal_46
mov rcx, rdi
call fcn.14003a840
test rax, rax
je 0x14001e4e5
sub rax, rdi
mov edx, reloc.WLDAP32.dll_Ordinal_46
mov r8, rax
mov rcx, rdi
call fcn.14003a840
mov rsi, rax
test rax, rax
je 0x14001e4e5
inc rsi
mov rcx, rdi
sub rcx, rsi
add rbx, rcx
test rsi, rsi
mov ebp, 0x1505
cmovne rdi, rsi
mov rsi, rdi
lea rax, [rbx + rdi]
cmp rdi, rax
cmova rbx, r14
mov r14, qword [rsp + 0x48]
test rbx, rbx
je 0x14001e531
nop dword [rax]
movzx ecx, byte [rsi]
call fcn.14002d0f0
movsx rcx, al
inc rsi
imul rbp, rbp, 0x21
mov rax, rsi
xor rbp, rcx
sub rax, rdi
cmp rax, rbx
jb 0x14001e510
mov rsi, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x30]
movzx eax, bpl
mov rbp, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
xor eax, eax
add rsp, 0x20
pop rdi
ret
Function at 0x14002a4e0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, r9
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
cmp rcx, 0xffffffffffffffff
jne 0x14002a51b
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, gethostname
mov edx, 0x51
cmp eax, 0x2733
cmove ecx, edx
mov eax, ecx
add rsp, 0x20
pop rbx
ret
mov qword [rbx], rcx
xor eax, eax
add rsp, 0x20
pop rbx
ret

Function at 0x14002a6c0
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xb8
mov rax, qword [0x1400feb78]
xor rax, rsp
mov qword [rsp + 0xa0], rax
mov r14, qword [rsp + 0x120]
mov rsi, rcx
movsxd rcx, edx
xor r13d, r13d
mov rax, rcx
mov r12, r9
shl rax, 5
mov r15, r8
lea rbx, [rsi + 0x288]
mov rbp, qword [rsi + rcx*8 + 0x240]
add rbx, rax
mov rax, qword [rsi + 0x3e8]
mov rdi, qword [rbx + 8]
sub rdi, qword [rbx + 0x10]
test byte [rax + 0x7c], 3
je 0x14002a7c7
lea rax, [0x14002a570]
cmp qword [rsi + rcx*8 + 0x268], rax
jne 0x14002a7c7
cmp qword [rbx], r13
je 0x14002a74e
test rdi, rdi
je 0x14002a7c7
mov rdx, 0xffffffffffffffff
xor r9d, r9d
mov r8, rdx
mov rcx, rbp
call fcn.140029bf0
cmp eax, 0xffffffff
je 0x14002a7c7
test al, 1
je 0x14002a7c7
mov rax, qword [rbx]
test rax, rax
jne 0x14002a7a0
mov rax, qword [rsi]
mov ecx, dword [rax + 0xb60]
add ecx, ecx
movsxd rcx, ecx
mov qword [rbx + 8], rcx
call qword [fcn.14006d248]
mov rdi, qword [rbx + 8]
mov qword [rbx], rax
mov qword [rbx + 0x10], r13
mov qword [rbx + 0x18], r13
test rax, rax
je 0x14002a7c3
mov rdx, qword [rbx + 0x10]
xor r9d, r9d
add rdx, rax
mov r8d, edi
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_recv]
movsxd rcx, eax
test eax, eax
jle 0x14002a7c7
add qword [rbx + 0x10], rcx
jmp 0x14002a7c7
mov qword [rbx + 8], r13
xor r9d, r9d
mov r8d, r12d
mov rdx, r15
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_send]
movsxd rdi, eax
mov dword [r14], r13d
cmp rdi, 0xffffffffffffffff
jne 0x14002a834
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, eax
cmp eax, 0x2733
jne 0x14002a800
mov dword [r14], 0x51
mov rax, r13
jmp 0x14002a837
mov r8d, pe_nt_image_headers64
lea rdx, [rsp + 0x20]
mov ecx, ebx
call fcn.140055f40
mov rcx, qword [rsi]
lea rdx, str.Send_failure:__s
mov r8, rax
call fcn.14002a0a0
mov rcx, qword [rsi]
mov dword [rcx + 0x10e8], ebx
mov dword [r14], gethostname
mov rax, rdi
mov rcx, qword [rsp + 0xa0]
xor rcx, rsp
call fcn.140015810
add rsp, 0xb8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret

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

Disassembly:
sub rsp, 0x28
test byte [rcx + 0x2d8], 1
je 0x14002ae1d
call fcn.1400234c0
test eax, eax
jne 0x14002ae43
xor al, al
add rsp, 0x28
ret
mov rcx, qword [rcx + 0x240]
cmp rcx, 0xffffffffffffffff
je 0x14002ae16
mov r9d, 2
lea rdx, [rsp + 0x30]
lea r8d, [r9 - 1]
call qword [sym.imp.WS2_32.dll_recv]
test eax, eax
je 0x14002ae16
mov al, 1
add rsp, 0x28
ret
Function at 0x14002c8c0
Capabilities:
Read file on windows

Disassembly:
sub rsp, 0x28
call fcn.140080884
cdqe
add rsp, 0x28
ret

Function at 0x14002cbb0
Capabilities:
Get common file path

Disassembly:
push rbx
push rbp
push rdi
sub rsp, 0x20
mov rbx, rcx
xor ebp, ebp
lea rcx, [0x1400962d0]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov rdi, rax
test rax, rax
jne 0x14002cbda
add rsp, 0x20
pop rdi
pop rbp
pop rbx
ret
lea rdx, str.LoadLibraryExA
mov qword [rsp + 0x48], r14
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, [0x1400962f0]
mov rcx, rbx
mov r14, rax
call fcn.14007b6d0
test rax, rax
je 0x14002cc3d
mov rcx, rbx
test r14, r14
je 0x14002cc27
xor edx, edx
lea r8d, [rdx + 8]
call r14
mov r14, qword [rsp + 0x48]
mov rbp, rax
add rsp, 0x20
pop rdi
pop rbp
pop rbx
ret
call qword [0x1400920c8]
mov r14, qword [rsp + 0x48]
mov rbp, rax
add rsp, 0x20
pop rdi
pop rbp
pop rbx
ret
test r14, r14
je 0x14002cc75
lea rdx, str.AddDllDirectory
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x14002cc75
xor edx, edx
mov r8d, 0x800
mov rcx, rbx
call r14
mov r14, qword [rsp + 0x48]
mov rbp, rax
add rsp, 0x20
pop rdi
pop rbp
pop rbx
ret
xor edx, edx
mov qword [rsp + 0x50], r15
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov r15d, eax
test eax, eax
je 0x14002cd38
mov qword [rsp + 0x40], rsi
mov rsi, 0xffffffffffffffff
mov rdx, rsi
nop
inc rdx
cmp byte [rbx + rdx], bpl
jne 0x14002cca0
lea ecx, [rax + 1]
add rcx, rdx
call qword [fcn.14006d248]
mov rdi, rax
test rax, rax
je 0x14002cd2a
mov edx, r15d
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x14002cd2a
mov rax, rsi
cmp byte [rdi + rax + 1], bpl
lea rax, [rax + 1]
jne 0x14002ccd0
mov ecx, 0x5c
mov word [rax + rdi], cx
inc rsi
cmp byte [rdi + rsi], bpl
jne 0x14002cce4
mov rcx, rdi
sub rcx, rbx
add rcx, rsi
nop word [rax + rax]
movzx eax, byte [rbx]
mov byte [rcx + rbx], al
lea rbx, [rbx + 1]
test al, al
jne 0x14002cd00
mov rcx, rdi
test r14, r14
je 0x14002cd21
xor edx, edx
lea r8d, [rdx + 8]
call r14
jmp 0x14002cd27
call qword [0x1400920c8]
mov rbp, rax
mov rcx, rdi
call qword [fcn.140067ebc]
mov rsi, qword [rsp + 0x40]
mov r15, qword [rsp + 0x50]
mov rax, rbp
mov r14, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
pop rbp
pop rbx
ret
Function at 0x14003abd0
Capabilities:
Resolve dns

Disassembly:
push rbx
push r12
push r13
push r14
push r15
sub rsp, 0x20
xor r13d, r13d
mov r12, r9
mov qword [r9], r13
mov ebx, r13d
lea r9, [rsp + 0x68]
mov r15d, r13d
call qword [sym.imp.WS2_32.dll_getaddrinfo]
mov r14d, eax
test eax, eax
jne 0x14003ad94
mov qword [rsp + 0x58], rsi
mov rsi, qword [rsp + 0x68]
mov qword [rsp + 0x60], rdi
test rsi, rsi
je 0x14003ad74
mov qword [rsp + 0x50], rbp
mov eax, dword [rsi + 4]
cmp eax, 2
jne 0x14003ac2d
lea ebp, [rax + 0xe]
jmp 0x14003ac39
cmp eax, 0x17
jne 0x14003ace1
lea ebp, [rax + 5]
cmp qword [rsi + 0x20], r13
je 0x14003ace1
mov rax, qword [rsi + 0x10]
test rax, rax
je 0x14003ace1
cmp rax, rbp
jb 0x14003ace1
mov ecx, Ordinal_50
call qword [fcn.14006d248]
mov rdi, rax
test rax, rax
je 0x14003ad1c
mov ecx, dword [rsi]
mov dword [rax], ecx
mov ecx, dword [rsi + 4]
mov dword [rax + 4], ecx
mov ecx, dword [rsi + 8]
mov dword [rax + 8], ecx
mov ecx, dword [rsi + 0xc]
mov dword [rax + 0xc], ecx
mov rcx, rbp
mov dword [rax + 0x10], ebp
mov qword [rax + 0x20], r13
mov qword [rax + 0x18], r13
mov qword [rax + 0x28], r13
call qword [fcn.14006d248]
mov qword [rdi + 0x20], rax
test rax, rax
je 0x14003ad0b
mov rdx, qword [rsi + 0x20]
mov r8, rbp
mov rcx, rax
call fcn.140062270
mov rcx, qword [rsi + 0x18]
test rcx, rcx
je 0x14003acce
call qword [case.0x14001e8a9.0]
mov qword [rdi + 0x18], rax
test rax, rax
je 0x14003acf0
test rbx, rbx
cmove rbx, rdi
test r15, r15
je 0x14003acde
mov qword [r15 + 0x28], rdi
mov r15, rdi
mov rsi, qword [rsi + 0x28]
test rsi, rsi
jne 0x14003ac20
jmp 0x14003ad22
mov rcx, qword [rdi + 0x20]
mov r14d, 8
call qword [fcn.140067ebc]
mov rcx, rdi
call qword [fcn.140067ebc]
jmp 0x14003ad22
mov rcx, rdi
mov r14d, 8
call qword [fcn.140067ebc]
jmp 0x14003ad22
mov r14d, 8
mov rcx, qword [rsp + 0x68]
mov rbp, qword [rsp + 0x50]
test rcx, rcx
je 0x14003ad37
call qword [sym.imp.WS2_32.dll_freeaddrinfo]
test r14d, r14d
je 0x14003ad6f
test rbx, rbx
je 0x14003ad6a
mov rcx, qword [rbx + 0x20]
call qword [fcn.140067ebc]
mov rcx, qword [rbx + 0x18]
call qword [fcn.140067ebc]
mov rdi, qword [rbx + 0x28]
mov rcx, rbx
call qword [fcn.140067ebc]
mov rbx, rdi
test rdi, rdi
jne 0x14003ad41
mov rbx, r13
jmp 0x14003ad83
test rbx, rbx
jne 0x14003ad83
mov r14d, 0x2af9
mov ecx, r14d
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov rdi, qword [rsp + 0x60]
mov eax, r14d
mov rsi, qword [rsp + 0x58]
mov qword [r12], rbx
add rsp, 0x20
pop r15
pop r14
pop r13
pop r12
pop rbx
ret

Function at 0x14003fe90
Capabilities:
Query environment variable

Disassembly:
sub rsp, 0x148
mov rax, qword [0x1400feb78]
xor rax, rsp
mov qword [rsp + 0x130], rax
call fcn.14007c14c
mov byte [rsp + 0x20], 0
test rax, rax
je 0x14003fef6
mov r8d, 0x104
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
cmp byte [rsp + 0x20], 0
je 0x14003fef6
lea rcx, [rsp + 0x20]
call qword [case.0x14001e8a9.0]
mov rcx, qword [rsp + 0x130]
xor rcx, rsp
call fcn.140015810
add rsp, 0x148
ret
xor eax, eax
mov rcx, qword [rsp + 0x130]
xor rcx, rsp
call fcn.140015810
add rsp, 0x148
ret
Function at 0x140044910
Capabilities:
Send data
Send data on socket

Disassembly:
cmp edx, 0x1f
jne 0x140044abd
push rbp
push rdi
push r14
sub rsp, 0x20
mov rbp, qword [rcx]
mov r14, rcx
mov qword [rsp + 0x40], rbx
mov qword [rsp + 0x50], rsi
mov qword [rsp + 0x58], r15
mov rdi, qword [rbp + 0x1f8]
lea rsi, [rdi + 0x1cb8]
lea rbx, [rdi + 0x1eb8]
mov qword [rbx], rsi
cmp rsi, rbx
jae 0x14004495e
mov byte [rsi], 0xff
inc qword [rbx]
mov rax, qword [rbx]
jmp 0x140044961
mov rax, rsi
cmp rax, rbx
jae 0x14004497a
mov byte [rax], 0xfa
inc qword [rbx]
mov rax, qword [rbx]
cmp rax, rbx
jae 0x14004497a
mov byte [rax], Ordinal_33
inc qword [rbx]
movzx ecx, word [rdi + 0x1ca8]
call qword [sym.imp.WS2_32.dll_htons]
movzx ecx, word [rdi + 0x1caa]
movzx r15d, ax
mov word [rsp + 0x48], ax
call qword [sym.imp.WS2_32.dll_htons]
mov r9, qword [rbx]
movzx ecx, ax
cmp r9, rbx
jae 0x1400449b1
mov byte [r9], r15b
inc qword [rbx]
mov r9, qword [rbx]
mov r15, qword [rsp + 0x58]
cmp r9, rbx
jae 0x140044a07
movzx eax, byte [rsp + 0x49]
mov byte [r9], al
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140044a07
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140044a07
shr cx, 8
mov byte [r9], cl
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140044a07
mov byte [r9], 0xff
inc qword [rbx]
mov r9, qword [rbx]
cmp r9, rbx
jae 0x140044a07
mov byte [r9], 0xf0
mov r9, qword [rbx]
inc r9
mov qword [rdi + 0x1ec0], r9
lea r8, [rdi + 0x1cba]
sub r9, rsi
mov qword [rbx], rsi
sub r9, 2
mov edx, 0x3e
mov rcx, rbp
call fcn.1400443b0
mov rcx, qword [r14 + 0x240]
xor r9d, r9d
mov rdx, rsi
lea r8d, [r9 + 3]
call qword [sym.imp.WS2_32.dll_send]
mov rsi, qword [rsp + 0x50]
mov rbx, qword [rsp + 0x40]
test eax, eax
jns 0x140044a69
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.14002a0a0
lea rdx, [rdi + 0x1cbb]
mov r8d, 4
mov rcx, r14
call fcn.140044790
mov rcx, qword [r14 + 0x240]
lea rdx, [rdi + 0x1cbf]
xor r9d, r9d
lea r8d, [r9 + 2]
call qword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x140044ab5
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, str.Sending_data_failed___d_
mov rcx, rbp
mov r8d, eax
call fcn.14002a0a0
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret
Function at 0x140046280
Capabilities:
Receive data
Receive data on socket

Disassembly:
push rsi
push rdi
push r14
sub rsp, 0xd0
mov rax, qword [0x1400feb78]
xor rax, rsp
mov qword [rsp + 0xc0], rax
mov rdi, qword [rcx + 0x798]
lea rax, [rsp + 0x30]
mov rsi, qword [rcx]
mov r14, rcx
mov dword [rsp + 0x30], pe_nt_image_headers64
xor r9d, r9d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
mov r8d, dword [rdi + 0x15c]
mov rdx, qword [rdi + 0x168]
add r8d, 4
mov rcx, qword [rdi + 0x18]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_recvfrom]
cmp dword [rdi + 0x150], 0
mov dword [rdi + 0x154], eax
jne 0x140046315
movsxd r8, dword [rsp + 0x30]
lea rcx, [rdi + 0xd0]
lea rdx, [rsp + 0x40]
call fcn.140062270
mov eax, dword [rsp + 0x30]
mov dword [rdi + 0x150], eax
mov r8d, dword [rdi + 0x154]
mov qword [rsp + 0xf8], rbx
mov qword [rsp + 0x100], rbp
cmp r8d, 4
jge 0x140046376
lea rdx, str.Received_too_short_packet
mov rcx, rsi
call fcn.14002a0a0
mov dword [rdi + 0xc], 7
xor eax, eax
mov rbp, qword [rsp + 0x100]
mov rbx, qword [rsp + 0xf8]
mov rcx, qword [rsp + 0xc0]
xor rcx, rsp
call fcn.140015810
add rsp, 0xd0
pop r14
pop rdi
pop rsi
ret
mov rax, qword [rdi + 0x168]
movzx ecx, byte [rax]
movzx edx, byte [rax + 1]
shl ecx, 8
or edx, ecx
mov dword [rdi + 0xc], edx
sub edx, 3
je 0x140046426
sub edx, 1
je 0x14004649c
sub edx, 1
je 0x1400463e0
cmp edx, 1
je 0x1400463c3
lea r8, str.Internal_error:_Unexpected_packet
mov rcx, rsi
lea rdx, [0x14009a9bc]
call fcn.14002a0a0
jmp 0x14004649c
add r8d, 0xfffffffe
lea rdx, [rax + 2]
mov rcx, rdi
call fcn.140045fb0
test eax, eax
je 0x14004649c
jmp 0x14004634a
mov rdx, rax
lea rbp, [rax + 4]
lea eax, [r8 - 4]
movsxd rbx, eax
movzx ecx, byte [rdx + 2]
movzx eax, byte [rdx + 3]
mov rdx, rbx
shl ecx, 8
or ecx, eax
mov dword [rdi + 8], ecx
mov rcx, rbp
call fcn.140045ed0
cmp rax, rbx
jae 0x14004649c
mov r8, rbp
lea rdx, str.TFTP_error:__s_n
mov rcx, rsi
call fcn.14002a220
jmp 0x14004649c
cmp r8d, 4
jle 0x14004649c
movzx ecx, byte [rax + 2]
mov rdx, rax
movzx eax, byte [rax + 3]
shl ecx, 8
or ecx, eax
movzx eax, word [rdi + 0x48]
inc eax
movzx eax, ax
cmp eax, ecx
jne 0x14004649c
lea eax, [r8 - 4]
mov rcx, r14
lea r8, [rdx + 4]
movsxd r9, eax
mov edx, 1
call fcn.140029fc0
mov ebx, eax
test eax, eax
je 0x14004647b
mov edx, 5
mov rcx, rdi
call fcn.140046f20
mov eax, ebx
jmp 0x14004634a
mov eax, dword [rdi + 0x154]
mov rcx, rsi
sub eax, 4
cdqe
add qword [rsi + 0x110], rax
mov rdx, qword [rsi + 0x110]
call fcn.1400375b0
mov rcx, r14
call fcn.140037880
test eax, eax
je 0x140046348
mov edx, 5
mov rcx, rdi
call fcn.140046f20
mov eax, Ordinal_46
jmp 0x14004634a
Function at 0x14004dbe0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0xc0
mov rax, qword [0x1400feb78]
xor rax, rsp
mov qword [rsp + 0xb0], rax
mov rbp, qword [rcx + 0x248]
lea r8, [rsp + 0x20]
mov rsi, qword [rcx]
lea rdx, [rsp + 0x30]
mov rdi, rcx
mov dword [rsp + 0x20], pe_nt_image_headers64
mov rcx, rbp
mov rbx, 0xffffffffffffffff
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x14004dc5a
lea r8, [rsp + 0x20]
mov dword [rsp + 0x20], pe_nt_image_headers64
lea rdx, [rsp + 0x30]
mov rcx, rbp
call qword [sym.imp.WS2_32.dll_accept]
mov rbx, rax
mov rdx, rbp
mov rcx, rdi
call fcn.14002ad00
mov rcx, rsi
cmp rbx, 0xffffffffffffffff
jne 0x14004dc7f
lea rdx, str.Error_accept__ing_server_connect
call fcn.14002a0a0
lea eax, [rbx + 0x1f]
jmp 0x14004dcfb
lea rdx, str.Connection_accepted_from_server_n
call fcn.14002a220
and dword [rdi + 0x3c4], 0xfffff7ff
mov edx, 1
mov rcx, rbx
mov qword [rdi + 0x248], rbx
call fcn.140056980
mov byte [rdi + 0x261], 1
cmp qword [rsi + 0x738], 0
je 0x14004dcf9
mov dl, 1
mov rcx, rsi
call fcn.14001a1a0
mov rcx, qword [rsi + 0x740]
mov r8d, 1
mov rdx, rbx
call qword [rsi + 0x738]
xor edx, edx
mov rcx, rsi
mov ebx, eax
call fcn.14001a1a0
test ebx, ebx
je 0x14004dcf9
mov rcx, rdi
call fcn.14004e220
mov eax, Ordinal_46
jmp 0x14004dcfb
xor eax, eax
mov rcx, qword [rsp + 0xb0]
xor rcx, rsp
call fcn.140015810
lea r11, [rsp + 0xc0]
mov rbx, qword [r11 + 0x18]
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret

Function at 0x14004ee70
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push rbx
sub rsp, 0x20
mov rax, qword [rcx]
mov rbx, rcx
add rcx, 0x798
test dword [rax + 0xe70], 0x200
jne 0x14004ee98
cmp dword [rax + 0x9f8], 0
je 0x14004eec4
mov r8, qword [rcx + 0x88]
test r8, r8
je 0x14004eec4
lea rdx, str.MDTM__s
call fcn.14005d120
test eax, eax
jne 0x14004eed1
mov dword [rbx + 0x854], 0x12
add rsp, 0x20
pop rbx
ret
mov rcx, rbx
add rsp, 0x20
pop rbx
jmp fcn.14004fcf0
add rsp, 0x20
pop rbx
ret
Function at 0x14004f680
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push rbx
sub rsp, 0x20
mov r8, qword [rcx]
mov rbx, rcx
mov rax, qword [r8 + 0x1f8]
cmp dword [rax + 0x20], 0
je 0x14004f6b5
mov r8d, reloc.WS2_32.dll_listen
mov dword [rcx + 0x854], 0xd
mov dl, 1
add rsp, 0x20
pop rbx
jmp fcn.14004f7c0
mov eax, dword [r8 + 0xe70]
bt eax, 0xe
jae 0x14004f6ce
xor edx, edx
add rsp, 0x20
pop rbx
jmp fcn.1400501f0
test byte [r8 + 0xe74], 1
je 0x14004f76d
mov rcx, qword [rcx + 0x820]
test rcx, rcx
jne 0x14004f727
mov r8, qword [r8 + 0xbf8]
test r8, r8
jne 0x14004f70a
bt eax, 0xd
lea r8, str.LIST
lea rax, str.NLST
cmovb r8, rax
lea rcx, [rbx + 0x798]
lea rdx, str.PRET__s
call fcn.14005d120
test eax, eax
je 0x14004f75d
add rsp, 0x20
pop rbx
ret
mov r8, rcx
lea rcx, [rbx + 0x798]
bt eax, 0x19
jae 0x14004f74d
lea rdx, str.PRET_STOR__s
call fcn.14005d120
test eax, eax
je 0x14004f75d
add rsp, 0x20
pop rbx
ret
lea rdx, str.PRET_RETR__s
call fcn.14005d120
test eax, eax
jne 0x14004f777
mov dword [rbx + 0x854], 0x1d
add rsp, 0x20
pop rbx
ret
add rsp, 0x20
pop rbx
jmp fcn.140050160
add rsp, 0x20
pop rbx
ret

Function at 0x14004fab0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push rbx
sub rsp, 0x20
mov rax, qword [rcx]
mov rbx, rcx
mov rdx, qword [rax + 0x1f8]
cmp dword [rdx + 0x20], 0
je 0x14004fafd
cmp qword [rcx + 0x820], 0
je 0x14004fafd
add rcx, 0x798
lea rdx, str.REST__d
xor r8d, r8d
call fcn.14005d120
test eax, eax
jne 0x14004fb07
mov dword [rbx + 0x854], 0x1a
add rsp, 0x20
pop rbx
ret
add rsp, 0x20
pop rbx
jmp fcn.14004f680
add rsp, 0x20
pop rbx
ret

Function at 0x14004fc90
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
add rcx, 0x798
mov rax, qword [rbx]
mov rdx, qword [rax + 0x1f8]
cmp dword [rdx + 0x20], 1
jne 0x14004fcdc
mov r8, qword [rcx + 0x88]
test r8, r8
je 0x14004fcdc
lea rdx, str.SIZE__s
call fcn.14005d120
test eax, eax
jne 0x14004fce9
mov dword [rbx + 0x854], 0x17
add rsp, 0x20
pop rbx
ret
mov rcx, rbx
add rsp, 0x20
pop rbx
jmp fcn.14004fab0
add rsp, 0x20
pop rbx
ret

Function at 0x14004fcf0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov rdx, qword [rcx]
mov r9, rcx
mov ecx, dword [rdx + 0xe70]
bt ecx, 0x18
jae 0x14004fd4e
cmp qword [r9 + 0x820], 0
je 0x14004fd4e
movsx eax, byte [r9 + 0x844]
shr ecx, 0xb
not cl
and ecx, 1
shl ecx, 3
or ecx, 0x41
cmp eax, ecx
je 0x14004fd4e
mov rax, qword [rdx + 0x1f8]
mov r8d, reloc.WS2_32.dll_send
mov rcx, r9
mov dword [rax + 0x20], 1
mov edx, dword [rdx + 0xe70]
shr edx, 0xb
and dl, 1
jmp fcn.14004e4e0
mov rcx, r9
jmp fcn.14004fc90