Function at 0x4059a7
Capabilities:
Create directory
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x78
mov eax, dword [section..data]
xor eax, esp
mov dword [esp + 0x74], eax
push ebx
push ebp
mov ebp, dword [sym.imp.libav.dll_Ordinal_44283]
push esi
push edi
mov esi, ecx
xor ebx, ebx
push str.MaxAttempts
push esi
mov dword [esp + 0x24], edx
mov edi, ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x18], ebx
call ebp
pop ecx
xor edx, edx
pop ecx
mov ecx, dword [esp + 0x8c]
inc edx
cmp dword [eax + 0x10], ecx
jne 0x4059f3
mov dword [esp + 0x18], edx
cmp dword [eax + 0x14], ebx
je 0x4059f7
mov dword [esp + 0x18], ebx
push 0x410780
call dword [sym.imp.libav.dll_Ordinal_44203]
mov ebx, eax
pop ecx
test ebx, ebx
jne 0x405a11
push 0x39
pop eax
jmp 0x405e3a
push 0x200
push ebx
push 0x410580
call dword [sym.imp.MSVCR110.dll_strncpy]
add esp, 0xc
mov byte [0x41077f], 0
push ebx
call dword [sym.imp.MSVCR110.dll_free]
mov dword [esp], 0x410580
call dword [sym.imp.MSVCR110.dll__mkdir]
pop ecx
test eax, eax
jne 0x405a09
lea eax, [esp + 0x28]
push eax
call dword [sym.imp.MSVCR110.dll__time64]
mov dword [esp], str.LocalIPAddress
push esi
call ebp
xor ebx, ebx
pop ecx
pop ecx
cmp dword [eax + 0x18], ebx
je 0x405a6a
mov eax, dword [eax + 8]
mov dword [esp + 0x10], eax
push str.HTTPProxyServer
push esi
call ebp
pop ecx
pop ecx
cmp dword [eax + 0x18], ebx
jne 0x405a8c
push str.PrivateMirror
push esi
call ebp
pop ecx
pop ecx
cmp dword [eax + 0x18], ebx
jne 0x405a8c
push 1
jmp 0x405a8d
push ebx
lea edx, [esp + 0x34]
call fcn.00406326
pop ecx
push 0x2e
lea eax, [esp + 0x58]
push ebx
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
push str.DatabaseCustomURL
push esi
call ebp
mov ebx, eax
pop ecx
pop ecx
cmp dword [ebx + 0x18], edi
je 0x405aec
mov ebp, dword [esp + 0x18]
mov ecx, dword [ebx + 8]
push ebp
push dword [esp + 0x14]
lea edx, [esp + 0x1c]
push esi
call fcn.00402929
mov ebx, dword [ebx + 0x28]
add esp, 0xc
test eax, eax
push 1
mov dword [esp + 0x24], eax
pop eax
cmove edi, eax
test ebx, ebx
jne 0x405abc
mov ebp, dword [sym.imp.libav.dll_Ordinal_44283]
jmp 0x405af4
mov eax, dword [esp + 0x20]
mov dword [esp + 0x20], eax
push str.update_db
push esi
call ebp
cmp dword [eax + 0x18], 0
pop ecx
pop ecx
mov dword [esp + 0x24], eax
je 0x405bda
mov ebx, dword [eax + 8]
push 7
push str.custom
push ebx
call sub.MSVCR110.dll_memcmp
add esp, 0xc
test eax, eax
je 0x405bad
push dword [esp + 0x8c]
mov edx, dword [esp + 0x20]
push ecx
push dword [esp + 0x20]
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
push esi
push eax
lea eax, [esp + 0x78]
push eax
mov ecx, ebx
call fcn.00402ebe
mov ebx, eax
add esp, 0x28
cmp ebx, 0x32
jg 0x405dd2
push 1
test ebx, ebx
pop eax
cmove edi, eax
mov eax, dword [esp + 0x24]
mov eax, dword [eax + 0x28]
mov dword [esp + 0x24], eax
test eax, eax
jne 0x405b0c
lea eax, [esp + 0x30]
push eax
call fcn.004061bb
pop ecx
lea ecx, [esp + 0x30]
call fcn.00406406
push 0x410580
call dword [sym.imp.libav.dll_Ordinal_44210]
pop ecx
call fcn.0040373d
test eax, eax
jns 0x405df6
push 0x40
jmp 0x405a0b
push str.DatabaseCustomURL
push esi
call ebp
cmp dword [eax + 0x18], 0
mov ebx, dword [esp + 0x28]
mov esi, dword [sym.imp.MSVCR110.dll_free]
push 0x38
pop ecx
push 0
cmove ebx, ecx
call esi
add esp, 0xc
push 0
call esi
pop ecx
jmp 0x405dd2
push dword [esp + 0x8c]
mov ebx, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
push ecx
push ebx
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
push esi
push eax
lea eax, [esp + 0x78]
push eax
mov ecx, str.main
call fcn.00402ebe
add esp, 0x28
cmp eax, 0x32
jg 0x405dd0
push 1
mov edx, dword [esp + 0x20]
test eax, eax
pop eax
push dword [esp + 0x8c]
cmove edi, eax
push ecx
push ebx
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
push esi
push eax
lea eax, [esp + 0x78]
push eax
mov ecx, str.daily
call fcn.00402ebe
add esp, 0x28
cmp eax, 0x32
jg 0x405dd0
push 1
test eax, eax
pop eax
push str.SafeBrowsing
push esi
cmove edi, eax
call ebp
cmp dword [eax + 0x18], 0
pop ecx
pop ecx
jne 0x405ced
push 4
mov ebx, str.safebrowsing.cvd
push ebx
call dword [sym.imp.libav.dll_Ordinal_44340]
pop ecx
pop ecx
test eax, eax
je 0x405c98
push 4
mov ebx, str.safebrowsing.cld
push ebx
call dword [sym.imp.libav.dll_Ordinal_44340]
pop ecx
pop ecx
test eax, eax
jne 0x405ca0
push ebx
call dword [sym.imp.MSVCR110.dll__unlink]
pop ecx
mov ebx, dword [esp + 0x18]
push str.Bytecode
push esi
call ebp
cmp dword [eax + 0x18], 0
pop ecx
pop ecx
jne 0x405d33
push 4
mov ebx, str.bytecode.cvd
push ebx
call dword [sym.imp.libav.dll_Ordinal_44340]
pop ecx
pop ecx
test eax, eax
je 0x405ce0
push 4
mov ebx, str.bytecode.cld
push ebx
call dword [sym.imp.libav.dll_Ordinal_44340]
pop ecx
pop ecx
test eax, eax
jne 0x405d70
push ebx
call dword [sym.imp.MSVCR110.dll__unlink]
pop ecx
jmp 0x405d70
push dword [esp + 0x8c]
mov edx, dword [esp + 0x20]
push ecx
push ebx
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
push esi
push eax
lea eax, [esp + 0x78]
push eax
mov ecx, str.safebrowsing
call fcn.00402ebe
add esp, 0x28
cmp eax, 0x32
jg 0x405dd0
test eax, eax
push 1
pop eax
cmove edi, eax
jmp 0x405ca4
push dword [esp + 0x8c]
mov edx, dword [esp + 0x20]
push ecx
push ebx
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
push esi
push eax
lea eax, [esp + 0x78]
push eax
mov ecx, str.bytecode
call fcn.00402ebe
add esp, 0x28
cmp eax, 0x32
jg 0x405dd0
test eax, eax
push 1
pop eax
cmove edi, eax
push str.ExtraDatabase
push esi
call ebp
mov ebx, eax
pop ecx
cmp dword [ebx + 0x18], 0
pop ecx
je 0x405b79
push dword [esp + 0x8c]
mov edx, dword [esp + 0x20]
push ecx
push dword [esp + 0x20]
lea eax, [esp + 0x3c]
push eax
push ecx
push dword [esp + 0x24]
lea eax, [esp + 0x2c]
push ecx
mov ecx, dword [ebx + 8]
push esi
push eax
lea eax, [esp + 0x78]
push eax
call fcn.00402ebe
add esp, 0x28
cmp eax, 0x32
jg 0x405dd0
mov ebx, dword [ebx + 0x28]
test eax, eax
push 1
pop eax
cmove edi, eax
test ebx, ebx
jne 0x405d86
jmp 0x405b79
mov ebx, eax
lea eax, [esp + 0x30]
push eax
call fcn.004061bb
pop ecx
lea ecx, [esp + 0x30]
call fcn.00406406
push 0x410580
call dword [sym.imp.libav.dll_Ordinal_44210]
pop ecx
mov eax, ebx
jmp 0x405e3a
test edi, edi
je 0x405e38
push str.HTTPProxyServer
push esi
call ebp
push str.NotifyClamd
push esi
call ebp
add esp, 0x10
cmp dword [eax + 0x1c], 0
je 0x405e1b
mov ecx, dword [eax + 8]
call fcn.00406bbb
mov edi, str.OnUpdateExecute
push edi
push esi
call ebp
cmp dword [eax + 0x18], 0
pop ecx
pop ecx
je 0x405e38
mov edx, dword [eax + 8]
push esi
mov ecx, edi
call fcn.0040196f
pop ecx
xor eax, eax
mov ecx, dword [esp + 0x84]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00401000
add esp, 0x78
ret