Function at 0x406640
Capabilities:
Check if file exists
Read .ini file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d0258
mov eax, dword fs:[0]
push eax
sub esp, 0x74
mov eax, dword [0x508164]
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
mov eax, dword [ebp + 8]
test eax, eax
je 0x40667d
push dword [eax]
call dword [sym.imp.KERNEL32.dll_SetEvent]
call fcn.00406f00
push str.Collector_Start___
push 0x114
push 0x4e9b40
push 4
call fcn.00407ee0
push eax
call fcn.00407c80
add esp, 0x14
call fcn.00405e30
call fcn.0044d170
push str.wintrust.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov edi, eax
test edi, edi
je 0x4066d2
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.CryptCATAdminAcquireContext2
push edi
call esi
push str.CryptCATAdminCalcHashFromFileHandle2
push edi
call esi
call fcn.00407880
mov edi, eax
mov ecx, edi
mov dword [ebp - 0x7c], edi
call fcn.00438a50
test al, al
je 0x406a4f
mov al, byte [0x508ba8]
mov ecx, dword [0x50d2a4]
mov byte [edi + 0xb0], al
mov eax, dword [0x508ba4]
mov dword [edi + 0xc8], eax
mov eax, dword [0x508ba0]
mov dword [edi + 0xcc], eax
mov eax, dword [0x50d2a0]
shld ecx, eax, 0x14
shl eax, 0x14
mov dword [edi + 0xd0], eax
mov eax, dword [0x508b98]
mov dword [edi + 0xd4], ecx
mov ecx, dword [0x508b9c]
shld ecx, eax, 0x14
shl eax, 0x14
mov dword [edi + 0xd8], eax
lea eax, [edi + 0x130]
mov dword [edi + 0xdc], ecx
cmp dword [eax + 0x14], 8
jb 0x406756
mov eax, dword [eax]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x406a33
lea ecx, [ebp - 0x74]
call fcn.0040eca0
push 1
push 0x4e9980
mov ecx, eax
mov dword [ebp - 4], 0
call fcn.004086c0
mov dword [ebp - 0x34], 0
xor ecx, ecx
mov dword [ebp - 0x30], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x44], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x34], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
push 0xc
push str.Progress.ini
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 1
call fcn.004086c0
mov dword [ebp - 0x1c], 0
xor ecx, ecx
mov dword [ebp - 0x18], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x2c], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0x1c], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
lea ecx, [ebp - 0x44]
call fcn.0040c2c0
lea ecx, [ebp - 0x74]
mov dword [ebp - 4], 0xffffffff
call fcn.0040c2c0
cmp dword [ebp - 0x18], 8
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
push eax
push 0
push str.errcnt
push str.DATA
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
lea ecx, [ebp - 0x2c]
mov esi, eax
call fcn.0040c2c0
cmp esi, 3
jg 0x406a33
mov dword [ebp - 4], 2
lea ecx, [ebp - 0x80]
mov dword [ebp - 0x80], 0x406ad0
call fcn.0040b140
mov dword [ebp - 0x78], eax
test eax, eax
je 0x406862
lock inc dword [eax + 4]
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 3
call fcn.0048d710
test al, al
je 0x406a72
lea ecx, [ebp - 0x78]
call fcn.0040c1f0
jmp 0x4068a8
mov ecx, edi
mov dword [ebp - 4], 0xffffffff
call fcn.0043aa80
push str.Collector_End___
push 0x13e
push 0x4e9b40
push 4
call fcn.00407ee0
push eax
call fcn.00407c80
add esp, 0x14
cmp dword [0x50d2a8], 1
jne 0x4068ea
call fcn.00406e60
xor eax, eax
jmp 0x406a54
or edi, 0xffffffff
call fcn.00407880
push str.ReportData_Start
push 0xc5
push 0x4e9b40
push 4
mov esi, eax
call fcn.00407ee0
push eax
call fcn.00407c80
lea eax, [esi + 0x100]
push 0x4e9c70
mov edx, eax
mov dword [ebp - 0x7c], eax
lea ecx, [ebp - 0x5c]
call fcn.00408890
add esp, 0x18
mov dword [ebp - 4], 6
mov eax, dword [0x50d2a8]
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
cmp eax, 2
je 0x406969
mov ecx, dword [ebp - 0x7c]
lea edx, [ebp - 0x5c]
call fcn.00406050
test al, al
jne 0x406964
push 0xbb8
call esi
mov eax, dword [0x50d2a8]
cmp eax, 2
jne 0x406942
jmp 0x406969
mov eax, dword [0x50d2a8]
cmp byte [0x508ba9], 0
je 0x4069e8
mov dword [ebp - 0x78], 0
cmp eax, 2
je 0x4069e8
nop
lea ecx, [ebp - 0x5c]
call fcn.004509c0
mov edi, eax
cmp edi, 0xffffffff
je 0x4069c8
test edi, edi
je 0x4069c8
mov ecx, dword [ebp - 0x78]
mov eax, 0x55555556
inc ecx
imul ecx
mov dword [ebp - 0x78], ecx
mov eax, edx
shr eax, 0x1f
add eax, edx
lea eax, [eax + eax*2]
sub ecx, eax
jne 0x4069b6
push 0x2710
jmp 0x4069bb
push 0x36ee80
call esi
cmp dword [0x50d2a8], 2
jne 0x406980
jmp 0x4069e8
push edi
push str.ReportData_result__d_
push 0xd8
push 0x4e9b40
push 4
call fcn.00407ee0
push eax
call fcn.00407910
add esp, 0x18
push str.ReportData_End
push 0xeb
push 0x4e9b40
push 4
call fcn.00407ee0
push eax
call fcn.00407c80
add esp, 0x14
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x5c]
call fcn.0040c2c0
cmp dword [0x50d2a8], 1
je 0x4068de
call fcn.00406e60
mov ecx, edi
call fcn.00406590
xor eax, eax
jmp 0x406a54
call fcn.00406e60
mov ecx, edi
call fcn.0043b0a0
xor ecx, ecx
cmp byte [0x50d292], cl
sete cl
call fcn.00406240
mov eax, 1
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.0048d8b2
mov esp, ebp
pop ebp
ret 4
lea ecx, [ebp - 0x74]
call fcn.0040e030
push eax
mov byte [ebp - 4], 4
call fcn.0040c990
int3