joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140024614
Capabilities:
Link many functions at runtime

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x50
mov rax, qword [0x14003e468]
xor rax, rsp
mov qword [rsp + 0x48], rax
mov ebp, r8d
mov r14, rdx
mov r13, rcx
call fcn.14001cae0
xor ebx, ebx
cmp qword [0x140041198], rbx
mov rdi, rax
jne 0x140024727
lea rcx, str.USER32.DLL
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov rsi, rax
test rax, rax
je 0x1400247fe
lea rdx, str.MessageBoxW
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x1400247fe
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_EncodePointer]
lea rdx, str.GetActiveWindow
mov rcx, rsi
mov qword [0x140041198], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_EncodePointer]
lea rdx, str.GetLastActivePopup
mov rcx, rsi
mov qword [0x1400411a0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_EncodePointer]
lea rdx, str.GetUserObjectInformationW
mov rcx, rsi
mov qword [0x1400411a8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_EncodePointer]
mov r11, rax
mov qword [0x1400411b8], rax
test rax, rax
je 0x14002471e
lea rdx, str.GetProcessWindowStation
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_EncodePointer]
mov qword [0x1400411b0], rax
jmp 0x14002472e
mov rax, qword [0x1400411b0]
jmp 0x140024735
mov rax, qword [0x1400411b0]
mov r11, qword [0x1400411b8]
cmp rax, rdi
je 0x14002479c
cmp r11, rdi
je 0x14002479c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_DecodePointer]
mov rcx, qword [0x1400411b8]
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_DecodePointer]
mov r12, rax
test rsi, rsi
je 0x14002479c
test rax, rax
je 0x14002479c
call rsi
test rax, rax
je 0x140024796
lea rcx, [rsp + 0x30]
mov r9d, 0xc
lea r8, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
lea edx, [r9 - 0xb]
mov rcx, rax
call r12
test eax, eax
je 0x140024796
test byte [rsp + 0x40], 1
jne 0x14002479c
bts ebp, 0x15
jmp 0x1400247dc
mov rcx, qword [0x1400411a0]
cmp rcx, rdi
je 0x1400247dc
call qword [sym.imp.KERNEL32.dll_DecodePointer]
test rax, rax
je 0x1400247dc
call rax
mov rbx, rax
test rax, rax
je 0x1400247dc
mov rcx, qword [0x1400411a8]
cmp rcx, rdi
je 0x1400247dc
call qword [sym.imp.KERNEL32.dll_DecodePointer]
test rax, rax
je 0x1400247dc
mov rcx, rbx
call rax
mov rbx, rax
mov rcx, qword [0x140041198]
call qword [sym.imp.KERNEL32.dll_DecodePointer]
test rax, rax
je 0x1400247fe
mov r9d, ebp
mov r8, r14
mov rdx, r13
mov rcx, rbx
call rax
jmp 0x140024800
xor eax, eax
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.1400187e0
add rsp, 0x50
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x140002254
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rbx
sub rsp, 0x20
mov ecx, dword [0x140040d78]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbx, rax
test rax, rax
jne 0x1400022ae
mov r8, qword [0x14003e0a0]
mov rcx, qword [0x140040d58]
lea edx, [rax + 8]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, dword [0x140040d78]
mov rdx, rax
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, rbx
call fcn.14000135b
lea rcx, [0x14000222c]
mov rdx, rbx
call fcn.1400023d0
mov rax, rbx
add rsp, 0x20
pop rbx
ret

Function at 0x1400022b8
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140040d78], eax
add rsp, 0x28
jmp fcn.140002254

Function at 0x1400023d0
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x40
cmp dword [0x140040d80], 0
mov r14, rdx
mov r15, rcx
lea rbx, [0x140040d90]
jne 0x14000241d
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov rcx, rbx
mov dword [0x140040db8], eax
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov dword [0x140040d80], 1
mov ecx, dword [0x140040db8]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbp, rax
test rax, rax
jne 0x1400024f2
mov rcx, qword [0x140040d58]
lea edx, [rax + 8]
lea r8d, [rax + 0x28]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rbp, rax
test rax, rax
je 0x14000251d
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x140040d88]
test rax, rax
je 0x14000246d
mov qword [rax], rbp
mov rcx, rbx
mov qword [rbp + 8], rax
mov qword [0x140040d88], rbp
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
and dword [rsp + 0x30], 0
and dword [rsp + 0x28], 0
lea r9, [rbp + 0x20]
mov r8, rdi
mov rcx, rax
mov rdx, rbx
mov dword [rsp + 0x20], 0x100000
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov rdx, qword [rbp + 0x20]
lea rcx, [rbp + 0x18]
lea r8, [0x140002538]
mov r9, rbp
mov dword [rsp + 0x28], 8
or dword [rsp + 0x20], 0xffffffff
call qword [sym.imp.KERNEL32.dll_RegisterWaitForSingleObject]
mov ecx, dword [0x140040db8]
mov rdx, rbp
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [0x140040d58]
xor edx, edx
lea r8d, [rdx + 0x18]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
test rax, rax
je 0x14000251d
mov qword [rax + 8], r15
mov qword [rax + 0x10], r14
mov rcx, qword [rbp + 0x10]
mov qword [rax], rcx
mov qword [rbp + 0x10], rax
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x70]
add rsp, 0x40
pop r15
pop r14
pop rdi
ret
Function at 0x140002638
Capabilities:
Initialize winsock library

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x1c0
mov ebx, reloc.WS2_32.dll_recv
lea r8, [0x14000254c]
lea ecx, [rbx + 0x28]
mov edx, ebx
call fcn.1400031c8
xor r8d, r8d
xor edx, edx
mov ecx, ebx
mov qword [0x140040dc8], rax
call fcn.140003048
xor ebx, ebx
cmp word [0x140040dc0], bx
mov qword [0x140045a40], rax
jne 0x14000275b
lea rdx, [rsp + 0x20]
mov ecx, 0x101
call qword [sym.imp.WS2_32.dll_WSAStartup]
lea edi, [rbx + 1]
mov word [0x140040dc0], di
test eax, eax
je 0x1400026a9
mov word [0x140040dc0], bx
lea rcx, str.ws2_32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov qword [0x140040df0], rax
test rax, rax
je 0x14000275b
lea rdx, str.getaddrinfo
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140040df0]
lea rdx, str.freeaddrinfo
mov qword [0x140040dd0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140040df0]
lea rdx, str.getnameinfo
mov qword [0x140040dd8], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x140040df0]
lea rdx, str.WSAStringToAddressA
mov qword [0x140040de0], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp qword [0x140040dd0], rbx
mov qword [0x140040de8], rax
je 0x14000275b
cmp qword [0x140040dd8], rbx
je 0x14000275b
cmp qword [0x140040de0], rbx
je 0x14000275b
mov ecx, dword [0x140040dc4]
test rax, rax
cmovne ecx, edi
mov dword [0x140040dc4], ecx
mov rbx, qword [rsp + 0x1d0]
add rsp, 0x1c0
pop rdi
ret

Function at 0x140005b20
Capabilities:
Resume thread

Disassembly:
push rdi
sub rsp, 0x20
mov rcx, qword [0x140045ae0]
call fcn.140003044
cmp dword [0x14003e018], 0
mov rdi, qword [rax]
je 0x140005b97
cmp qword [0x140045b00], rdi
jne 0x140005b97
cmp dword [0x140040e94], 0
je 0x140005b97
mov qword [rsp + 0x30], rbx
mov rbx, qword [0x140040e98]
mov qword [rsp + 0x38], rsi
xor esi, esi
test rbx, rbx
je 0x140005b87
cmp rbx, rdi
je 0x140005b7c
cmp dword [rbx + 0x38], esi
jne 0x140005b7c
mov rcx, qword [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov dword [rbx + 0x38], esi
mov rbx, qword [rbx]
test rbx, rbx
jne 0x140005b68
mov rbx, qword [rsp + 0x30]
mov dword [0x140040e94], esi
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
Function at 0x140005ba0
Capabilities:
Check for time delay via gettickcount
Suspend thread

Disassembly:
push rsi
sub rsp, 0x20
mov rcx, qword [0x140045ae0]
call fcn.140003044
cmp dword [0x14003e018], 0
mov rsi, qword [rax]
je 0x140005ce0
cmp dword [0x140040e94], 0
jne 0x140005ce0
lea rcx, [0x140040ea0]
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x38], rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [0x140040e64], 0
je 0x140005c16
lea rcx, [0x1400463c0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea rcx, [0x140045b40]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [0x140056800]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov qword [0x140045b00], rsi
mov dword [0x140040e94], 1
call qword [sym.imp.USER32.dll_PostThreadMessageA]
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov rbx, qword [0x140040e98]
lea edi, [rax + 0xc8]
test rbx, rbx
je 0x140005c93
cmp rbx, rsi
je 0x140005c8b
cmp dword [rbx + 0x38], 0
jne 0x140005c8b
nop
call qword [sym.imp.KERNEL32.dll_GetTickCount]
cmp eax, edi
jae 0x140005c7b
mov ecx, 1
call qword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [rbx + 0x38], 0
je 0x140005c60
cmp dword [rbx + 0x38], 0
jne 0x140005c8b
mov rcx, qword [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_SuspendThread]
mov rbx, qword [rbx]
test rbx, rbx
jne 0x140005c53
cmp dword [0x140040e64], 0
mov rdi, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
je 0x140005ccd
lea rcx, [0x140045b40]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x1400463c0]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x140040ea0]
add rsp, 0x20
pop rsi
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
add rsp, 0x20
pop rsi
ret
Function at 0x14000a860
Capabilities:
Terminate thread

Disassembly:
push rbx
sub rsp, 0x40
call fcn.14000a670
call fcn.140005ba0
xor ecx, ecx
call fcn.14000ab20
test eax, eax
jne 0x14000a870
mov rbx, qword [0x140040e80]
test rbx, rbx
je 0x14000a950
cmp dword [0x140040e88], eax
je 0x14000a950
cmp dword [0x140040ed0], 0
mov eax, dword [0x140040e74]
mov dword [rsp + 0x20], 0x23
lea eax, [rax*4]
mov dword [rsp + 0x24], eax
je 0x14000a91b
mov rcx, qword [0x140046360]
movsxd r8, eax
mov rdx, rbx
call sub.msvcrt.dll_memcpy
xor r9d, r9d
cmp dword [0x140040e74], r9d
jle 0x14000a914
xor r8d, r8d
nop word [rax + rax]
mov rdx, qword [0x140046360]
inc r9d
add rdx, r8
add r8, 4
movzx ecx, byte [rdx]
movzx eax, byte [rdx + 3]
mov byte [rdx], al
movzx eax, byte [rdx + 2]
mov byte [rdx + 3], cl
movzx ecx, byte [rdx + 1]
mov byte [rdx + 1], al
mov byte [rdx + 2], cl
cmp r9d, dword [0x140040e74]
jl 0x14000a8e0
mov rbx, qword [0x140046360]
call fcn.14001dfe0
lea rcx, [0x140056820]
mov dword [rsp + 0x30], eax
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x140040ef8]
lea rcx, [rsp + 0x20]
mov rdx, rbx
call qword [rax + 0x18]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov dword [rsp + 0x20], 1
call fcn.14001dfe0
lea rcx, [0x140056820]
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x24], 0
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x140040ef8]
lea rcx, [rsp + 0x20]
xor edx, edx
call qword [rax + 0x18]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov rax, qword [0x140040ef8]
call qword [rax + 0x28]
lea rcx, [0x140045b40]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
lea rcx, [0x1400463c0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rcx, qword [0x140040ee8]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateThread]
mov rcx, qword [0x140040ee8]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [0x140040ef0]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateThread]
mov rcx, qword [0x140040ef0]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, [0x140045b40]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x1400463c0]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
lea rcx, [0x140045b40]
call qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
lea rcx, [0x140056820]
call qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
lea rcx, [0x1400463c0]
call qword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
add rsp, 0x40
pop rbx
ret
Function at 0x14000d500
Capabilities:
Hash data with crc32

Disassembly:
xor ecx, ecx
lea rdx, [0x140040f00]
nop dword [rax]
mov eax, ecx
shr eax, 1
test cl, 1
je 0x14000d51e
xor eax, 0xedb88320
test al, 1
je 0x14000d52b
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d52d
shr eax, 1
test al, 1
je 0x14000d53a
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d53c
shr eax, 1
test al, 1
je 0x14000d549
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d54b
shr eax, 1
test al, 1
je 0x14000d558
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d55a
shr eax, 1
test al, 1
je 0x14000d567
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d569
shr eax, 1
test al, 1
je 0x14000d576
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d578
shr eax, 1
test al, 1
je 0x14000d585
shr eax, 1
xor eax, 0xedb88320
jmp 0x14000d587
shr eax, 1
inc ecx
mov dword [rdx], eax
add rdx, 4
cmp ecx, 0x100
jl 0x14000d510
ret

Function at 0x14000edf0
Capabilities:
Get file size
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x110
mov rsi, rdx
lea rdx, [rsp + 0x40]
mov rbp, r8
mov rdi, rcx
xor ebx, ebx
call fcn.14000f620
test eax, eax
je 0x14000eee9
lea rdx, [rsp + 0x40]
mov rcx, rsi
call sub.msvcrt.dll__stricmp
test eax, eax
jne 0x14000eee9
lea rdx, [rsp + 0xa4]
mov rcx, rbp
call sub.msvcrt.dll__stricmp
test eax, eax
jne 0x14000eee9
mov qword [rsp + 0x30], rbx
lea r8d, [rbx + 1]
xor r9d, r9d
mov edx, 0x80000000
mov rcx, rdi
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbp, rax
cmp rax, 0xffffffffffffffff
je 0x14000eee9
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
movsxd rdi, eax
cmp edi, 0xffffffff
je 0x14000eee0
test eax, eax
jle 0x14000eee0
lea ecx, [rdi + 1]
movsxd rcx, ecx
call sub.msvcrt.dll_malloc
mov rsi, rax
test rax, rax
je 0x14000eee0
lea r9, [rsp + 0x138]
mov r8d, edi
mov rdx, rax
mov rcx, rbp
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14000eee0
cmp dword [rsp + 0x138], edi
jne 0x14000eee0
mov rcx, rsi
mov byte [rdi + rsi], bl
call fcn.14000f300
mov ebx, eax
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea r11, [rsp + 0x110]
mov eax, ebx
mov rbx, qword [r11 + 0x10]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
Function at 0x140015b60
Capabilities:
Set console window title

Disassembly:
sub rsp, 0x48
call qword [sym.imp.KERNEL32.dll_AllocConsole]
lea rcx, str.PureBasic_Console_Debugger__press_CtrlC_to_stop_program_
call qword [sym.imp.KERNEL32.dll_SetConsoleTitleA]
mov ecx, 0xfffffff5
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
lea rdx, [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetConsoleScreenBufferInfo]
mov eax, 0x1f4
mov ecx, 0xfffffff5
mov word [rsp + 0x22], ax
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edx, dword [rsp + 0x20]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetConsoleScreenBufferSize]
mov ecx, 0xfffffff6
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edx, 0x4000
mov rcx, rax
call sub.msvcrt.dll__open_osfhandle
lea rdx, [0x1400304d0]
mov ecx, eax
call sub.msvcrt.dll__fdopen
xor r9d, r9d
xor edx, edx
lea r8d, [r9 + 4]
mov rcx, rax
mov qword [0x140041340], rax
call sub.msvcrt.dll_setvbuf
mov ecx, 0xfffffff5
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edx, 0x4000
mov rcx, rax
call sub.msvcrt.dll__open_osfhandle
lea rdx, [0x140032fa0]
mov ecx, eax
call sub.msvcrt.dll__fdopen
xor r9d, r9d
xor edx, edx
lea r8d, [r9 + 4]
mov rcx, rax
mov qword [0x140041348], rax
call sub.msvcrt.dll_setvbuf
mov ecx, 0xfffffff4
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edx, 0x4000
mov rcx, rax
call sub.msvcrt.dll__open_osfhandle
lea rdx, [0x140032fa0]
mov ecx, eax
call sub.msvcrt.dll__fdopen
xor r9d, r9d
xor edx, edx
lea r8d, [r9 + 4]
mov rcx, rax
mov qword [0x140041350], rax
call sub.msvcrt.dll_setvbuf
mov rax, qword [0x140041348]
mov qword [0x140055e20], rax
call fcn.140011cf0
add rsp, 0x48
ret
Function at 0x14001b100
Capabilities:
Get file size
Read file on windows

Disassembly:
push rbx
push rbp
push rsi
push r12
sub rsp, 0x48
xor ebx, ebx
mov r12d, edx
mov ebp, 1
mov qword [rsp + 0x30], rbx
xor r9d, r9d
mov edx, 0x80000000
mov r8d, ebp
mov dword [rsp + 0x28], ebx
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x14001b2d9
xor edx, edx
mov rcx, rax
mov qword [rsp + 0x70], rdi
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp eax, 0xffffffff
je 0x14001b18c
test eax, eax
jle 0x14001b18c
mov rdx, qword [0x140046360]
lea r9, [rsp + 0x80]
mov r8d, eax
mov rcx, rsi
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14001b18c
cmp dword [rsp + 0x80], edi
cmove ebx, ebp
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
je 0x14001b2d4
mov rdx, qword [0x140046360]
mov rax, rdx
cmp dword [rdx], 0x50555245
jne 0x14001b2d4
mov esi, dword [rdx + 8]
add rax, 0xc
lea ecx, [rsi - 0x52455331]
cmp ecx, 8
ja 0x14001b2d4
lea ecx, [rdi - 8]
mov qword [rsp + 0x40], r15
movsxd r15, ecx
lea rcx, [r15 + rdx]
cmp rax, rcx
jae 0x14001b2cf
mov qword [rsp + 0x78], r13
mov qword [rsp + 0x88], r14
lea r13, [0x14001b3f0]
nop word [rax + rax]
cmp dword [rax], 0x434e5354
movsxd rdi, dword [rax + 4]
lea r14, [rax + 8]
jne 0x14001b2ab
test edi, edi
jle 0x14001b2ab
mov rcx, qword [0x140040d58]
lea r8, [rdi + 0x28]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rbx, rax
test rax, rax
je 0x14001b2ab
lea rcx, [rax + 0x28]
mov r8, rdi
mov rdx, r14
mov dword [rax + 0x10], edi
mov dword [rax + 0x14], r12d
mov qword [rax + 8], rcx
call sub.msvcrt.dll_memcpy
cmp esi, 0x52455331
je 0x14001b284
jle 0x14001b29a
cmp esi, 0x52455333
jle 0x14001b270
mov qword [rbx + 0x18], r13
lea rax, [0x14001de80]
jmp 0x14001b296
lea rax, [0x14001b300]
mov qword [rbx + 0x18], rax
lea rax, [0x14001de50]
jmp 0x14001b296
lea rax, [0x14001b2f0]
mov qword [rbx + 0x18], rax
lea rax, [0x14001de40]
mov qword [rbx + 0x20], rax
mov rax, qword [0x140041720]
mov qword [0x140041720], rbx
mov qword [rbx], rax
mov rdx, qword [0x140046360]
lea rax, [r14 + rdi]
add rdx, r15
cmp rax, rdx
jb 0x14001b200
mov r14, qword [rsp + 0x88]
mov r13, qword [rsp + 0x78]
mov r15, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x70]
add rsp, 0x48
pop r12
pop rsi
pop rbp
pop rbx
ret
Function at 0x140020230
Capabilities:
Encode data using xor
Generate random numbers via winapi

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0xc0
mov edi, 1
lea rcx, [rsp + 0xd0]
xor r8d, r8d
xor edx, edx
mov r9d, edi
mov dword [rsp + 0x20], 0xf0000040
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
xor ebx, ebx
test eax, eax
je 0x140020295
mov rcx, qword [rsp + 0xd0]
lea r8, [rsp + 0x30]
lea edx, [rdi + 0x1f]
call qword [sym.imp.ADVAPI32.dll_CryptGenRandom]
mov rcx, qword [rsp + 0xd0]
test eax, eax
cmovne edi, ebx
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
test edi, edi
je 0x140020301
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [rsp + 0x30], eax
call fcn.14001dfe0
mov rcx, rbx
movups xmm0, xmmword [0x14003f550]
mov dword [rsp + 0x34], eax
mov eax, dword [0x140041dc8]
movups xmmword [rsp + 0x40], xmm0
mov dword [rsp + 0x38], eax
movzx eax, byte [rsp + rcx + 0x30]
add rcx, 6
xor byte [rsp + rcx + 0x2b], al
movzx eax, byte [rsp + rcx + 0x2b]
xor byte [rsp + rcx + 0x2c], al
movzx eax, byte [rsp + rcx + 0x2c]
xor byte [rsp + rcx + 0x2d], al
movzx eax, byte [rsp + rcx + 0x2d]
xor byte [rsp + rcx + 0x2e], al
movzx eax, byte [rsp + rcx + 0x2e]
xor byte [rsp + rcx + 0x2f], al
movzx eax, byte [rsp + rcx + 0x2f]
xor byte [rsp + rcx + 0x30], al
cmp rcx, 0x1e
jl 0x1400202c1
lea rcx, [rsp + 0x60]
call fcn.1400288b4
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x60]
mov r8d, 0x20
call fcn.140029144
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x50]
call fcn.1400287d8
lea rdx, [0x140000000]
nop word [rax + rax]
movzx ecx, byte [rsp + rbx + 0x50]
inc rbx
mov eax, ecx
and ecx, 0xf
shr rax, 4
movzx eax, byte [rax + rdx + 0x37778]
mov byte [rdx + rbx*2 + 0x42006], al
movzx eax, byte [rcx + rdx + 0x37778]
mov byte [rdx + rbx*2 + 0x42007], al
cmp rbx, 0x10
jl 0x140020340
lea r8, [0x140042098]
lea rdx, [rsp + 0x30]
lea rcx, [0x140041e20]
mov r9d, 0x20
call fcn.14002aba0
mov rbx, qword [rsp + 0xd8]
add rsp, 0xc0
pop rdi
ret
Function at 0x140020ef0
Capabilities:
Send data
Send data on socket

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
xor ebx, ebx
mov edi, edx
mov rbp, rcx
test edx, edx
jle 0x140020f4b
nop
mov rcx, qword [0x140041de8]
mov r8d, edi
movsxd rdx, ebx
sub r8d, ebx
add rdx, rbp
xor r9d, r9d
call qword [sym.imp.WS2_32.dll_send]
mov esi, eax
cmp eax, 0xffffffff
jne 0x140020f45
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
add eax, 0xffffd8bb
test eax, 0xfffffffa
je 0x140020f65
add ebx, esi
cmp ebx, edi
jl 0x140020f10
mov eax, 1
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret
xor eax, eax
jmp 0x140020f50
Function at 0x140fb2210
Capabilities:
Decompress data using aplib

Disassembly:
call 0x140fb2397
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x140fb2241
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140fb2227
add dl, dl
jne 0x140fb224e
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140fb22ae
xor eax, eax
add dl, dl
jne 0x140fb225d
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x140fb2365
add dl, dl
jne 0x140fb226e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140fb227b
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140fb2288
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140fb2295
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x140fb22a2
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x140fb2236
mov eax, 1
add dl, dl
jne 0x140fb22be
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140fb22cb
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140fb22b3
sub eax, ebx
mov ebx, 1
jne 0x140fb2304
mov ecx, 1
add dl, dl
jne 0x140fb22e6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140fb22f3
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140fb22db
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140fb2236
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x140fb2320
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140fb232d
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140fb2315
cmp eax, 0x7d00
jae 0x140fb2353
cmp eax, 0x500
jb 0x140fb234e
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140fb2236
cmp eax, 0x7f
ja 0x140fb2356
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x140fb2236
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x140fb238a
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x140fb2236
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20