Function at 0x418a91
Capabilities:
Print debug messages
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2d0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x10], 0
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
push 0x539bfc
push 0x539af8
call fcn.004cf9b0
add esp, 8
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2c8], eax
cmp dword [ebp - 0x2c8], 1
je 0x418aec
cmp dword [ebp - 0x2c8], 2
je 0x418b15
jmp 0x418b3e
mov dword [ebp - 0x28], 0x51b030
mov dword [ebp - 0x24], 0x51b040
push str.PHONE.xml
push 0x539af8
call fcn.004cf9c0
add esp, 8
mov dword [ebp - 8], 0xa
jmp 0x418b65
mov dword [ebp - 0x28], 0x51b05c
mov dword [ebp - 0x24], 0x51b06c
push str.EMAIL.xml
push 0x539af8
call fcn.004cf9c0
add esp, 8
mov dword [ebp - 8], 0xa
jmp 0x418b65
mov dword [ebp - 0x28], 0x51b088
mov dword [ebp - 0x24], 0x51b094
push str.PSU.xml
push 0x539af8
call fcn.004cf9c0
add esp, 8
mov dword [ebp - 8], 0xa
push 0x80
push 0x539af8
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
call fcn.0040883f
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x418b8a
xor eax, eax
jmp 0x418fa1
mov ecx, dword [ebp - 8]
push ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.004089d2
mov dword [ebp - 0x1c], eax
xor eax, eax
mov ax, word [0x539af6]
test eax, eax
je 0x418be7
push str._RCP____GET_XML_file_Size__n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [ebp - 8]
push ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.0044ce83
add esp, 8
mov eax, dword [ebp - 0x1c]
push eax
push 0x51b0cc
lea ecx, [ebp - 0xa8]
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea edx, [ebp - 0xa8]
push edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [ebp - 0x1c]
cmp eax, dword [ebp - 8]
je 0x418c2d
xor ecx, ecx
mov cx, word [0x539af6]
test ecx, ecx
je 0x418c07
push 0x51b0e4
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [ebp - 0x28], 0
je 0x418c14
mov dword [ebp - 0x28], 0
cmp dword [ebp - 0x24], 0
je 0x418c21
mov dword [ebp - 0x24], 0
call fcn.00408962
xor eax, eax
jmp 0x418fa1
push 8
lea edx, [ebp - 0x18]
push edx
call fcn.00408a86
mov dword [ebp - 0x1c], eax
xor eax, eax
mov ax, word [0x539af6]
test eax, eax
je 0x418c7b
mov ecx, dword [ebp - 0x1c]
push ecx
push str._RCP__ReadData___d__n
lea edx, [ebp - 0x128]
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x128]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 8
lea ecx, [ebp - 0x18]
push ecx
call fcn.0044ce83
add esp, 8
cmp dword [ebp - 0x1c], 8
jne 0x418c9c
mov edx, dword [ebp - 0x18]
and edx, 0xff
cmp edx, 0x1b
jne 0x418c9c
mov eax, dword [ebp - 0x17]
and eax, 0xff
cmp eax, 0x23
je 0x418cb3
push str._RCP__Header_Read_ERROR___n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call fcn.00408962
xor eax, eax
jmp 0x418fa1
mov ecx, dword [ebp - 0x16]
and ecx, 0xff
shl ecx, 8
shl ecx, 8
shl ecx, 8
mov edx, dword [ebp - 0x15]
and edx, 0xff
shl edx, 8
shl edx, 8
add ecx, edx
mov eax, dword [ebp - 0x14]
and eax, 0xff
shl eax, 8
add ecx, eax
mov edx, dword [ebp - 0x13]
and edx, 0xff
add ecx, edx
mov dword [ebp - 0x20], ecx
mov eax, dword [ebp - 0x20]
push eax
call fcn.004e8de9
add esp, 4
mov dword [ebp - 0x2ac], eax
mov ecx, dword [ebp - 0x2ac]
mov dword [ebp - 0xc], ecx
cmp dword [ebp - 0xc], 0
je 0x418d26
mov edx, dword [ebp - 0x20]
push edx
push 0
mov eax, dword [ebp - 0xc]
push eax
call fcn.004cf390
add esp, 0xc
jmp 0x418d86
xor ecx, ecx
mov cx, word [0x539af6]
test ecx, ecx
je 0x418d3e
push str._PSU__XML_GetPrinterInfo_____Memory_Allocation_error___n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [ebp - 0x28], 0
je 0x418d5c
mov edx, dword [ebp - 0x28]
mov dword [ebp - 0x2b0], edx
mov eax, dword [ebp - 0x2b0]
push eax
call fcn.004e8e12
add esp, 4
cmp dword [ebp - 0x24], 0
je 0x418d7a
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x2b4], ecx
mov edx, dword [ebp - 0x2b4]
push edx
call fcn.004e8e12
add esp, 4
call fcn.00408962
xor eax, eax
jmp 0x418fa1
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp - 0x24]
push ecx
call fcn.004089d2
mov dword [ebp - 0x1c], eax
xor edx, edx
mov dx, word [0x539af6]
test edx, edx
je 0x418de4
push str._RCP____GET_Printer_Setting_XML_file___n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp - 0x24]
push ecx
call fcn.0044ce83
add esp, 8
mov edx, dword [ebp - 0x1c]
push edx
push str._RCP__WriteData___d__n
lea eax, [ebp - 0x1a8]
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea ecx, [ebp - 0x1a8]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov edx, dword [ebp - 0x1c]
cmp edx, dword [ebp - 8]
je 0x418e47
xor eax, eax
mov ax, word [0x539af6]
test eax, eax
je 0x418e03
push str._PSU__XML_data_Read_ERROR___n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
cmp dword [ebp - 0xc], 0
je 0x418e21
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x2b8], ecx
mov edx, dword [ebp - 0x2b8]
push edx
call fcn.004e8e12
add esp, 4
cmp dword [ebp - 0x28], 0
je 0x418e2e
mov dword [ebp - 0x28], 0
cmp dword [ebp - 0x24], 0
je 0x418e3b
mov dword [ebp - 0x24], 0
call fcn.00408962
xor eax, eax
jmp 0x418fa1
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
call fcn.00408a86
mov dword [ebp - 0x1c], eax
xor edx, edx
mov dx, word [0x539af6]
test edx, edx
je 0x418ec0
mov eax, dword [ebp - 0x20]
push eax
push str._PSU__Request_XML_File_Size_to_read___d__n
lea ecx, [ebp - 0x228]
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea edx, [ebp - 0x228]
push edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [ebp - 0x1c]
push eax
push str._PSU__Get_XML_File_ReadData___d__n
lea ecx, [ebp - 0x2a8]
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
lea edx, [ebp - 0x2a8]
push edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
call fcn.0044ce83
add esp, 8
mov edx, dword [ebp - 0x1c]
cmp edx, dword [ebp - 0x20]
jne 0x418f56
mov dword [ebp - 0x10], 0
push ecx
mov ecx, esp
mov dword [ebp - 0x2bc], esp
push 0x539af8
call fcn.004e819a
mov dword [ebp - 0x2cc], eax
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.00418fa5
add esp, 0xc
mov dword [ebp - 0x2d0], eax
mov edx, dword [ebp - 0x2d0]
mov dword [ebp - 4], edx
xor eax, eax
mov ax, word [0x539af6]
test eax, eax
je 0x418f35
cmp dword [ebp - 4], 0
jne 0x418f2a
push str._PSU__XML_:_Save_XML_file_failed_
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
jmp 0x418f35
push str._PSU__XML_:_Save_XML_file_Success_
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x2c0], ecx
mov edx, dword [ebp - 0x2c0]
push edx
call fcn.004e8e12
add esp, 4
mov dword [ebp - 4], 1
jmp 0x418f8c
xor eax, eax
mov ax, word [0x539af6]
test eax, eax
je 0x418f6d
push str._RCP__XML:_Read_data_failed
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x2c4], ecx
mov edx, dword [ebp - 0x2c4]
push edx
call fcn.004e8e12
add esp, 4
mov dword [ebp - 4], 0
call fcn.00408962
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x418f9e
xor eax, eax
jmp 0x418fa1
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret