-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center.
-
×InformationNeed Windows 11 help?Check documents on compatibility, FAQs, upgrade information and available fixes.
Windows 11 Support Center.
- HP Community
- Desktops
- Desktop Software and How To Questions
- Change BIOS password through WMI always returns error code 6
Create an account on the HP Community to personalize your profile and ask a question
04-06-2021 01:50 PM
I'm trying to change the BIOS password of this device using WMI scripts, but the return code is always 6 (Access Denied), I am sure the password is right.
The password configured is the "Setup Password", the "Power-On Password" is empty.
The script I am using to change the password is:
#Connect to the HP_BIOSSettingInterface WMI class
$Interface = Get-WmiObject -Namespace root/hp/InstrumentedBIOS -Class HP_BIOSSettingInterface
#Change an existing setup password
$Interface.SetBIOSSetting("Setup Password","<utf-16/>" + "NewPassword","<utf-16/>" + "OldPassword")
But it returns error code 6
This same script works well on some HP Compaq 8100 Elite SFF PC (around 50%), I didn't found differences between the devices.
In this device, we have tried to remove the password and put it again, send the password encoded in KBD explained in this forum, and even execute this wrong WMI script to get an error code 5, but it still returns an error code 6:
#Connect to the HP_BIOSSettingInterface WMI class
$Interface = Get-WmiObject -Namespace root/hp/InstrumentedBIOS -Class HP_BIOSSettingInterface
#Change an existing setup password
$Interface.SetBIOSSetting("Setup Password","<utf-16/>")
There is some lock on the BIOS that does not allow me to change the BIOS password with WMI?
Or there is a way to reinstall corrupted HP WMI classes in this computer?
04-06-2021 01:54 PM
Hey @koraniar 🙂
Thank you for visiting the HP Support Community.
According to the Community's Rules of Participation:
4d. No posts shall include instructions or directions intended to bypass or subvert security measures, including passwords, locking mechanisms, fingerprint scans, etc., or to bypass any safety measures.
Therefore, this topic is being locked. If you would like help resetting the password on your product, please Contact HP support in your region.
Regards,
MarcusC