From 56d8123f441a81cef6a475ddba0ea686a8113c3f Mon Sep 17 00:00:00 2001 From: nfel Date: Sun, 30 Aug 2026 14:58:32 +0330 Subject: [PATCH] docs: record OTP template parsing checkpoint --- REFACTORING-AUDIT.md | 1 + REFACTORING-TODO.md | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/REFACTORING-AUDIT.md b/REFACTORING-AUDIT.md index 2ba48eb..c795483 100644 --- a/REFACTORING-AUDIT.md +++ b/REFACTORING-AUDIT.md @@ -283,6 +283,7 @@ The current composition root is `cmd/serve.go`; `repository.System` aggregates P ### `A004` — OTP application checkpoint - Extracted OTP code generation and the default expiration into the transport-independent `application/otp` package while preserving the existing disabled-code and six-digit behavior; focused and full Auth tests pass in `0c92b14`. +- Extracted OTP template parameter decoding into the same application package and kept persistence JSON types at the infrastructure boundary; full Auth tests pass in `62fb1b1`. - A004 remains in progress: template lookup, delivery, verification, and thin gRPC adapter extraction still use the legacy use-case/repository composition. ### `I001` — publisher-backed ICO purchase map diff --git a/REFACTORING-TODO.md b/REFACTORING-TODO.md index 62e4d23..31d6577 100644 --- a/REFACTORING-TODO.md +++ b/REFACTORING-TODO.md @@ -107,7 +107,7 @@ This is the authoritative execution tracker for the refactor. Work is performed | A001 | `DONE` | Map every auth RPC to business operations and dependencies. | Method-level migration map is recorded in `REFACTORING-AUDIT.md`; completed on `2026-08-30`. | | A002 | `DONE` | Introduce auth domain entities, value objects, errors, and repository ports. | Added pure Auth entities/value objects, domain errors, and inward-facing repository/cache ports with no gRPC, GORM, Redis, or framework imports; committed as `32f182b`/`d292822`. | | A003 | `STARTED` | Move auth persistence and Redis implementations into infrastructure. | Explicit mappings and domain-port adapters now cover users, identities, sessions, permissions, roles, role-permissions, bank information, OTP templates, and cache; legacy repository integration and ownership migration remain. | -| A004 | `STARTED` | Extract OTP application use cases and thin gRPC adapters. | OTP code generation is now an application primitive; template delivery and gRPC adapter extraction remain. | +| A004 | `STARTED` | Extract OTP application use cases and thin gRPC adapters. | OTP code generation, expiration, and template parameter parsing are application primitives; template delivery/verification and gRPC adapter extraction remain. | | A005 | `TODO` | Extract authentication/JWT application use cases and adapters. | Token behavior, validation, and status mapping remain compatible. | | A006 | `TODO` | Extract identity and permission use cases and adapters. | Public and internal authorization services pass tests. | | A007 | `TODO` | Replace auth bootstrap with explicit dependency composition. | Dependency direction is enforced and the service builds. | @@ -290,3 +290,4 @@ Append one row whenever a task changes status. Existing rows are never rewritten | 2026-08-30 | A003 | `TODO` | `STARTED` | Added infrastructure persistence mappings between legacy database records and the new Auth domain entities; mapping tests and full Auth tests pass in `58f6a43`. | | 2026-08-30 | A003 | `STARTED` | `STARTED` | Added remaining persistence mappings and domain-port adapters for sessions, permissions, roles, role-permissions, bank information, and OTP templates; full Auth tests pass in `e6e8e34`. Legacy repository implementations still require relocation/integration. | | 2026-08-30 | A004 | `TODO` | `STARTED` | Extracted OTP code generation and expiration constant into `application/otp`, retained compatible use-case behavior, and added focused tests in `0c92b14`. | +| 2026-08-30 | A004 | `STARTED` | `STARTED` | Extracted OTP template parameter decoding into `application/otp`; full Auth tests pass in `62fb1b1`. Legacy template lookup and delivery composition remain. |