Function at 0x404b20
Capabilities:
Get common file path
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa34
mov eax, dword [0x5b0050]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov dword [ebp - 0xa10], ecx
xor eax, eax
mov word [ebp - 0x20c], ax
push 0x206
push 0
lea ecx, [ebp - 0x20a]
push ecx
call fcn.005341e0
add esp, 0xc
mov ecx, 6
mov esi, str.srclient.dll
lea edi, [ebp - 0xa0c]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0xe6
push 0
lea edx, [ebp - 0x9f2]
push edx
call fcn.005341e0
add esp, 0xc
mov ecx, 6
mov esi, 0x58f004
lea edi, [ebp - 0x90c]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0xe6
push 0
lea eax, [ebp - 0x8f2]
push eax
call fcn.005341e0
add esp, 0xc
mov ecx, 6
mov esi, 0x58f020
lea edi, [ebp - 0x80c]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0xe6
push 0
lea ecx, [ebp - 0x7f2]
push ecx
call fcn.005341e0
add esp, 0xc
mov ecx, 6
mov esi, 0x58f03c
lea edi, [ebp - 0x70c]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0xe6
push 0
lea edx, [ebp - 0x6f2]
push edx
call fcn.005341e0
add esp, 0xc
mov eax, dword [0x58f058]
mov dword [ebp - 0x60c], eax
mov ecx, dword [0x58f05c]
mov dword [ebp - 0x608], ecx
mov edx, dword [0x58f060]
mov dword [ebp - 0x604], edx
mov eax, dword [0x58f064]
mov dword [ebp - 0x600], eax
mov ecx, dword [0x58f068]
mov dword [ebp - 0x5fc], ecx
mov dx, word [0x58f06c]
mov word [ebp - 0x5f8], dx
push 0xea
push 0
lea eax, [ebp - 0x5f6]
push eax
call fcn.005341e0
add esp, 0xc
mov ecx, dword [0x58f070]
mov dword [ebp - 0x50c], ecx
mov edx, dword [0x58f074]
mov dword [ebp - 0x508], edx
mov eax, dword [0x58f078]
mov dword [ebp - 0x504], eax
mov ecx, dword [0x58f07c]
mov dword [ebp - 0x500], ecx
mov edx, dword [0x58f080]
mov dword [ebp - 0x4fc], edx
mov ax, word [0x58f084]
mov word [ebp - 0x4f8], ax
push 0xea
push 0
lea ecx, [ebp - 0x4f6]
push ecx
call fcn.005341e0
add esp, 0xc
mov ecx, 6
mov esi, 0x58f088
lea edi, [ebp - 0x40c]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0xe6
push 0
lea edx, [ebp - 0x3f2]
push edx
call fcn.005341e0
add esp, 0xc
mov eax, dword [0x58f0a4]
mov dword [ebp - 0x30c], eax
mov ecx, dword [0x58f0a8]
mov dword [ebp - 0x308], ecx
mov edx, dword [0x58f0ac]
mov dword [ebp - 0x304], edx
mov eax, dword [0x58f0b0]
mov dword [ebp - 0x300], eax
mov ecx, dword [0x58f0b4]
mov dword [ebp - 0x2fc], ecx
mov dx, word [0x58f0b8]
mov word [ebp - 0x2f8], dx
push 0xea
push 0
lea eax, [ebp - 0x2f6]
push eax
call fcn.005341e0
add esp, 0xc
push 0x800
push 0
mov ecx, dword [ebp - 0xa10]
add ecx, 0x714
push ecx
call fcn.005341e0
add esp, 0xc
mov dword [ebp - 0xa14], 0
jmp 0x404d7d
mov edx, dword [ebp - 0xa14]
add edx, 1
mov dword [ebp - 0xa14], edx
cmp dword [ebp - 0xa14], 8
jge 0x404db6
mov eax, dword [ebp - 0xa14]
shl eax, 8
lea ecx, [ebp + eax - 0xa0c]
push ecx
mov edx, dword [ebp - 0xa14]
shl edx, 8
mov eax, dword [ebp - 0xa10]
lea ecx, [eax + edx + 0x714]
push ecx
call dword [sym.imp.SHLWAPI.dll_StrCpyW]
jmp 0x404d6e
mov edx, dword [ebp - 0xa10]
mov dword [edx + 0x1a14], 0
call fcn.004045d0
mov dword [ebp - 0xa34], eax
mov eax, dword [ebp - 0xa34]
mov dword [ebp - 0xa1c], eax
mov ecx, dword [ebp - 0xa1c]
sub ecx, 1
mov dword [ebp - 0xa1c], ecx
cmp dword [ebp - 0xa1c], 0xa
ja case.default.0x404dff
mov edx, dword [ebp - 0xa1c]
jmp dword [edx*4 + 0x40511c]
push str.driverxp
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push str.driver2003
lea ecx, [ebp - 0x20c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push str.driverWin7
lea edx, [ebp - 0x20c]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push str.driver2008
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push 0x58f128
lea ecx, [ebp - 0x20c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push str.driverWin10
lea edx, [ebp - 0x20c]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x404e90
push str.driverWin8
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x5be218
mov ecx, dword [ebp - 0xa10]
add ecx, 0x50c
push ecx
call dword [sym.imp.SHLWAPI.dll_StrCpyW]
lea edx, [ebp - 0x20c]
push edx
mov eax, dword [ebp - 0xa10]
add eax, 0x50c
push eax
call dword [sym.imp.SHLWAPI.dll_StrCatW]
cmp dword [0x5bdd04], 0x40
jne 0x404ee4
push str.x64_
mov ecx, dword [ebp - 0xa10]
add ecx, 0x50c
push ecx
call dword [sym.imp.SHLWAPI.dll_StrCatW]
jmp 0x404efc
push str.x86_
mov edx, dword [ebp - 0xa10]
add edx, 0x50c
push edx
call dword [sym.imp.SHLWAPI.dll_StrCatW]
mov eax, dword [ebp - 0xa10]
add eax, 0x304
push eax
push 0
push 0
push 5
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
je 0x404f4f
push 0x104
mov ecx, dword [ebp - 0xa10]
add ecx, 0x304
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x58f194
mov edx, dword [ebp - 0xa10]
add edx, 0x304
push edx
call dword [sym.imp.SHLWAPI.dll_StrStrW]
xor ecx, ecx
mov word [eax], cx
mov dword [ebp - 0xa20], 2
cmp dword [0x5bdd04], 0x40
jne 0x404f74
mov edx, dword [ebp - 0xa20]
or edx, 0x100
mov dword [ebp - 0xa20], edx
lea eax, [ebp - 0xa28]
push eax
mov ecx, dword [ebp - 0xa20]
push ecx
push 0
push 0x58f198
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40502c
mov edx, dword [ebp - 0xa10]
add edx, 0x304
mov dword [ebp - 0xa18], edx
mov eax, dword [ebp - 0xa18]
add eax, 2
mov dword [ebp - 0xa30], eax
mov ecx, dword [ebp - 0xa18]
mov dx, word [ecx]
mov word [ebp - 0xa22], dx
add dword [ebp - 0xa18], 2
cmp word [ebp - 0xa22], 0
jne 0x404fbd
mov eax, dword [ebp - 0xa18]
sub eax, dword [ebp - 0xa30]
sar eax, 1
mov dword [ebp - 0xa2c], eax
mov ecx, dword [ebp - 0xa2c]
lea edx, [ecx + ecx + 2]
push edx
mov eax, dword [ebp - 0xa10]
add eax, 0x304
push eax
push 1
push 0
push str.wwP1
mov ecx, dword [ebp - 0xa28]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edx, dword [ebp - 0xa28]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0x58f21c
mov eax, dword [ebp - 0xa10]
add eax, 0x304
push eax
call dword [sym.imp.SHLWAPI.dll_StrCatW]
push 0x58f220
mov ecx, dword [ebp - 0xa10]
add ecx, 0x304
push ecx
call dword [sym.imp.SHLWAPI.dll_StrCatW]
push str.config.ini
mov edx, dword [ebp - 0xa10]
add edx, 0x304
push edx
call dword [sym.imp.SHLWAPI.dll_StrCatW]
mov eax, dword [ebp - 0xa10]
add eax, 0x304
push eax
push 0x58f244
push 0x58f250
push 0x58f260
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
cmp dword [0x5bdd04], 0x40
jne 0x4050c1
mov ecx, dword [ebp - 0xa10]
add ecx, 0x304
push ecx
push 0x58f270
push 0x58f278
push 0x58f284
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
jmp 0x4050e3
mov edx, dword [ebp - 0xa10]
add edx, 0x304
push edx
push 0x58f294
push str.os64
push 0x58f2a8
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
mov eax, dword [ebp - 0xa10]
add eax, 0x304
push eax
push 0x58f2b8
push 0x58f2bc
push str.debug
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
mov eax, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00531c35
mov esp, ebp
pop ebp
ret