115 Commits

Author SHA1 Message Date
9caeac4cba Support secret_id_bound_cidrs replacing bound_cidr_list for AppRole (#24)
The latter parameter is deprecated in Vault. The connector now supports
both while the former one is deprecated and will be removed when it is
removed from Vault.
2018-11-19 15:21:19 +01:00
c1ec929147 Re-build test data using Vault 0.11
In preparations for 1.0 compatibility and some later features the test
data generated with 0.5 becomes more of a problem without intermediate
updates, so it is now rebuilt from scratch.

As part of this change the unseal key is now split in 3 parts with a
threshold of 2 instead of the former 1/1,
2018-11-19 15:00:23 +01:00
96fd377db2 Moved Vault version to test into environment variable 2018-11-14 18:00:25 +01:00
46cb33fd7d Test against 0.11.5 2018-11-14 17:47:32 +01:00
b6d36fbc5c Test against 0.11.4 2018-10-24 09:22:25 +02:00
c869a640a9 Test against 0.11.3 2018-10-10 14:17:38 +02:00
874341ddf7 Removed abstract methods defined in builder interface from factory 2018-10-06 14:28:58 +02:00
c111a6aff0 Enforce TLS 1.2 by default with option to override (#22)
The TLS version can be explicitly set in builder or constructor. If not
given, the connector will only use 1.2 as Vault does by default, too.
2018-10-06 14:24:06 +02:00
13793dc9ce Add replication flags to HealthResponse (closes #21) 2018-10-06 10:58:43 +02:00
44858edb76 Add missing flags to SealResponse (closes #20) 2018-10-05 20:31:59 +02:00
8287be48b9 Merge branch 'master' into develop 2018-10-05 19:41:36 +02:00
51d118786a Test against 0.11.2 2018-10-05 19:37:37 +02:00
6b1211d90f Modified test mocks for compatibility with JDK 10 build environments 2018-09-09 14:39:52 +02:00
ee9a6530d3 Test against 0.11.1 2018-09-09 14:01:31 +02:00
3db73a913a Test against 0.11.0 2018-08-29 11:45:37 +02:00
ce9cd9bbf1 Test against 0.10.4 2018-07-26 20:10:06 +02:00
9e50190c02 Test against 0.10.3 2018-06-22 20:26:42 +02:00
4dea8a1c5f Test against 0.10.2 2018-06-10 20:37:26 +02:00
47e7a3f4b0 Test against 0.10.1 2018-04-26 20:44:52 +02:00
a5a708895e Test against 0.10.0 2018-04-19 20:24:49 +02:00
bc1223e1a3 Test against 0.10.0 2018-04-10 18:21:52 +02:00
4d46f2c6d1 Modified test mocks for compatibility with JDK 10 build environments 2018-03-28 17:39:30 +02:00
d2aaea1938 Clean up after migration to Builder
* Corrected implementation of Builder interface instead of the abstract Factory class

* Removed withSslContext() which is already deprecated in the factory
2018-03-25 17:45:59 +02:00
065f662b95 Add package-info and overview.html for more Javadoc output 2018-03-25 14:57:07 +02:00
23fbc7a6d3 Replaced VaultConnectorFactory with VaultConnectorBuilder
The class is more a builder than a factory, so is has been renamed.
The factory delegates to the builder for now to ease migration, but will
be removed with the next major release.
2018-03-24 13:59:22 +01:00
1a18f9f6b7 Refactored custom trusted CA strategy
The connector no longer stores the final SSLContext, but the trusted
X509Certificate object and creates a SSLSocketFactory as required.
2018-03-24 13:43:27 +01:00
0c23f47bd5 Test against 0.9.6 2018-03-21 11:48:27 +01:00
27e7a2dffc Test against 0.9.5 2018-02-27 18:07:23 +01:00
41c15f285c Test against 0.9.4 2018-02-24 10:58:45 +01:00
9362e245ee Minor test changes
Changed Thread.sleep() to TimeUnit.SECONDS.sleep()
2018-02-20 19:25:07 +01:00
b2082925d5 Copy Vault data directory to temp location before each test
To avoid the annoying clean before each test run (because Vault data has
been modified by previous run), the data is now copied from resource
directory to temporary location.
2018-02-04 20:04:47 +01:00
23cea38da6 Test against 0.9.3 2018-01-29 16:30:51 +01:00
bf2da210ba Test against 0.9.2 2018-01-28 10:35:19 +01:00
91fb012acc Update copyright notice to 2018 2018-01-01 17:22:02 +01:00
61e1f3f745 Test against 0.9.1 2017-12-22 16:40:15 +01:00
50cd400ba3 Migrated tests to JUnit5 and removed PowerMock
* Unit tests are using JUnit Jupiter framework
 * Enabled support for legacy rules for now
 * Replaced PowerMock with custom ByteBuddy redefinition for the offline test
2017-11-26 18:17:13 +01:00
470dcb48ba Test framework migrated to Mockito/Powermock 2
This simple migration with the bare minimum of changes necessary solves
compatibility issues with Java 9 build environments.
2017-11-25 18:43:25 +01:00
736f23c19a Tested against 0.9.0 2017-11-16 20:34:52 +01:00
007b523295 Extracted nested try-blocks from response handling into new methods. 2017-10-03 17:29:11 +02:00
061c1e9743 Minor CleanUp
Reworked some JavaDoc comments and optimized imports.
2017-10-03 17:12:03 +02:00
6904ed6817 Added tests for parse exceptions. 2017-09-27 20:23:14 +02:00
1ed5d8d992 Added tests for unexpected 200 responses.
Some methods do expect code 204 (successful without result), those are now covered by tested.
2017-09-27 20:07:12 +02:00
f70fc084be Override toString() on ErrorResponse
Partially reverts last commit that added first error message to exception
without checking for presence of such.
2017-09-25 20:48:36 +02:00
4b14ab3f4b Offline tests with mocked Vault server
Added some tests that do not require an actual Vault server to test constructors and exceptional behavior.
2017-09-25 20:39:13 +02:00
29776f459e Fixed Exception class on invalid response during sealStatus() 2017-09-25 20:35:37 +02:00
4ca8aa56d2 Test constructors and exceptions on sealStatus 2017-09-24 13:23:13 +02:00
e002fc749a Adaptation to Vault 0.8 endpoints for renew and revoke leases (#11)
Breaking backwards compatibility with Vault 0.7 and below.
2017-09-24 11:08:00 +02:00
b9ad2d1551 Test against 0.8.3
Minor test adaptation, because default policy is no longer added to AppRole by default.
2017-09-23 14:46:41 +02:00
35a8c2e0fa Test constants made constant 2017-09-09 20:32:56 +02:00
89f7581d17 Test against 0.8.2 2017-09-08 19:21:41 +02:00