Open
Conversation
Introduce a new `type` field to select what kind of secret to generate and support new type `curve25519_keypair` to generate Curve25519 keypair
dbourdrez
requested changes
Feb 6, 2026
| subcategory: "" | ||
| description: |- | ||
| A cryptographic randomly generated secret stored as bytes in a Vault secret. The resulting Vault secret will have a custom metadata secret_type with the value random_secret and a custom metadata secret_length with the same value as the length attribute. | ||
| A cryptographic randomly generated secret stored as bytes in a Vault secret. Secret can be either a random bytes (random_secret) array or a Curve25519 keypair (curve25519_keypair). The resulting Vault secret will have a custom metadata secret_type with the type of the secret and a custom metadata secret_length with the same value as the length attribute. |
There was a problem hiding this comment.
Suggested change
| A cryptographic randomly generated secret stored as bytes in a Vault secret. Secret can be either a random bytes (random_secret) array or a Curve25519 keypair (curve25519_keypair). The resulting Vault secret will have a custom metadata secret_type with the type of the secret and a custom metadata secret_length with the same value as the length attribute. | |
| A cryptographic randomly generated secret stored as bytes in a Vault secret. A secret can be either an array of random bytes (random_secret) or a Curve25519 keypair (curve25519_keypair). The resulting Vault secret will have a custom metadata secret_type with the type of the secret and a custom metadata secret_length with the same value as the length attribute. |
| # vaultprov_random_secret (Resource) | ||
|
|
||
| A cryptographic randomly generated secret stored as bytes in a Vault secret. The resulting Vault secret will have a custom metadata `secret_type` with the value `random_secret` and a custom metadata `secret_length` with the same value as the `length` attribute. | ||
| A cryptographic randomly generated secret stored as bytes in a Vault secret. Secret can be either a random bytes (`random_secret`) array or a Curve25519 keypair (`curve25519_keypair`). The resulting Vault secret will have a custom metadata `secret_type` with the type of the secret and a custom metadata `secret_length` with the same value as the `length` attribute. |
There was a problem hiding this comment.
Suggested change
| A cryptographic randomly generated secret stored as bytes in a Vault secret. Secret can be either a random bytes (`random_secret`) array or a Curve25519 keypair (`curve25519_keypair`). The resulting Vault secret will have a custom metadata `secret_type` with the type of the secret and a custom metadata `secret_length` with the same value as the `length` attribute. | |
| A cryptographic randomly generated secret stored as bytes in a Vault secret. A secret can be either an array of random bytes (`random_secret`) or a Curve25519 keypair (`curve25519_keypair`). The resulting Vault secret will have a custom metadata `secret_type` with the type of the secret and a custom metadata `secret_length` with the same value as the `length` attribute. |
| if err != nil { | ||
| return nil, nil, err | ||
| } | ||
| return privateKey.Bytes(), privateKey.Public().(*ecdh.PublicKey).Bytes(), nil |
There was a problem hiding this comment.
Suggested change
| return privateKey.Bytes(), privateKey.Public().(*ecdh.PublicKey).Bytes(), nil | |
| return privateKey.Bytes(), privateKey.PublicKey().Bytes(), nil |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Introduce a new
typefield to select what kind of secret to generate and support new typecurve25519_keypairto generate Curve25519 keypair