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

Disassembly:
mov qword [rsp + 8], rbx
mov eax, r8d
xor r9d, r9d
or al, cl
mov r10, rcx
or al, dl
test al, 7
jne 0x140042e67
shr r8d, 3
test r8d, r8d
je 0x140042f30
cmp r8d, 8
jb 0x140042e3c
lea eax, [r8 - 1]
lea r11, [rcx + rax*8]
lea rax, [rdx + rax*8]
cmp rcx, rax
ja 0x140042dbb
cmp r11, rdx
jae 0x140042e3c
mov r11d, r8d
and r11d, 0xfffffff8
mov ebx, 4
nop word [rax + rax]
movdqu xmm0, xmmword [rcx + r9*8]
lea eax, [rbx - 2]
movdqu xmm1, xmmword [rdx + r9*8]
pxor xmm1, xmm0
movdqu xmmword [rcx + r9*8], xmm1
add r9d, 8
movdqu xmm0, xmmword [rcx + rax*8]
movdqu xmm1, xmmword [rdx + rax*8]
pxor xmm1, xmm0
movdqu xmmword [rcx + rax*8], xmm1
mov eax, ebx
movdqu xmm0, xmmword [rcx + rax*8]
movdqu xmm1, xmmword [rdx + rax*8]
pxor xmm1, xmm0
movdqu xmmword [rcx + rax*8], xmm1
lea eax, [rbx + 2]
add ebx, 8
movdqu xmm0, xmmword [rcx + rax*8]
movdqu xmm1, xmmword [rdx + rax*8]
pxor xmm1, xmm0
movdqu xmmword [rcx + rax*8], xmm1
cmp r9d, r11d
jb 0x140042dd0
cmp r9d, r8d
jae 0x140042f30
sub rdx, r10
lea rcx, [rcx + r9*8]
sub r8d, r9d
mov r9d, r8d
nop dword [rax]
mov rax, qword [rdx + rcx]
xor qword [rcx], rax
lea rcx, [rcx + 8]
sub r9, 1
jne 0x140042e50
mov rbx, qword [rsp + 8]
ret
test r8d, r8d
je 0x140042f30
cmp r8d, 0x40
jb 0x140042f0c
lea eax, [r8 - 1]
lea r11, [rax + rcx]
add rax, rdx
cmp r10, rax
ja 0x140042e93
cmp r11, rdx
jae 0x140042f0c
mov ebx, r8d
and ebx, 0xffffffc0
mov r11d, 0x20
nop
movdqu xmm0, xmmword [r9 + rcx]
lea eax, [r11 - 0x10]
movdqu xmm1, xmmword [r9 + rdx]
pxor xmm1, xmm0
movdqu xmmword [r9 + rcx], xmm1
add r9d, 0x40
movdqu xmm0, xmmword [rax + rcx]
movdqu xmm1, xmmword [rax + rdx]
pxor xmm1, xmm0
movdqu xmmword [rax + rcx], xmm1
mov eax, r11d
movdqu xmm0, xmmword [rax + rcx]
movdqu xmm1, xmmword [rax + rdx]
pxor xmm1, xmm0
movdqu xmmword [rax + rcx], xmm1
lea eax, [r11 + 0x10]
add r11d, 0x40
movdqu xmm0, xmmword [rax + rcx]
movdqu xmm1, xmmword [rax + rdx]
pxor xmm1, xmm0
movdqu xmmword [rax + rcx], xmm1
cmp r9d, ebx
jb 0x140042ea0
cmp r9d, r8d
jae 0x140042f30
mov eax, r9d
sub rdx, r10
add rax, r10
sub r8d, r9d
mov r9d, r8d
nop dword [rax + rax]
movzx ecx, byte [rdx + rax]
xor byte [rax], cl
lea rax, [rax + 1]
sub r9, 1
jne 0x140042f20
mov rbx, qword [rsp + 8]
ret
Function at 0x14004c100
Capabilities:
Enumerate pe sections

Disassembly:
mov r9, rcx
test rdx, rdx
je 0x14004c2c2
test rcx, rcx
je 0x14004c2c2
movzx eax, byte [rdx + 6]
movabs r10, 0xffc0fffffff
movzx r8d, byte [rdx + 7]
movzx ecx, byte [rdx + 0xf]
shl rcx, 8
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 5]
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 4]
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 3]
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 2]
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 1]
shl r8, 8
or r8, rax
movzx eax, byte [rdx]
shl r8, 8
or r8, rax
movzx eax, byte [rdx + 0xe]
or rcx, rax
movzx eax, byte [rdx + 0xd]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0xc]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0xb]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0xa]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 9]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 8]
shl rcx, 8
or rcx, rax
mov rax, r8
and rax, r10
shr r8, 0x2c
mov qword [r9], rax
mov rax, rcx
shr rcx, 0x18
shl rax, 0x14
or r8, rax
movabs rax, 0xfffffc0ffff
and r8, rax
movabs rax, 0xffffffc0f
and rcx, rax
mov qword [r9 + 8], r8
mov qword [r9 + 0x10], rcx
xor r8d, r8d
mov qword [r9 + 0x18], r8
mov qword [r9 + 0x20], r8
mov qword [r9 + 0x28], r8
movzx eax, byte [rdx + 0x16]
movzx ecx, byte [rdx + 0x17]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x15]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x14]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x13]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x12]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x11]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x10]
shl rcx, 8
or rcx, rax
mov qword [r9 + 0x30], rcx
movzx eax, byte [rdx + 0x1e]
movzx ecx, byte [rdx + 0x1f]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x1d]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x1c]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x1b]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x1a]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x19]
shl rcx, 8
or rcx, rax
movzx eax, byte [rdx + 0x18]
shl rcx, 8
or rcx, rax
mov qword [r9 + 0x40], r8
mov qword [r9 + 0x38], rcx
xor eax, eax
mov byte [r9 + 0x58], r8b
ret
mov eax, 0xffffff53
ret
Function at 0x14004c8f0
Capabilities:
Encrypt data using salsa20 or chacha

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x50
mov rax, qword [0x14010bcf8]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov edi, r8d
mov r9, rdx
mov rbx, rcx
test rcx, rcx
je 0x14004c9b9
test rdx, rdx
je 0x14004c9b9
lea eax, [rdi - 0x10]
test eax, 0xffffffef
jne 0x14004c9b9
test dl, 3
je 0x14004c949
mov r8d, edi
lea rcx, [rsp + 0x20]
call fcn.1400b14c0
lea r9, [rsp + 0x20]
mov eax, dword [r9]
lea rcx, [r9 + 0x10]
mov dword [rbx + 0x10], eax
lea rdx, str.expand_32_byte_k0
mov eax, dword [r9 + 4]
cmp edi, 0x20
mov dword [rbx + 0x14], eax
mov eax, dword [r9 + 8]
cmovne rcx, r9
mov dword [rbx + 0x18], eax
mov eax, dword [r9 + 0xc]
mov dword [rbx + 0x1c], eax
lea rax, str.expand_16_byte_k
cmovne rdx, rax
mov eax, dword [rcx]
mov dword [rbx + 0x20], eax
mov eax, dword [rcx + 4]
mov dword [rbx + 0x24], eax
mov eax, dword [rcx + 8]
mov dword [rbx + 0x28], eax
mov eax, dword [rcx + 0xc]
mov dword [rbx + 0x2c], eax
mov eax, dword [rdx]
mov dword [rbx], eax
mov eax, dword [rdx + 4]
mov dword [rbx + 4], eax
mov eax, dword [rdx + 8]
mov dword [rbx + 8], eax
mov eax, dword [rdx + 0xc]
mov dword [rbx + 0xc], eax
xor eax, eax
mov dword [rbx + 0x40], 0
jmp 0x14004c9be
mov eax, 0xffffff53
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.1400b06c0
mov rbx, qword [rsp + 0x78]
add rsp, 0x50
pop rdi
ret
Function at 0x140057da0
Capabilities:
Encode data using xor

Disassembly:
push rsi
sub rsp, 0x450
mov rax, qword [0x14010bcf8]
xor rax, rsp
mov qword [rsp + 0x430], rax
mov esi, r9d
mov r10, rdx
mov r9d, dword [rcx]
neg esi
mov eax, r9d
mov r11, rcx
xor eax, dword [rdx]
and eax, esi
movsxd rdx, r8d
mov dword [rsp], eax
test r8d, r8d
jle 0x140057e92
mov qword [rsp + 0x448], rbx
add rcx, 8
mov qword [rsp + 0x440], rdi
mov rbx, r10
sub rbx, r11
lea rdi, [rsp]
sub rdi, r11
mov r8, rdx
nop dword [rax]
nop word [rax + rax]
mov eax, dword [rbx + rcx]
xor eax, dword [rcx]
lea rcx, [rcx + 4]
and eax, esi
mov dword [rdi + rcx - 4], eax
sub r8, 1
jne 0x140057e10
mov ebx, dword [rsp]
lea rcx, [r11 + 8]
mov rdi, qword [rsp + 0x440]
xor r9d, ebx
mov dword [r11], r9d
mov r8, rdx
lea r9, [rsp]
sub r9, r11
nop dword [rax]
nop dword [rax + rax]
mov eax, dword [rcx + r9]
xor dword [rcx], eax
lea rcx, [rcx + 4]
sub r8, 1
jne 0x140057e50
xor dword [r10], ebx
lea r8, [rsp]
mov rbx, qword [rsp + 0x448]
lea rax, [r10 + 8]
sub r8, r10
nop word [rax + rax]
mov ecx, dword [r8 + rax]
xor dword [rax], ecx
lea rax, [rax + 4]
sub rdx, 1
jne 0x140057e80
jmp 0x140057e9b
xor r9d, eax
mov dword [rcx], r9d
xor dword [r10], eax
xor eax, eax
mov rcx, qword [rsp + 0x430]
xor rcx, rsp
call fcn.1400b06c0
add rsp, 0x450
pop rsi
ret

Function at 0x140058940
Capabilities:
Hash data with md5

Disassembly:
mov qword [rsp + 0x18], rbx
push rsi
sub rsp, 0x20
mov rsi, rdx
mov rbx, rcx
test rcx, rcx
je 0x140058a30
test rdx, rdx
je 0x140058a30
mov eax, dword [rcx]
mov qword [rsp + 0x30], rbp
xor ebp, ebp
mov qword [rsp + 0x38], rdi
lea rdi, [rcx + 0xc]
mov byte [rax + rdi], 0x80
mov ecx, dword [rcx]
inc ecx
mov dword [rbx], ecx
cmp ecx, 0x38
jbe 0x1400589ab
mov r8d, 0x40
xor edx, edx
sub r8d, ecx
add rcx, rdi
call fcn.1400b1300
mov rdx, rdi
mov dword [rbx], 0x40
mov rcx, rbx
call fcn.140057fe0
mov ecx, ebp
mov dword [rbx], ebp
mov r8d, 0x38
xor edx, edx
sub r8d, ecx
add rcx, rdi
call fcn.1400b1300
mov r8d, dword [rbx + 4]
mov rdx, rdi
mov ecx, dword [rbx + 8]
mov eax, r8d
shr eax, 0x1d
lea eax, [rax + rcx*8]
mov rcx, rbx
mov dword [rbx + 8], eax
lea eax, [r8*8]
mov dword [rbx + 4], eax
mov dword [rdi + 0x38], eax
mov eax, dword [rbx + 8]
mov dword [rdi + 0x3c], eax
call fcn.140057fe0
movups xmm0, xmmword [rbx + 0x4c]
mov rdi, qword [rsp + 0x38]
xor eax, eax
movups xmmword [rsi], xmm0
mov qword [rbx], rbp
mov dword [rbx + 8], ebp
mov rbp, qword [rsp + 0x30]
mov dword [rbx + 0x4c], 0x67452301
mov dword [rbx + 0x50], 0xefcdab89
mov dword [rbx + 0x54], 0x98badcfe
mov dword [rbx + 0x58], 0x10325476
mov rbx, qword [rsp + 0x40]
add rsp, 0x20
pop rsi
ret
mov rbx, qword [rsp + 0x40]
mov eax, 0xffffff53
add rsp, 0x20
pop rsi
ret
Function at 0x1400823e0
Capabilities:
Encrypt data using dpapi
Read file on windows

Disassembly:
push rsi
push rdi
sub rsp, 0x68
lea rdx, [0x1400fc754]
mov rdi, rcx
call fcn.1400b8904
mov rsi, rax
test rax, rax
jne 0x140082427
call fcn.1400b8698
mov ecx, dword [rax]
call fcn.1400b86b8
mov r9, rax
lea rdx, [0x1400dbd08]
mov r8, rdi
xor ecx, ecx
call fcn.140082080
xor eax, eax
add rsp, 0x68
pop rdi
pop rsi
ret
mov qword [rsp + 0x88], rbp
xor edx, edx
xor ebp, ebp
mov qword [rsp + 0x90], r14
mov rcx, rsi
lea r8d, [rbp + 2]
call fcn.1400b8e70
mov rcx, rsi
call fcn.1400b936c
movsxd r14, eax
test eax, eax
jns 0x14008247b
call fcn.1400b8698
mov ecx, dword [rax]
call fcn.1400b86b8
mov r9, rax
lea rdx, [0x1400dbd30]
mov r8, rdi
xor ecx, ecx
call fcn.140082080
jmp 0x14008259d
cmp r14d, 0x1000
jl 0x14008249a
mov r8, rdi
lea rdx, [0x1400dbd60]
xor ecx, ecx
call fcn.140082080
jmp 0x14008259d
mov qword [rsp + 0x80], rbx
mov rcx, rsi
mov qword [rsp + 0x60], r15
call fcn.1400b9374
mov rdx, r14
mov ecx, 1
call fcn.140082340
mov r9, rsi
mov r8d, 1
mov rdx, r14
mov rcx, rax
mov r15, rax
call fcn.1400b8ba0
test rax, rax
jne 0x1400824fd
call fcn.1400b8698
mov ecx, dword [rax]
call fcn.1400b86b8
mov r9, rax
lea rdx, [0x1400dbd88]
mov r8, rdi
xor ecx, ecx
call fcn.140082080
jmp 0x140082590
lea rax, [rsp + 0x40]
mov dword [rsp + 0x50], r14d
mov qword [rsp + 0x30], rax
lea rcx, [rsp + 0x50]
xorps xmm0, xmm0
mov dword [rsp + 0x28], 1
xor r9d, r9d
mov qword [rsp + 0x20], rbp
xor r8d, r8d
mov qword [rsp + 0x58], r15
xor edx, edx
movups xmmword [rsp + 0x40], xmm0
call sub.CRYPT32.dll_CryptUnprotectData
test eax, eax
jne 0x14008254c
lea rdx, [0x1400dbce8]
xor ecx, ecx
call fcn.140082080
jmp 0x140082590
mov edx, dword [rsp + 0x40]
mov ecx, 1
inc rdx
call fcn.140082340
mov r8d, dword [rsp + 0x40]
mov rcx, rax
mov rdx, qword [rsp + 0x48]
mov rbx, rax
call fcn.1400b14c0
mov rcx, rbx
call fcn.14007fad0
mov rcx, qword [rsp + 0x48]
mov rbp, rax
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, rbx
call fcn.140082370
mov rbx, qword [rsp + 0x80]
mov r15, qword [rsp + 0x60]
mov rcx, rsi
call fcn.1400b87e4
mov r14, qword [rsp + 0x90]
mov rax, rbp
mov rbp, qword [rsp + 0x88]
add rsp, 0x68
pop rdi
pop rsi
ret
Function at 0x140084f50
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
sub rsp, 0x30
cmp qword [rcx + 0x628], 0
mov rax, r8
mov rbp, rdx
mov rbx, rcx
je 0x140084f8b
lea rdx, [0x1400dcc20]
xor ecx, ecx
call fcn.140082080
mov eax, 0xffffffff
mov rbx, qword [rsp + 0x50]
add rsp, 0x30
pop rbp
ret
lea rdx, [rcx + 0x638]
mov qword [rsp + 0x40], rsi
mov rcx, rax
mov qword [rsp + 0x48], rdi
lea r8, [0x140084a80]
call fcn.1400950b0
mov esi, eax
test eax, eax
jns 0x140084fd6
mov ecx, eax
call fcn.140091550
mov r8, rax
lea rdx, [0x1400dcc60]
mov r9d, esi
xor ecx, ecx
call fcn.140082080
mov eax, 0xffffffff
jmp 0x14008505a
xor eax, eax
mov qword [rbx + 0x638], rbp
mov qword [rsp + 0x28], rax
lea r8, [0x140085120]
mov r9, rbx
mov dword [rsp + 0x20], eax
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
test rax, rax
jne 0x140085044
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140086b90
mov r8, rax
lea rdx, [0x1400dccb0]
xor ecx, ecx
call fcn.140082080
lea rcx, [rbx + 0x638]
call fcn.140093330
test eax, eax
jne 0x14008503d
xor edx, edx
lea rcx, [rbx + 0x638]
call fcn.140093120
mov eax, 0xffffffff
jmp 0x14008505a
mov qword [rbx + 0x628], rax
call qword [sym.imp.WS2_32.dll_WSACreateEvent]
mov qword [rbx + 0x630], rax
xor eax, eax
mov rsi, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x48]
mov rbx, qword [rsp + 0x50]
add rsp, 0x30
pop rbp
ret
Function at 0x140088c90
Capabilities:
Create thread

Disassembly:
jmp 0x140087b80
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rdx
mov rbx, rcx
call fcn.140085dd0
mov rcx, rbx
mov r8, qword [rax]
cmp byte [r8 + 0xbb8], 0
je 0x140087bb7
mov rdx, rdi
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
jmp 0x140088c90
call fcn.140085da0
mov rcx, rax
lea rdx, [fcn.1400822e0]
mov r8, rdi
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
jmp fcn.1400914e0
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
mov rbp, rdx
lea rax, str.called
mov rbx, rcx
mov qword [rsp + 0x20], rax
lea rdx, str.hb_b_
mov ecx, 4
lea r9, str.wintun_read_start
mov r8d, 0x3dc
call fcn.140082160
mov rcx, rbx
call fcn.140085dd0
lea r8, [0x140088a60]
mov rcx, rax
lea rdx, [rbx + 0x268]
call fcn.1400950b0
mov edi, eax
test eax, eax
jns 0x140088d1a
mov ecx, eax
call fcn.140091550
mov r8, rax
lea rdx, str.wintun_read_thread_...__uv_async_init_failed_with_error:__s___d_
mov r9d, edi
xor ecx, ecx
call fcn.140082080
mov eax, edi
jmp 0x140088de3
mov ecx, reloc.WS2_32.dll_recv
call fcn.140082380
xor r9d, r9d
xor r8d, r8d
xor edx, edx
xor ecx, ecx
mov qword [rax], rbx
mov qword [rax + 8], rbp
mov qword [rbx + 0x268], rax
call qword [sym.imp.KERNEL32.dll_CreateEventA]
mov qword [rbx + 0x260], rax
test rax, rax
jne 0x140088d73
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140086b90
mov r8, rax
lea rdx, str.wintun_read_start_...__CreateEvent_failed_with_error:__s
xor ecx, ecx
call fcn.140082080
mov eax, 0xffffffff
jmp 0x140088de3
xor eax, eax
lea r8, [0x140088e00]
mov qword [rsp + 0x28], rax
mov r9, rbx
xor edx, edx
mov dword [rsp + 0x20], eax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
test rax, rax
jne 0x140088dda
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140086b90
mov r8, rax
lea rdx, str.wintun_read_start_...__CreateThread_failed_with_error:__s
xor ecx, ecx
call fcn.140082080
lea rcx, [rbx + 0x268]
call fcn.140093330
test eax, eax
jne 0x140088dd3
xor edx, edx
lea rcx, [rbx + 0x268]
call fcn.140093120
mov eax, 0xffffffff
jmp 0x140088de3
mov qword [rbx + 0x258], rax
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x1400890b0
Capabilities:
Get common file path

Disassembly:
push rbx
sub rsp, 0x250
mov rax, qword [0x14010bcf8]
xor rax, rsp
mov qword [rsp + 0x240], rax
mov rbx, rcx
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x104
call fcn.1400b1300
mov edx, 0x104
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
xor edx, edx
lea rcx, [rsp + 0x130]
mov r8d, 0x104
call fcn.1400b1300
lea r9, [rsp + 0x20]
mov edx, 0x104
lea r8, str._s_netsh.exe
lea rcx, [rsp + 0x130]
call fcn.140082280
xor r8d, r8d
lea rcx, [rsp + 0x130]
mov rdx, rbx
call fcn.140082f80
test eax, eax
je 0x140089152
mov r8d, eax
lea rdx, str.wintun_run_netsh_...__netsh_exit_with_code:__d
xor ecx, ecx
call fcn.140082080
mov eax, 0xffffffff
jmp 0x140089154
xor eax, eax
mov rcx, qword [rsp + 0x240]
xor rcx, rsp
call fcn.1400b06c0
add rsp, 0x250
pop rbx
ret
Function at 0x14008f0e0
Capabilities:
Read file on windows

Disassembly:
mov edx, 0xffffffff
jmp sym.lightway.exe_json_object_from_fd_ex

Function at 0x14008f0f0
Capabilities:
Read file on windows

Disassembly:
push rbx
push rbp
push rdi
mov eax, 0x1030
call fcn.1400b0700
sub rsp, rax
mov rax, qword [0x14010bcf8]
xor rax, rsp
mov qword [rsp + 0x1020], rax
mov edi, edx
mov ebp, ecx
call sym.lightway.exe_printbuf_new
mov rbx, rax
test rax, rax
jne 0x14008f137
lea rcx, str.json_object_from_file:_printbuf_new_failed_n
call fcn.14008efb0
xor eax, eax
jmp 0x14008f249
mov eax, 0x20
mov qword [rsp + 0x1060], rsi
cmp edi, 0xffffffff
cmove edi, eax
mov ecx, edi
call sym.lightway.exe_json_tokener_new_ex
mov rsi, rax
test rax, rax
jne 0x14008f185
call fcn.1400b8698
mov ecx, dword [rax]
call sym.lightway.exe__json_c_strerror
mov r8, rax
lea rcx, str.json_object_from_fd:_unable_to_allocate_json_tokener_depth_d_:__s_n
mov edx, edi
call fcn.14008efb0
mov rcx, rbx
call sym.lightway.exe_printbuf_free
xor eax, eax
jmp 0x14008f241
mov r8d, 0x1000
lea rdx, [rsp + 0x20]
mov ecx, ebp
call fcn.1400c1a1c
test eax, eax
jle 0x14008f1c6
nop dword [rax + rax]
mov r8d, eax
lea rdx, [rsp + 0x20]
mov rcx, rbx
call sym.lightway.exe_printbuf_memappend
mov r8d, 0x1000
lea rdx, [rsp + 0x20]
mov ecx, ebp
call fcn.1400c1a1c
test eax, eax
jg 0x14008f1a0
jns 0x14008f1f9
call fcn.1400b8698
mov ecx, dword [rax]
call sym.lightway.exe__json_c_strerror
mov r8, rax
lea rcx, str.json_object_from_fd:_error_reading_fd__d:__s_n
mov edx, ebp
call fcn.14008efb0
mov rcx, rsi
call sym.lightway.exe_json_tokener_free
mov rcx, rbx
call sym.lightway.exe_printbuf_free
xor eax, eax
jmp 0x14008f241
mov r8d, dword [rbx + 8]
mov rcx, rsi
mov rdx, qword [rbx]
call sym.lightway.exe_json_tokener_parse_ex
mov rdi, rax
test rax, rax
jne 0x14008f22e
mov rcx, rsi
call sym.lightway.exe_json_tokener_get_error
mov ecx, eax
call sym.lightway.exe_json_tokener_error_desc
mov rdx, rax
lea rcx, str.json_tokener_parse_ex_failed:__s_n
call fcn.14008efb0
mov rcx, rsi
call sym.lightway.exe_json_tokener_free
mov rcx, rbx
call sym.lightway.exe_printbuf_free
mov rax, rdi
mov rsi, qword [rsp + 0x1060]
mov rcx, qword [rsp + 0x1020]
xor rcx, rsp
call fcn.1400b06c0
add rsp, 0x1030
pop rdi
pop rbp
pop rbx
ret
Function at 0x140090950
Capabilities:
Generate random numbers via winapi

Disassembly:
push rbx
sub rsp, 0x30
mov qword [rsp + 0x48], 0
call qword [sym.imp.KERNEL32.dll_GetVersion]
mov ecx, 0xf0000040
mov edx, 0xf0000000
cmp al, 4
mov r9d, 1
cmovbe ecx, edx
xor r8d, r8d
mov dword [rsp + 0x20], ecx
xor edx, edx
lea rcx, [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
jne 0x1400909c9
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 2
mov ebx, eax
call fcn.1400b4830
lea rdx, str.error_CryptAcquireContextA_0x_08lx
mov r8d, ebx
mov rcx, rax
call fcn.140007860
xor ecx, ecx
call fcn.1400b9c50
imul eax, eax, 0x19d699a5
add rsp, 0x30
pop rbx
ret
mov rcx, qword [rsp + 0x48]
lea r8, [rsp + 0x40]
mov edx, 4
call qword [sym.imp.ADVAPI32.dll_CryptGenRandom]
mov rcx, qword [rsp + 0x48]
xor edx, edx
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
test ebx, ebx
jne 0x140090a0c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, 2
mov ebx, eax
call fcn.1400b4830
lea rdx, str.error_CryptGenRandom_0x_08lx
jmp 0x1400909ab
mov eax, dword [rsp + 0x40]
add rsp, 0x30
pop rbx
ret

Function at 0x140091520
Capabilities:
Set socket configuration

Disassembly:
mov r8, rdx
mov edx, 0x1002
jmp 0x1400925f0

Function at 0x140091530
Capabilities:
Set socket configuration

Disassembly:
mov r8, rdx
mov edx, 0x1001
jmp 0x1400925f0
sub rsp, 0x38
test rcx, rcx
je 0x14009267d
test r8, r8
je 0x14009267d
mov eax, dword [rcx + 0x10]
cmp eax, 0xc
jne 0x140092613
mov rcx, qword [rcx + 0x110]
jmp 0x14009261c
cmp eax, 0x10
jne 0x140092673
mov rcx, qword [rcx + 0x70]
cmp dword [r8], 0
mov r9, r8
mov r8d, edx
mov dword [rsp + 0x40], 4
mov edx, 0xffff
jne 0x140092647
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getsockopt]
jmp 0x140092655
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x14009266c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.14009c1d0
add rsp, 0x38
ret
xor eax, eax
add rsp, 0x38
ret
mov eax, 0xfffff02f
add rsp, 0x38
ret
mov eax, 0xfffff019
add rsp, 0x38
ret

Function at 0x1400925f0
Capabilities:
Set socket configuration

Disassembly:
mov r8, rdx
mov edx, 0x1001
jmp 0x1400925f0
sub rsp, 0x38
test rcx, rcx
je 0x14009267d
test r8, r8
je 0x14009267d
mov eax, dword [rcx + 0x10]
cmp eax, 0xc
jne 0x140092613
mov rcx, qword [rcx + 0x110]
jmp 0x14009261c
cmp eax, 0x10
jne 0x140092673
mov rcx, qword [rcx + 0x70]
cmp dword [r8], 0
mov r9, r8
mov r8d, edx
mov dword [rsp + 0x40], 4
mov edx, 0xffff
jne 0x140092647
lea rax, [rsp + 0x40]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getsockopt]
jmp 0x140092655
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
jne 0x14009266c
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, eax
call fcn.14009c1d0
add rsp, 0x38
ret
xor eax, eax
add rsp, 0x38
ret
mov eax, 0xfffff02f
add rsp, 0x38
ret
mov eax, 0xfffff019
add rsp, 0x38
ret
Function at 0x140093500
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
mov rsi, rcx
mov rdi, r8
mov rcx, qword [r8 + 0x70]
mov rbx, rdx
cmp rcx, 0xffffffffffffffff
jne 0x140093580
mov eax, dword [rdx + 0x58]
test al, 0x40
je 0x1400935f8
mov edx, eax
and edx, 0xffffffbf
sub dword [rbx + 0x7c], 1
mov dword [rbx + 0x58], edx
jne 0x140093555
test dl, 1
jne 0x140093555
test al, 4
je 0x140093555
and eax, 0xffffffbb
mov dword [rbx + 0x58], eax
test al, 8
je 0x140093555
mov rax, qword [rbx + 8]
dec dword [rax + 8]
cmp qword [rbx + 0x100], 0
je 0x1400935f8
mov ecx, dword [r8 + 0x40]
call fcn.1400a1d10
mov ecx, eax
call fcn.14009c1d0
mov edx, eax
mov rcx, rbx
call qword [rbx + 0x100]
jmp 0x1400935f8
cmp dword [r8 + 0x40], 0
jl 0x1400935d5
lea r9, [rdx + 0x110]
mov dword [rsp + 0x20], 8
mov edx, 0xffff
mov r8d, 0x700b
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jne 0x1400935d5
mov rax, qword [rbx + 0x130]
mov qword [rdi + 0x1a8], rax
mov rax, qword [rbx + 0x100]
mov qword [rbx + 0x130], rdi
test rax, rax
je 0x1400935f8
xor edx, edx
mov rcx, rbx
call rax
jmp 0x1400935f8
mov rcx, qword [rdi + 0x70]
call qword [sym.imp.WS2_32.dll_closesocket]
mov qword [rdi + 0x70], 0xffffffffffffffff
test byte [rbx + 0x58], 0x40
je 0x1400935f8
mov rdx, rdi
mov rcx, rbx
call fcn.1400941c0
mov ecx, dword [rbx + 0x78]
mov eax, dword [rbx + 0x58]
dec ecx
mov dword [rbx + 0x78], ecx
test al, 1
je 0x140093621
test ecx, ecx
jne 0x140093621
test al, 0x20
jne 0x140093621
or eax, 0x20
mov dword [rbx + 0x58], eax
mov rax, qword [rsi + 0x50]
mov qword [rbx + 0x50], rax
mov qword [rsi + 0x50], rbx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret
Function at 0x140093640
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
sub dword [rdx + 0x7c], 1
mov rbp, r8
mov rbx, rdx
mov rdi, rcx
jne 0x14009367f
mov eax, dword [rdx + 0x58]
test al, 1
jne 0x14009367f
test al, 4
je 0x14009367f
and eax, 0xfffffffb
mov dword [rdx + 0x58], eax
test al, 8
je 0x14009367f
mov rax, qword [rdx + 8]
dec dword [rax + 8]
dec dword [rcx + 0x20]
xor edx, edx
mov eax, dword [rbx + 0x118]
mov esi, edx
test eax, eax
je 0x140093698
mov dword [rbx + 0x118], edx
jmp 0x1400936ec
mov ecx, dword [r8 + 0x40]
test ecx, ecx
js 0x1400936e7
test byte [rbx + 0x58], 1
je 0x1400936ad
mov esi, 0x3e3
jmp 0x1400936ee
mov rcx, qword [rbx + 0x110]
xor r9d, r9d
mov dword [rsp + 0x20], edx
mov r8d, 0x7010
mov edx, 0xffff
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jne 0x1400936df
or dword [rbx + 0x58], 0xc080
inc dword [rdi + 0xa8]
jmp 0x1400936ee
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x1400936ec
call fcn.1400a1d10
mov esi, eax
mov ecx, esi
call fcn.14009c1d0
mov edx, eax
mov rcx, rbp
call qword [rbp + reloc.WS2_32.dll_WSASetLastError]
mov ecx, dword [rbx + 0x78]
mov eax, dword [rbx + 0x58]
dec ecx
mov dword [rbx + 0x78], ecx
test al, 1
je 0x140093726
test ecx, ecx
jne 0x140093726
test al, 0x20
jne 0x140093726
or eax, 0x20
mov dword [rbx + 0x58], eax
mov rax, qword [rdi + 0x50]
mov qword [rbx + 0x50], rax
mov qword [rdi + 0x50], rbx
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret