All case studies

Hospitality & Payments (Choice Hotels)

PCI Tokenization Proxy & Okta Auth Migration

Migrated legacy PCI tokenization systems into a highly available Spring Boot microservice using the proxy pattern and Okta JWT authentication.

Role
Senior Java Backend Developer
Period
Jun 2022 — Mar 2026
Impact
Isolated PCI compliance scope while maintaining high availability across thousands of US hotels.
Stack
  • Java 11
  • Spring Boot
  • Okta / JWT
  • AWS EC2
  • Microservices
How a request moves through the proxy
How a request moves through the proxy. 1. Client to Tokenization proxy: Sends the card and its credentials. 2. Tokenization proxy to Okta: Authenticates the caller. 3. Okta to Tokenization proxy: Issues an access token. 4. Tokenization proxy to Tokenization v1: Asks for a token. 5. Tokenization v1 to Vault provider: Exchanges the card for a token. 6. Tokenization v1 to Tokenization proxy: Returns the token. 7. Tokenization proxy to Client: Returns the token only, never the card.How a request moves through the proxy. 1. Client to Tokenization proxy: Sends the card and its credentials. 2. Tokenization proxy to Okta: Authenticates the caller. 3. Okta to Tokenization proxy: Issues an access token. 4. Tokenization proxy to Tokenization v1: Asks for a token. 5. Tokenization v1 to Vault provider: Exchanges the card for a token. 6. Tokenization v1 to Tokenization proxy: Returns the token. 7. Tokenization proxy to Client: Returns the token only, never the card.

Problem

Card data at a hotel chain passes through many systems, and every system that touched it fell inside PCI compliance scope. Audits were costly and every payment-adjacent change was slow.

The legacy tokenization provider was also expensive and came with many restrictions, and access to it relied on a legacy authentication mechanism, so it was hard to say, and to prove, who could tokenize a card.

The goal was one small, highly available place where only authenticated clients can exchange a card for a token, without interrupting bookings.

System Architecture

A Spring Boot microservice acts as a proxy in front of the existing tokenization service. Every call passes through it, so it controls the whole flow: who may call, what is sent on and what comes back. The flow above is a simplified illustration of that shape.

  • Authenticate first. Okta-issued JWTs mean only authenticated clients can tokenize a card. Access tokens are cached and checked locally, so Okta is not in the path of every request.
  • Validate, then forward. The proxy checks and maps each request before it reaches the tokenization service, and returns only the token, never the card.
  • Gradual cut-over. Consumers moved over one at a time instead of in one big switch.

Trade-offs

  • One extra hop on payment-adjacent calls, in exchange for a single, small, auditable PCI boundary.
  • A critical shared dependency, so it had to be built for high availability from day one.
  • Cached tokens trade freshness for speed. Checking tokens locally keeps Okta off the hot path, but a revoked token keeps working until it expires.
  • Standard identity over custom auth: an external dependency, but no bespoke credential handling.

Measurable Impact

  • PCI compliance scope was isolated to the tokenization service and its proxy boundary.
  • Only authenticated clients can tokenize a card, and access is explicit and auditable per client.
  • High availability was maintained across thousands of US hotels throughout the migration.

Working on a similar system?

Tell me about the constraints and I'll reply with how I'd approach it.