Function at 0x402af0
Capabilities:
Create directory
Get common file path
Set file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x40a246
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x228
mov eax, dword [0x40e090]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push ebx
lea ecx, [esp + 0x10]
mov dword [esp + 0x230], eax
xor esi, esi
call fcn.004026a0
xor eax, eax
cmp ebx, esi
mov byte [esp + 0x18], 0
mov ecx, 0x40
lea edi, [esp + 0x19]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov dword [esp + 0x23c], esi
stosb byte es:[edi], al
je 0x402d24
cmp byte [ebx + 1], 0x3a
jne 0x402d24
push 1
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x14]
call fcn.004021d0
mov eax, dword [eax]
push 0x40b2ec
push eax
call fcn.00404359
add esp, 8
test eax, eax
mov eax, dword [esp + 0x10]
setne bl
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402ba0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
test bl, bl
je 0x402bb2
push 0x40b2ec
lea ecx, [esp + 0x10]
call fcn.004025c0
push 0xc
push str.KAVLEOS.Conf
lea ecx, [esp + 0x14]
call fcn.00401e60
push 0x104
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp eax, 3
jle 0x402d1f
mov ecx, dword [ebp + 8]
mov dl, byte [ecx]
cmp dl, byte [esp + 0x18]
jne 0x402d1f
lea ecx, [esp + 0x10]
call fcn.00401000
xor eax, eax
mov byte [esp + 0x120], 0
mov ecx, 0x40
lea edi, [esp + 0x121]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov byte [esp + 0x23c], 1
mov byte [esp + 0x1b], 0
xor eax, eax
lea ecx, [ecx]
mov cl, byte [esp + eax + 0x18]
mov byte [esp + eax + 0x120], cl
inc eax
test cl, cl
jne 0x402c20
mov al, byte [esp + 0x18]
cmp al, 0x61
jge 0x402c3e
add al, 0x20
mov byte [esp + 0x18], al
lea edi, [esp + 0x18]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402c43
mov eax, dword [str.kav2007]
mov ecx, dword [0x40b2d8]
mov dword [edi], eax
mov dword [edi + 4], ecx
lea edi, [esp + 0x120]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402c63
mov edx, dword [str.KAV2007]
mov ecx, dword [esp + 0xc]
mov eax, dword [0x40b2d0]
mov dword [edi], edx
push ecx
lea edx, [esp + 0x1c]
push edx
push str.Path
push str.Install_Path
mov dword [edi + 4], eax
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov eax, dword [esp + 0xc]
push 6
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x124]
push eax
call fcn.00401770
add esp, 8
push str.SOFTWAREkingsoftAntiVirus
push 0x80000002
lea ecx, [esp + 0x18]
call fcn.00401010
lea edi, [esp + 0x18]
dec edi
lea esp, [esp]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402ce0
mov cx, word [0x40b2ec]
lea edx, [esp + 0x18]
push edx
mov word [edi], cx
push str.ProgramPath
lea ecx, [esp + 0x18]
call fcn.004010b0
lea ecx, [esp + 0x10]
call fcn.00401050
lea ecx, [esp + 0x10]
mov byte [esp + 0x23c], 0
call fcn.00401110
mov esi, 1
mov eax, dword [esp + 0xc]
add eax, 0xfffffff0
mov dword [esp + 0x23c], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402d4d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x234]
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x22c]
mov eax, esi
call fcn.00403bb5
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret