adrobisch / tresor

Scala lib for secrets

Version Matrix

tresor 🔒 [tʁeˈzoːɐ̯]

travis latest release codecov

A Scala library to access secrets (credentials etc.) from different sources.


import com.drobisch.tresor._
import com.drobisch.tresor.vault._

val vaultConfig = VaultConfig(apiUrl = "http://vault-host:8200/v1", token = "vault-token")

KV[cats.effect.IO].secret(KeyValueContext(key = "treasure", vaultConfig)) // IO[vault.Lease]


  • Provider for AES-256 encryption
  • Providers for secrets from Hashicorp Vault engines (currently KV, Database, AWS)
  • Integration with cats-effect
  • Supports Scala 2.11, 2.12


Apache License 2.0