diff --git a/docs/src/main/asciidoc/spring-cloud-vault.adoc b/docs/src/main/asciidoc/spring-cloud-vault.adoc index ebfa73ef..00086f9e 100644 --- a/docs/src/main/asciidoc/spring-cloud-vault.adoc +++ b/docs/src/main/asciidoc/spring-cloud-vault.adoc @@ -241,17 +241,6 @@ further investigation. The nonce is kept in memory and is lost during application restart. -.bootstrap.yml with disabled nonce -==== -[source,yaml] ----- -spring.cloud.vault: - authentication: AWS_EC2 - aws-ec2: - use-nonce: false ----- -==== - AWS-EC2 authentication roles are optional and default to the AMI. You can configure the authentication role by setting the `spring.cloud.vault.aws-ec2.role` property. @@ -277,7 +266,6 @@ spring.cloud.vault: role: application-server aws-ec2-path: aws-ec2 identity-document: http://... - use-nonce: false ---- ==== @@ -286,7 +274,6 @@ authentication method * `role` sets the role name of the AWS EC2 role definition * `aws-ec2-path` sets the path of the AWS EC2 mount to use * `identity-document` sets URL of the PKCS#7 AWS EC2 identity document -* `use-nonce` setting this value to `false` will disable nonce usage See also: https://www.vaultproject.io/docs/auth/aws-ec2.html[Vault Documentation: Using the aws-ec2 auth backend] diff --git a/spring-cloud-vault-config/src/main/java/org/springframework/cloud/vault/config/VaultProperties.java b/spring-cloud-vault-config/src/main/java/org/springframework/cloud/vault/config/VaultProperties.java index f7018409..050e4078 100644 --- a/spring-cloud-vault-config/src/main/java/org/springframework/cloud/vault/config/VaultProperties.java +++ b/spring-cloud-vault-config/src/main/java/org/springframework/cloud/vault/config/VaultProperties.java @@ -13,15 +13,16 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - package org.springframework.cloud.vault.config; import lombok.Data; +import lombok.Getter; import org.hibernate.validator.constraints.NotEmpty; import org.hibernate.validator.constraints.Range; import org.springframework.boot.bind.RelaxedPropertyResolver; import org.springframework.boot.context.properties.ConfigurationProperties; +import org.springframework.boot.context.properties.DeprecatedConfigurationProperty; import org.springframework.context.EnvironmentAware; import org.springframework.core.env.Environment; import org.springframework.core.io.Resource; @@ -184,7 +185,11 @@ public class VaultProperties implements EnvironmentAware { /** * Flag whether to generate and send a nonce. + * + * @deprecated not used, will be removed in a future version. */ + @Getter(onMethod = @__(@DeprecatedConfigurationProperty(reason = "not used"))) + @Deprecated private boolean useNonce = true; }