Friday, March 1, 2024
HomeWINDOWSThe server certificate did not match any of the expected values

The server certificate did not match any of the expected values

-


In this article, we will look at how to fix The server certificate did not match any of the expected values, Error 0x8a15005e. The issue happens when a user is trying to use the WinGet tool on Command Prompt or Windows PowerShell. For example, some users get the error when searching for software on the Microsoft Store using the winget command.

The server certificate did not match any of the expected values

The error message that shows up looks like this:

Failed when opening source(s); try the ‘source reset’ command if the problem persists.
An unexpected error occurred while executing the command:
0x8a15005e : The server certificate did not match any of the expected values.

Microsoft added certificate pinning in WinGet to provide an additional layer of security to ensure that a user is connected to the real MS Store endpoint for authentication purposes.

What causes the 0x8a15005e error?

There are several possible causes of the 0x8a15005e error. If you reinstall your Windows operating system or there are network issues, you might get the error. Also, corrupted system files and Windows update issues can trigger the error. If you access Windows Terminal, Command Prompt, or Windows PowerShell without admin rights while running WinGet commands, you may get the error message ‘The server certificate did not match any of the expected values’. Those are the main causes for the error and we can look at the you can fix it.

Fix The server certificate did not match any of the expected values, Error 0x8a15005e

To fix error 0x8a15005e, The server certificate did not match any of the expected values when running WinGet commands to update or install apps on Microsoft Store, try the following solutions to fix the issues successfully:

  1. Close command windows and restart your computer
  2. Open Windows Terminal, Command Prompt, or PowerShell with Administrative privileges.
  3. Execute the BypassCertificatePinning command line on WinGet
  4. Repair corrupted system files
  5. Check for system updates

Let us now look at these solutions in detail.

1] Close command windows and restart your computer

Restarting your computer is the first way to fix issues related to temporary issues that occur unexpectedly on computers and programs. In this case, if you are using Command Prompt or PowerShell and run into the temporary hitch, it will be resolved and you won’t get the error while running the winget commands.

2] Open Windows Terminal, Command Prompt, or PowerShell with Administrative privileges

error 0x8a15005e

A lack of necessary access privileges can trigger the error. So you need to install or update apps using the WinGet command with administrative rights. To do this, right-click on the start button and select Windows Terminal (Admin), or Windows PowerShell (Admin). Alternatively, you can search for Windows Terminal, CMD, or PowerShell in the search box and select Run as administrator. After that, try to run the command and see if the issue is fixed.

3] Execute the BypassCertificatePinning command line on WinGet

The server certificate did not match any of the expected values, 0x8a15005e

Running a command to bypass certificate pinning ensures that the administrator is allowed to execute the commands. To run the BypassCertificatePinning command on WinGet, follow the steps below:

NOTE: Bypassing the certificate pinning is not advisable as it is a security feature. However, unless you are specifically targeted, it cannot lead to any security issues. Having said that, we recommend disabling the bypassing settings after you are done running the winget command by running the following command:

winget settings –disable BypassCertificatePinningForMicrosoftStore

Related: How to update all installed Programs at once using WINGET

4] Repair corrupted system files

The server certificate did not match any of the expected values, 0x8a15005e

Repairing system files may fix The server certificate did not match any of the expected values error if some system files that WinGet depends on are corrupted or missing. To do this, first, run the System File Check (SFC) scannow tool. If that brings up an error, run the Deployment Image Servicing and Management (DISM) tool to fix system files further.

5] Check for system updates

The server certificate did not match any of the expected values, 0x8a15005e

Finally, ensure that your Windows system is updated. Also, check if you are running an outdated Windows Terminal app. By default, Windows runs updates automatically whenever they are available. However, you can check optional updates in the Windows Update settings.

We hope one of the solutions works for you.

Read: How to use WINGET to download Microsoft Store apps

What is winget used for?

WinGet is a command line tool used to install, update, upgrade, discover, configure, and remove programs from Windows 11 and Windows 10 PCs. It is the Windows Package Manager service interface for users. The tool is beneficial to users who install or manage programs from various sources like GitHub, the Microsoft Store, or any other repositories.

The server certificate did not match any of the expected values



Source link

www.thewindowsclub.com

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular