Format-Preserving Encryption for Spring Boot
Auto-configured Spring Boot starter for Cyphera. Add the dependency, drop in a configuration file, and inject CypheraClient anywhere in your application.
What It Does
The Cyphera Spring Boot Starter brings data protection to any Spring Boot application with zero boilerplate. Add the Maven dependency, place a cyphera.json configuration file on your classpath, and Spring auto-configures a CypheraClient bean you can inject anywhere. Protect and access sensitive fields with a single method call. Data Protection Headers (DPH) are embedded in the protected output so access needs no configuration name.
Quick Example
Maven dependency
<dependency> <groupId>io.cyphera</groupId> <artifactId>cyphera-spring-boot-starter</artifactId> <version>VERSION</version> </dependency>
Usage in Java
@Autowired private CypheraClient cyphera; public void example() { String protectedValue = cyphera.protect("ssn", "123-45-6789"); // → "T01i6J-xF-07pX" (DPH-formatted, protected data) String accessed = cyphera.access(protectedValue); // → "123-45-6789" }
How It Works
The starter auto-configures based on a cyphera.json configuration file. Configurations map field names to encryption engines, alphabets, and key references. The CypheraClient provides:
protect(configuration, value)— protect using a named configurationaccess(protectedValue)— access using header-based configuration lookupsdk()— access the underlying Cyphera SDK instance
Configuration lives in application.yml with support for classpath-based configuration files and (in the future) remote configuration servers.