Function at 0x1400217f4
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push rbp
push rbx
push rsi
push r12
push r13
push r14
push r15
sub rsp, 0x4a0
lea rbp, [rsp + 0x40]
mov qword [rbp + 0x30], 0xfffffffffffffffe
mov rax, qword [0x14009b3d0]
xor rax, rbp
mov qword [rbp + 0x450], rax
mov qword [rbp], r9
mov r13, r8
mov r12, rdx
xor ebx, ebx
mov qword [rbp + 8], rbx
mov qword [rbp + 0x28], rcx
and qword [rbp + 0x20], rbx
xor eax, eax
mov qword [rbp + 0x40], rax
test rdx, rdx
je 0x140021ac5
mov rcx, rdx
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcslen]
inc eax
cdqe
lea r15, [rax + rax]
mov eax, 0x80000000
add rax, r15
mov ecx, 0xffffffff
cmp rax, rcx
ja 0x140021935
movsxd rsi, r15d
cmp r15d, 0x400
jg 0x1400218b1
mov rcx, rsi
call fcn.140024b80
test al, al
je 0x1400218b1
lea rax, [rsi + 0xf]
cmp rax, rsi
ja 0x14002189e
movabs rax, 0xffffffffffffff0
and rax, 0xfffffffffffffff0
call fcn.14005dd10
sub rsp, rax
lea r14, [rsp + 0x40]
jmp 0x1400218fa
mov rax, rsi
not rax
cmp rax, 0x10
jb 0x1400218c3
add rsi, 0x10
jmp 0x1400218c7
mov rsi, qword [rbp + 0x18]
cmp rax, 0x10
sbb ecx, ecx
and ecx, 0x80070216
cmp rax, 0x10
jb 0x140021b12
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
test rax, rax
je 0x140021935
and qword [rax], 0
mov rbx, rax
mov qword [rbp + 8], rax
lea r14, [rax + 0x10]
test r14, r14
je 0x140021935
mov byte [r14], 0
and qword [rsp + 0x38], 0
and qword [rsp + 0x30], 0
mov dword [rsp + 0x28], r15d
mov qword [rsp + 0x20], r14
or r9d, 0xffffffff
mov r8, r12
xor edx, edx
lea ecx, [rdx + 3]
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
neg eax
sbb rsi, rsi
and rsi, r14
jmp 0x140021937
xor esi, esi
test rsi, rsi
je 0x140021ac1
xor edx, edx
lea r8d, [rdx + 0x60]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov r14, rax
mov qword [rbp + 0x10], rax
test rax, rax
jne 0x140021982
xor edx, edx
lea r8d, [rax + 2]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LoadLibraryExA]
mov r14, rax
mov qword [rbp + 0x10], rax
test rax, rax
jne 0x140021982
call fcn.14001dd98
mov esi, eax
jmp 0x140021a96
mov r8, qword [rbp]
mov rdx, r13
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_FindResourceA]
mov rsi, rax
test rax, rax
jne 0x1400219a4
call fcn.14001dd98
jmp 0x140021a85
mov rdx, rsi
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov r15, rax
mov qword [rbp + 0x18], rax
test rax, rax
je 0x14002199a
mov rdx, rsi
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
mov dword [rbp], esi
lea eax, [rsi + 1]
cmp eax, esi
jae 0x1400219de
mov esi, 0x8007000e
jmp 0x140021a87
mov r8d, eax
test eax, eax
je 0x140021a0f
xor edx, edx
or rax, 0xffffffffffffffff
div r8
cmp rax, 1
jb 0x140021b18
cmp r8, 0x400
jbe 0x140021a0f
mov edx, r8d
lea rcx, [rbp + 0x40]
call fcn.14001da84
jmp 0x140021a17
lea rax, [rbp + 0x48]
mov qword [rbp + 0x40], rax
jmp 0x140021a28
cmp qword [rbp + 0x40], 0
je 0x1400219d4
mov r9, rsi
mov r8, r15
mov rdx, rsi
mov rcx, qword [rbp + 0x40]
call fcn.140024e7c
test eax, eax
je 0x140021a69
cmp eax, 0xc
je 0x140021b2f
cmp eax, 0x16
je 0x140021b29
cmp eax, 0x22
je 0x140021b29
cmp eax, 0x50
jne 0x140021b23
mov rax, qword [rbp + 0x40]
mov byte [rsi + rax], 0
mov r8d, dword [rbp + 0x4c0]
mov rdx, qword [rbp + 0x40]
lea rcx, [rbp + 0x20]
call fcn.1400214ec
mov esi, eax
test r14, r14
je 0x140021a96
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
nop
lea rax, [rbp + 0x48]
cmp qword [rbp + 0x40], rax
je 0x140021aaa
lea rcx, [rbp + 0x40]
call fcn.14001f474
nop
jmp 0x140021ab8
mov rcx, rbx
mov rbx, qword [rbx]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
test rbx, rbx
jne 0x140021aac
mov eax, esi
jmp 0x140021af0
mov rax, qword [rbp + 0x40]
lea rcx, [rbp + 0x48]
cmp rax, rcx
je 0x140021ad8
lea rcx, [rbp + 0x40]
call fcn.14001f474
nop
jmp 0x140021ae6
mov rcx, rbx
mov rbx, qword [rbx]
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
test rbx, rbx
jne 0x140021ada
mov eax, 0x8007000e
mov rcx, qword [rbp + 0x450]
xor rcx, rbp
call fcn.14005d930
lea rsp, [rbp + reloc.mfc140.dll_Ordinal_1120]
pop r15
pop r14
pop r13
pop r12
pop rsi
pop rbx
pop rbp
ret
call fcn.14001ebd0
nop
mov ecx, 0x80070216
call fcn.14001ebd0
nop
call sub.mfc140.dll_Ordinal_2342
int3
call sub.mfc140.dll_Ordinal_2342
int3
call sub.mfc140.dll_Ordinal_2344
int3