Function at 0x407590
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x100
mov eax, dword [0x45c5d0]
xor eax, esp
mov dword [esp + 0xf8], eax
push ebp
push esi
push edi
lea eax, [esp + 0x20]
push eax
call fcn.00408520
mov eax, dword [esp + 0xc4]
cmp eax, 5
je 0x4077e6
cmp eax, 6
je 0x4077e6
cmp eax, 0xb
je 0x4075d8
cmp eax, 0xc
jl 0x40769f
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea ecx, [esp + 0xc]
push ecx
push 3
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerAutoplayHandlers
push closesocket
call edi
mov edx, dword [esp + 0xc]
test eax, eax
jne 0x407699
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [esp + 0x18], eax
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x1c]
push ecx
push 0
push 0
push str.DisableAutoplay
mov ebp, 4
push edx
mov dword [esp + 0x34], ebp
call esi
test eax, eax
je 0x407636
mov eax, dword [esp + 0xc]
push eax
jmp 0x40783a
cmp dword [esp + 0x18], 1
jne 0x407647
mov ecx, dword [esp + 0xc]
push ecx
jmp 0x407884
lea edx, [esp + 0xc]
push edx
push 3
push 0
push str.SYSTEMCurrentControlSetServicesCdrom
push reloc.OLEAUT32.dll_SysReAllocString
call edi
test eax, eax
mov eax, dword [esp + 0xc]
jne 0x407883
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x14]
push edx
push 0
push 0
push str.AutoRun
push eax
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], ebp
call esi
test eax, eax
jne 0x40763d
cmp dword [esp + 0x10], 1
je 0x40762c
mov edx, dword [esp + 0xc]
push edx
jmp 0x407884
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea ecx, [esp + 0xc]
push ecx
push 3
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionPoliciesExplorer
push reloc.OLEAUT32.dll_SysReAllocString
call esi
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [esp + 0xc]
test eax, eax
je 0x4076cb
push edx
jmp 0x40771b
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x14]
push ecx
push 0
push 0
push str.NoDriveTypeAutoRun
push edx
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], 4
call edi
test eax, eax
je 0x4076fc
mov eax, dword [esp + 0xc]
push eax
jmp 0x40771b
mov eax, dword [esp + 0x10]
cmp eax, 0xb5
je 0x40763d
cmp eax, 0xff
je 0x40763d
mov ecx, dword [esp + 0xc]
push ecx
mov ebp, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call ebp
lea edx, [esp + 0xc]
push edx
push 3
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionPoliciesExplorer
push closesocket
call esi
test eax, eax
mov eax, dword [esp + 0xc]
jne 0x4077de
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x1c]
push edx
push 0
push 0
push str.NoDriveTypeAutoRun
push eax
mov dword [esp + 0x30], 0
mov dword [esp + 0x34], 4
call edi
test eax, eax
je 0x40779b
mov ecx, dword [esp + 0xc]
push ecx
call ebp
lea ecx, [esp + 0x20]
call fcn.00408630
mov eax, 1
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0xf8]
xor ecx, esp
call fcn.0043164a
add esp, 0x100
ret
mov eax, dword [esp + 0x18]
cmp eax, 0xb5
je 0x4077da
cmp eax, 0xff
je 0x4077da
mov edx, dword [esp + 0xc]
push edx
call ebp
lea ecx, [esp + 0x20]
call fcn.00408630
mov eax, 1
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0xf8]
xor ecx, esp
call fcn.0043164a
add esp, 0x100
ret
mov eax, dword [esp + 0xc]
push eax
call ebp
jmp 0x40788a
lea edx, [esp + 0xc]
push edx
push 3
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionPoliciesExplorer
push closesocket
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
mov eax, dword [esp + 0xc]
jne 0x407883
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x14]
push edx
push 0
push 0
push str.NoDriveTypeAutoRun
push eax
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], 4
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x407866
mov ecx, dword [esp + 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esp + 0x20]
call fcn.00408630
mov eax, 1
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0xf8]
xor ecx, esp
call fcn.0043164a
add esp, 0x100
ret
mov eax, dword [esp + 0x10]
cmp eax, 0xb5
je 0x40787f
cmp eax, 0xff
je 0x40787f
mov edx, dword [esp + 0xc]
push edx
jmp 0x40783a
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esp + 0x20]
call fcn.00408630
mov ecx, dword [esp + 0x104]
pop edi
pop esi
pop ebp
xor ecx, esp
xor eax, eax
call fcn.0043164a
add esp, 0x100
ret