joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14001a8a7
Capabilities:
Terminate process

Disassembly:
mov qword [rsp + 8], rcx
push r15
xor rax, rax
push rax
push rax
push rax
sub rsp, 0x28
call fcn.14003de50
push qword [rsp + 0x50]
push 0
push 1
pop rcx
pop rdx
pop r8
call sub.KERNEL32.dll_OpenProcess
mov qword [rsp + 0x28], rax
mov r15, qword [rsp + 0x28]
and r15, r15
je 0x14001a90b
push 1
push qword [rsp + 0x30]
pop rcx
pop rdx
call sub.KERNEL32.dll_TerminateProcess
and rax, rax
je 0x14001a901
mov qword [rsp + 0x30], 1
push qword [rsp + 0x28]
pop rcx
call sub.KERNEL32.dll_CloseHandle
mov rax, qword [rsp + 0x30]
jmp 0x14001a915
add rsp, 0x40
pop r15
ret

Function at 0x14001eae4
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rcx
mov qword [rsp + 0x10], rdx
push rbp
push r15
mov rax, SafeArrayPutElement
sub rsp, 8
mov qword [rsp], 0
dec rax
jne 0x14001eaf8
sub rsp, 0x28
call fcn.14003de50
mov rdx, qword [rsp + 0xe0]
lea rcx, [rsp + 0x28]
sub rsp, 0x10
call fcn.14003dec0
add rsp, 0x10
lea rax, [rsp + 0x30]
lea rax, [rsp + 0x98]
lea rbp, [rsp + 0x30]
mov dword [rbp], 0x68
mov dword [rbp + 0x3c], 1
mov r15, qword [rsp + 0xe8]
and r15, 2
and r15, r15
je 0x14001eb6a
lea rbp, [rsp + 0x30]
mov word [rbp + 0x40], 0
jmp 0x14001eb75
lea rbp, [rsp + 0x30]
mov word [rbp + 0x40], 1
lea rax, [rsp + 0x98]
mov rax, rax
push rax
lea rax, [rsp + 0x38]
mov rax, rax
push rax
push 0
push 0
push 0
push 0
push 0
push 0
push qword [rsp + 0x68]
push 0
pop rcx
pop rdx
pop r8
pop r9
sub rsp, 0x20
call sub.KERNEL32.dll_CreateProcessW
add rsp, 0x50
mov qword [rsp + 0xb0], rax
cmp qword [rsp + 0xb0], 0
je 0x14001ec44
mov r15, qword [rsp + 0xe8]
and r15, 1
and r15, r15
je 0x14001ec36
lea rbp, [rsp + 0x98]
push qword [rbp + 8]
pop rax
mov qword [rsp + 0xb8], rax
push 1
pop rcx
call fcn.14002aa3c
lea rax, [rsp + 0xc0]
mov rax, rax
push rax
push qword [rsp + 0xc0]
pop rcx
pop rdx
call sub.KERNEL32.dll_GetExitCodeThread
movsxd r15, dword [rsp + 0xc0]
cmp r15, 0x103
je 0x14001ec34
jmp 0x14001ec36
jmp 0x14001ebfc
lea rbp, [rsp + 0x98]
mov rax, qword [rbp]
jmp 0x14001ec47
xor rax, rax
push rax
mov rcx, qword [rsp + 0x30]
sub rsp, 0x28
call fcn.14003df60
add rsp, 0x28
pop rax
add rsp, 0xc8
pop r15
pop rbp
ret

Function at 0x14001f040
Capabilities:
Get thread local storage value

Disassembly:
sub rsp, 0x48
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x30], rcx
call sub.KERNEL32.dll_GetLastError
mov qword [rsp + 0x38], rax
mov rcx, qword [0x14030c150]
call sub.KERNEL32.dll_TlsGetValue
mov rcx, qword [rsp + 0x30]
mov qword [rax + 0x10], rcx
mov rcx, qword [rsp + 0x38]
call sub.KERNEL32.dll_SetLastError
mov rax, qword [rsp + 0x28]
add rsp, 0x48
ret
Function at 0x140020aa8
Capabilities:
Terminate thread

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdi, rcx
call fcn.1400209f0
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateThread]
lea rcx, [0x1403139a0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140311fe8]
jmp 0x140020ae4
cmp qword [rbx + 0x18], rdi
je 0x140020aeb
mov rbx, qword [rbx]
test rbx, rbx
jne 0x140020adb
jmp 0x140020b05
mov rcx, qword [rbx + 0x10]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, [rbx + 0x10]
lea rcx, [0x140311fe8]
call fcn.14003d944
lea rcx, [0x1403139a0]
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140020b20
Capabilities:
Create thread

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rbp
mov qword [r11 + 0x20], rsi
push rdi
sub rsp, 0x30
lea rax, [r11 + 0x18]
mov r9, rdx
mov r8, rcx
mov qword [r11 - 0x10], rax
xor edi, edi
mov edx, 0x1000
xor ecx, ecx
mov dword [rsp + 0x20], edi
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov rbp, rax
test rax, rax
je 0x140020be6
lea rcx, [0x1403139a0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140311fe8]
jmp 0x140020baa
lea rsi, [rbx + 0x10]
xor edx, edx
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x140020ba7
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rbx]
lea rcx, [0x140311fe8]
mov rdx, rsi
call fcn.14003d944
jmp 0x140020baa
mov rbx, qword [rbx]
test rbx, rbx
jne 0x140020b77
mov rdx, qword [0x14030c0c8]
lea rcx, [0x140311fe8]
mov rdi, rdx
inc rdx
mov qword [0x14030c0c8], rdx
lea edx, [rbx + 0x20]
call fcn.14003d98c
lea rcx, [0x1403139a0]
mov qword [rax], rbp
mov qword [rax + 8], rdi
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x58]
mov rax, rdi
add rsp, 0x30
pop rdi
ret
Function at 0x140020d90
Capabilities:
Enumerate gui resources

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x40
test ecx, ecx
je 0x140020e07
movsxd rdx, ecx
lea rcx, [0x140020cec]
call qword [sym.imp.USER32.dll_EnumWindows]
mov rbx, qword [0x140311ff0]
test rbx, rbx
je 0x140020e7a
mov rdi, qword [rbx]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rbx + 0x10], eax
jne 0x140020dfd
cmp byte [rbx + 0x20], 0
je 0x140020dfd
mov rcx, qword [rbx + 0x18]
xor r9d, r9d
mov dword [rsp + 0x30], 3
and dword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
lea rdx, [r9 - 2]
xor r8d, r8d
call qword [sym.imp.USER32.dll_SetWindowPos]
mov rbx, rdi
test rdi, rdi
jne 0x140020dc3
jmp 0x140020e7a
mov rbx, qword [0x140311ff0]
test rbx, rbx
je 0x140020e7a
mov rdi, qword [rbx]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [rbx + 0x10], eax
jne 0x140020e72
cmp byte [rbx + 0x21], 0
je 0x140020e36
mov rcx, qword [rbx + 0x18]
mov edx, 1
call qword [sym.imp.USER32.dll_EnableWindow]
cmp byte [rbx + 0x20], 0
je 0x140020e62
mov rcx, qword [rbx + 0x18]
mov dword [rsp + 0x30], 3
and dword [rsp + 0x28], 0
and dword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
or rdx, 0xffffffffffffffff
call qword [sym.imp.USER32.dll_SetWindowPos]
lea rdx, [rbx + 0x10]
lea rcx, [0x140311ff0]
call fcn.14003d944
mov rbx, rdi
test rdi, rdi
jne 0x140020e13
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x58]
add rsp, 0x40
pop rdi
ret

Function at 0x140020f48
Capabilities:
Accept command line arguments

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x20
mov rdi, rcx
mov rcx, qword [0x140313a40]
call fcn.14003cc20
xor ebp, ebp
or esi, 0xffffffff
mov r14, rax
mov ebx, ebp
call qword [sym.imp.KERNEL32.dll_GetCommandLineW]
movzx edx, word [rax]
test dx, dx
je 0x140021045
mov rcx, qword [rsp + 0x40]
mov r9w, 0x22
cmp dx, 0x20
jne 0x140020f9f
add rax, 2
cmp word [rax], 0x20
je 0x140020f95
movzx edx, word [rax]
mov r8d, 1
cmp dx, r9w
jne 0x140020fdd
add rax, 2
mov rbx, rax
movzx ecx, word [rax]
test cx, cx
je 0x14002101d
cmp cx, r9w
je 0x140020fcf
add rax, 2
movzx ecx, word [rax]
test cx, cx
jne 0x140020fbd
cmp word [rax], bp
je 0x14002101d
mov rcx, rax
add rax, 2
jmp 0x140021025
test dx, dx
je 0x140021022
mov rbx, rax
cmp dx, 0x20
je 0x140020fcf
add rax, 2
cmp word [rax], r9w
jne 0x140021013
add rax, 2
movzx ecx, word [rax]
test cx, cx
je 0x14002101d
cmp cx, r9w
je 0x140021013
add rax, 2
movzx ecx, word [rax]
test cx, cx
jne 0x140021001
movzx edx, word [rax]
test dx, dx
jne 0x140020fe5
jmp 0x140020fcf
mov rcx, rax
jmp 0x140021025
mov r8d, ebp
cmp dword [r14], esi
jne 0x14002102f
test rdi, rdi
jne 0x14002104f
test r8d, r8d
je 0x140021036
inc esi
movzx edx, word [rax]
mov rbx, rbp
test dx, dx
jne 0x140020f8f
test rdi, rdi
jne 0x140021064
movsxd rax, esi
jmp 0x140021066
test rbx, rbx
je 0x140021064
sub rcx, rbx
mov rax, rbx
sar rcx, 1
mov dword [rdi], ecx
inc dword [r14]
jmp 0x140021066
mov dword [rdi], ebp
mov rbx, qword [rsp + 0x48]
mov rbp, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rsi
ret
Function at 0x14002107c
Capabilities:
Accept command line arguments

Disassembly:
sub rsp, 0x28
mov rcx, qword [0x140313a40]
call fcn.14003cc20
xor ecx, ecx
add rsp, 0x28
jmp fcn.140020f48

Function at 0x140021110
Capabilities:
Get thread local storage value

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x20
mov ebx, ecx
mov rcx, qword [0x140313a40]
xor ebp, ebp
mov esi, edx
mov dword [rax + 8], ebp
call fcn.14003cc20
test ebx, ebx
js 0x14002113f
mov dword [rax], ebx
lea rcx, [rsp + 0x30]
call fcn.140020f48
mov edi, dword [rsp + 0x30]
mov edx, esi
mov ecx, edi
mov rbx, rax
call fcn.14003e210
mov ecx, ebp
jmp 0x14002117b
test edi, edi
je 0x140021180
movzx edx, word [rbx]
cmp dx, 0x22
jne 0x14002116e
inc ecx
jmp 0x140021175
mov word [rax], dx
add rax, 2
add rbx, 2
dec edi
cmp word [rbx], bp
jne 0x14002115d
mov word [rax], bp
mov rbx, qword [rsp + 0x38]
mov rbp, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
jmp fcn.14003e350
Function at 0x14002192c
Capabilities:
Read file on windows

Disassembly:
mov rcx, qword [rcx + 0x18]
mov r9d, r8d
or r8d, 0xffffffff
jmp 0x140021b48
mov rax, rsp
mov dword [rax + 0x20], r9d
mov dword [rax + 0x18], r8d
mov dword [rax + 0x10], edx
mov qword [rax + 8], rcx
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x48
xor eax, eax
mov ecx, 0x1000
mov r15d, r9d
mov r13d, r8d
mov edi, ecx
mov esi, eax
mov r14d, eax
mov r12d, eax
cmp edx, 0x18
je 0x140021c87
cmp edx, 2
je 0x140021c87
mov rcx, qword [0x1403117dc]
xor edx, edx
mov r8d, 0x2000
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
xor ecx, ecx
lea r9, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
mov rcx, qword [rsp + 0x90]
lea r8d, [r12 + 2]
lea rdx, [rsp + 0x34]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor ecx, ecx
test eax, eax
je 0x140021c70
mov r15, qword [rsp + 0x90]
mov ebp, edi
cmp dword [rsp + 0x38], 2
jne 0x140021c68
cmp r13d, 0xffffffff
je 0x140021bf5
cmp r14d, r13d
jae 0x140021c68
add r14d, 2
test edi, edi
jne 0x140021c20
mov rcx, qword [0x1403117dc]
movsxd r9, ebp
lea edx, [rdi + 8]
add r9, r9
mov r8, rbx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edi, 0x1000
xor ecx, ecx
mov rbx, rax
movzx eax, word [rsp + 0x34]
cmp ax, 0xa
je 0x140021c68
cmp ax, 0xd
je 0x140021c40
mov word [r12 + rbx], ax
inc esi
inc ebp
add r12, 2
dec edi
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x38]
lea rdx, [rsp + 0x34]
mov r8d, 2
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor ecx, ecx
test eax, eax
jne 0x140021be3
mov r15d, dword [rsp + 0xa8]
movsxd rax, esi
mov edx, r15d
mov word [rbx + rax*2], cx
mov rcx, rbx
call fcn.1400b3e50
jmp 0x140021d50
mov r8, rcx
mov rcx, qword [0x1403117dc]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r15d, dword [rsp + 0xa0]
mov rbp, qword [rsp + 0x90]
mov rbx, rax
mov r13d, edi
cmp r15d, 0xffffffff
je 0x140021cba
cmp r14d, r15d
jae 0x140021d24
xor ecx, ecx
lea r9, [rsp + 0x38]
lea rdx, [rsp + 0x30]
lea r8d, [rcx + 1]
mov qword [rsp + 0x20], rcx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140021d24
cmp dword [rsp + 0x38], 1
jne 0x140021d24
inc r14d
test edi, edi
jne 0x140021d08
mov rcx, qword [0x1403117dc]
lea edx, [rdi + 8]
movsxd r9, r13d
mov r8, rbx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edi, 0x1000
mov rbx, rax
mov al, byte [rsp + 0x30]
cmp al, 0xa
je 0x140021d24
cmp al, 0xd
je 0x140021caf
mov byte [r12 + rbx], al
inc esi
inc r13d
inc r12
dec edi
jmp 0x140021caf
mov r15d, dword [rsp + 0xa8]
xor ecx, ecx
cmp dword [rsp + 0x98], 0x18
movsxd rax, esi
mov edx, r15d
mov byte [rax + rbx], cl
mov rcx, rbx
jne 0x140021d4b
call fcn.1400b3eb0
jmp 0x140021d50
call fcn.1400b4200
mov rcx, qword [0x1403117dc]
mov r8, rbx
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
add rsp, 0x48
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x1400219fc
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x30
xor ebx, ebx
mov edi, r8d
mov rsi, rdx
mov rbp, rcx
test r8d, r8d
jle 0x140021a63
mov rcx, qword [rbp + 0x18]
and dword [rsp + 0x50], 0
and qword [rsp + 0x20], 0
mov r8d, edi
movsxd rdx, ebx
lea r9, [rsp + 0x50]
sub r8d, ebx
add rdx, rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x140021a55
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x140021a5f
add ebx, dword [rsp + 0x50]
cmp ebx, edi
jge 0x140021a63
jmp 0x140021a20
add ebx, dword [rsp + 0x50]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x58]
movsxd rax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
Function at 0x140021b48
Capabilities:
Read file on windows

Disassembly:
mov rcx, qword [rcx + 0x18]
mov r9d, r8d
or r8d, 0xffffffff
jmp 0x140021b48
mov rax, rsp
mov dword [rax + 0x20], r9d
mov dword [rax + 0x18], r8d
mov dword [rax + 0x10], edx
mov qword [rax + 8], rcx
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x48
xor eax, eax
mov ecx, 0x1000
mov r15d, r9d
mov r13d, r8d
mov edi, ecx
mov esi, eax
mov r14d, eax
mov r12d, eax
cmp edx, 0x18
je 0x140021c87
cmp edx, 2
je 0x140021c87
mov rcx, qword [0x1403117dc]
xor edx, edx
mov r8d, 0x2000
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
xor ecx, ecx
lea r9, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
mov rcx, qword [rsp + 0x90]
lea r8d, [r12 + 2]
lea rdx, [rsp + 0x34]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor ecx, ecx
test eax, eax
je 0x140021c70
mov r15, qword [rsp + 0x90]
mov ebp, edi
cmp dword [rsp + 0x38], 2
jne 0x140021c68
cmp r13d, 0xffffffff
je 0x140021bf5
cmp r14d, r13d
jae 0x140021c68
add r14d, 2
test edi, edi
jne 0x140021c20
mov rcx, qword [0x1403117dc]
movsxd r9, ebp
lea edx, [rdi + 8]
add r9, r9
mov r8, rbx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edi, 0x1000
xor ecx, ecx
mov rbx, rax
movzx eax, word [rsp + 0x34]
cmp ax, 0xa
je 0x140021c68
cmp ax, 0xd
je 0x140021c40
mov word [r12 + rbx], ax
inc esi
inc ebp
add r12, 2
dec edi
mov qword [rsp + 0x20], rcx
lea r9, [rsp + 0x38]
lea rdx, [rsp + 0x34]
mov r8d, 2
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_ReadFile]
xor ecx, ecx
test eax, eax
jne 0x140021be3
mov r15d, dword [rsp + 0xa8]
movsxd rax, esi
mov edx, r15d
mov word [rbx + rax*2], cx
mov rcx, rbx
call fcn.1400b3e50
jmp 0x140021d50
mov r8, rcx
mov rcx, qword [0x1403117dc]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r15d, dword [rsp + 0xa0]
mov rbp, qword [rsp + 0x90]
mov rbx, rax
mov r13d, edi
cmp r15d, 0xffffffff
je 0x140021cba
cmp r14d, r15d
jae 0x140021d24
xor ecx, ecx
lea r9, [rsp + 0x38]
lea rdx, [rsp + 0x30]
lea r8d, [rcx + 1]
mov qword [rsp + 0x20], rcx
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140021d24
cmp dword [rsp + 0x38], 1
jne 0x140021d24
inc r14d
test edi, edi
jne 0x140021d08
mov rcx, qword [0x1403117dc]
lea edx, [rdi + 8]
movsxd r9, r13d
mov r8, rbx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edi, 0x1000
mov rbx, rax
mov al, byte [rsp + 0x30]
cmp al, 0xa
je 0x140021d24
cmp al, 0xd
je 0x140021caf
mov byte [r12 + rbx], al
inc esi
inc r13d
inc r12
dec edi
jmp 0x140021caf
mov r15d, dword [rsp + 0xa8]
xor ecx, ecx
cmp dword [rsp + 0x98], 0x18
movsxd rax, esi
mov edx, r15d
mov byte [rax + rbx], cl
mov rcx, rbx
jne 0x140021d4b
call fcn.1400b3eb0
jmp 0x140021d50
call fcn.1400b4200
mov rcx, qword [0x1403117dc]
mov r8, rbx
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
add rsp, 0x48
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x140022c70
Capabilities:
Get file size
Read file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x70
xor edi, edi
mov r13, r8
mov rbx, rdx
lea eax, [rdi + 1]
mov r15, rcx
mov r12d, edi
cmp dword [rcx + 0x10], eax
jne 0x140022e27
test rdx, rdx
je 0x140022e27
mov qword [rsp + 0x30], rdi
lea r8d, [rdi + 7]
xor r9d, r9d
mov edx, 0x80000000
mov rcx, rbx
mov dword [rsp + 0x28], pe_nt_image_headers64
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbp, rax
cmp rax, 0xffffffffffffffff
je 0x140022e27
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov rcx, qword [0x1403117dc]
xor edx, edx
mov eax, eax
mov r8d, 0x200000
mov qword [rsp + 0xc8], rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r14, rax
test rax, rax
je 0x140022e1e
call fcn.140056840
mov rsi, rax
test rax, rax
je 0x140022e0c
lea rdx, [rsp + 0x40]
mov rcx, rbx
call sub.msvcrt.dll__wstat
mov edx, 0x1a4
mov rcx, rsi
call fcn.140056da0
lea rdx, [rsp + 0x40]
mov rcx, rsi
call fcn.140057390
mov rax, qword [r15 + 0x38]
mov ecx, dword [rax + 0x10]
dec ecx
test ecx, 0xfffffffd
je 0x140022d6a
mov rdx, r13
mov rcx, rsi
call fcn.140056310
jmp 0x140022d88
mov rcx, r13
call fcn.1400b4120
mov rcx, rsi
mov rdx, rax
mov rbx, rax
call fcn.140056d90
mov rcx, rbx
call fcn.1400b4110
mov r13, qword [rsp + 0xc8]
mov rcx, rsi
mov rdx, r13
call fcn.140056df0
mov edx, 0x8000
mov rcx, rsi
call fcn.140056be0
mov rcx, qword [r15]
mov rdx, rsi
call fcn.140057540
jmp 0x140022dce
mov rcx, qword [r15]
movsxd r8, eax
mov rdx, r14
movsxd rbx, eax
call fcn.1400574c0
cmp rax, rbx
jne 0x140022df8
add r12, rbx
lea r9, [rsp + 0xb0]
mov r8d, 0x200000
mov rdx, r14
mov rcx, rbp
mov qword [rsp + 0x20], rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [rsp + 0xb0]
test eax, eax
jg 0x140022db5
cmp r12, r13
mov eax, 1
mov rcx, rsi
cmove rdi, rax
call fcn.1400565b0
mov rcx, qword [0x1403117dc]
mov r8, r14
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, rdi
mov rbx, qword [rsp + 0xb8]
add rsp, 0x70
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
Function at 0x140023800
Capabilities:
Initialize winsock library

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x1c0
mov ebx, reloc.WS2_32.dll_recv
lea r8, [0x140023714]
lea ecx, [rbx + 0x28]
mov edx, ebx
call fcn.14003d044
xor r8d, r8d
xor edx, edx
mov ecx, ebx
mov qword [0x140312428], rax
call fcn.14003ccb8
xor ebx, ebx
cmp word [0x140312420], bx
mov qword [0x140313b80], rax
jne 0x14002392b
lea rdx, [rsp + 0x20]
mov ecx, 0x101
call qword [sym.imp.WS2_32.dll_WSAStartup]
lea edi, [rbx + 1]
mov word [0x140312420], di
test eax, eax
je 0x140023871
mov word [0x140312420], bx
lea rcx, str.ws2_32.dll
xor edx, edx
mov r8d, 0x800
call qword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov qword [0x140312450], rax
test rax, rax
je 0x14002392b
lea rdx, str.getaddrinfo
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140312450]
lea rdx, str.freeaddrinfo
mov qword [0x140312430], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140312450]
lea rdx, str.getnameinfo
mov qword [0x140312438], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140312450]
lea rdx, str.WSAStringToAddressA
mov qword [0x140312440], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp qword [0x140312430], rbx
mov qword [0x140312448], rax
je 0x14002392b
cmp qword [0x140312438], rbx
je 0x14002392b
cmp qword [0x140312440], rbx
je 0x14002392b
mov ecx, dword [0x140312424]
test rax, rax
cmovne ecx, edi
mov dword [0x140312424], ecx
mov rbx, qword [rsp + 0x1d0]
add rsp, 0x1c0
pop rdi
ret
Function at 0x140024450
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140312458], 0
jne 0x140024475
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140312458], 1
mov dword [0x14031245c], eax
mov rcx, qword [0x1403117dc]
xor edx, edx
mov r8d, 0x90
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x14031245c]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
xor ebx, eax
mov ecx, ebx
add rsp, 0x20
pop rbx
jmp 0x140024630
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
cmp dword [0x140312458], 0
mov ebx, ecx
jne 0x140024654
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x14002467c
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
lea rdx, [rdi + 8]
mov r8d, reloc.OLEAUT32.dll_SafeArrayGetElemsize
nop word [rax + rax]
imul eax, ebx, 0x53a9b4fb
mov ecx, 1
mov ebx, 1
sub ecx, eax
lea rdx, [rdx + 4]
mov dword [rdx + 0x40], ecx
imul eax, ecx, 0x53a9b4fb
sub ebx, eax
mov dword [rdx - 4], ebx
dec r8
jne 0x140024690
lea esi, [r8 + 0x1f]
mov dword [rdi], r8d
mov dword [rdi + 4], 0xa
lea ebp, [rsi - 0xf]
nop word [rax + rax]
movsxd r11, dword [rdi]
movsxd rbx, dword [rdi + 4]
mov r10d, dword [rdi + rbx*4 + 8]
mov r9d, dword [rdi + r11*4 + 8]
mov eax, dword [rdi + r11*4 + 0x4c]
ror r9d, 5
lea rcx, [rdi + r11*4]
lea r8, [rdi + r11*4]
ror eax, 0xd
add r9d, r10d
add eax, dword [rdi + rbx*4 + 0x4c]
dec r11d
mov dword [r8 + 0x4c], r9d
cmovs r11d, ebp
dec ebx
mov dword [rcx + 8], eax
cmovs ebx, ebp
mov dword [rdi], r11d
mov dword [rdi + 4], ebx
dec rsi
jne 0x1400246d0
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
Function at 0x140024630
Capabilities:
Get thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140312458], 0
jne 0x140024475
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140312458], 1
mov dword [0x14031245c], eax
mov rcx, qword [0x1403117dc]
xor edx, edx
mov r8d, 0x90
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x14031245c]
mov rdx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
xor ebx, eax
mov ecx, ebx
add rsp, 0x20
pop rbx
jmp 0x140024630
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
cmp dword [0x140312458], 0
mov ebx, ecx
jne 0x140024654
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x14002467c
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
lea rdx, [rdi + 8]
mov r8d, reloc.OLEAUT32.dll_SafeArrayGetElemsize
nop word [rax + rax]
imul eax, ebx, 0x53a9b4fb
mov ecx, 1
mov ebx, 1
sub ecx, eax
lea rdx, [rdx + 4]
mov dword [rdx + 0x40], ecx
imul eax, ecx, 0x53a9b4fb
sub ebx, eax
mov dword [rdx - 4], ebx
dec r8
jne 0x140024690
lea esi, [r8 + 0x1f]
mov dword [rdi], r8d
mov dword [rdi + 4], 0xa
lea ebp, [rsi - 0xf]
nop word [rax + rax]
movsxd r11, dword [rdi]
movsxd rbx, dword [rdi + 4]
mov r10d, dword [rdi + rbx*4 + 8]
mov r9d, dword [rdi + r11*4 + 8]
mov eax, dword [rdi + r11*4 + 0x4c]
ror r9d, 5
lea rcx, [rdi + r11*4]
lea r8, [rdi + r11*4]
ror eax, 0xd
add r9d, r10d
add eax, dword [rdi + rbx*4 + 0x4c]
dec r11d
mov dword [r8 + 0x4c], r9d
cmovs r11d, ebp
dec ebx
mov dword [rcx + 8], eax
cmovs ebx, ebp
mov dword [rdi], r11d
mov dword [rdi + 4], ebx
dec rsi
jne 0x1400246d0
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

Function at 0x140024730
Capabilities:
Get thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
cmp dword [0x140312458], 0
mov rbx, rcx
jne 0x140024747
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r9, rax
test rax, rax
jne 0x14002476f
call fcn.140024450
mov ecx, dword [0x14031245c]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r9, rax
movsxd r8, dword [r9]
movsxd rdx, dword [r9 + 4]
mov eax, reloc.WS2_32.dll_recv
mov r10d, dword [r9 + r8*4 + 0x4c]
mov r11d, dword [r9 + r8*4 + 8]
ror r10d, 0xd
add r10d, dword [r9 + rdx*4 + 0x4c]
ror r11d, 5
add r11d, dword [r9 + rdx*4 + 8]
mov dword [r9 + r8*4 + 8], r10d
mov dword [r9 + r8*4 + 0x4c], r11d
dec r8d
mov ecx, r11d
cmovs r8d, eax
dec edx
cmovs edx, eax
mov dword [r9], r8d
mov dword [r9 + 4], edx
inc rbx
je 0x1400247e8
mov edx, r10d
mov r8, rbx
mov eax, ebx
shr r8, 0x20
imul rax, rdx
shr rax, 0x20
imul rcx, r8
imul rdx, r8
shr rcx, 0x20
add rax, rcx
add rax, rdx
add rsp, 0x20
pop rbx
ret
mov eax, r10d
shl rax, 0x20
and rax, rcx
add rsp, 0x20
pop rbx
ret