Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Add ability to issue a aws_acm_certificate from a private CA (acmcpa) #5550

Closed
TFaga opened this issue Aug 14, 2018 · 9 comments
Closed
Labels
enhancement Requests to existing resources that expand the functionality or scope. service/acm Issues and PRs that pertain to the acm service.
Milestone

Comments

@TFaga
Copy link

TFaga commented Aug 14, 2018

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

Support for issuing certificates (aws_acm_certificate) with a private CA (`aws_acmpca_certificate_authority) from the certificate manager.

Currently there is no option to pass in the arn of a private CA in order to issue a private certificate instead of a default public one.

I can tackle this myself if I didn't miss something.

New or Affected Resource(s)

  • aws_acm_certificate

Potential Terraform Configuration

resource "aws_acm_certificate" "cert" {
  domain_name       = "internal.example.com"
  certificate_authority_arn = "arn:aws:acm-pca:region:account:certificate-authority/12345678-1234-1234-1234-123456789012"
}

References

@bflad
Copy link
Contributor

bflad commented Aug 15, 2018

Hi @TFaga Thanks for submitting this feature request.

Its important to note that ACM and ACMPCA are different at the SDK level and use different API endpoints. For implementing this support, we will want to create a completely separate resource to handle these concerns. 👍

@bflad bflad added new-resource Introduces a new resource. service/acmpca Issues and PRs that pertain to the acmpca service. labels Aug 15, 2018
@TFaga
Copy link
Author

TFaga commented Aug 16, 2018

Hi @bflad

Thanks for getting back. From my understanding, the certificates found in the acm-pca endpoint serve a different purpose then the ones mentioned in this issue (aws_acm_certificate). They are only for issuing certificates you generated locally and sent the CSR to the PCA. AWS never gets the private keys and as such are not managed by AWS at all. You can only revoke them AFAIK.

If however, you want to generate a managed certificates from a PCA that functions the same as the public certificates (i.e. keys managed by AWS and usable in integrated services), you need to issue the certificate with the acm client and pass in a PCA arn, which currently you cannot do with terraform.

So to summarize we could do two things:

  • Add the certificate_authority_arnproperty to the aws_acm_certificate in order to enable issuing private managed certificates from a PCA,
  • Create a new resource (e.g. acm_acmpca_certificate) which represents the other type of certificate (unmanaged), which is created with an external CSR.

@bflad bflad added enhancement Requests to existing resources that expand the functionality or scope. service/acm Issues and PRs that pertain to the acm service. and removed service/acmpca Issues and PRs that pertain to the acmpca service. new-resource Introduces a new resource. labels Aug 16, 2018
@bflad
Copy link
Contributor

bflad commented Aug 16, 2018

Ah ha! Okay I see what you mean there is a difference between these two:

In your case, you are correct that for the first case, we can (and should 😄 ) do this with the existing resource. The second will need to be a separate resource. My apologies for the confusion.

@gitchandran
Copy link

When will this feature get released? Are there any alternative to generate private certificate using the current version of terraform?

@bhemmings
Copy link

Hi is there any news on being able to use aws_acm_certificate to issue private certificates, Can use aws_acmpca_certificate_authority for creating a pca but dont seem to be able to use this through tf at mo?

@texdc
Copy link

texdc commented Aug 1, 2019

@bflad Please ensure the 2 PRs for this issue are properly reviewed asap. This functionality has been available in the AWS SDK for over a year now. TF is generally better about staying on top of new features.

@bflad bflad added this to the v2.23.0 milestone Aug 6, 2019
@bflad
Copy link
Contributor

bflad commented Aug 6, 2019

Hi folks 👋 Support for issuing private certificates via a new certificate_authority_arn argument in the aws_acm_certificate resource has been merged and will release with version 2.23.0 of the Terraform AWS Provider, later this week.

If you're interesting in additional functionality, such as issuing ACM PCA certificates (not through ACM), please file new feature request issues for further triage. Thanks.

@bflad bflad closed this as completed Aug 6, 2019
@ghost
Copy link

ghost commented Aug 7, 2019

This has been released in version 2.23.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks!

@ghost
Copy link

ghost commented Nov 2, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked and limited conversation to collaborators Nov 2, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Requests to existing resources that expand the functionality or scope. service/acm Issues and PRs that pertain to the acm service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants