Function at 0x1400117e0
Capabilities:
Delete file
Print debug messages
Read .ini file
Set file attributes

Disassembly:
mov r11, rsp
push rbx
push rsi
push r12
push r13
push r15
sub rsp, 0x610
mov rax, qword [0x140074c00]
xor rax, rsp
mov qword [rsp + 0x5f0], rax
xor r15d, r15d
mov r13, r8
mov r12, rcx
mov rbx, rdx
mov qword [r11 + 0x20], rbp
lea rcx, [rsp + 0x52]
lea r8d, [r15 + 0x7e]
xor edx, edx
mov qword [r11 - 0x38], r14
mov word [rsp + 0x50], r15w
call fcn.14003ea70
lea rcx, [rsp + 0xd2]
xor edx, edx
mov r8d, 0x206
mov word [rsp + 0xd0], r15w
call fcn.14003ea70
lea rcx, [rsp + 0x3e2]
xor edx, edx
mov r8d, 0x206
mov word [rsp + 0x3e0], r15w
call fcn.14003ea70
lea rcx, [rsp + 0x2e1]
xor edx, edx
mov r8d, 0xff
mov dword [rsp + 0x44], r15d
mov byte [rsp + 0x40], r15b
mov byte [rsp + 0x41], r15b
mov byte [rsp + 0x42], r15b
mov byte [rsp + 0x2e0], r15b
call fcn.14003ea70
lea r14, [0x14007b800]
lea r9, [rsp + 0x50]
lea r8, [0x140060dbc]
lea rdx, str.PortName
mov rcx, rbx
mov qword [rsp + 0x28], r14
mov dword [rsp + 0x20], 0x80
call qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea r9, [rsp + 0xd0]
lea r8, [0x140060dbc]
lea rdx, str.DeviceName
mov rcx, rbx
mov qword [rsp + 0x28], r14
mov dword [rsp + 0x20], 0x208
call qword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea rbp, [rbx + 0x208]
lea rsi, [rsp + 0x50]
mov rax, rbp
sub rsi, rbp
nop dword [rax]
movzx edx, word [rax]
movzx ecx, word [rax + rsi]
sub edx, ecx
jne 0x140011923
add rax, 2
test ecx, ecx
jne 0x140011910
mov qword [rsp + 0x608], rdi
test edx, edx
jne 0x14001194c
lea rsi, [rsp + 0xd0]
lea rdi, [0x140060dbc]
mov ecx, 1
repe cmpsw word [rsi], word [rdi]
jne 0x140011a46
lea rdx, [rsp + 0x3e0]
mov rcx, rbp
call fcn.140005e70
test eax, eax
jne 0x14001197f
lea rdx, [rsp + 0x3e0]
mov rcx, rbp
call fcn.140004b10
lea rcx, str.GetPrinterDeviceName___get_hDevice
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
jmp 0x14001198c
lea rcx, str.GetPrinterDeviceName_IPP___get_hDevice
call qword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea rdi, [rsp + 0x3e0]
lea rax, [rsp + 0xd0]
mov edx, 0x104
sub rdi, rax
lea rcx, [rsp + 0xd0]
nop dword [rax]
lea rax, [rdx + 0x7ffffefa]
test rax, rax
je 0x1400119d4
movzx eax, word [rdi + rcx]
test ax, ax
je 0x1400119d4
mov word [rcx], ax
add rcx, 2
sub rdx, 1
jne 0x1400119b0
jmp 0x1400119d9
test rdx, rdx
jne 0x1400119dd
sub rcx, 2
mov word [rcx], r15w
mov edi, 5
nop word [rax + rax]
lea r8, [rsp + 0xd0]
lea rdx, str.DeviceName
mov r9, r14
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
test eax, eax
jne 0x140011a46
sub edi, 1
jne 0x1400119f0
mov edx, 0x80
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
lea r8, [rsp + 0xd0]
lea rdx, str.DeviceName
mov r9, r14
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
xor r9d, r9d
mov qword [rsp + 0x30], r15
lea rcx, [rsp + 0xd0]
lea r8d, [r9 + 3]
mov edx, 0xc0000000
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r14, qword [rsp + 0x600]
mov rbp, qword [rsp + 0x658]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x140011b33
mov edi, 3
nop word [rax + rax]
mov qword [rsp + 0x38], r15
lea rax, [rsp + 0x44]
lea r8, [rsp + 0x40]
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x2e0]
mov r9d, 3
mov edx, 0x22003c
mov rcx, rsi
mov dword [rsp + 0x28], 0xff
mov qword [rsp + 0x20], rax
dec edi
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x140011b09
lea ecx, [rax + 0x14]
call qword [sym.imp.KERNEL32.dll_Sleep]
test edi, edi
jne 0x140011aa0
mov rcx, rsi
mov byte [rbx + 0x488], 0x7e
mov byte [rbx + 0x489], r15b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x140011b41
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, [rsp + 0x2e0]
mov r8, rbx
mov rcx, r12
call fcn.140012700
mov dword [r13], eax
mov dword [r12 + 0x90], r15d
jmp 0x140011b41
mov byte [rbx + 0x488], 0x7e
mov byte [rbx + 0x489], r15b
mov rdi, qword [rsp + 0x608]
mov rcx, qword [rsp + 0x5f0]
xor rcx, rsp
call fcn.14003d6d0
add rsp, 0x610
pop r15
pop r13
pop r12
pop rsi
pop rbx
ret