@Gustavo Adolfo Hernández Cabrera To generate a certificate with Digicert in the Azure portal using the Key Vault, you need to follow these steps:
- Make sure you have an activated DigiCert CertCentral account. If you don't have one, you can sign up for a CertCentral account on the DigiCert website.
- Create a key vault in Azure. You can use an existing key vault or create one by completing the steps in one of these quickstarts:
- Add DigiCert to the certificate authority list in the key vault. To do this, go to the key vault you want to add it to select Certificates on the Key Vault property page, select the Certificate Authorities tab, and then select Add. Under Create a certificate authority, enter the following values:
- Name: An identifiable issuer name. For example, DigiCertCA.
- Provider: DigiCert.
- Account ID: Your DigiCert CertCentral account ID.
- Account Password: The API key you generated in your DigiCert CertCentral account.
- Account ID: Your DigiCert CertCentral account ID.
- Provider: DigiCert.
- Name: An identifiable issuer name. For example, DigiCertCA.
- Set the issuer. Doing so will add Digicert as a certificate authority in the key vault. You can use the following PowerShell command to set the issuer:
<span class=" active-doc-3" data-doc-items="3">Set-AzKeyVaultCertificateIssuer -VaultName "YourVaultName" -Name "TestIssuer01" -IssuerProvider DigiCert -AccountId "YourDigiCertCertCentralAccountID" -ApiKey "YourDigiCertCertCentralAPIKey" -OrganizationDetails (New-AzKeyVaultCertificateOrganizationDetail -Id "YourOrganizationIDfromDigiCertAccount") -PassThru[4](#doc-pos=3)</span>
- Set the policy for the certificate and issuing certificate from DigiCert directly in Key Vault:
$Policy = New-AzKeyVaultCertificatePolicy -SecretContentType
Regarding the backend API, you can use the same certificate for both frontend and backend if they are hosted on the same domain. If you have a different domain for the backend, you will need to obtain a separate certificate for it.
The error message you are seeing (NET::<span class=" active-doc-0" data-doc-items="0">ERR_CERT_AUTHORITY_INVALID
) indicates that the certificate authority is not trusted by the client. You can try installing the certificate on the VM to resolve this issue. Alternatively, you can use a publicly trusted certificate authority like DigiCert to issue the certificate for your backend API.
I hope this helps! Let me know if you have any further questions.