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

Remove unnecessary return statements on lambdas and encapsulate public fields with fluent accessors #179

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions docs/modules/ROOT/pages/includes/quarkus-vault.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -260,13 +260,13 @@ Renew grace period duration.
<p>
This value if used to extend a lease before it expires its ttl, or recreate a new lease before the current
lease reaches its max_ttl.
By default Vault leaseDuration is equal to 7 days (ie: 168h or 604800s).
By default, Vault leaseDuration is equal to 7 days (ie: 168h or 604800s).
If a connection pool maxLifetime is set, it is reasonable to set the renewGracePeriod to be greater
than the maxLifetime, so that we are sure we get a chance to renew leases before we reach the ttl.
In any case you need to make sure there will be attempts to fetch secrets within the renewGracePeriod,
because that is when the renewals will happen. This is particularly important for db dynamic secrets
because if the lease reaches its ttl or max_ttl, the password of the db user will become invalid and
it will be not longer possible to log in.
it will be no longer possible to log in.
This value should also be smaller than the ttl, otherwise that would mean that we would try to recreate
leases all the time.

Expand Down Expand Up @@ -384,7 +384,7 @@ a| [[quarkus-vault_quarkus.vault.kv-secret-engine-version]]`link:#quarkus-vault_
--
Kv secret engine version.
<p>
see https://www.vaultproject.io/docs/secrets/kv/index.html
see <a href="https://www.vaultproject.io/docs/secrets/kv/index.html">KV secrets engine</a>

ifdef::add-copy-button-to-env-var[]
Environment variable: env_var_with_copy_button:+++QUARKUS_VAULT_KV_SECRET_ENGINE_VERSION+++[]
Expand Down Expand Up @@ -420,7 +420,7 @@ The secret properties would be fetched from Vault using a `GET` on
`https://localhost:8200/v1/secret/data/config/myapp` for a KV secret engine v2 (or
`https://localhost:8200/v1/secret/config/myapp` for a KV secret engine v1).
<p>
see https://www.vaultproject.io/docs/secrets/kv/index.html
see <a href="https://www.vaultproject.io/docs/secrets/kv/index.html">KV secrets engine</a>

ifdef::add-copy-button-to-env-var[]
Environment variable: env_var_with_copy_button:+++QUARKUS_VAULT_KV_SECRET_ENGINE_MOUNT_PATH+++[]
Expand Down Expand Up @@ -670,7 +670,7 @@ Vault Enterprise namespace
<p>
If set, this will add a `X-Vault-Namespace` header to all requests sent to the Vault server.
<p>
See https://www.vaultproject.io/docs/enterprise/namespaces
See <a href="https://www.vaultproject.io/docs/enterprise/namespaces">Vault Enterprise namespaces</a>

ifdef::add-copy-button-to-env-var[]
Environment variable: env_var_with_copy_button:+++QUARKUS_VAULT_ENTERPRISE_NAMESPACE+++[]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -307,24 +307,24 @@ public void testSignIntermediateCAOptions() throws Exception {

// Sign the intermediate CA using "pki"
SignIntermediateCAOptions options = new SignIntermediateCAOptions();
options.subjectCommonName = "test.example.com";
options.subjectOrganization = "Test Org";
options.subjectOrganizationalUnit = "Test Unit";
options.subjectStreetAddress = "123 Main Street";
options.subjectLocality = "New York";
options.subjectProvince = "NY";
options.subjectCountry = "USA";
options.subjectPostalCode = "10030";
options.subjectSerialNumber = "9876543210";
options.subjectAlternativeNames = singletonList("alt.example.com");
options.ipSubjectAlternativeNames = singletonList("1.2.3.4");
options.uriSubjectAlternativeNames = singletonList("ex:12345");
//options.otherSubjectAlternativeNames = singletonList("1.3.6.1.4.1.311.20.2.3;UTF8:test");
options.excludeCommonNameFromSubjectAlternativeNames = true;
options.timeToLive = "8760h";
options.maxPathLength = 3;
options.permittedDnsDomains = asList("subs1.example.com", "subs2.example.com");
options.useCSRValues = false;
options.subjectCommonName("test.example.com");
options.subjectOrganization("Test Org");
options.subjectOrganizationalUnit("Test Unit");
options.subjectStreetAddress("123 Main Street");
options.subjectLocality("New York");
options.subjectProvince("NY");
options.subjectCountry("USA");
options.subjectPostalCode("10030");
options.subjectSerialNumber("9876543210");
options.subjectAlternativeNames(singletonList("alt.example.com"));
options.ipSubjectAlternativeNames(singletonList("1.2.3.4"));
options.uriSubjectAlternativeNames(singletonList("ex:12345"));
//options.otherSubjectAlternativeNames(singletonList("1.3.6.1.4.1.311.20.2.3;UTF8:test"));
options.excludeCommonNameFromSubjectAlternativeNames(true);
options.timeToLive("8760h");
options.maxPathLength(3);
options.permittedDnsDomains(asList("subs1.example.com", "subs2.example.com"));
options.useCSRValues(false);

SignedCertificate result = pkiSecretEngine.signIntermediateCA((String) csrResult.csr.getData(), options);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,9 @@ public VaultTuneInfo getTuneInfo(String mount) {
* Get the info for a secret engine, including its type.
*
* @since Vault 1.10.0
* @see https://www.vaultproject.io/api-docs/system/mounts#get-the-configuration-of-a-secret-engine
* @see <a href="https://www.vaultproject.io/api-docs/system/mounts#get-the-configuration-of-a-secret-engine">
* Get the configuration of a secret engine
* </a>
*
* @param mount Name of the secret engine
* @return current secret engine info
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,9 @@ public interface VaultSystemBackendReactiveEngine {
* Get the info for a secret engine, including its type.
*
* @since Vault 1.10.0
* @see https://www.vaultproject.io/api-docs/system/mounts#get-the-configuration-of-a-secret-engine
* @see <a href="https://www.vaultproject.io/api-docs/system/mounts#get-the-configuration-of-a-secret-engine">
* Get the configuration of a secret engine
* </a>
*
* @param mount Name of the secret engine
* @return current secret engine info
Expand Down
Loading