From c6cd6a9a5642eb99ad6bc78198fc4019883e5999 Mon Sep 17 00:00:00 2001 From: thephez Date: Wed, 15 Apr 2026 12:26:25 -0400 Subject: [PATCH 1/6] docs(explanations): correct high-severity audit findings for v3.1 - fees: update cost table to current source constants (storage, processing, hashing); remove stale Query row - identity: replace outdated "future feature" note with accurate statement that credit withdrawals are live - platform-protocol-document: fix $dataContractId field name, add 7 missing base fields (transfer timestamps and block heights), update DPNS records field from dashUniqueIdentityId/dashAliasIdentityId to identity - platform-protocol-state-transition: add address-based state transition types 9-14 with links to protocol-ref/address-system.md Co-Authored-By: Claude Sonnet 4.6 --- docs/explanations/fees.md | 13 ++++++------- docs/explanations/identity.md | 4 +--- .../explanations/platform-protocol-document.md | 18 ++++++++++++------ .../platform-protocol-state-transition.md | 6 ++++++ 4 files changed, 25 insertions(+), 16 deletions(-) diff --git a/docs/explanations/fees.md b/docs/explanations/fees.md index 1c351c365..b7e93462f 100644 --- a/docs/explanations/fees.md +++ b/docs/explanations/fees.md @@ -26,14 +26,13 @@ The current cost schedule is outlined in the table below: | Operation | Cost (credits) | | - | - | -| Permanent storage | 40000 / byte | -| Base processing fee | 100000 | -| Write to storage | 750 / byte | -| Load from storage | 3500 / byte | +| Permanent storage | 27000 / byte | +| Base processing fee | 10000 | +| Write to storage | 400 / byte | +| Load from storage | 20 / byte | | Seek storage | 2000 | -| Query | 75 / byte | -| Load from memory | 20 / byte | -| Blake3 hash function | 400 + 64 / 64-byte block | +| Load from memory | 10 / byte | +| Blake3 hash function | 100 base + 300 / 64-byte block | :::{note} Refer to the [Identity explanation](../explanations/identity.md) section for information regarding how credits are created. diff --git a/docs/explanations/identity.md b/docs/explanations/identity.md index 9a991b7e1..05ac5535e 100644 --- a/docs/explanations/identity.md +++ b/docs/explanations/identity.md @@ -66,6 +66,4 @@ Note: the payout key is associated with the masternode owner identity, so both t DPP v0.13 introduced the initial implementation of credits. As mentioned above, credits provide the mechanism for paying fees that cover the cost of platform usage. Once a user locks Dash on the core blockchain and proves ownership of the locked value in an identity create or topup transaction, their credit balance increases by that amount. As they perform platform actions, these credits are deducted to pay the associated fees. -:::{attention} -As of Dash Platform v1.0, credits deducted to pay state transition fees cannot be converted back into Dash by masternodes. This aspect of the credit system will come in a future release. -::: +Credits can be converted back to Dash using the identity credit withdrawal state transition, subject to a daily network-wide limit. diff --git a/docs/explanations/platform-protocol-document.md b/docs/explanations/platform-protocol-document.md index 85c225d11..0df9c44c9 100644 --- a/docs/explanations/platform-protocol-document.md +++ b/docs/explanations/platform-protocol-document.md @@ -21,13 +21,20 @@ Dash Platform Protocol (DPP) defines a set of base fields that must be present i | $id | The document ID (32 bytes) | | $type | Document type defined in the referenced contract | | $revision | Document revision (=>1) | -| $dataContract | Data contract the document is associated with | +| $dataContractId | Data contract the document is associated with (32 bytes) | | $ownerId | [Identity](../explanations/identity.md) of the user submitting the document (32 bytes) | | $createdAt | Time (in milliseconds) the document was created | | $updatedAt | Time (in milliseconds) the document was last updated | +| $transferredAt | Time (in milliseconds) the document was last transferred | +| $createdAtBlockHeight | Platform block height when the document was created | +| $updatedAtBlockHeight | Platform block height when the document was last updated | +| $transferredAtBlockHeight | Platform block height when the document was last transferred | +| $createdAtCoreBlockHeight | Core block height when the document was created | +| $updatedAtCoreBlockHeight | Core block height when the document was last updated | +| $transferredAtCoreBlockHeight | Core block height when the document was last transferred | :::{attention} -The `$createdAt` and `$updatedAt` fields will only be present in documents that add them to the list of [required properties](../reference/data-contracts.md#required-properties). +The timestamp and block height fields will only be present in documents that add them to the list of [required properties](../reference/data-contracts.md#required-properties). ::: ### Data Contract Fields @@ -44,8 +51,7 @@ Each application defines its own fields via document definitions in its data con | domain | normalizedParentDomainName | string | | domain | preorderSalt | array (bytes) | | domain | records | object | -| domain | records.dashUniqueIdentityId | array (bytes) | -| domain | records.dashAliasIdentityId | array (bytes) | +| domain | records.identity | array (32 bytes) | | domain | subdomainRules | object | | domain | subdomainRules.allowSubdomains | boolean | @@ -63,7 +69,7 @@ The following example shows the structure of a DPNS `domain` document as output "parentDomainName": "dash", "preorderSalt": "bcCSdtGqqZdXBQB4DDBIU2RPAwFDFt9tMr0LX6m5qCQ=", "records": { - "dashUniqueIdentityId": "UQTRY+wqPyL27V7YjJadJdyXVBETj6CfzvqUg5aY5E4=" + "identity": "UQTRY+wqPyL27V7YjJadJdyXVBETj6CfzvqUg5aY5E4=" }, "subdomainRules": { "allowSubdomains": false @@ -71,7 +77,7 @@ The following example shows the structure of a DPNS `domain` document as output "$revision": 1, "$createdAt": null, "$updatedAt": null, - "$dataContract": { + "$dataContractId": { // Truncated ... }, "$type": "domain" diff --git a/docs/explanations/platform-protocol-state-transition.md b/docs/explanations/platform-protocol-state-transition.md index 1d94e51ce..705a02f03 100644 --- a/docs/explanations/platform-protocol-state-transition.md +++ b/docs/explanations/platform-protocol-state-transition.md @@ -45,6 +45,12 @@ The following table contains a list of currently defined payload types: | [Identity Credit Withdrawal](../protocol-ref/identity.md) (`6`) | Information required to withdraw credits from Dash Platform | | [Identity Credit Transfer](../protocol-ref/identity.md) (`7`) | Information required to transfer credits | | Masternode Vote (`8`) | Contested resource vote details (e.g., [DPNS premium name vote](../explanations/dpns.md#conflict-resolution)) | +| [Identity Credit Transfer To Addresses](../protocol-ref/address-system.md#identity-credit-transfer-to-addresses) (`9`) | Transfer identity credits to one or more Platform addresses | +| [Identity Create From Addresses](../protocol-ref/address-system.md#identity-create-from-addresses) (`10`) | Create a new identity funded from Platform addresses | +| [Identity Top Up From Addresses](../protocol-ref/address-system.md#identity-top-up-from-addresses) (`11`) | Add credits to an existing identity from Platform addresses | +| [Address Funds Transfer](../protocol-ref/address-system.md#address-funds-transfer) (`12`) | Transfer funds between Platform addresses | +| [Address Funding From Asset Lock](../protocol-ref/address-system.md#address-funding-from-asset-lock) (`13`) | Fund a Platform address using an asset lock proof | +| [Address Credit Withdrawal](../protocol-ref/address-system.md#address-credit-withdrawal) (`14`) | Withdraw credits from a Platform address | ### Application Usage From e78dedf621f60417b1dc22c0f84c1614a2472267 Mon Sep 17 00:00:00 2001 From: thephez Date: Wed, 15 Apr 2026 13:05:17 -0400 Subject: [PATCH 2/6] docs(explanations): correct medium-severity audit findings for v3.1 - fees: rename User Tip to User Fee Increase; update formula to use feeMultiplier - nft: rename System Only restriction to No Creation Allowed - data-trigger: fix document column (All Document Types -> domain); update links from documents_batch to batch - tokens: correct group member max power parenthetical (65536 -> 65535) Co-Authored-By: Claude Sonnet 4.6 --- docs/explanations/fees.md | 9 +++++---- docs/explanations/nft.md | 2 +- docs/explanations/platform-protocol-data-trigger.md | 6 +++--- docs/explanations/platform-protocol-document.md | 2 +- docs/explanations/tokens.md | 2 +- 5 files changed, 11 insertions(+), 10 deletions(-) diff --git a/docs/explanations/fees.md b/docs/explanations/fees.md index b7e93462f..bd6d639c8 100644 --- a/docs/explanations/fees.md +++ b/docs/explanations/fees.md @@ -56,17 +56,18 @@ An in-depth look at the Fee Multiplier can be found at **link** In an attempt to minimize Dash Platform's storage requirements, users are incentivized to remove data that they no longer want to be stored in the Dash Platform state for a refund. Data storage fees are distributed to masternodes over the data's lifetime which is 50 years for permanent storage. Therefore, at any time before the data's fees are entirely distributed, there will be fees remaining which can be refunded to the user if they decide to delete the data. -## User Tip +## User Fee Increase -Platform supports a user tip component that can be used to incentivize inclusion of a state -transition in the next block, especially during periods of high traffic. +Platform supports a user fee increase that can be used to incentivize inclusion of a state +transition in the next block, especially during periods of high traffic. This is expressed as a +multiplier on the processing fee. ## Formula The high level formula for a state transition's fee is: ```text - fee = storageFee + processingFee - storageRefund + userTip + fee = storageFee + processingFee * feeMultiplier - storageRefund ```