Function at 0x140008d40
Capabilities:
Write file on windows

Disassembly:
push rbx
push rsi
sub rsp, 0x3b8
mov rax, qword [0x14023fa70]
xor rax, rsp
mov qword [rsp + 0x3a0], rax
mov rbx, r8
mov esi, edx
test rcx, rcx
jne 0x140008d70
mov ebx, 0x10000
jmp 0x140009039
cmp dword [rcx], 1
je 0x140008d89
mov dword [0x140241ea0], 0x80000
mov eax, 0x80000
jmp 0x140009041
mov qword [rsp + 0x3b0], rdi
mov rdi, qword [rcx + 8]
cmp dword [rdi + 8], 0xffffffff
je 0x140008da3
mov rcx, qword [rdi]
call fcn.140006530
mov rcx, qword [rdi]
mov dword [rdi + 8], 0xffffffff
cmp esi, dword [rcx + 8]
jl 0x140008dbc
mov ebx, 0x10000
jmp 0x140009031
cmp esi, dword [rcx + 0x14]
jge 0x140008dc6
call fcn.140006170
mov rax, qword [rdi]
cmp dword [rax + 0x14], esi
jge 0x140008de1
nop
mov rcx, qword [rdi]
call fcn.1400061d0
mov r11, qword [rdi]
cmp dword [r11 + 0x14], esi
jl 0x140008dd0
lea r8, [rsp + 0x50]
mov edx, esi
mov rcx, rdi
call fcn.140006750
test byte [rsp + 0x158], 0x10
movzx eax, byte [rbx]
je 0x140008e36
cmp al, 0x2f
je 0x140008e25
cmp al, 0x5c
je 0x140008e25
test al, al
je 0x140008e0f
cmp byte [rbx + 1], 0x3a
je 0x140008e25
lea rcx, [rdi + 0x150]
mov rdx, rbx
call fcn.140006d20
xor ebx, ebx
jmp 0x140009031
xor ecx, ecx
mov rdx, rbx
call fcn.140006d20
xor ebx, ebx
jmp 0x140009031
mov qword [rsp + 0x3d8], rbp
mov r9, rbx
mov rcx, rbx
test al, al
je 0x140008e5f
cmp al, 0x2f
je 0x140008e50
cmp al, 0x5c
jne 0x140008e54
lea r9, [rcx + 1]
movzx eax, byte [rcx + 1]
inc rcx
test al, al
jne 0x140008e48
lea rdx, [rsp + 0x180]
mov rcx, rbx
sub rdx, rbx
nop dword [rax]
movzx eax, byte [rcx]
inc rcx
mov byte [rdx + rcx - 1], al
test al, al
jne 0x140008e70
cmp r9, rbx
jne 0x140008e8c
mov byte [rsp + 0x180], al
jmp 0x140008eb8
mov rax, r9
sub rax, rbx
mov byte [rsp + rax + 0x180], 0
movzx eax, byte [rsp + 0x180]
cmp al, 0x2f
je 0x140008eea
cmp al, 0x5c
je 0x140008eea
test al, al
je 0x140008eb8
cmp byte [rsp + 0x181], 0x3a
je 0x140008eea
mov qword [rsp + 0x20], r9
lea r8, [rdi + 0x150]
lea rdx, [0x1401ae6dc]
lea r9, [rsp + 0x180]
lea rcx, [rsp + 0x290]
call qword [sym.imp.USER32.dll_wsprintfA]
lea rcx, [rdi + 0x150]
jmp 0x140008f09
lea r8, [rsp + 0x180]
lea rdx, str._s_s
lea rcx, [rsp + 0x290]
call qword [sym.imp.USER32.dll_wsprintfA]
xor ecx, ecx
lea rdx, [rsp + 0x180]
call fcn.140006d20
mov eax, dword [rsp + 0x158]
xor ebx, ebx
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], eax
lea rcx, [rsp + 0x290]
xor r9d, r9d
xor r8d, r8d
mov edx, 0x40000000
mov dword [rsp + 0x20], 2
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rbp, rax
cmp rax, 0xffffffffffffffff
jne 0x140008f5c
mov ebx, 0x200
jmp 0x140009029
mov rdx, qword [rdi + 0x140]
mov rcx, qword [rdi]
call fcn.140008610
cmp qword [rdi + 0x148], rbx
jne 0x140008f90
mov ecx, 0x4000
call fcn.1400091a0
mov qword [rdi + 0x148], rax
nop word [rax + rax]
mov rdx, qword [rdi + 0x148]
mov rcx, qword [rdi]
lea r9, [rsp + 0x40]
mov r8d, 0x4000
call fcn.140008830
mov esi, eax
cmp eax, 0xffffff96
je 0x140009013
test eax, eax
js 0x140008fe2
jle 0x140008fd8
mov rdx, qword [rdi + 0x148]
lea r9, [rsp + 0x44]
mov r8d, eax
mov rcx, rbp
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140008fe9
cmp byte [rsp + 0x40], bl
jne 0x140008ff0
test esi, esi
jne 0x140008f90
mov ebx, 0x5000000
jmp 0x140009018
mov ebx, 0x400
jmp 0x140009018
lea r9, [rsp + 0x16c]
lea r8, [rsp + 0x15c]
lea rdx, [rsp + 0x164]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_SetFileTime]
jmp 0x140009018
mov ebx, 0x1000
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rdi]
call fcn.140006530
mov rbp, qword [rsp + 0x3d8]
mov rdi, qword [rsp + 0x3b0]
mov eax, ebx
mov dword [0x140241ea0], ebx
mov rcx, qword [rsp + 0x3a0]
xor rcx, rsp
call fcn.1401435e0
add rsp, 0x3b8
pop rsi
pop rbx
ret