Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add invite funding key derivation path #140

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
2 changes: 1 addition & 1 deletion dip-0009/assignments.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Here is a table of current feature paths and any associated DIP. Future DIPs may
| Feature Index * | Feature | DIP Number and Name | Note |
| ------------------ | ------------ | ------------------- | ---- |
| `3'` | Masternode Keys | [DIP 0003: Deterministic Masternode List](https://github.com/dashpay/dips/blob/master/dip-0003.md) | The masternode related keys are located in the following sub-paths: <br>`0'/*` - _Reserved_<br>`1'/*` - Voting Key<br>`2'/*` - Owner Key<br>`3'/*` - Operator Key<br>`4'/*` - [Platform P2P Key](../dip-0028.md#calculating-the-platform-node-id) (ED25519)<br><br>For example, the first voting key for Dash would be at `m/9'/5'/3'/1'/0` |
| `5'` | Identity Keys | [DIP 0013: Identities in Hierarchical Deterministic wallets](../dip-0013.md) | The related keys are located in the following sub-paths: <br>`0'/key type'/identity index'/key index'/*` - Identity Authentication ([details](../dip-0013.md#identity-authentication-keys))<br>`1'/*` - Identity Registration Funding ([details](../dip-0013.md#identity-registration-funding-keys))<br>`2'/*` - Identity Topup Funding ([details](../dip-0013.md#identity-top-up-funding-keys))<br><br>For example, the first Identity Registration Funding key for Dash would be at `m/9'/5'/5'/1'/0` |
| `5'` | Identity Keys | [DIP 0013: Identities in Hierarchical Deterministic wallets](../dip-0013.md) | The related keys are located in the following sub-paths: <br>`0'/key type'/identity index'/key index'/*` - Identity Authentication ([details](../dip-0013.md#identity-authentication-keys))<br>`1'/*` - Identity Registration Funding ([details](../dip-0013.md#identity-registration-funding-keys))<br>`2'/*` - Identity Topup Funding ([details](../dip-0013.md#identity-top-up-funding-keys))<br>`3'/*` - Identity Invitation Funding ([details](../dip-0013.md#identity-invitatation-funding-keys))<br><br>For example, the first Identity Registration Funding key for Dash would be at `m/9'/5'/5'/1'/0` |
| `15'` | DashPay - Incoming Funds | [DIP 0015: DashPay](../dip-0015.md#dashpay-incoming-funds-derivation-path) | The related keys are located in the following sub-paths: `/0'/account'/*`<br><br>For example, incoming funds for the first identity would be at `m/9'/5'/15'/0'/*` |
| `16'` | DashPay - Auto Accept Proof | [DIP 0015: DashPay](../dip-0015.md#auto-accept-proof-autoacceptproof) | The related keys are located in the following sub-paths: `16'/expiration timestamp'`<br><br>For example, the key for a proof expiring at a Unix epoch time of `1605927033` would be at `m/9'/5'/16'/1605927033'` |

Expand Down
21 changes: 21 additions & 0 deletions dip-0013.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
1. [Identity Authentication keys](#identity-authentication-keys)
1. [Identity Registration Funding keys](#identity-registration-funding-keys)
1. [Identity Top Up Funding keys](#identity-top-up-funding-keys)
1. [Identity Invitation Funding keys](#identity-invitation-funding-keys)
1. [Copyright](#copyright)

# Abstract
Expand Down Expand Up @@ -158,6 +159,26 @@ It is recommended that 30 address hashes of these keys be added to the bloom fil
If transactions containing 25 address hashes or more have been found, the filter should be
regenerated with 30 more.


# Identity Invitation Funding keys

Identity Invitation Funding keys used to fund invites are the fourth sub-feature for identities. They are always derived as ECDSA keys.

We define the following levels for them:

`m / purpose' / coin_type' / feature' / sub feature' / funding index' /`

Sub feature is set to `3'`.

If a wallet recovers an unused invitation funding transaction, the wallet should allow the user to
attempt reusing it. Dash Platform can be queried to see if the invitation funding transaction
has been used. It will be up to the user to determine if the invite should be resent to the original
recipient or a new recipient.

It is recommended that 30 address hashes of these keys be added to the bloom filter sent to peers.
If transactions containing 25 address hashes or more have been found, the filter should be
regenerated with 30 more.

# Copyright

Copyright (c) 2020 Dash Core Group, Inc. [Licensed under the MIT
Expand Down