joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140038910
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
xor r8d, r8d
xor edx, edx
mov rbx, rcx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__fseeki64]
mov edi, 1
lea rcx, [0x140059748]
mov r9, rbx
mov edx, edi
lea r8d, [rdi + 1]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
movzx edx, word [0x140059748]
cmp dl, 0xff
jne 0x14003895d
cmp byte [0x140059749], 0xfe
jne 0x14003898e
lea eax, [rdi + 1]
jmp 0x14003899e
cmp dl, 0xef
jne 0x14003898e
cmp byte [0x140059749], 0xbb
jne 0x14003898e
mov r9, rbx
lea rcx, [0x140059748]
mov r8, rdi
mov rdx, rdi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp byte [0x140059748], 0xbf
jne 0x14003898e
mov eax, edi
jmp 0x14003899e
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll__fseeki64]
xor eax, eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x1400389ac
Capabilities:
Timestomp file

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x40
and qword [rsp + 0x30], 0
mov rdi, rdx
xor r9d, r9d
mov dword [rsp + 0x28], 0x2000000
mov rsi, rcx
mov dword [rsp + 0x20], 3
mov edx, 0x100
mov rcx, qword [rdi + 0x68]
lea r8d, [r9 + 2]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140038a49
lea rcx, [rdi + 0x4c]
lea rdx, [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
lea rcx, [rdi + 0x3c]
lea rdx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
lea rcx, [rdi + 0x2c]
lea rdx, [rsp + 0x68]
call qword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
lea r9, [rsp + 0x68]
mov rcx, rbx
lea r8, [rsp + 0x70]
lea rdx, [rsp + 0x78]
call qword [sym.imp.KERNEL32.dll_SetFileTime]
test eax, eax
jne 0x140038a40
mov rcx, rsi
call sym.luart_static.exe_lua_error
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rsp, 0x40
pop rdi
pop rsi
pop rbx
ret

Function at 0x140038f80
Capabilities:
Terminate process

Disassembly:
push rbx
sub rsp, 0x20
mov r8d, dword [sym.luart_static.exe_TPipe]
mov edx, 1
call sym.luart_static.exe_lua_toself
or edx, 0xffffffff
mov rbx, rax
mov rcx, qword [rax + 0x38]
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov rcx, qword [rbx + 8]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x10]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x18]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x20]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbx + 0x40]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
mov rcx, rbx
lea r8d, [rdx + 0x58]
call sub.VCRUNTIME140.dll_memset
xor eax, eax
add rsp, 0x20
pop rbx
ret
Function at 0x1400398a8
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov ecx, 1
lea edi, [rcx + rax]
mov edx, edi
add rdx, rdx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov rdx, rax
mov ecx, edi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov rax, rbx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x1400398ec
Capabilities:
Copy file
Delete directory
Enumerate files on windows
Enumerate files recursively
Set current directory

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rbp
push rsi
push rdi
push r14
sub rsp, 0x280
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rsp + 0x270], rax
mov rbp, rdx
mov rsi, rcx
mov rcx, rbp
lea rdx, [0x14004da54]
call fcn.14002a56c
mov rcx, rax
mov rbx, rax
call fcn.140039b04
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
xor r14d, r14d
test eax, eax
je 0x140039a0a
lea rdx, [rsp + 0x20]
lea rcx, [0x140050c98]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x1400399e4
cmp word [rsp + 0x4c], 0x2e
movzx eax, word [rsp + 0x4e]
jne 0x140039993
test ax, ax
je 0x1400399d2
cmp word [rsp + 0x4c], 0x2e
jne 0x140039993
cmp ax, 0x2e
jne 0x140039993
cmp word [rsp + 0x50], r14w
je 0x1400399d2
lea rdx, [rsp + 0x4c]
mov rcx, rbp
call fcn.14002a56c
test byte [rsp + 0x20], 0x10
lea rcx, [rsp + 0x4c]
mov rbx, rax
mov rdx, rax
je 0x1400399b9
call fcn.1400398ec
jmp 0x1400399c5
mov r8d, 1
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x140039a0a
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rdx, [rsp + 0x20]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x14003996b
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_FindClose]
lea rcx, [0x14004a734]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
mov eax, 1
jmp 0x140039a0c
xor eax, eax
mov rcx, qword [rsp + 0x270]
xor rcx, rsp
call fcn.1400474b0
lea r11, [rsp + 0x280]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
Function at 0x140039b04
Capabilities:
Create directory

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r14
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__wcsdup]
mov esi, 1
xor ebp, ebp
mov rdi, rax
movzx eax, word [rbx]
lea r14d, [rsi + 0x5b]
test ax, ax
je 0x140039b5c
mov r8d, ebp
mov edx, ebp
cmp ax, 0x2f
jne 0x140039b4c
mov word [rdx + rdi], r14w
add r8, rsi
lea rdx, [r8 + r8]
movzx eax, word [rdx + rbx]
test ax, ax
jne 0x140039b41
mov rcx, rdi
mov edx, r14d
call sub.VCRUNTIME140.dll_wcschr
mov rbx, rax
test rax, rax
je 0x140039bac
cmp word [rax - 2], 0x3a
mov word [rax], bp
je 0x140039b95
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x140039b95
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x140039baa
mov word [rbx], r14w
sub rbx, rdi
sar rbx, 1
lea eax, [rsi + rbx]
cdqe
lea rcx, [rdi + rax*2]
jmp 0x140039b5f
mov esi, ebp
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rbx, qword [rsp + 0x30]
mov eax, esi
mov rsi, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x38]
mov rdi, qword [rsp + 0x48]
add rsp, 0x20
pop r14
ret

Function at 0x140039bd4
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set current directory

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x280
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rsp + 0x270], rax
mov rdi, rcx
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
xor esi, esi
test eax, eax
je 0x140039c9d
lea rdx, [rsp + 0x20]
lea rcx, [0x140050c98]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140039c7c
cmp word [rsp + 0x4c], 0x2e
movzx ecx, word [rsp + 0x4e]
jne 0x140039c4d
test cx, cx
je 0x140039c6a
cmp word [rsp + 0x4c], 0x2e
jne 0x140039c4d
cmp cx, 0x2e
jne 0x140039c4d
cmp word [rsp + 0x50], si
je 0x140039c6a
test byte [rsp + 0x20], 0x10
lea rcx, [rsp + 0x4c]
je 0x140039c60
call fcn.140039bd4
jmp 0x140039c66
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x140039c9d
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x140039c26
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FindClose]
lea rcx, [0x14004a734]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x140039c9f
xor eax, eax
mov rcx, qword [rsp + 0x270]
xor rcx, rsp
call fcn.1400474b0
lea r11, [rsp + 0x280]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
Function at 0x14003a5d8
Capabilities:
Decode data using base64 via winapi

Disassembly:
mov r11, rsp
mov qword [r11 + 0x20], rbx
push rdi
sub rsp, 0x40
mov edx, dword [rcx + 8]
lea rax, [r11 + 0x10]
and dword [rsp + 0x50], 0
xor r9d, r9d
and dword [rsp + 0x60], 0
mov rbx, rcx
mov rcx, qword [rcx + 0x10]
and dword [rsp + 0x58], 0
mov qword [r11 - 0x18], rax
lea r8d, [r9 + 1]
lea rax, [r11 + 0x18]
mov qword [r11 - 0x20], rax
lea rax, [r11 + 8]
mov qword [r11 - 0x28], rax
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x14003a682
mov ecx, dword [rsp + 0x50]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edx, dword [rbx + 8]
mov r8d, 1
mov rcx, qword [rbx + 0x10]
mov rdi, rax
lea rax, [rsp + 0x58]
mov r9, rdi
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x60]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x14003a679
mov eax, dword [rsp + 0x50]
mov qword [rbx + 8], rax
mov qword [rbx + 0x10], rdi
jmp 0x14003a682
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rbx, qword [rsp + 0x68]
add rsp, 0x40
pop rdi
ret

Function at 0x14003a690
Capabilities:
Encode data using base64 via winapi

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 0x20], rsi
push rdi
sub rsp, 0x30
mov rsi, rdx
lea rax, [rax + 0x10]
mov edx, dword [rdx + 8]
mov rbp, rcx
xor ebx, ebx
mov qword [rsp + 0x20], rax
mov dword [rax], ebx
xor r9d, r9d
mov rcx, qword [rsi + 0x10]
mov r8d, 0x40000001
call qword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
test eax, eax
je 0x14003a720
mov ecx, dword [rsp + 0x48]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edx, dword [rsi + 8]
mov r8d, 0x40000001
mov rcx, qword [rsi + 0x10]
mov rdi, rax
lea rax, [rsp + 0x48]
mov r9, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
test eax, eax
je 0x14003a717
mov r8d, dword [rsp + 0x48]
mov rdx, rdi
mov rcx, rbp
call sym.luart_static.exe_lua_pushlstring
mov ebx, 1
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rbp, qword [rsp + 0x50]
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x58]
add rsp, 0x30
pop rdi
ret

Function at 0x14003bdac
Capabilities:
Delete file

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
lea r8, str.DLL_binary_modules
mov edx, 0xfff0b9d8
mov rdi, rcx
call sym.luart_static.exe_lua_getfield
test eax, eax
je 0x14003be2e
mov rcx, rdi
call sym.luart_static.exe_lua_pushnil
jmp 0x14003be1d
xor r8d, r8d
mov rcx, rdi
lea edx, [r8 - 2]
call sym.luart_static.exe_lua_tolwstring
or edx, 0xffffffff
mov rcx, rdi
mov rbx, rax
call sym.luart_static.exe_lua_touserdata
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edx, 0xfffffffe
mov rcx, rdi
call sym.luart_static.exe_lua_settop
mov edx, 0xfffffffe
mov rcx, rdi
call sym.luart_static.exe_lua_next
test eax, eax
jne 0x14003bdd8
mov rbx, qword [rsp + 0x30]
xor eax, eax
add rsp, 0x20
pop rdi
ret
Function at 0x14003be3c
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov edx, 0x64
mov rdi, rcx
xor ecx, ecx
lea r8d, [rdx - 0x5a]
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov rdx, rax
xor ecx, ecx
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov rdx, rbx
xor ecx, ecx
mov qword [0x140059750], rax
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov rcx, qword [0x140059750]
mov edx, eax
test rcx, rcx
je 0x14003bf08
cmp rdx, 2
jbe 0x14003bf08
call fcn.14003c268
mov qword [0x140059708], rax
test rax, rax
je 0x14003bf08
lea rdx, str.package
mov rcx, rdi
call sym.luart_static.exe_lua_getglobal
lea r8, str.searchers
or edx, 0xffffffff
mov rcx, rdi
call sym.luart_static.exe_lua_getfield
xor r8d, r8d
lea rdx, [0x14003c004]
mov rcx, rdi
call sym.luart_static.exe_lua_pushcclosure
mov ebx, 0xfffffffe
mov rcx, rdi
mov edx, ebx
call sym.luart_static.exe_luaL_len
mov edx, ebx
mov rcx, rdi
lea r8, [rax + 1]
call sym.luart_static.exe_lua_rawseti
lea edx, [rbx - 1]
mov rcx, rdi
call sym.luart_static.exe_lua_settop
lea eax, [rbx + 3]
jmp 0x14003bf0a
xor eax, eax
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x14003c268
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
sub rsp, 0x20
mov rsi, rdx
mov rdi, rcx
mov ebp, 1
mov edx, 0x4e078
mov ecx, ebp
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
lea r9, [rsp + 0x40]
mov edx, ebp
lea r8d, [rbp + 3]
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x14003c2bf
mov r8d, dword [rsp + 0x40]
lea r9, [rsp + 0x50]
mov edx, ebp
mov byte [rdi], 0x50
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
mov r9d, 0x806
mov dword [rbx + 0x70], 6
mov r8, rsi
mov rdx, rdi
mov rcx, rbx
call fcn.14002cf10
test eax, eax
jne 0x14003c2e9
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor ebx, ebx
mov rax, rbx
mov rbx, qword [rsp + 0x48]
add rsp, 0x20
pop rdi
pop rsi
pop rbp
ret
Function at 0x14003e248
Capabilities:
Encrypt data via sspi
Send data
Send data on socket

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f]
sub rsp, 0x98
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rbp + 7], rax
mov rsi, qword [rdx + 0x80]
mov r13d, r9d
mov qword [rbp - 0x51], rdx
xor edi, edi
xor edx, edx
mov qword [rbp - 0x59], r8
call qword [sym.luart_static.exe_lua_pushboolean]
xor r15d, r15d
test r13d, r13d
je 0x14003e3a2
mov edx, dword [rsi + 0x20]
mov r14d, r13d
sub r14d, r15d
mov ecx, 1
cmp dword [rsi + 0x28], r14d
cmovb r14d, dword [rsi + 0x28]
add edx, dword [rsi + 0x24]
add edx, r14d
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov r12, rax
test rax, rax
je 0x14003e39a
mov ecx, dword [rsi + 0x20]
movsxd rbx, r14d
add rcx, rax
mov edx, r15d
mov r8, rbx
add rdx, qword [rbp - 0x59]
call sub.VCRUNTIME140.dll_memmove
mov ecx, dword [rsi + 0x20]
lea r8, [rbp - 0x49]
and dword [rbp - 5], 0
xor r9d, r9d
and dword [rbp - 0x49], 0
xor edx, edx
mov dword [rbp - 0x39], ecx
lea rax, [rcx + r12]
mov dword [rbp - 0x35], 7
mov qword [rbp - 0x21], rax
mov eax, dword [rsi + 0x24]
mov dword [rbp - 0x19], eax
lea rax, [rcx + rbx]
mov rbx, qword [rbp - 0x51]
add rax, r12
mov qword [rbp - 0x11], rax
lea rax, [rbp - 0x39]
mov qword [rbp - 0x31], r12
mov dword [rbp - 0x25], 1
mov rcx, qword [rbx + 0x80]
mov dword [rbp - 0x29], r14d
mov dword [rbp - 0x15], 6
mov dword [rbp - 0x45], 4
mov qword [rbp - 0x41], rax
mov rcx, qword [rcx + 0x18]
call sub.Secur32.dll_EncryptMessage
test eax, eax
js 0x14003e38d
mov r8d, dword [rbp - 0x19]
xor r9d, r9d
add r8d, dword [rbp - 0x29]
mov rdx, r12
add r8d, dword [rbp - 0x39]
mov rcx, qword [rbx + 8]
call qword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x14003e395
mov rcx, r12
add edi, eax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add r15d, dword [rsi + 0x28]
cmp r15d, r13d
jb 0x14003e297
jmp 0x14003e3a2
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
or edi, 0xffffffff
jmp 0x14003e3a2
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, edi
mov rcx, qword [rbp + 7]
xor rcx, rsp
call fcn.1400474b0
add rsp, 0x98
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret
Function at 0x14003e8a4
Capabilities:
Resolve dns

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
sub rsp, 0xe0
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rsp + 0xd0], rax
and qword [rsp + 0x28], 0
mov rdi, rcx
movzx esi, r8w
lea rcx, [rsp + 0x30]
mov rax, rdx
mov qword [rsp + 0x20], rcx
mov rcx, rax
xor r9d, r9d
xor r8d, r8d
movzx edx, si
call sub.DNSAPI.dll_DnsQuery_A
mov ebx, eax
mov ebp, 1
test eax, eax
jne 0x14003e978
cmp si, bp
jne 0x14003e913
mov rax, qword [rsp + 0x30]
mov ecx, dword [rax + 0x20]
call qword [sym.imp.WS2_32.dll_inet_ntoa]
mov rdx, rax
jmp 0x14003e961
cmp si, 0x1c
jne 0x14003e958
mov ebx, 0x80
lea rcx, [rsp + 0x50]
mov r8d, ebx
xor edx, edx
call sub.VCRUNTIME140.dll_memset
mov rax, qword [rsp + 0x30]
lea r8, [rsp + 0x50]
mov r9d, ebx
lea rdx, [rsp + 0x38]
lea ecx, [rbx - 0x69]
movups xmm0, xmmword [rax + 0x20]
movdqu xmmword [rsp + 0x38], xmm0
call sub.WS2_32.dll_inet_ntop
lea rdx, [rsp + 0x50]
jmp 0x14003e961
mov rdx, qword [rsp + 0x30]
mov rdx, qword [rdx + 0x20]
mov rcx, rdi
call qword [sym.luart_static.exe_lua_pushstring]
mov rcx, qword [rsp + 0x30]
mov edx, ebp
call sub.DNSAPI.dll_DnsFree
jmp 0x14003e9ae
cmp ebx, 0x251d
je 0x14003e9a5
cmp ebx, 0x25e5
je 0x14003e9a5
cmp ebx, 0x232b
je 0x14003e9a5
xor edx, edx
mov rcx, rdi
call qword [sym.luart_static.exe_lua_pushboolean]
mov ecx, ebx
call qword [sym.imp.WS2_32.dll_WSASetLastError]
jmp 0x14003e9ae
mov rcx, rdi
call qword [sym.luart_static.exe_lua_pushnil]
mov eax, ebp
mov rcx, qword [rsp + 0xd0]
xor rcx, rsp
call fcn.1400474b0
mov rbx, qword [rsp + 0x118]
add rsp, 0xe0
pop rdi
pop rsi
pop rbp
ret
Function at 0x1400410b4
Capabilities:
Reference http user-agent string

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
mov rbp, rsp
sub rsp, 0x80
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rbp - 0x10], rax
xor esi, esi
lea rdx, str.Mozilla_5.0__Windows_NT_6.1__Win64__x64__rv:89.0__Gecko_20100101_Firefox_89.0
xorps xmm0, xmm0
mov rbx, rcx
movups xmmword [rcx + 0x30], xmm0
mov qword [rcx + 0x40], rsi
lea edi, [rsi + 0xf]
mov qword [rcx + 0x48], rdi
lea r8d, [rsi + 0x4d]
mov byte [rcx + 0x30], sil
add rcx, 0x50
movups xmmword [rcx], xmm0
mov qword [rcx + 0x10], rsi
mov qword [rcx + 0x18], rsi
call fcn.140040414
xorps xmm0, xmm0
lea ecx, [rsi + 0x60]
movups xmmword [rbx + 0x70], xmm0
mov qword [rbx + 0x80], rsi
mov qword [rbx + 0x88], rdi
mov byte [rbx + 0x70], sil
movups xmmword [rbx + 0x98], xmm0
mov qword [rbx + 0xa8], rsi
mov qword [rbx + 0xb0], rdi
mov byte [rbx + 0x98], sil
movups xmmword [rbx + 0xc8], xmm0
mov qword [rbx + 0xd8], rsi
mov qword [rbx + 0xe0], rdi
mov byte [rbx + 0xc8], sil
movups xmmword [rbx + 0xe8], xmm0
mov qword [rbx + 0xf8], rsi
mov qword [rbx + 0x100], rdi
mov byte [rbx + 0xe8], sil
movups xmmword [rbx + 0x108], xmm0
mov qword [rbx + 0x118], rsi
mov qword [rbx + 0x120], rdi
mov byte [rbx + 0x108], sil
movups xmmword [rbx + 0x128], xmm0
mov qword [rbx + 0x138], rsi
mov qword [rbx + 0x140], rdi
mov byte [rbx + 0x128], sil
mov word [rbx + 0x148], si
movups xmmword [rbx + 0x150], xmm0
mov qword [rbx + 0x160], rsi
mov qword [rbx + 0x168], rdi
mov byte [rbx + 0x150], sil
mov qword [rbx + 0x101a8], rsi
mov qword [rbx + 0x101b0], rsi
call fcn.1400477cc
movdqa xmm1, xmmword [0x140051d10]
lea rcx, [rbx + 0x101b8]
xorps xmm0, xmm0
movdqa xmmword [rbp - 0x40], xmm1
movups xmmword [rbp - 0x50], xmm0
mov qword [rax], rax
lea rdx, [rbp - 0x60]
mov qword [rax + 8], rax
mov qword [rax + 0x10], rax
mov word [rax + 0x18], 0x101
mov qword [rbx + 0x101a8], rax
lea rax, [rbp - 0x50]
mov qword [rbp - 0x60], rax
lea rax, [rbp - 0x10]
movups xmmword [rbp - 0x30], xmm0
mov qword [rbp - 0x58], rax
mov byte [rbp - 0x50], sil
movdqa xmmword [rbp - 0x20], xmm1
mov byte [rbp - 0x30], sil
call fcn.140040f0c
lea rcx, [rbp - 0x50]
call fcn.140041284
mov rax, rbx
mov rcx, qword [rbp - 0x10]
xor rcx, rsp
call fcn.1400474b0
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret
Function at 0x140044570
Capabilities:
Get file size
Read file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rbp
push rsi
push rdi
push r14
push r15
mov eax, 0x1060
call fcn.1400474e0
sub rsp, rax
mov rax, qword [0x1400593d8]
xor rax, rsp
mov qword [rsp + 0x1050], rax
mov rbp, r8
xor edi, edi
and qword [rsp + 0x30], rdi
mov r15, rdx
mov r14, rcx
mov dword [rsp + 0x28], 0x80
xor r9d, r9d
mov edx, 0x80000000
lea r8d, [rdi + 3]
mov rcx, rbp
mov dword [rsp + 0x20], r8d
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
jne 0x140044609
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
mov rcx, r14
call qword [sym.luart_static.exe_luaL_getlasterror]
xor r8d, r8d
or edx, 0xffffffff
mov rcx, r14
call qword [sym.luart_static.exe_lua_tolstring]
lea rdx, str.cannot_open_File_:__s
mov rcx, r14
mov r8, rax
call qword [sym.luart_static.exe_luaL_error]
lea rdx, [rsp + 0x48]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
jmp 0x14004463c
mov r8d, dword [rsp + 0x40]
lea rdx, [rsp + 0x50]
add edi, dword [rsp + 0x40]
lea rcx, [r15 + 0x150]
call fcn.140042894
mov eax, edi
cmp rax, qword [rsp + 0x48]
jge 0x140044664
and qword [rsp + 0x20], 0
lea r9, [rsp + 0x40]
mov r8d, 0x1000
lea rdx, [rsp + 0x50]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x140044619
jmp 0x1400445d6
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rbp
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, qword [rsp + 0x1050]
xor rcx, rsp
call fcn.1400474b0
mov rbx, qword [rsp + 0x10a8]
add rsp, 0x1060
pop r15
pop r14
pop rdi
pop rsi
pop rbp
ret

Function at 0x140044dc0
Capabilities:
Reference http user-agent string

Disassembly:
push rbx
sub rsp, 0x20
and qword [rcx + 0x10], 0
lea rdx, str.Mozilla_5.0__Windows_NT_6.1__Win64__x64__rv:89.0__Gecko_20100101_Firefox_89.0
mov rbx, rcx
xorps xmm0, xmm0
add rcx, 0x20
mov r8d, 0x4d
movups xmmword [rcx], xmm0
and qword [rcx + 0x10], 0
and qword [rcx + 0x18], 0
call fcn.140040414
mov eax, reloc.WS2_32.dll_ntohs
xorps xmm0, xmm0
movups xmmword [rbx + 0x40], xmm0
and qword [rbx + 0x50], 0
mov qword [rbx + 0x58], rax
mov byte [rbx + 0x40], 0
movups xmmword [rbx + 0x68], xmm0
and qword [rbx + 0x78], 0
mov qword [rbx + 0x80], rax
mov rax, rbx
mov byte [rbx + 0x68], 0
add rsp, 0x20
pop rbx
ret
Function at 0x140045858
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x30
mov rbx, r8
mov rdi, rdx
mov rsi, rcx
call qword [sym.luart_static.exe_lua_pushlightuserdata]
mov r8d, 1
lea rdx, [0x1400456a4]
mov rcx, rsi
call qword [sym.luart_static.exe_lua_pushcclosure]
mov r8d, 1
lea rdx, str.Task
mov rcx, rsi
call qword [sym.luart_static.exe_lua_pushnewinstance]
or edx, 0xffffffff
mov rcx, rsi
call qword [sym.luart_static.exe_lua_pushvalue]
and qword [rsp + 0x28], 0
mov r9, rdi
and dword [rsp + 0x20], 0
mov r8, rbx
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rdi], rax
test rax, rax
je 0x1400458ea
and qword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rsi
call qword [sym.luart_static.exe_lua_callk]
jmp 0x14004591d
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
mov rcx, rsi
call qword [sym.luart_static.exe_luaL_getlasterror]
xor r8d, r8d
or edx, 0xffffffff
mov rcx, rsi
call qword [sym.luart_static.exe_lua_tolstring]
lea rdx, str.async_error_:__s
mov rcx, rsi
mov r8, rax
call qword [sym.luart_static.exe_luaL_error]
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rdi
ret

Function at 0x14004628c
Capabilities:
Parse url

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
push r14
push r15
sub rsp, 0x20
mov ebx, edx
mov rdi, rcx
mov edx, 0x68
mov r14, r8
lea r15d, [rdx - 0x67]
mov ecx, r15d
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
lea r8, [rsp + 0x50]
mov edx, ebx
mov rcx, rdi
mov rsi, rax
call qword [sym.luart_static.exe_lua_tolwstring]
mov qword [r14], rax
mov r9, rsi
mov dword [rsi], 0x68
xor r8d, r8d
mov dword [rsi + 0x20], r15d
mov dword [rsi + 0x30], r15d
mov dword [rsi + 0x40], r15d
mov dword [rsi + 0x50], r15d
mov dword [rsi + 0x10], r15d
mov edx, dword [rsp + 0x50]
mov rcx, qword [r14]
call qword [sym.imp.WININET.dll_InternetCrackUrlW]
test eax, eax
je 0x140046305
mov rax, rsi
jmp 0x140046324
mov ecx, 0x2ee5
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov rcx, qword [r14]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r15
pop r14
pop rdi
ret