Allowing GCP provisioner to issue SSH User Certificates - Option 1 #1557
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Name of feature:
Allowing GCP provisioner to issue SSH User Certificates - Option 1
Pain or issue this feature alleviates:
Why is this important to the project (if not answered above):
Workloads running in GCP Compute Instances are run with an assigned Service Account. The Service Account authenticated on a given Compute Instance can be found in the Identity Token obtained from the metadata server that the GCP provisioner uses to obtain the Compute Instance identity and generate the SSH Host Certificate.
Allowing the GCP provisioner to issue SSH User Certificates would allow the above referred Workloads to use the smallstep infrastructure to sign into other Compute Instances. Examples of workloads that would benefit from this change are: CICD systems like Jenkins and Ansible.
Without this feature there would be two other options to achieve this:
ca.json
configuration file.However neither of these can validate the service account principal.
Is there documentation on how to use this feature? If so, where?
If this change is accepted we could update the documentation for the GCP provisioner here
In what environments or workflows is this feature supported?
This would work for smallstep-ca deployments that support GCP
In what environments or workflows is this feature explicitly NOT supported (if any)?
This will not work outside of GCP
Supporting links/other PRs/issues:
This proposal features minimal changes to the existing code, we removed the enforcement of the
HostCert
type, added the username validation and changed the certificate template. However this change requires a significant refactor to the tests because of the change in the certificate template which leads to rely more on the Certificate Sign Request as opposed to the provisioner sign options.We propose a second approach which relies the most on the provisioner sign options but required a bigger refactor to the codebase:
#1558
❤️ Thank you!