Function at 0x401cd0
Capabilities:
Get file attributes
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41fccc
mov eax, dword fs:[0]
push eax
push ecx
mov eax, 0x2a20
call fcn.0040b050
mov eax, dword [0x428530]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
push str._bmploader_start__
mov esi, ecx
push 0x42160c
push 0x429d3c
mov dword [ebp - 0x2a20], esi
call fcn.00408aec
push str._RzxMon_process_
push 0x42160c
push 0x429d3c
mov dword [ebp - 4], 0
call fcn.00408aec
add esp, 0x18
call fcn.004010e0
lea eax, [ebp - 0x1614]
push eax
call fcn.00406de2
add esp, 4
lea ecx, [ebp - 0x1614]
push 0x421304
push ecx
call fcn.00409fc8
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x401db7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [ebp - 0x1614]
push edx
push str._open_file_failed__szBmpLoader:_s___d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x14
push str._close_RzxMon.exe_
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
call fcn.00401150
or eax, 0xffffffff
jmp 0x402413
mov dword [ebp - 0x2a18], ebx
push 0x3ff
lea eax, [ebp - 0x613]
push 0
push eax
mov byte [ebp - 4], 1
mov byte [ebp - 0x614], 0
call fcn.00409be0
push 0x1ff
lea ecx, [ebp - 0x213]
push 0
push ecx
mov byte [ebp - 0x214], 0
call fcn.00409be0
lea edx, [ebp - 0x614]
push edx
call fcn.00406e68
add esp, 0x1c
add esi, 4
push esi
lea eax, [ebp - 0x214]
push str._s.rzx
push eax
call fcn.0040afc4
lea eax, [ebp - 0x214]
add esp, 0xc
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x401e24
lea edi, [ebp - 0x614]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x401e34
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebp - 0x614]
push 0x421300
push ecx
call fcn.00409fc8
mov esi, eax
add esp, 8
test esi, esi
jne 0x401eb8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [ebp - 0x614]
push edx
push str._open_file_failed__szDstFile:_s___d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x14
push str._close_RzxMon.exe_
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
call fcn.00401150
push ebx
call fcn.00409cc7
add esp, 4
or eax, 0xffffffff
jmp 0x402413
push 0x200000
call fcn.00408ce7
add esp, 4
mov edi, eax
mov eax, dword [ebp - 0x2a20]
mov ecx, dword [eax]
push 0
push ecx
push ebx
call fcn.0040af48
add esp, 0xc
jmp 0x401ee0
push ebx
push 0x200000
push 1
push edi
call fcn.0040a229
push esi
push eax
push 1
push edi
call fcn.00409e92
push ebx
call fcn.0040ae96
add esp, 0x24
test eax, eax
je 0x401ee0
test esi, esi
je 0x401f12
push esi
call fcn.00409cc7
add esp, 4
push edi
call fcn.0040a595
mov edi, dword [ebp - 0x2a20]
mov edx, dword [edi]
push edx
call fcn.00408ce7
mov esi, eax
lea eax, [ebp - 0xa14]
add esp, 8
push eax
call fcn.00407de9
lea ecx, [ebp - 0xa14]
add esp, 4
push ecx
call fcn.0040746f
lea eax, [ebp - 0xa14]
add esp, 4
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x401f50
mov edx, dword [0x4217d8]
mov ecx, dword [0x4217dc]
mov dword [eax], edx
mov edx, dword [0x4217e0]
mov dword [eax + 4], ecx
mov cx, word [0x4217e4]
mov dword [eax + 8], edx
mov dl, byte [0x4217e6]
mov word [eax + 0xc], cx
push 0
mov byte [eax + 0xe], dl
lea eax, [ebp - 0xa14]
push 0
push eax
call fcn.004075a9
add esp, 0xc
lea ecx, [ebp - 0x2a2c]
call fcn.004074cf
push 0x421300
lea ecx, [ebp - 0xa14]
push ecx
lea ecx, [ebp - 0x2a2c]
mov byte [ebp - 4], 2
call fcn.004078fb
test eax, eax
jne 0x40202e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edx, [ebp - 0xa14]
push edx
push str._open_file_failed__szDstFile:_s___d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x14
push str._close_RzxMon.exe_
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
call fcn.00401150
lea ecx, [ebp - 0x2a2c]
mov byte [ebp - 4], 1
call fcn.004078f0
mov eax, dword [ebp - 0x2a18]
test eax, eax
je 0x402026
push eax
call fcn.00409cc7
add esp, 4
or eax, 0xffffffff
jmp 0x402413
mov dword [ebp - 0x2a20], esi
push 0
push 0
push ebx
mov byte [ebp - 4], 3
call fcn.0040af48
mov eax, dword [edi]
push ebx
push eax
push 1
push esi
call fcn.0040a229
add esp, 0x1c
cmp eax, dword [edi]
jne 0x40245f
push eax
push esi
lea ecx, [ebp - 0x2a2c]
call fcn.00407520
test eax, eax
je 0x40245f
push esi
mov byte [ebp - 4], 2
call fcn.0040a595
add esp, 4
lea ecx, [ebp - 0x2a2c]
call fcn.00407551
lea ecx, [ebp - 0xe14]
push ecx
call fcn.00406e68
lea eax, [ebp - 0x214]
add esp, 4
dec eax
lea esp, [esp]
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x4020a0
mov edx, dword [str..ups]
mov cl, byte [0x4217d4]
mov dword [eax], edx
mov byte [eax + 4], cl
lea eax, [ebp - 0x214]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4020c1
lea edi, [ebp - 0xe14]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4020d1
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea edx, [ebp - 0xe14]
and ecx, 3
push 1
push edx
rep movsb byte es:[edi], byte [esi]
call fcn.004071e2
lea eax, [ebp - 0xe14]
add esp, 8
push eax
call fcn.0040721f
add esp, 4
test eax, eax
jne 0x40211c
lea ecx, [ebp - 0xe14]
push ecx
call fcn.004071c3
add esp, 4
lea edx, [ebp - 0x614]
push edx
lea eax, [ebp - 0x2214]
push str.__s_
push eax
call fcn.0040afc4
lea eax, [ebp - 0x2214]
add esp, 0xc
dec eax
mov edi, edi
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402140
mov ecx, dword [str.__o_]
mov dl, byte [0x4217c4]
mov dword [eax], ecx
mov byte [eax + 4], dl
lea eax, [ebp - 0xe14]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402161
lea edi, [ebp - 0x2214]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402171
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
lea eax, [ebp - 0x2214]
rep movsb byte es:[edi], byte [esi]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402190
mov ecx, dword [str.___y]
mov dl, byte [0x4217bc]
push 0
push 0
mov dword [eax], ecx
push 0x40
mov byte [eax + 4], dl
lea eax, [ebp - 0x2214]
push 1
push eax
call fcn.00406eba
add esp, 0x14
test eax, eax
jne 0x4021ee
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x614]
push ecx
push str._run_decompresion_command_failed___s__d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x14
jmp 0x401fff
lea edx, [ebp - 0xe14]
push edx
lea eax, [ebp - 0xa14]
push eax
lea ecx, [ebp - 0x2a14]
push str.__s___inl__sr___s_
push ecx
call fcn.0040afc4
add esp, 0x10
push 1
push 0
push str.GlobalFF844264_D119_416A_8CB5_981A498343D1
lea ecx, [ebp - 0x2a1c]
mov dword [ebp - 0x2a30], 0
call fcn.00407d2e
push 0
push 0
push 0x20
push 1
lea edx, [ebp - 0x2a30]
push edx
lea eax, [ebp - 0x2a14]
push eax
mov byte [ebp - 4], 4
call fcn.00406bdd
add esp, 0x18
test eax, eax
je 0x40242f
cmp dword [ebp - 0x2a30], 1
je 0x40242f
push str.Uping
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
push 0xdbba0
lea ecx, [ebp - 0x2a1c]
call fcn.00407bc8
test eax, eax
je 0x40229a
push str._run_Update_command_failed_2_
jmp 0x402434
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0
lea ecx, [ebp - 0x614]
push 0
push ecx
call fcn.004075a9
add esp, 0xc
push 0
lea edx, [ebp - 0xa14]
push 0
push edx
call fcn.004075a9
lea eax, [ebp - 0xe14]
add esp, 0xc
push eax
call fcn.00407588
add esp, 4
push str._close_RzxMon.exe_
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
call fcn.00401150
push str._update_successfully
push 0x42160c
push 0x429d3c
call fcn.00408aec
lea ecx, [ebp - 0x1214]
add esp, 0xc
push ecx
call fcn.00407de9
lea edx, [ebp - 0x1214]
add esp, 4
push edx
call fcn.0040746f
add esp, 4
lea eax, [ebp - 0x1214]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
or eax, 2
push eax
lea ecx, [ebp - 0x1214]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0x1214]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402350
mov edx, dword [str._rzx]
mov cl, byte [0x421634]
mov dword [eax], edx
mov byte [eax + 4], cl
lea eax, [ebp - 0x1214]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x402370
mov edx, dword [str._rzxmon.exe]
mov ecx, dword [0x4216f4]
mov dword [eax], edx
mov edx, dword [0x4216f8]
mov dword [eax + 4], ecx
mov dword [eax + 8], edx
mov eax, dword [0x429d38]
cmp eax, 0xffffffff
je 0x4023a7
test eax, eax
je 0x4023a7
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
push 0
push 0x20
lea eax, [ebp - 0x1214]
push 0
push eax
call fcn.00406eba
add esp, 0x14
test eax, eax
jne 0x4023e0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str._start_RzxMon.exe_failed___d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x10
lea ecx, [ebp - 0x2a1c]
mov byte [ebp - 4], 2
call fcn.00407c14
lea ecx, [ebp - 0x2a2c]
mov byte [ebp - 4], 1
call fcn.004078f0
mov eax, dword [ebp - 0x2a18]
test eax, eax
je 0x402411
push eax
call fcn.00409cc7
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00409bc8
mov esp, ebp
pop ebp
ret
push str._run_Update_command_failed1_
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0xc
call fcn.00401150
lea ecx, [ebp - 0x2a1c]
mov byte [ebp - 4], 2
call fcn.00407c14
jmp 0x402004
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0xa14]
push ecx
push str._operate_file_failed__szDstFile:_s___d
push 0x42160c
push 0x429d3c
call fcn.00408b57
add esp, 0x14
push str._close_RzxMon.exe_
push 0x42160c
push 0x429d3c
call fcn.00408aec
add esp, 0xc
call fcn.00401150
push esi
call fcn.0040a595
add esp, 4
jmp 0x402004