How to use Vault with Spring applications
Oct 08, 2018
See Vault in action with Spring Boot and Spring Cloud by watching this detailed demo from the Spring I/O conference.
At a recent talk for the Spring I/O conference in Barcelona, Jan Dittberner, a software architect at the IT services firm T-Systems, walked through his process for securing Spring Boot applications with Vault. This talk is 90% demo time, covering:
- Vault token and AppRole authentication in Spring Boot
- Dynamic X.509 (TLS) certificates from Vault PKI
- Dynamic database credentials from Vault's database engine with PostgreSQL
The demo is a great intro to Vault's secret management capabilities for anyone who's working in a Spring-based Java environment. Vault has excellent integration with Spring Cloud as well, so there's no tricky setup if that's a part of your environment.
There is also some demo time on how to use the generic secrets backend for other application credentials.
Demo code on GitHub: https://github.com/jandd/spring-boot-vault-demo
There are also several good resources from the Spring open source community for setting up the Spring Cloud Vault integration: