This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.SYNOPSIS | |
This script searches for certificates with a specific description pattern, exports them, installs them in WSL, and checks the response using curl. | |
In case Script execution is not allowed on the system, you can run the following command to allow the script to run: | |
powershell -ExecutionPolicy Unrestricted | |
.DESCRIPTION | |
The script searches for certificates with a specific description pattern. It exports each certificate, installs them in WSL, and checks the response using curl. If the response is not correct, it tries the next certificate from the results. If the list is exhausted and WSL still responds with an incorrect answer, it throws an error. | |
.PARAMETER DescriptionPattern | |
The pattern to search for in the certificate description. Default is "CA". | |
.PARAMETER ExcludeIssuers |