Skip to content
Gab
All work

Case study

SmartVault

SmartVault connects a physical vault to a mobile app and a backend service that handles secure access workflows, vault state, and real-time coordination between mobile, web, and hardware clients.

Category
IoT / Backend Engineering / Mobile
Team
Team project
Split view: the SmartVault mobile app's PIN unlock dialog with a lime Unlock button, next to the physical vault being opened with its keypad.
Demo capture

SmartVault is a prototype and is not presented as a certified security product.

Part 1

ContextThe problem and where I fit in.

01Problem

A connected vault has to coordinate a phone, a backend, and hardware in real time—while treating every unlock attempt as a security event.

02My role

  • Worked on the backend architecture and the integration between the mobile app, the API, and the vault hardware.

Team: Team project

Part 2

BuildWhat was made, and why it was made that way.

03Solution

A FastAPI service, refactored around Clean Architecture, owns access control and vault state. The mobile app talks to it over REST and WebSockets, so unlocks and state changes reach every connected client in real time.

04Features

  • PIN-based unlocking

    Implemented

    Hashed PIN validation with lockout after repeated failures.

  • Biometric authentication

    Implemented

    Face recognition integration alongside the PIN flow.

  • Real-time communication

    Implemented

    WebSocket channels keep the app, web, and hardware in sync.

  • Mobile app

    Implemented

    React Native app for unlocking and monitoring the vault.

  • Observability

    Implemented

    Metrics, structured logs with sensitive-field redaction, and health checks.

05Architecture

  1. API layer

    HTTP endpoints, WebSocket handlers, validation, dependency injection

    • FastAPI
  2. Application layer

    Use cases, services, and ports

    • Python
  3. Domain layer

    Users, vaults, access logs, PIN and status value objects

    • Pure Python
  4. Infrastructure

    Repositories, cache and rate limiting, biometrics, notifications

    • PostgreSQL
    • SQLAlchemy
    • Alembic
    • Redis
  5. Runtime

    Containerised services with metrics and error tracking

    • Docker Compose
    • Prometheus
    • Grafana
    • Sentry

Dependency rule: inner layers know nothing about outer layers. The domain has no infrastructure dependencies.

06Engineering decisions

  1. Clean Architecture refactor

    Separating domain rules from FastAPI, the database, and Redis made the security-critical logic testable in isolation with in-memory fakes.

  2. Security events are first-class

    PIN lockouts, authentication failures, and unlock operations are tracked explicitly, and logs redact PINs, passwords, and tokens.

  3. Real-time over polling

    WebSockets push vault state changes to clients instead of having each device poll the API.

Part 3

ResultsWhat came of it, honestly.

07Outcomes & limits

Outcomes

  • A working prototype: the mobile app unlocking the physical vault, backed by the API.

Limitations

  • A student project and prototype—not a certified or audited security product.
  • Illustration

    Applied AI / Full-Stack Development

    BentaBuddy

    Hackathon project · 2026

    A local-first AI business assistant that turns customer conversations into structured, owner-reviewed orders and bookings.

    • React
    • TypeScript
    • Vite
    • +5 more