Function at 0x5d1db0
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
mov esi, ecx
lea eax, [esp + 0x18]
push edi
lea ecx, [esp + 0x14]
push eax
push ecx
push 0
push 0xf003f
push 0
push 0x6fc418
push 0
push str.SoftwareDownloadManagermaxID
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov ecx, dword [esp + 0x14]
lea edx, [esp + 0x18]
lea eax, [esp + 0x10]
push edx
push eax
push 0
push 0
push str.maxID
push ecx
mov dword [esp + 0x30], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x5d1e11
xor eax, eax
jmp 0x5d1e15
mov eax, dword [esp + 0x10]
mov ecx, dword [0x6fcc2c]
inc eax
cmp ecx, eax
mov dword [esp + 0x10], eax
jbe 0x5d1e2b
lea eax, [ecx + 1]
mov dword [esp + 0x10], eax
mov dword [esi + 0x4a0], eax
mov ecx, dword [0x6fcc2c]
cmp eax, ecx
jle 0x5d1e40
mov dword [0x6fcc2c], eax
mov edi, dword [esp + 0x28]
test edi, edi
je 0x5d1e5b
mov edx, dword [esi + 0x4a0]
push 0
push 0
push edx
lea ecx, [esi + 0x20]
call fcn.005dfb60
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x10]
push 4
push eax
push 4
push 0
push str.maxID
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x24]
test eax, eax
je 0x5d1e97
mov eax, dword [esi + 0x4a8]
mov ecx, dword [esi + 0x4ac]
jmp 0x5d1e9b
xor eax, eax
xor ecx, ecx
push ecx
push eax
mov eax, dword [esp + 0x18]
lea ebp, [esi + 0x20]
push eax
mov ecx, ebp
call fcn.005e13f0
mov ecx, dword [esp + 0x10]
push ecx
mov ecx, ebp
call fcn.005df100
mov eax, dword [esi + 0xc8]
test eax, eax
jne 0x5d1ecc
mov ecx, dword [esi + 0xa74]
test ecx, ecx
je 0x5d1ee4
mov edx, dword [esi + 0x4a0]
push 0
push edx
push eax
mov eax, dword [esi + 0xa74]
mov ecx, ebp
push eax
call fcn.005df1f0
test edi, edi
jne 0x5d2008
mov eax, dword [esi + 0x50]
test eax, eax
je 0x5d2008
mov eax, dword [esi + 0x4c]
test eax, eax
je 0x5d2008
lea ebx, [esi + 0x4d8]
test ebx, ebx
je 0x5d2008
mov eax, dword [esi + 0x45c]
test eax, eax
jne 0x5d1f2e
mov ecx, dword [esp + 0x10]
push ecx
mov ecx, ebp
call fcn.005e6030
test al, al
je 0x5d205a
mov eax, dword [esi + 0x50]
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x5d1f6f
push eax
call fcn.00609a4e
add esp, 4
test eax, eax
je 0x5d1f6f
mov edx, dword [esi + 0x50]
push edx
call fcn.00609a4e
mov ecx, dword [esi + 0x50]
mov edx, dword [esi + 0x45c]
add esp, 4
lea eax, [eax + eax + 2]
push eax
push ecx
push 1
push 0
push 0x6d10ac
push edx
call edi
mov eax, dword [esi + 0x4c]
test eax, eax
je 0x5d1faa
push eax
call fcn.00609a4e
add esp, 4
test eax, eax
je 0x5d1faa
mov eax, dword [esi + 0x4c]
push eax
call fcn.00609a4e
mov edx, dword [esi + 0x4c]
add esp, 4
lea ecx, [eax + eax + 2]
mov eax, dword [esi + 0x45c]
push ecx
push edx
push 1
push 0
push str.LocalPath
push eax
call edi
push ebx
call fcn.00609a4e
add esp, 4
test eax, eax
je 0x5d1fd8
push ebx
call fcn.00609a4e
mov edx, dword [esi + 0x45c]
add esp, 4
lea ecx, [eax + eax + 2]
push ecx
push ebx
push 1
push 0
push str.LogFileName
push edx
call edi
mov ecx, dword [esi + 0x4b4]
lea eax, [esi + 0x4b0]
test ecx, ecx
jl 0x5d2008
jg 0x5d1fef
cmp dword [eax], 0
jbe 0x5d2008
push 8
push eax
mov eax, dword [esi + 0x45c]
push 0
push 0
push 0x6e03bc
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [esp + 0x24]
test eax, eax
je 0x5d205a
mov eax, dword [esi + 0x4b4]
lea edi, [esi + 0x4b0]
test eax, eax
jl 0x5d205a
jg 0x5d2027
cmp dword [edi], 0
jbe 0x5d205a
mov eax, dword [esi + 0x45c]
test eax, eax
jne 0x5d2041
mov ecx, dword [esp + 0x10]
push ecx
mov ecx, ebp
call fcn.005e6030
test al, al
je 0x5d205a
mov edx, dword [esi + 0x45c]
push 8
push edi
push 0
push 0
push 0x6e03bc
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret 8