Function at 0x4cc060
Capabilities:
Delete registry value
Get file size
Move file
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x563df8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x28c
push ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x48], edi
mov eax, dword [edi + 0x14]
mov dword [ebp - 4], 0
test eax, eax
je 0x4ccaea
mov eax, dword [eax + 0x1c]
mov dword [ebp - 0x2c], eax
call fcn.004ce550
push str.Assembling_all_downloaded_portions_into_one_file..._n
mov ecx, edi
call fcn.004cb260
mov ecx, dword [edi + 0x50]
mov eax, dword [ecx]
test eax, eax
je 0x4cc0ce
push 0
push 0x1392
push 0x111
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [edi + 0xc]
test eax, eax
je 0x4cc0ea
mov edx, dword [edi + 0x10]
push edx
push 0x1392
push 0x111
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ebx, dword [ebp + 0xc]
test ebx, ebx
je 0x4cc384
cmp dword [edi], 0
je 0x4cc384
mov eax, dword [edi + 0x14]
push ebx
mov ecx, dword [eax + 0x10]
push ecx
call fcn.0052f680
add esp, 8
test eax, eax
je 0x4cc384
push 1
push ebx
call fcn.0044fc50
add esp, 8
test eax, eax
je 0x4cc148
push ebx
lea edx, [ebp - 0x298]
push str.Delete_old_file__s_n
push edx
call fcn.00527718
add esp, 0xc
lea eax, [ebp - 0x298]
mov ecx, edi
push eax
call fcn.004cb260
mov ecx, dword [edi + 0x14]
push 0
push ebx
mov esi, dword [ecx + 0x10]
push esi
mov dword [ebp - 0x30], esi
call fcn.0044faa0
add esp, 0xc
mov dword [ebp - 0x24], eax
test eax, eax
jne 0x4cc349
mov edx, dword [0x5c2a74]
mov dword [ebp - 0x20], edx
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push esi
lea eax, [ebp - 0x20]
push str.Can_not_rename_temp_file__s_to__s__error___ld_n
push eax
call fcn.0053afda
mov ecx, dword [ebp - 0x20]
add esp, 0x14
push ecx
mov ecx, edi
call fcn.004cb260
push ebx
lea ecx, [ebp - 0x1c]
call fcn.0054222c
mov edx, dword [ebp - 0x1c]
push 0x5c
push edx
mov byte [ebp - 4], 2
call fcn.00526d20
add esp, 8
test eax, eax
jne 0x4cc1d6
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
call fcn.005421be
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0
call fcn.005421be
jmp 0x4cc316
mov byte [eax + 1], 0
mov eax, dword [ebp - 0x1c]
push 0
push eax
call fcn.0044fd10
add esp, 8
test eax, eax
jne 0x4cc2f7
push str.Folder_does_not_exist__Creating..._n
mov ecx, edi
call fcn.004cb260
mov esi, 2
jmp 0x4cc206
mov ebx, dword [ebp + 0xc]
inc esi
lea ecx, [ebp - 0x1c]
push esi
push 0x5c
call fcn.00542693
mov esi, eax
cmp esi, 0xffffffff
je 0x4cc2e5
lea ecx, [ebp - 0x44]
push esi
push ecx
lea ecx, [ebp - 0x1c]
call fcn.0053abba
mov eax, dword [eax]
push 0
push eax
mov byte [ebp - 4], 3
call fcn.0044fd10
add esp, 8
lea ecx, [ebp - 0x44]
test eax, eax
sete bl
mov byte [ebp - 4], 2
call fcn.005421be
test bl, bl
je 0x4cc203
lea edx, [ebp - 0x50]
push esi
push edx
lea ecx, [ebp - 0x1c]
call fcn.0053abba
mov eax, dword [eax]
push 0
push eax
mov byte [ebp - 4], 4
call fcn.0044fe10
add esp, 8
lea ecx, [ebp - 0x50]
test eax, eax
sete bl
mov byte [ebp - 4], 2
call fcn.005421be
test bl, bl
je 0x4cc203
lea eax, [ebp - 0x30]
push esi
push eax
lea ecx, [ebp - 0x1c]
call fcn.0053abba
mov esi, eax
mov byte [ebp - 4], 5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esi]
push eax
push ecx
lea edx, [ebp - 0x20]
push str.Can_not_create_folder__s__error___ld_n
push edx
call fcn.0053afda
add esp, 0x10
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 2
call fcn.005421be
mov eax, dword [ebp - 0x20]
mov ecx, edi
push eax
call fcn.004cb260
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
call fcn.005421be
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0
call fcn.005421be
mov ebx, dword [ebp + 0xc]
jmp 0x4cc30f
mov ecx, dword [ebp - 0x30]
push 0
push ebx
push ecx
call fcn.0044faa0
add esp, 0xc
mov dword [ebp - 0x24], eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
call fcn.005421be
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0
call fcn.005421be
mov eax, dword [ebp - 0x24]
test eax, eax
jne 0x4cc349
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0x14]
push eax
push ebx
lea ecx, [ebp - 0x298]
mov eax, dword [edx + 0x10]
push eax
push str.Can_not_rename_temp_file__s_to__s__errno___ld_n
push ecx
call fcn.00527718
add esp, 0x14
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
jmp 0x4cc384
call fcn.00529287
mov ecx, dword [edi + 0x14]
mov eax, dword [eax]
push eax
push ebx
mov edx, dword [ecx + 0x10]
lea eax, [ebp - 0x298]
push edx
push str.Rename_temp_file__s_to__s._n
push eax
call fcn.00527718
add esp, 0x14
lea ecx, [ebp - 0x298]
push ecx
mov ecx, edi
call fcn.004cb260
mov edx, dword [ebp + 8]
mov dword [edx], 1
mov eax, dword [ebp + 8]
cmp dword [eax], 0
je 0x4cc390
mov eax, ebx
jmp 0x4cc396
mov ecx, dword [edi + 0x14]
mov eax, dword [ecx + 0x10]
push 0
push 0
push 3
push 0
push 1
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 0x18], eax
jne 0x4cc403
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
lea edx, [ebp - 0x298]
push esi
push str.Error_opening_local_file_for_writing__errcode___ld._n
push edx
call fcn.00527718
add esp, 0xc
lea eax, [ebp - 0x298]
mov ecx, edi
push eax
call fcn.004cb260
mov ecx, dword [0x5c8354]
push ecx
mov ecx, dword [edi + 0x4c]
call fcn.004d1ef0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
lea edx, [ebp - 0x4c]
lea esi, [edi + 0x78]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esi], eax
mov dword [esi + 4], 0
cmp dword [esi], 0xffffffff
jne 0x4cc460
mov eax, dword [esi + 4]
test eax, eax
jne 0x4cc460
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
test eax, eax
je 0x4cc460
call ebx
push eax
lea eax, [ebp - 0x298]
push str.Error_during_GetFileSize____errcode___d._n
push eax
call fcn.00527718
add esp, 0xc
lea ecx, [ebp - 0x298]
push ecx
mov ecx, edi
call fcn.004cb260
xor ebx, ebx
mov dword [esi], ebx
mov dword [esi + 4], ebx
jmp 0x4cc47f
mov edx, dword [ebp - 0x4c]
push 1
push 0
push 0
push edx
call fcn.005291e0
mov ecx, dword [esi]
add ecx, eax
mov dword [esi], ecx
mov eax, dword [esi + 4]
adc eax, edx
xor ebx, ebx
mov dword [esi + 4], eax
mov eax, dword [edi + 0x50]
mov eax, dword [eax]
cmp eax, ebx
je 0x4cc49a
push esi
push 0x1393
push 0x111
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [esi + 4]
mov eax, dword [edi + 0x14]
mov edx, dword [esi]
push ecx
mov ecx, dword [eax + 0x10]
push edx
push ecx
lea edx, [ebp - 0x298]
push str.Size_of__s_is__I64d_n
push edx
call fcn.00527718
add esp, 0x14
lea eax, [ebp - 0x298]
mov ecx, edi
push eax
call fcn.004cb260
mov ecx, dword [ebp - 0x18]
push 2
push ebx
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [ebp + 8]
cmp dword [edx], ebx
je 0x4cc4e4
mov eax, dword [ebp + 0xc]
jmp 0x4cc4ea
mov eax, dword [edi + 0x14]
mov eax, dword [eax + 0x10]
push ebx
push ebx
lea ecx, [ebp - 0x34]
push ebx
push ecx
push eax
call fcn.0052776a
mov esi, dword [ebp - 0x2c]
add esp, 0x14
cmp esi, ebx
je 0x4cc806
mov edx, dword [ebp + 8]
cmp dword [edx], ebx
je 0x4cc511
mov eax, dword [ebp + 0xc]
jmp 0x4cc517
mov eax, dword [edi + 0x14]
mov eax, dword [eax + 0x10]
mov ecx, dword [esi + 0x10]
push eax
push ecx
lea edx, [ebp - 0x298]
push str.Adding_file__s_to_file__s._n
push edx
call fcn.00527718
add esp, 0x10
lea eax, [ebp - 0x298]
mov ecx, edi
push eax
call fcn.004cb260
cmp dword [esi + 0x14], ebx
je 0x4cc65d
mov edx, dword [esi + 0x10]
mov eax, dword [ebp - 0x18]
lea ecx, [ebp - 0x34]
push ecx
push edx
push eax
mov ecx, edi
call fcn.004ccb40
cmp eax, ebx
mov dword [ebp - 0x14], eax
je 0x4cc669
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 0xc]
cmp eax, ebx
je 0x4cc647
mov edx, dword [edi + 0x14]
mov esi, eax
mov edx, dword [edx + 0x10]
mov eax, edx
mov bl, byte [eax]
mov cl, bl
cmp bl, byte [esi]
jne 0x4cc5a8
test cl, cl
je 0x4cc5a4
mov bl, byte [eax + 1]
mov cl, bl
cmp bl, byte [esi + 1]
jne 0x4cc5a8
add eax, 2
add esi, 2
test cl, cl
jne 0x4cc584
xor eax, eax
jmp 0x4cc5ad
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x4cc647
mov esi, dword [ebp + 0xc]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
jne 0x4cc60c
call fcn.00529287
mov ecx, dword [edi + 0x14]
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x298]
mov edx, dword [ecx + 0x10]
push edx
push esi
push str.Can_not_rename_back_file__s_to__s__errno___ld_n
push eax
call fcn.00527718
add esp, 0x14
lea ecx, [ebp - 0x298]
push ecx
mov ecx, edi
call fcn.004cb260
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
call fcn.00529287
mov edx, dword [eax]
mov eax, dword [edi + 0x14]
push edx
lea edx, [ebp - 0x298]
mov ecx, dword [eax + 0x10]
push ecx
push esi
push str.Rename_back_file__s_to__s._n
push edx
call fcn.00527718
add esp, 0x14
lea eax, [ebp - 0x298]
mov ecx, edi
push eax
call fcn.004cb260
mov ecx, dword [ebp + 8]
mov dword [ecx], 0
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push str.This_file_has_flag_isCmpleted__0__it_has_not_been_added._n
mov ecx, edi
call fcn.004cb260
mov edx, dword [esi + 0x10]
push edx
call fcn.005284b2
add esp, 4
cmp eax, 0xffffffff
mov eax, dword [esi + 0x10]
push eax
jne 0x4cc685
push str.Could_not_delete_temp_file__s_n
jmp 0x4cc68a
push str.Deleting_temp_file__s_n
lea ecx, [ebp - 0x298]
push ecx
call fcn.00527718
add esp, 0xc
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
mov eax, dword [esi + 0x24]
lea ecx, [ebp - 0x2c]
push eax
push 0x5a3e38
push ecx
call fcn.00527718
mov eax, dword [edi + 0x54]
mov esi, dword [esi + 0x1c]
add esp, 0xc
cmp eax, ebx
je 0x4cc4fd
lea edx, [ebp - 0x2c]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
lea eax, [ebp - 0x2c]
lea ecx, [ebp - 0x298]
push eax
push str.Deleting_record__s_from_registry_n
push ecx
call fcn.00527718
mov edx, dword [0x5c2a74]
add esp, 0xc
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], edx
lea eax, [ebp - 0x2c]
lea ecx, [ebp - 0x20]
push eax
push str.sk_s
push ecx
mov byte [ebp - 4], 6
call fcn.0053afda
mov ecx, dword [ebp - 0x20]
add esp, 0xc
lea edx, [ebp - 0x1c]
lea eax, [ebp - 0x24]
push edx
mov edx, dword [edi + 0x54]
push eax
push ebx
push ebx
push ecx
push edx
mov dword [ebp - 0x1c], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4cc78e
cmp dword [ebp - 0x24], ebx
jbe 0x4cc78e
mov edx, dword [edi + 0x54]
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x14]
push eax
push ecx
push ebx
push ebx
push 0x5ba2c4
push edx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x1c], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x14]
mov edx, dword [edi + 0x54]
add ecx, eax
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp - 0x20]
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueA]
mov ecx, dword [edi + 0x54]
lea eax, [ebp - 0x14]
push 4
push eax
push 4
push ebx
push 0x5ba2c4
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
cmp esi, ebx
mov dword [ebp - 0x60], ebx
mov dword [ebp - 0x58], ebx
mov dword [ebp - 0x54], ebx
je 0x4cc7b1
mov eax, dword [esi + 0x24]
mov dword [ebp - 0x5c], eax
jmp 0x4cc7b8
mov dword [ebp - 0x5c], 0xffffffff
mov edx, dword [edi + 0x54]
lea ecx, [ebp - 0x60]
push 0x10
push ecx
push ebx
push ebx
push 0x5a9b3c
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [ebp - 0x5c]
lea ecx, [ebp - 0x298]
push eax
push str.Updating_record_with_ID_0__set_nextID__d_n
push ecx
call fcn.00527718
add esp, 0xc
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0
call fcn.005421be
jmp 0x4cc4fd
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, edi
call fcn.004cdef0
push str.Rebuilding_file_complete._n
mov ecx, edi
call fcn.004cb260
cmp dword [edi], ebx
je 0x4ccadb
cmp dword [ebp + 0xc], ebx
je 0x4ccadb
mov ecx, dword [ebp + 8]
cmp dword [ecx], ebx
jne 0x4ccadb
mov edx, dword [edi + 0x14]
mov esi, dword [ebp + 0xc]
mov eax, dword [edx + 0x10]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x4cc86c
test cl, cl
je 0x4cc868
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x4cc86c
add eax, 2
add esi, 2
test cl, cl
jne 0x4cc848
xor eax, eax
jmp 0x4cc871
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, ebx
je 0x4ccadb
mov esi, dword [ebp + 0xc]
push 1
push esi
call fcn.0044fc50
add esp, 8
cmp eax, ebx
je 0x4cc8ae
push esi
lea eax, [ebp - 0x298]
push str.Delete_old_file__s_n
push eax
call fcn.00527718
add esp, 0xc
lea ecx, [ebp - 0x298]
push ecx
mov ecx, edi
call fcn.004cb260
mov edx, dword [edi + 0x14]
mov eax, dword [ebp + 0xc]
push 1
push eax
mov ebx, dword [edx + 0x10]
push ebx
mov dword [ebp - 0x2c], ebx
call fcn.0044faa0
add esp, 0xc
mov dword [ebp - 0x24], eax
test eax, eax
jne 0x4cca9d
mov ecx, dword [0x5c2a74]
mov dword [ebp - 0x14], ecx
mov byte [ebp - 4], 7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, dword [ebp + 0xc]
push eax
push esi
push ebx
lea edx, [ebp - 0x14]
push str.Can_not_rename_temp_file__s_to__s__error___ld_n
push edx
call fcn.0053afda
mov eax, dword [ebp - 0x14]
add esp, 0x14
mov ecx, edi
push eax
call fcn.004cb260
push esi
lea ecx, [ebp - 0x18]
call fcn.0054222c
mov ecx, dword [ebp - 0x18]
push 0x5c
push ecx
mov byte [ebp - 4], 8
call fcn.00526d20
add esp, 8
test eax, eax
jne 0x4cc942
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 7
call fcn.005421be
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.005421be
jmp 0x4cca67
mov byte [eax + 1], 0
mov edx, dword [ebp - 0x18]
push 1
push edx
call fcn.0044fd10
add esp, 8
test eax, eax
jne 0x4cca48
push str.Folder_does_not_exist__Creating..._n
mov ecx, edi
call fcn.004cb260
mov esi, 2
jmp 0x4cc972
mov ebx, dword [ebp - 0x2c]
inc esi
lea ecx, [ebp - 0x18]
push esi
push 0x5c
call fcn.00542693
mov esi, eax
cmp esi, 0xffffffff
je 0x4cca36
lea eax, [ebp - 0x38]
push esi
push eax
lea ecx, [ebp - 0x18]
call fcn.0053abba
mov eax, dword [eax]
push 1
push eax
mov byte [ebp - 4], 9
call fcn.0044fd10
add esp, 8
lea ecx, [ebp - 0x38]
test eax, eax
sete bl
mov byte [ebp - 4], 8
call fcn.005421be
test bl, bl
je 0x4cc96f
lea ecx, [ebp - 0x3c]
push esi
push ecx
lea ecx, [ebp - 0x18]
call fcn.0053abba
mov eax, dword [eax]
push 1
push eax
mov byte [ebp - 4], 0xa
call fcn.0044fe10
add esp, 8
lea ecx, [ebp - 0x3c]
test eax, eax
sete bl
mov byte [ebp - 4], 8
call fcn.005421be
test bl, bl
je 0x4cc96f
lea edx, [ebp - 0x40]
push esi
push edx
lea ecx, [ebp - 0x18]
call fcn.0053abba
mov esi, eax
mov byte [ebp - 4], 0xb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov eax, dword [esi]
push eax
lea ecx, [ebp - 0x14]
push str.Can_not_create_folder__s__error___ld_n
push ecx
call fcn.0053afda
add esp, 0x10
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 8
call fcn.005421be
mov edx, dword [ebp - 0x14]
mov ecx, edi
push edx
call fcn.004cb260
jmp 0x4cca48
mov eax, dword [ebp + 0xc]
push 1
push eax
push ebx
call fcn.0044faa0
add esp, 0xc
mov dword [ebp - 0x24], eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 7
call fcn.005421be
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.005421be
mov eax, dword [ebp - 0x24]
test eax, eax
jne 0x4cca9d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0x14]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
mov eax, dword [edx + 0x10]
lea ecx, [ebp - 0x298]
push eax
push str.Can_not_rename_temp_file__s_to__s__errno___ld_n
push ecx
call fcn.00527718
add esp, 0x14
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
jmp 0x4ccadb
call fcn.00529287
mov eax, dword [eax]
mov edx, dword [edi + 0x14]
mov ecx, dword [ebp + 0xc]
push eax
mov eax, dword [edx + 0x10]
push ecx
push eax
lea ecx, [ebp - 0x298]
push str.Rename_temp_file__s_to__s._n
push ecx
call fcn.00527718
add esp, 0x14
lea edx, [ebp - 0x298]
mov ecx, edi
push edx
call fcn.004cb260
mov eax, dword [ebp + 8]
mov dword [eax], 1
mov ecx, dword [0x5c7498]
push ecx
call fcn.005297d3
add esp, 4
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8