Eric Harris-Braun
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Versions and GitHub Sync Note Insights Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       owned this note    owned this note      
    Published Linked with GitHub
    Subscribed
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Subscribe
    # ADR - Key/Identity Management Integration of DPKI during **INSTALLATION** of Holochain so that all apps and app management can operate on top of that security. ## User experience (Human Commons usage): **Summary:** A wizard walks user through the process of establishing initial security pattern strong enough for the near term future. They can upgrade security as they use Holochain and apps more, such that they are socially connected enough to implement "m of n" trusted user approaches. ### Assumptions * We can't force people to start up M-of-N because they won't have or know how to find N friends to authorize. * So we'll start them with a strong revocation key and gamify their future upgrades to more resilient approaches (Level 1 security, Level 2 security, etc. or perhaps semantic tagging on security and then associate levels with sets of semantics) **Question:** Is multi-factor security just making up for the fact that each of the factors is insecure and vulnerable to central control? Thus a multi-factor attempts to diversify coordination across vulnerability to different centralizers (but mobile phone still ends up being a core vulnerability). ### Scenarios: 1. Initialization (source of seeds) * Move mouse to generate randomness for master source of seeds (24 - 48 words for generating revocation seed and device seeds), write them down and put them in a safe place. Do not put them in a digital form (unless we make a service that can interface hardware wallets for storing them?) 2. Generation (initial identity for device) * Click on button to get Nth seed for generating an Identity for a device (uses a deterministic combination of a subset of the 48) * GenSeed stored locally (encrypted & password protected) used to create the Identity/Address key for each app, and registered with DPKI so you know which Nth number in the seed sequence to use as you keep adding apps. 3. Regeneration (phone dropped in toilet) 4. Revocation (device stolen / compromise of control) ## Tech details: - 48 (or 24?) words becomes the seed for revocation keys - Use deterministic combination of a subset (32? words) for seeds for generator keys (one per device) - Generate next dozen GenSeeds and store the HASH of each in first DPKI chain, so that we can magically bind devices together as controlled by this agent for syncing local data - Note this means that Generated seeds are actually stored on the device, but the revocation keys aren't! ## Holochain Key/Agent API functions necessary to implement (rust crate; subconsious): ### Order of Seed and Key Generation: - gen_seed_words(entropy,num_words) -> source_of_seesds_word_list - gen_revocation_key(source_of_seeds_word_list) -> revocation_pub_key **(NEW)** // Can we split into 2? gen_revocation_seed(seed_word_list, password) -> revocation_seed && gen_revocation_private_key(revocation_seed) - get_revocation_private_key(revocation_pub_key) -> revocation_priv_key **(NEW)** - gen_gen_seed(source_of_seeds_word_list,nth_gen) -> seed // ? Can we use a clearer name? Is this used to generate 12 mnumonic words from 48 words? Then we need functions generate_generation_mnemonic_words(revocation_mnemonic_words, password, n) -> [generation_mnemonic_words(12)](list size = n) - gen_key(seed,nth_key) -> private_key - get_public_key(private_key) -> public_key - encrypt_key(private_key,password) -> encrypted_key - decrypt_key(encrypted_key,password) -> private_key - de/serialize_key(serialized_/encrypted_key) -> serialized_/encrypted_key - **hardware_wallet integration functions here** ## DPKI Notes: * DPKI needs to register and publish the public side of this data, but private keys should never transmit over any wire, not even API bridges between local apps. This means the underlying Holochain system must write/encrypt/password protect the priv key files to persistor layer. * If we register Bridge APIs to the DPKI chain it creates a usability advantage, but it also creates a "centralized" vulnerability where if that DPKI instance/device is compromised, it immediately exposes every app relying on it for key generation and revocation. If there was another way to bridge which did not create this immutable record, and just received inbound calls authorized by keys it knows it has generated, then there's no outward pointer to expose control of all apps. ----- ----- # Proposals for changes to Core for DPKI ## List of Core Dev Executables: - Load Revocation Keys into the header - Generate Revocation Seed and **Keys (new)** - Generate GenSeeds and Keys - Private Keys Encryption Decision (Encrypt/Decrypt, Sterilization) ## List of DPKI Intern Executables (DPKI Implementation): **Login** - Determine whether it's the user's first time to use Holochain. Call is_init_login() - First Time: User registers. Create object holo_init_registration - Returns : Master_Seed, And N Gen_Seeds - Already registered, but installing Holochain on new device: - Have Gen_Seed: - Use the Gen Seed created to link magically to the same account. - No more Gen_Seed left: - Use the Master_Seed to create more Gen_Seed - Old Device Stolen: go to Stolen Recovery - Old Device Lost: go to Destroy Recovery **Registration** - Generate Entropy: gen_entropy(x, y) - Call gen_seed_words(entropy,num_words) --> seed_word_list (? gne) - Fields inside revocation keys: dna_hash, revocation_pub_key, user_app_pub_key - Call gen_rev_key() - Call gen_gen_seed(seed_word_list,nth_gen) --> Store the Seed_Hash As the anchors for alternate platforms (Laptop, Mobile, etc..) - Go to New Device. **New Device** - Call gen_key(seed,nth_key) returns priv Key - Choose the Revocation Method - Default use Level1 - Switch(){level1, level2} - Level1 security: - Require 12 mnemonic words - Level2 security: - No longer require 12 mnemonic words for the device lost, rather the is generated for the keys - Require N friends information to reach and recover. - Store hash(private_Key) Locally (Local Chain?) - get_public_key(private_key)--> link to the generation_seed_hash (Manager the pub keys linked to the DHT) - Maintain a Map<generation_seeds, device(mac)> **Stolen Recovery** (Revocation Process) - **(Validation For Revocation)** - **Level 1** - Use the Master_Seed(i.e. one for each user the 24 or 48 word string). - Mark the old generation Seed as no longer valid. - **Level 2** - Notify you N list friends let them link a signed revocation_key(any string) to your public_key for that App in the DPKI - Once this is validated the person's identity is verified and create new generation seed. - **(Revocation Process)** - **Both Levels** - If register with a new device, give new generation Seed for that device. - Create new GenKeys for each app in the previous gen_seed and link them to the new GenSeed Hash **Destroy Recovery** (Recovery Process) - Use your seed(i.e. created for each DPKI) or your Master_Seed(i.e. one for each user the 24 or 48 word string) - Recover exactly the same things on new device. ----- ### Questions ? - Is there a way to recover your Master_Seed (the GenSeed) if it is lost? ## Graph ```graphviz digraph tree { rankdir=LR; size="20,37!" ratio=fill; node [shape=record] {node[color=red; fontcolor=red; fontsize=100] MasterSeed } {node[color=red; fontcolor=red;fontsize=100] RevSeed } {node[color=blue; fontcolor=blue;fontsize=100] GenSeed0; GenSeed1; GenSeedN; } {node[color=black; fontcolor=black; fontsize=100] Gen0Key0; Gen0Key1; Gen0KeyN; Gen1Key0; Gen1Key1; Gen1KeyN; GenNKey0; GenNKey1; GenNKeyN;} MasterSeed [label="MasterSeed\n(24 words)"] Gen0Key0 [label="{Gen0Key0 |{AuthorKeyPair|NetworkKeyPair}}"] Gen0Key1 [label="{Gen0Key1 |{AuthorKeyPair|NetworkKeyPair}}"] Gen0KeyN [label="{Gen0KeyN |{AuthorKeyPair|NetworkKeyPair}}"] Gen1Key0 [label="{Gen1Key0 |{AuthorKeyPair|NetworkKeyPair}}"] Gen1Key1 [label="{Gen1Key1 |{AuthorKeyPair|NetworkKeyPair}}"] Gen1KeyN [label="{Gen1KeyN |{AuthorKeyPair|NetworkKeyPair}}"] GenNKey0 [label="{GenNKey0 |{AuthorKeyPair|NetworkKeyPair}}"] GenNKey1 [label="{GenNKey1 |{AuthorKeyPair|NetworkKeyPair}}"] GenNKeyN [label="{GenNKeyN |{AuthorKeyPair|NetworkKeyPair}}"] MasterSeed->GenSeed0 MasterSeed->GenSeed1 MasterSeed->GenSeedN MasterSeed->RevSeed RevSeed->RevKey0 RevSeed->RevKey1 RevSeed->RevKeyN GenSeed0->Gen0Key0 GenSeed0->Gen0Key1 GenSeed0->Gen0KeyN GenSeed1->Gen1Key0 GenSeed1->Gen1Key1 GenSeed1->Gen1KeyN GenSeedN->GenNKey0 GenSeedN->GenNKey1 GenSeedN->GenNKeyN }

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully