190 Commits

Author SHA1 Message Date
Spring Operator
22596e9a7a URL Cleanup.
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* [ ] http://www.apache.org/licenses/ with 2 occurrences migrated to:
  https://www.apache.org/licenses/ ([https](https://www.apache.org/licenses/) result 200).
* [ ] http://www.apache.org/licenses/LICENSE-2.0 with 268 occurrences migrated to:
  https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200).
* [ ] http://www.apache.org/licenses/LICENSE-2.0.txt with 1 occurrences migrated to:
  https://www.apache.org/licenses/LICENSE-2.0.txt ([https](https://www.apache.org/licenses/LICENSE-2.0.txt) result 200).

Original pull request: #397.
2019-03-25 10:14:41 +02:00
Spring Operator
678a208b61 URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

Original pull request: gh-394.
2019-03-21 22:06:54 +02:00
Spring Operator
28838bf39e URL Cleanup (#391)
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* http://maven.apache.org/xsd/maven-4.0.0.xsd with 2 occurrences migrated to:
  https://maven.apache.org/xsd/maven-4.0.0.xsd ([https](https://maven.apache.org/xsd/maven-4.0.0.xsd) result 200).
* http://www.apache.org/licenses/LICENSE-2.0 with 6 occurrences migrated to:
  https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200).
* http://maven.apache.org/maven-v4_0_0.xsd with 2 occurrences migrated to:
  https://maven.apache.org/maven-v4_0_0.xsd ([https](https://maven.apache.org/maven-v4_0_0.xsd) result 301).
* http://repo.spring.io/libs-milestone-local with 1 occurrences migrated to:
  https://repo.spring.io/libs-milestone-local ([https](https://repo.spring.io/libs-milestone-local) result 302).

# Ignored
These URLs were intentionally ignored.

* http://maven.apache.org/POM/4.0.0 with 8 occurrences
* http://www.w3.org/2001/XMLSchema-instance with 4 occurrences

Original pull request: gh-391.
2019-03-18 08:13:02 +01:00
Mark Paluch
41141c35f5 [maven-release-plugin] prepare for next development iteration
See gh-330
2018-11-14 09:27:11 +01:00
Mark Paluch
d772003bbd [maven-release-plugin] prepare release 2.0.3.RELEASE
See gh-330
2018-11-14 09:27:01 +01:00
Mark Paluch
941da95a58 Fix secret rotation on expired leases.
Handling for expired leases now considers the appropriate exception type.

See gh-319 gh-321.
2018-11-09 08:06:39 +01:00
Nándor István Krácser
ce8ab7f83b Fix typo in KubernetesAuthenticationOptionsBuilder.
Original pull request: gh-317.
2018-10-05 10:44:09 +02:00
Mark Paluch
b179ceee7e [maven-release-plugin] prepare for next development iteration 2018-09-10 15:03:01 +02:00
Mark Paluch
77d821cfb5 [maven-release-plugin] prepare release 2.0.2.RELEASE 2018-09-10 15:03:01 +02:00
Mark Paluch
6d67f1f0bb Polishing.
Add missing assertions. Javadoc.

See gh-284.
2018-08-27 15:38:29 +02:00
Mark Paluch
a0451bb32c Pretty-print JSON for policy creation.
We now use pretty-printed (formatted) JSON for policy creation/updating to avoid templating character clashes between compact JSON formatting and Vault 0.11's policy templating feature.

Closes gh-288.
2018-08-25 22:46:23 +02:00
Mark Paluch
e9c7331519 Guard tests against unsupported Vault versions.
Closes gh-263.
2018-07-28 20:59:32 +02:00
Mark Paluch
5b11cb7bb4 Fix TTL format for PKI Certificate Requests.
We now send TTL validity as seconds instead of attempting to serialize a Duration object.

Closes gh-263.
2018-07-27 15:34:45 +02:00
Mark Paluch
3ded0020b0 Extend netty availability discovery.
We now check additionally for presence of io.netty.handler.ssl.SslContext and io.netty.handler.codec.http.HttpClientCodec classes to prevent netty usage by presence of partial API components.

Closes gh-249.
2018-04-24 18:26:58 +02:00
Mark Paluch
d5904fa7c0 Polishing.
Catch RuntimeException in LifecycleAwareSessionManager on revocation.

See gh-203.
2018-04-23 15:49:23 +02:00
Vincent Oberle
e618b25f28 Fix JSON serialization of VaultTokenRequest.noParent.
Fixes gh-243.
Original pull request: gh-244.
2018-04-19 10:28:13 +02:00
Mark Paluch
746958d187 Upgrade to Vault 0.10.0.
Closes gh-240.
2018-04-11 14:54:34 +02:00
Mark Paluch
3bfed52adc [maven-release-plugin] prepare for next development iteration
See gh-229.
2018-04-04 17:46:21 +02:00
Mark Paluch
c725dcff33 [maven-release-plugin] prepare release 2.0.1.RELEASE
See gh-229.
2018-04-04 17:45:39 +02:00
Mark Paluch
ffd2536509 Polishing.
Add author tags. Extract actual VaultDecryptionResult construction based on results in own method. Introduce Plaintext.empty() factory method. Guard Ciphertext.with(…) against null values.

See also gh-223.
Original pull request: gh-225.
2018-03-21 15:26:35 +01:00
Mikko Koli
8ebd492db6 Allow empty plaintext for transit decryption.
Fixes gh-223.
Original pull request: gh-225.
2018-03-21 15:26:35 +01:00
Mark Paluch
bef6576c00 Guard tests against versions that do not support empty plaintext.
See gh-223.
2018-03-20 15:57:48 +01:00
Mark Paluch
a6807c09c3 Allow empty plaintext for transit encryption.
We now allow construction and encryption of empty Plaintext objects. Empty plaintext can make sense from a security perspective.

Closes gh-223.
2018-03-20 13:03:31 +01:00
Mark Paluch
61c1657743 Rotate non-renewable leases.
We now support rotation of non-renewable leases in the sense that we expire the lease first and then obtain secrets from Vault again. Previously, non-renewable secrets were not rotated at all as rotation was tied to the renewal only and without renewal there was no rotation.

See gh-215.
2018-03-20 12:50:47 +01:00
Mark Paluch
60d9534c9c Drop VaultToken on infrastructure errors during renewal.
We now drop the VaultToken if an infrastructure error (connection refused/connection timeout/read timeout/…) occurs. Dropping the token prevents usage of an expired token.

Closes gh-222.
2018-03-20 11:45:23 +01:00
Mark Paluch
7d6a5c0d0c Do not prepend slash to URIs with a scheme.
See gh-206.
2018-03-05 16:10:03 +01:00
Michael Bell
b72ed92729 Fix Javadoc example code in SecretLeaseContainer.
Original pull request: gh-209.
Closes gh-207.
2018-03-05 08:57:23 +01:00
Mark Paluch
aeb3f65a4c Annotate functional interfaces with FunctionalInterface.
Closes gh-204.
2018-02-28 14:52:12 +01:00
Mark Paluch
30a2e13b6a Polishing.
See gh-202.
2018-02-28 14:37:18 +01:00
Mark Paluch
bc5dec4d88 Return null on absent Policy via VaultSysTemplate.getPolicy(…).
We now return null if a policy was not found. Previously, a VaultException was thrown.

Closes gh-202.
2018-02-28 14:36:17 +01:00
Mark Paluch
d2c83b818f Prepare for next development iteration.
See gh-198.
2018-02-20 10:01:13 +01:00
Mark Paluch
4b1061d153 [maven-release-plugin] prepare release 2.0.0.RELEASE
See gh-198.
2018-02-20 09:43:14 +01:00
Mark Paluch
c3b2aee11d Add unit test for VaultPropertySource with profiles.
See gh-193.
2018-02-09 11:56:41 +01:00
Mark Paluch
78197da7ad Rename AwsIamAuthenticationOptions#serverName to serverId.
Align naming with Vault's serverId that sets Vault-AWS-IAM-Server-ID headers on AWS requests for consistency. serverName builder/getter is deprecated now.

Closes gh-191.
2018-02-06 11:10:35 +01:00
Mark Paluch
8f19127584 [maven-release-plugin] prepare for next development iteration 2018-01-25 09:48:54 +01:00
Mark Paluch
a94cbc15ae [maven-release-plugin] prepare release 2.0.0.RC2 2018-01-25 09:48:53 +01:00
Mark Paluch
11a346ef2b Polishing.
Adjust generics and wording in reactive Template API.
2018-01-25 09:44:34 +01:00
Mark Paluch
35b5797c63 Polishing.
See gh-187
2018-01-23 10:49:11 +01:00
Mark Paluch
9ed2196068 Polishing.
See gh-187
2018-01-22 19:29:09 +01:00
Mark Paluch
28ff17d4f8 Add VaultBytesEncryptor and VaultBytesKeyGenerator.
We now provide a Spring Security integration for Vault transit-based BytesEncryptor and BytesKeyGenerator.

VaultOperations operations = …;
VaultBytesKeyGenerator generator = new VaultBytesKeyGenerator(operations);

byte[] key = generator.generateKey();

VaultTransitOperations transit = …;
VaultBytesEncryptor encryptor = new VaultBytesEncryptor(transit, "my-key-name");

byte[] ciphertext = encryptor.encrypt(plaintext);
byte[] decrypted = encryptor.decrypt(ciphertext);

Closes gh-187.
2018-01-22 12:11:05 +01:00
Mark Paluch
3e6fbe7581 Polishing.
Remove PropertyTransformerSupport in favor of default method in PropertyTransformer and refactor PropertyTransformer to functional interface.

See gh-169.
2018-01-17 15:36:30 +01:00
Mark Paluch
f4d05a4fb6 Retain JSON data type in PropertySource.
We now retain the JSON data type in the property source. This change requires property transformers to accept/produce a Map of String to Object whereas it was String to String before.

See gh-169.
2018-01-17 13:06:08 +01:00
Mark Paluch
747a270604 Introduce reactive SessionManager.
We now provide a reactive, lifecycle-aware SessionManager using WebClient. ReactiveSessionManager is mirroring imperative SessionManager functionality. Using AbstractReactiveVaultConfiguration will register an adapter between ReactiveSessionManager and SessionManager to reuse the same token for reactive and imperative API use.

Closes gh-159.
2018-01-17 12:44:09 +01:00
Mark Paluch
b757ff04dc Polishing.
Introduce convenience factory method to convert a VaultToken into LoginToken.

See gh-159.
2018-01-17 12:44:09 +01:00
Mark Paluch
0710ae838a Extract common base class for LifecycleAwareSessionManager.
See gh-159.
2018-01-17 12:44:09 +01:00
Mark Paluch
ca874a6a31 Polishing.
Update license copyright years to 2018.
2018-01-16 14:35:51 +01:00
Mark Paluch
eacfcbfd5b Support Vault HA with redirects.
Fixes gh-184.
2018-01-16 14:34:49 +01:00
Mark Paluch
7244973bef Make RoleId and SecretId public.
AppRoleAuthenticationOptions.RoleId and AppRoleAuthenticationOptions.SecretId interfaces are now public.

Closes gh-179.
2017-11-23 12:07:44 +01:00
Mark Paluch
db195be8d8 Polishing.
Improve Javadoc.

See gh-177.
2017-11-16 12:19:55 +01:00
Mark Paluch
08063cc940 Return VaultResponse in ReactiveVaultOperations.write(…).
We now return the actual response when writing to a Vault path.

Closes gh-177.
2017-11-16 12:14:52 +01:00