Commit Graph

218 Commits

Author SHA1 Message Date
Mark Paluch
1cd03dd39e Introduce AutoConfiguration classes for Vault 2020-09-18 15:53:50 +02:00
Mark Paluch
c71bb083e6 Extract bean instance creation into VaultConfiguration and VaultReactiveAutoConfiguration 2020-09-18 15:53:32 +02:00
Mark Paluch
b86510a852 Remove Bootstrap context marker class from classpath 2020-09-17 16:21:57 +02:00
Mark Paluch
f0e2b64ec3 Introduce AutoConfiguration variants 2020-09-17 16:21:42 +02:00
Mark Paluch
73e978a946 Add Vault implementation for ConfigDataResolver and ConfigDataLoader
Discover SecretBackendMetadataFactory and VaultSecretBackendDescriptor using spring.factories. Add instance suppliers for all imperative support classes.
2020-09-17 16:21:16 +02:00
Mark Paluch
43990382c4 Expose RestTemplateFactory and WebClientFactory
We're now exposing vaulRestTemplateFactory and vaultWebClientFactory that allow construction of RestTemplate respective WebClient with Spring Vault's customizations applied.

Closes gh-401.
2020-09-17 12:06:50 +02:00
Mark Paluch
477e8b9bb9 Polishing
Reformat code using new formatter Settings.

See gh-482.
2020-09-17 11:28:42 +02:00
Mark Paluch
82e845fff0 Upgrade to Spring Vault 2.3.0 M1
Closes gh-482.
2020-09-17 11:28:06 +02:00
Mark Paluch
2e4bf3d0cd Introduce configuration properties for session lifecycle management
We now provide configuration properties to configure session token renewal, especially renewal and expiry thresholds.

spring.cloud.vault:
    session.lifecycle:
        enabled: true
        refresh-before-expiry: 10s
        expiry-threshold: 20s

Closes gh-400.
2020-08-11 17:07:37 +02:00
dependabot-preview[bot]
c799e4d2d6 Bump aws-java-sdk-core from 1.11.627 to 1.11.838
Bumps [aws-java-sdk-core](https://github.com/aws/aws-sdk-java) from 1.11.627 to 1.11.838.
- [Release notes](https://github.com/aws/aws-sdk-java/releases)
- [Changelog](https://github.com/aws/aws-sdk-java/blob/master/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-java/compare/1.11.627...1.11.838)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>

See gh-434.
2020-08-11 12:21:55 +02:00
spencergibb
895df4456a Uses new spring-cloud-starter-bootstrap.
This allows opt-in to bootstrap via classpath rather than properties.
2020-08-10 15:42:24 -04:00
buildmaster
d1ecef4af1 Going back to snapshots 2020-07-23 19:32:34 +00:00
buildmaster
b8a7610805 Update SNAPSHOT to 3.0.0-M3 2020-07-23 19:30:44 +00:00
spencergibb
ef59dcdb91 Adds junit-vintage-engine as a test dependency 2020-06-08 12:57:21 -04:00
buildmaster
89dd6abde4 Going back to snapshots 2020-05-29 19:31:33 +00:00
buildmaster
627411fb42 Update SNAPSHOT to 3.0.0-M2 2020-05-29 19:30:29 +00:00
Mark Paluch
68d9f7bc58 Introduce profile override for Key Value backend.
We now provide an override spring.cloud.vault.kv.profiles=… to specify application profiles that should be used for Vault access instead of Environment.getActiveProfiles().

Closes gh-385.
2020-05-20 15:26:43 +02:00
Mark Paluch
0f7b9ec7fc Remove spring.cloud.vault.generic configuration properties.
Spring Cloud Vault uses now a single mechanism for key-value backend configuration. Properties at spring.cloud.vault.generic.* are no longer supported.

All associated functionality is now solely available by configuring the corresponding spring.cloud.vault.kv.* properties. The support classes GenericSecretBackendMetadata and VaultGenericBackendProperties were removed in favor of KeyValueSecretBackendMetadata respective VaultKeyValueBackendProperties. spring.cloud.vault.kv.enabled is now enabled by default to preserve spring.cloud.vault.generic.enabled behavior.

Closes gh-395
2020-05-20 10:57:33 +02:00
buildmaster
180ebc4369 Bumping versions 2020-04-17 12:00:10 +00:00
buildmaster
2b897f3128 Going back to snapshots 2020-04-09 23:56:16 +00:00
buildmaster
baa0681ef9 Update SNAPSHOT to 3.0.0.M1 2020-04-09 23:55:07 +00:00
Mark Paluch
28f4399076 Deprecate spring.cloud.vault.generic in favor of spring.cloud.vault.kv
Deprecating properties that used the previous kv backend name "generic" so these can be removed with the next major release.

Closes gh-394.
2020-04-02 15:08:52 +02:00
Mark Paluch
7b45968938 Add integration test for VaultReactiveHealthIndicator
Add test for the reactive health indicator.

See gh-397
2020-04-02 14:34:35 +02:00
Mark Paluch
3d0672e159 Polishing
Add this for field dereference. Tweak renewal timing for shorter test runtime. Move lifecycle configuration into SecretLeaseContainer bean method.

Closes gh-393.
2020-03-20 14:23:29 +01:00
Mark Paluch
6ea30433f2 Request rotating tokens for Consul
Extend LeasingSecretBackendMetadata with callback methods before/after registration to add secret rotation listeners for config properties rebinding.

Refactor Consul configuration to use LeasingSecretBackendMetadata and rebind Consul ConfigurationProperties accordingly.

See gh-393
2020-03-20 14:22:53 +01:00
Mark Paluch
c4590c5250 Bypass Vault namespace for healthchecks
Apparently sys/init and sys/health are not available from within a namespace.

Closes gh-386.
2020-02-13 09:26:04 +01:00
Mark Paluch
6a6831c594 Adapt tests to bean overriding rules 2020-02-03 08:54:52 +01:00
Mark Paluch
b4793f0d1c Pass-thru VaultToken obtained from ReactiveSessionManager
We now pass-thru the token obtained from ReactiveSessionManager instead of caching it.
Previously, we used a method reference and the method reference cached the SessionToken Mono instead of requesting a fresh token each time from the session manager.

Closes gh-382.
2020-01-24 15:17:05 +01:00
Spencer Gibb
d3ab6c918c Bumps to 3.0.0 for ilford 2020-01-22 15:41:36 -05:00
Mark Paluch
0c45446882 Polishing
Use SpringRunner instead of SpringJUnit4ClassRunner.
2020-01-16 09:35:04 +01:00
Mark Paluch
49aee4cf51 Allow disabling authentication for Vault Agent use
We now allow disabling Spring Vault's ClientAuthentication and SessionManagement features to rely on authenticated requests sent by Vault Agent. The authentication infrastructure can be disabled via:

spring.cloud.vault:
    authentication: NONE

Closes gh-356.
2020-01-13 12:08:15 +01:00
Mark Paluch
4118d4a076 Update license headers to 2020
Closes gh-376.
2020-01-10 15:15:25 +01:00
buildmaster
9a1ddef9d2 Bumping versions to 2.2.2.BUILD-SNAPSHOT after release 2019-12-20 14:45:08 +00:00
buildmaster
1f07408fc3 Going back to snapshots 2019-12-20 14:45:08 +00:00
buildmaster
e1a32c057f Update SNAPSHOT to 2.2.1.RELEASE 2019-12-20 14:42:04 +00:00
Mark Paluch
ad986edba8 Fix versioned key-value access with disabled lifecycle support
Versioned key-value secrets are now loaded properly when lifecycle support is disabled.

We're using our own mechanism to read secrets instead of using Spring Vault's property source so we need to inspect whether the mount is a key-value v1 or v2 one to load its value properly.

Closes gh-372.
2019-12-02 09:54:53 +01:00
buildmaster
c0cc4535b2 Bumping versions to 2.2.1.BUILD-SNAPSHOT after release 2019-11-26 12:19:00 +00:00
buildmaster
75faff1e3a Going back to snapshots 2019-11-26 12:19:00 +00:00
buildmaster
78b478ed91 Update SNAPSHOT to 2.2.0.RELEASE 2019-11-26 12:17:10 +00:00
Mark Paluch
fbb36e29b8 Polishing 2019-11-14 15:58:19 +01:00
buildmaster
eefe187fae Going back to snapshots 2019-11-10 00:52:41 +00:00
buildmaster
3da9dfe0e2 Update SNAPSHOT to 2.2.0.RC2 2019-11-10 00:51:39 +00:00
buildmaster
7a5b0e0e80 Bumping versions 2019-11-07 16:44:25 +00:00
Mark Paluch
c66d5e6fed Consider performance standby mode in health check.
Extract common code to HealthBuilderDelegate.

Closes gh-367.
2019-11-06 11:28:52 +01:00
buildmaster
5ef5e6f0d2 Going back to snapshots 2019-10-24 21:45:57 +00:00
buildmaster
c22d0bd189 Update SNAPSHOT to 2.2.0.RC1 2019-10-24 21:45:14 +00:00
Mark Paluch
96994e5a6d Move off deprecated HealthIndicator API in favor of HealthContributor API.
Closes gh-361.
2019-10-21 10:35:06 +02:00
Mark Paluch
8af88cca87 Reduce need for bean method proxying and disable where not needed.
Closes gh-360.
2019-10-21 10:21:44 +02:00
buildmaster
6b6d110b84 Going back to snapshots 2019-10-03 21:46:49 +00:00
buildmaster
b22cee52cc Update SNAPSHOT to 2.2.0.M3 2019-10-03 21:46:05 +00:00