Skip to content

Feature: Add Custodial Wallet Persistence and KMS References #135

Description

@3m1n3nc3

Description

Add wallet and managed-key-reference models without storing plaintext Stellar secrets.

File Location

learnault-api/prisma/schema.prisma, wallet migration/types, KMS interface, and tests

Design Reference

API Roadmap Phase 1: Add Custodial Wallet Persistence and KMS References.

Dependencies

Tasks

  • Add wallet user, network, custody, public key, status, and timestamps
  • Add opaque managed-key/envelope metadata only
  • Enforce intended wallet and public-key uniqueness
  • Define provisioning, active, failed, export, migrated, and disabled transitions
  • Add KMS interface and fake
  • Test migration, uniqueness, transitions, redaction, and lifecycle

Acceptance Criteria

  • Schema/DTO cannot store plaintext secret
  • Uniqueness and transitions are enforced
  • KMS references never enter ordinary responses
  • Tests pass

Verification Evidence

  • Attach schema threat review, migration, and secret-redaction tests

Difficulty

Advanced

Activity

  1. added theissue type on Aug 19, 2026
  2. DhruvC-2938 commented on Aug 19, 2026

    @DhruvC-2938
    Contributor

    I’d like to work on this issue by implementing secure wallet persistence and managed-key references without ever storing plaintext Stellar secrets. I’ll update the Prisma schema and migration to support wallet users, networks, custody metadata, public keys, statuses, and lifecycle timestamps, while enforcing wallet and public-key uniqueness.

    I’ll also add opaque managed-key/envelope metadata and a KMS interface with a fake implementation for testing. The implementation will enforce valid wallet lifecycle transitions such as provisioning, active, failed, exported, migrated, and disabled, while ensuring KMS references never appear in normal API responses.

    Finally, I’ll add tests covering migrations, uniqueness constraints, lifecycle transitions, secret redaction, and the managed-key flow to verify that sensitive key material is never persisted or exposed.

  3. grantfox-oss commented on Aug 19, 2026

    @grantfox-oss

    🦊 GrantFox — @DhruvC-2938 has been assigned to this issue as part of the Third Campaign campaign!

    Next steps:

    1. Open a Pull Request referencing this issue (e.g., Closes #135)
    2. Your PR will be reviewed by the learnault maintainers

    Good luck! Track your progress on GrantFox.

  4. grantfox-oss commented on Aug 22, 2026

    @grantfox-oss

    🎉 This issue has been marked as completed on GrantFox as part of the Third Campaign campaign!

    @DhruvC-2938's PR #146 was approved and merged by @3m1n3nc3.

    🏆 @DhruvC-2938: You earned 35 FoxPoints for this contribution! Your current tier: Explorer (363 total points). Track your full progress on GrantFox.

    👏 Great work, @DhruvC-2938! Keep contributing to learnault.

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

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions