Skip to content
This repository was archived by the owner on Oct 7, 2024. It is now read-only.

Add Vault class - #222

Draft
danroc wants to merge 34 commits into
mainfrom
feat/vault-refactor
Draft

Add Vault class#222
danroc wants to merge 34 commits into
mainfrom
feat/vault-refactor

Conversation

@danroc

Copy link
Copy Markdown
Contributor

This PR adds a Vault class that will be used in the vault refactor.

The end goal of the refactor is to move the encryption logic out of the KeyringController into a separate class. This is the first step in this direction.

This PR doesn't modify the KeyringController, it will be done after the controller is migrated to the BaseControllerV2.

Closes#208

@danrocdanroc added team-accounts This should be handled by the Accounts Team snap-keyring-epic labels Apr 25, 2023
@danroc
danroc requested a review from a team as a code ownerApril 25, 2023 21:13
@socket-security

socket-securityBot commented Apr 25, 2023

Copy link
Copy Markdown

New dependency changes detected. Learn more about Socket for GitHub ↗︎


👍 No new dependency issues detected in pull request

Bot Commands

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of package-name@version specifiers. e.g. @SocketSecurity ignore foo@1.0.0 bar@* or ignore all packages with @SocketSecurity ignore-all

    Pull request alert summary
    IssueStatus
    Install scripts✅ 0 issues
    Native code✅ 0 issues
    Bin script shell injection✅ 0 issues
    Unresolved require✅ 0 issues
    Invalid package.json✅ 0 issues
    HTTP dependency✅ 0 issues
    Git dependency✅ 0 issues
    Potential typo squat✅ 0 issues
    Known Malware✅ 0 issues
    Telemetry✅ 0 issues
    Protestware/Troll package✅ 0 issues

    📊 Modified Dependency Overview:

    ➕ Added PackageCapability Access+/- Transitive CountPublisher
    @types/uuid@9.0.1None+0types
    ajv-formats@2.1.1None+6esp
    uuid@9.0.0None+0ctavan
    ajv@8.12.0eval+5esp

    - prepare
    strategy:
    matrix:
    node-version: [14.x, 16.x, 18.x, 19.x]

    Copy link
    Copy Markdown
    Contributor

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Does this break node14? In either case: Separate change.

    Comment threadsrc/Vault.ts
    Comment on lines +491 to +492
    * If a state is given, the vault will be restored form it, otherwise, a new
    * vault will be created.

    Copy link
    Copy Markdown
    Contributor

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Suggested change
    *Ifastateisgiven,thevaultwillberestoredformit,otherwise,anew
    *vaultwillbecreated.
    *Ifastateissupplied,theoriginatingvaultwillberestored.
    *Otherwise,anewvaultwillbeinitialized.

    Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

    Labels

    team-accountsThis should be handled by the Accounts Team

    Projects

    None yet

    Development

    Successfully merging this pull request may close these issues.

    Improve vault encryption

    2 participants

    @danroc@legobeat