Function at 0x1400038f0
Capabilities:
Print debug messages

Disassembly:
mov rax, rsp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x240
mov qword [rsp + 0x40], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov rdi, rdx
mov rbx, rcx
lea rcx, [rsp + 0x50]
call fcn.140001150
nop
xor ebp, ebp
mov rax, qword [0x1400ec150]
test rax, rax
jne 0x140003962
mov ecx, 0x310
call fcn.140051b7c
mov qword [rsp + 0x288], rax
test rax, rax
je 0x140003958
mov rcx, rax
call fcn.140023810
jmp 0x14000395b
mov rax, rbp
mov qword [0x1400ec150], rax
mov r8, rdi
lea rdx, str.WaitForWPSActive__s_
mov rcx, rax
call fcn.140023be0
mov r8, rdi
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.1400017c0
test eax, eax
jne 0x1400039bb
mov rcx, qword [rsp + 0x60]
test rcx, rcx
je 0x1400039a1
mov rax, qword [rsp + 0x88]
test rax, rax
je 0x1400039a1
call rax
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x1400039b1
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, 1
jmp 0x140003f49
mov rax, qword [0x1400ec150]
test rax, rax
jne 0x1400039f2
mov ecx, 0x310
call fcn.140051b7c
mov qword [rsp + 0x288], rax
test rax, rax
je 0x1400039e8
mov rcx, rax
call fcn.140023810
jmp 0x1400039eb
mov rax, rbp
mov qword [0x1400ec150], rax
lea rdx, str.Waiting_for_printer_wps_to_start...
mov rcx, rax
call fcn.140023be0
mov edi, ebp
mov r13, qword [rsp + 0x60]
mov r12, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x118]
test r13, r13
je 0x140003a99
test rbx, rbx
jne 0x140003a72
test r12, r12
je 0x140003a5b
lea rdx, str.IsWpsRunning
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, rax
mov qword [rsp + 0x118], rax
test rax, rax
jne 0x140003a72
mov dword [rsp + 0x50], 0x7f
lea rcx, str.EWSIntf::is_wps_running:_Function_not_found_in_DLL:_IsWpsRunning_n
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x140003a99
mov dword [rsp + 0x50], 6
lea rcx, str.EWSIntf::is_wps_running:_Attempting_to_lookup_IsWpsRunning_with_no_DLL_handle_n
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x140003a99
mov dword [rsp + 0x288], ebp
lea rdx, [rsp + 0x288]
mov rcx, r13
call rbx
test eax, eax
je 0x140003a99
cmp dword [rsp + 0x288], 1
sete al
cmp al, 1
je 0x140003ab5
mov ecx, 0x1f4
call qword [sym.imp.KERNEL32.dll_Sleep]
add edi, 1
cmp edi, 4
jae 0x140003e4f
jmp 0x140003a15
mov rsi, qword [0x1400ec150]
test rsi, rsi
jne 0x140003b79
mov ecx, 0x310
call fcn.140051b7c
mov rsi, rax
mov qword [rsp + 0x30], rax
test rax, rax
je 0x140003b6f
call fcn.1400588fc
mov rdx, rax
mov ecx, ebp
test rax, rax
setne cl
test ecx, ecx
jne 0x140003aff
mov ecx, 0x80004005
call fcn.140011180
int3
mov rax, qword [rax]
mov rcx, rdx
call qword [rax + 0x18]
add rax, 0x18
mov qword [rsi], rax
mov word [rsi + 0x64], 0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [0x1400bb640]
repne scasw ax, word [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [0x1400bb640]
mov rcx, rsi
call fcn.140010e40
lea rcx, [rsi + 8]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x30]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x26c]
mov word [rcx], 0
lea r8, [0x1400bb648]
mov edx, 0x50
call fcn.14007dab0
nop
jmp 0x140003b72
mov rsi, rbp
mov qword [0x1400ec150], rsi
lea rdx, str.Waiting_for_printer_wps_to_finish...
mov rcx, rsi
call fcn.140023be0
mov r15d, ebp
nop
nop
mov byte [rsp + 0x288], 0
xor r14b, r14b
test rbx, rbx
jne 0x140003bf3
test r12, r12
je 0x140003bdc
lea rdx, str.IsWpsRunning
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, rax
mov qword [rsp + 0x118], rax
test rax, rax
jne 0x140003bf3
mov dword [rsp + 0x50], 0x7f
lea rcx, str.EWSIntf::is_wps_running:_Function_not_found_in_DLL:_IsWpsRunning_n
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x140003c1f
mov dword [rsp + 0x50], 6
lea rcx, str.EWSIntf::is_wps_running:_Attempting_to_lookup_IsWpsRunning_with_no_DLL_handle_n
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x140003c1f
mov dword [rsp + 0x30], ebp
lea rdx, [rsp + 0x30]
mov rcx, r13
call rbx
test eax, eax
je 0x140003c1f
cmp dword [rsp + 0x30], 1
sete r14b
mov byte [rsp + 0x288], 1
test r14b, r14b
je 0x140003de5
mov rsi, qword [0x1400ec150]
test rsi, rsi
jne 0x140003cd9
mov ecx, 0x310
call fcn.140051b7c
mov rsi, rax
mov qword [rsp + 0x38], rax
test rax, rax
je 0x140003ccf
call fcn.1400588fc
mov ecx, ebp
test rax, rax
setne cl
test ecx, ecx
je 0x140003e0f
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rsi], rax
mov word [rsi + 0x64], 0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [0x1400bb640]
repne scasw ax, word [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [0x1400bb640]
mov rcx, rsi
call fcn.140010e40
lea rcx, [rsi + 8]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x30]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x26c]
mov word [rcx], 0
lea r8, [0x1400bb648]
mov edx, 0x50
call fcn.14007dab0
nop
jmp 0x140003cd2
mov rsi, rbp
mov qword [0x1400ec150], rsi
mov r8d, r15d
lea rdx, str.Waiting_for_printer_wps_iteration__d
mov rcx, rsi
call fcn.140023be0
mov rsi, qword [0x1400ec150]
test rsi, rsi
jne 0x140003da5
mov ecx, 0x310
call fcn.140051b7c
mov rsi, rax
mov qword [rsp + 0x38], rax
test rax, rax
je 0x140003d9b
call fcn.1400588fc
mov ecx, ebp
test rax, rax
setne cl
test ecx, ecx
je 0x140003e1a
mov rdx, qword [rax]
mov rcx, rax
call qword [rdx + 0x18]
add rax, 0x18
mov qword [rsi], rax
mov word [rsi + 0x64], 0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [0x1400bb640]
repne scasw ax, word [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [0x1400bb640]
mov rcx, rsi
call fcn.140010e40
lea rcx, [rsi + 8]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x30]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rsi + 0x26c]
mov word [rcx], 0
lea r8, [0x1400bb648]
mov edx, 0x50
call fcn.14007dab0
nop
jmp 0x140003d9e
mov rsi, rbp
mov qword [0x1400ec150], rsi
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx r9d, r14b
movzx r8d, byte [rsp + 0x288]
mov dword [rsp + 0x20], eax
lea rdx, str.____brv_d__running_d__gle_d
mov rcx, rsi
call fcn.140023be0
mov ecx, 0x7d0
call qword [sym.imp.KERNEL32.dll_Sleep]
add r15d, 1
cmp r15d, 0x5a
jae 0x140003e25
jmp 0x140003b90
mov rax, qword [rsp + 0x88]
test rax, rax
je 0x140003df7
mov rcx, r13
call rax
test r12, r12
je 0x140003e05
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, 5
jmp 0x140003f49
mov ecx, 0x80004005
call fcn.140011180
nop
mov ecx, 0x80004005
call fcn.140011180
nop
mov rax, qword [rsp + 0x88]
test rax, rax
je 0x140003e37
mov rcx, r13
call rax
test r12, r12
je 0x140003e45
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, 2
jmp 0x140003f49
mov rbx, qword [0x1400ec150]
test rbx, rbx
jne 0x140003f0f
mov ecx, 0x310
call fcn.140051b7c
mov rbx, rax
mov qword [rsp + 0x38], rax
test rax, rax
je 0x140003f05
call fcn.1400588fc
mov rcx, rax
test rax, rax
setne bpl
test ebp, ebp
jne 0x140003e98
mov ecx, 0x80004005
call fcn.140011180
int3
mov rax, qword [rax]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbx], rax
mov word [rbx + 0x64], 0
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [0x1400bb640]
repne scasw ax, word [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [0x1400bb640]
mov rcx, rbx
call fcn.140010e40
lea rcx, [rbx + 8]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rbx + 0x30]
call qword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea rcx, [rbx + 0x26c]
mov word [rcx], 0
lea r8, [0x1400bb648]
mov edx, 0x50
call fcn.14007dab0
nop
jmp 0x140003f08
mov rbx, rbp
mov qword [0x1400ec150], rbx
lea rdx, str.ERROR:_Printer_wps_never_started
mov rcx, rbx
call fcn.140023be0
nop
test r13, r13
je 0x140003f36
mov rax, qword [rsp + 0x88]
test rax, rax
je 0x140003f36
mov rcx, r13
call rax
test r12, r12
je 0x140003f44
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, 1
lea r11, [rsp + 0x240]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret