Skip to content

Auth: core building blocks — token generation, repositories, clock - #45

Open
RandyJDean wants to merge 1 commit into
07-09-auth_add_magic-link_session_migrations_and_runtime_datasourcefrom
07-09-auth_core_building_blocks_token_generation_repositories_clock
Open

Auth: core building blocks — token generation, repositories, clock#45
RandyJDean wants to merge 1 commit into
07-09-auth_add_magic-link_session_migrations_and_runtime_datasourcefrom
07-09-auth_core_building_blocks_token_generation_repositories_clock

Conversation

@RandyJDean

Copy link
Copy Markdown
Contributor
  • TokenGenerator mints 256-bit base64url tokens and stores only SHA-256
    hex digests
  • JdbcClient repositories (first runtime DB access in the repo):
    magic_link_tokens CRUD with an atomic consume, and the auth domain's
    minimal view of members incl. race-safe shell insert
  • Injectable UTC Clock so expiry logic is testable

Co-Authored-By: Claude Fable 5 noreply@anthropic.com

RandyJDean commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

@graphite-app

graphite-app Bot commented Jul 10, 2026

Copy link
Copy Markdown

Graphite Automations

"Request reviewers once CI passes" took an action on this PR • (07/10/26)

2 reviewers were added to this PR based on Henry Chen's automation.

Comment thread src/main/java/org/patinanetwork/patchats/auth/repo/MagicLinkTokenRepository.java Outdated
Comment thread src/main/java/org/patinanetwork/patchats/auth/repo/MemberAccountRepository.java Outdated
Comment thread src/main/java/org/patinanetwork/patchats/auth/repo/MemberAccountRepository.java Outdated
@RandyJDean
RandyJDean force-pushed the 07-09-auth_add_magic-link_session_migrations_and_runtime_datasource branch from 482ace2 to facb82a Compare July 31, 2026 17:24
@RandyJDean
RandyJDean force-pushed the 07-09-auth_core_building_blocks_token_generation_repositories_clock branch 2 times, most recently from 789997b to 71f627d Compare July 31, 2026 18:17
- TokenGenerator mints 256-bit base64url tokens and stores only SHA-256
  hex digests
- MagicLinkTokenRepository (JdbcClient, plain SQL): insert plus an atomic
  consume that returns the email, uniform-empty on every failure mode
- Injectable UTC Clock so expiry logic is testable

Member lookups go through the member domain's MemberRepo — auth owns no
member SQL of its own.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@RandyJDean
RandyJDean force-pushed the 07-09-auth_core_building_blocks_token_generation_repositories_clock branch from 71f627d to 2c57e4c Compare August 10, 2026 18:15
@RandyJDean
RandyJDean force-pushed the 07-09-auth_add_magic-link_session_migrations_and_runtime_datasource branch from facb82a to 1e878d8 Compare August 10, 2026 18:15
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants