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

VCert CLI doesn't support enroll certificates with EC Keys using --no-prompt flag #410

Open
luispresuelVenafi opened this issue Nov 8, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@luispresuelVenafi
Copy link
Contributor

PROBLEM SUMMARY
Currently VCert doesn't support the case to enroll a certificate key-pair (Certificate and Private Key) using Elliptic algorithm by using a --no-prompt flag, in other words, not providing a password. This works well with RSA Keys, so we should have parity usability in this case. This happens on both "service" and "local" generated key-pairs

STEPS TO REPRODUCE
vcert enroll -u https://redacted -t redacted_token -z redacted_ecc_zone --cn luis.presuel.venafi.example --key-type ecdsa --key-curve p521 --csr service --trust-bundle /path/to/bundle.pem --no-prompt

EXPECTED RESULTS
No issue at the end and certificate

ACTUAL RESULTS

vCert: 2023/11/08 10:00:15 Detected trust bundle flag at CLI.
vCert: 2023/11/08 10:00:15 You specified a trust bundle.
vCert: 2023/11/08 10:00:15 Successfully connected to Trust Protection Platform
vCert: 2023/11/08 10:00:16 Successfully read zone configuration for redacted_ecc_zone
vCert: 2023/11/08 10:00:16 Successfully created request for luis.presuel.venafi.example
vCert: 2023/11/08 10:00:18 Successfully posted request for luis.presuel.venafi.example, will pick up by redacted_ecc_zone\luis.presuel.venafi.example
vCert: 2023/11/08 10:00:24 Successfully retrieved request for redacted_ecc_zone\luis.presuel.venafi.example
vCert: 2023/11/08 10:00:24 pkcs8: only PKCS #5 v2.0 supported

ENVIRONMENT DETAILS
VCert version 5.2.0, TPP 23.1 and 22.3

COMMENTS/WORKAROUNDS
There's no direct work around as providing an empty string in the "key-password flag will result in VCert asking a prompt to introduce a password.

vcert enroll -u https://redacted -t redacted_token -z redacted_ecc --cn luis.presuel.venafi.example --key-type ecdsa --key-curve p521 --csr service --trust-bundle /pasth/totest.pem --key-password ""
Enter key passphrase:
vCert: 2023/11/08 10:14:30 Failed to read password from input: interrupted

The best would to provide a password and the remove it with openssl, but this beats the purpose to have VCert to ease this.

@luispresuelVenafi luispresuelVenafi added the bug Something isn't working label Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant