# Issue a certificate using
CA Service and verify in
Certificate Manager (2nd gen)

Learn how to issue a private certificate with Certificate Authority Service and use
Certificate Manager (2nd gen) to view and verify the certificate details in its
directory.

## Before you begin

1. You need an existing CA pool with an enabled CA in CA Service. For more information, see [Create a CA pool](https://docs.cloud.google.com/certificate-authority-service/docs/creating-ca-pool) and [Create a CA](https://docs.cloud.google.com/certificate-authority-service/docs/creating-certificate-authority).
2. Ensure you have the required IAM roles. For more information, see [Required roles](https://docs.cloud.google.com/certificate-manager/docs/v2/quickstart-ca-service#required-roles).

### Required roles


To get the permissions that
you need to issue a certificate and view resources,

ask your administrator to grant you the
following IAM roles on the project:

- [CA Service Certificate Requester](https://docs.cloud.google.com/iam/docs/roles-permissions/privateca#privateca.certificateRequester) (`roles/privateca.certificateRequester`)
- [CA Service Viewer](https://docs.cloud.google.com/iam/docs/roles-permissions/privateca#privateca.viewer) (`roles/privateca.viewer`)
- [Certificate Manager Viewer](https://docs.cloud.google.com/iam/docs/roles-permissions/certificatemanager#certificatemanager.viewer) (`roles/certificatemanager.viewer`)


For more information about granting roles, see [Manage access to projects, folders, and organizations](https://docs.cloud.google.com/iam/docs/granting-changing-revoking-access).


You might also be able to get
the required permissions through [custom
roles](https://docs.cloud.google.com/iam/docs/creating-custom-roles) or other [predefined
roles](https://docs.cloud.google.com/iam/docs/roles-overview#predefined).

## Issue a certificate using CA Service

To issue a certificate, complete the following steps:

1. In the Google Cloud console, go to **CA Service**.


   [Go to CA Service](https://console.cloud.google.com/security/cas/request)

   <br />

2. Follow the instructions in the CA Service documentation to
   [Request a certificate](https://docs.cloud.google.com/certificate-authority-service/docs/create-certificate#request-certificate).

3. Note the *domain name* or *identity* that you specify. You use
   this value to find the certificate in the directory.

## View and verify the certificate details in Certificate Manager (2nd gen)

After CA Service issues the certificate,
Certificate Manager (2nd gen) detects and adds it to the
certificate directory as an observed certificate.

To view the certificate, complete the following steps:

1. In the Google Cloud console, go to **Certificates**.


   [Go to Certificates](https://console.cloud.google.com/security/ccm/certificateDirectory)

   <br />

2. Wait a few minutes for the certificate to appear in the directory.
   If it doesn't appear, refresh the directory.

3. To find the certificate you issued, use the **Filter bar** to search using a
   relevant filter.

4. To open the details pane, click the certificate's *domain name* in the
   directory list.

5. Inspect the certificate properties:

   - **Validity** : Check both the **Not valid before** and **Not valid after** dates.
   - **Subject**: Confirm the subject matches the details that you provided during issuance.
   - **Issuance details**: Note the issuing CA and organization.

## Clean up


To avoid incurring charges to your Google Cloud account for
the resources used on this page, follow these steps.

To avoid incurring unintended costs, revoke and delete the CA service resource.

For more information about managing certificates in
CA Service, see
[Manage certificates](https://docs.cloud.google.com/certificate-authority-service/docs/managing-ca-state).

> [!NOTE]
> **Note:** No Certificate Manager (2nd gen) resources require cleanup. Certificate Manager (2nd gen) only observes the certificate and automatically removes expired records from the directory.

## What's next

- [Compare Certificate Manager versions](https://docs.cloud.google.com/certificate-manager/docs/v2/comparison)
- [How Certificate Manager (2nd gen) works](https://docs.cloud.google.com/certificate-manager/docs/v2/core-components)
- [Automate certificate lifecycle for load balancers](https://docs.cloud.google.com/certificate-manager/docs/v2/quickstart-lb-certificates)
- [View certificate directory](https://docs.cloud.google.com/certificate-manager/docs/v2/inventory)
- [Create issuance configuration](https://docs.cloud.google.com/certificate-manager/docs/v2/issuance-configuration)