I have placed the .p12 file in the default location. However I’m not sure how to set the password.
I cannot run the keytool command because I’m using the built-in JRE. Unless the included JRE is accessible somewhere with the keytool exe? Where is this installed.
Could you please either let me know where I can configure the password or how to run the keytool command with the included JRE.
To find the embedded JRE, you have to navigate to the installation folder of the SonarQube for Visual Studio, which as per Microsoft’s documentation, should be in %LocalAppData%\Microsoft\VisualStudio\<Visual Studio version>\Extensions\. The JRE should then be in the sub-folders Sloop\jre.
Then you can use the embedded keytool with a command similar to: "[full_path_to_extension]\Sloop\jre\bin\keytool.exe" -import -trustcacerts -keystore ~/.sonarlint/ssl/truststore.p12 -storepass sonarlint -noprompt -file <YOUR_CERTIFICATE_NAME.cer>