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

Roadmap #1

Open
4 of 8 tasks
coolaj86 opened this issue Aug 22, 2024 · 1 comment
Open
4 of 8 tasks

Roadmap #1

coolaj86 opened this issue Aug 22, 2024 · 1 comment

Comments

@coolaj86
Copy link
Member

coolaj86 commented Aug 22, 2024

  • Create DIP9/DIP13 key for identity
  • Create the other 5 keys for an identity
  • Create AssetLock Tx
  • Broadcast via Tx
  • Create AssetLockProof
    (txoutproof for block?? getaddressmempool for instant send??)
    • assetLockTransaction.hash
    • dpp.identity.createInstantAssetLockProof(
          instantLock.toBuffer(),
          assetLockTransaction.toBuffer(),
          outputIndex,
      )
      dpp.identity.createChainAssetLockProof(
          // @ts-ignore
          assetLockMetadata.height,
          assetLockTransaction.getOutPointBuffer(outputIndex),
      )
      
  • Create TRANSition (NOT transACTION)
  • listen on p2p for isdlock messages zmq for zmqpubrawtxlocksig notifications
  • Broadcast via GRPC
grpcui -proto ./packages/dapi-grpc/protos/platform/v0/platform.proto seed-1.testnet.networks.dash.org:1443

Biggest Reference

https://docs.dash.org/projects/platform/en/latest/docs/reference/dapi-endpoints-platform-endpoints.htm

Resources

@coolaj86
Copy link
Member Author

coolaj86 commented Aug 27, 2024

We may be able to sidestep all of the WASM, etc. The process may be this simple:

  1. Create a wallet with a few BIP44 and DIP9 HD accounts
  2. Generate private and public keys
  3. Send an assetLock payment, which is an almost normal transaction, but with a burn memo for the same amount as some special outputs appended to the end
  4. lots of things:
  5. Sign https://docs.dash.org/projects/platform/en/latest/docs/protocol-ref/identity.html#identity-state-transition-signing
  6. Broadcast https://docs.dash.org/projects/platform/en/stable/docs/reference/dapi-endpoints-platform-endpoints.html#broadcaststatetransition

Create Identity Transition State

{
  "protocolVersion":1,
  "type":2,
  // ecdsaSig(assetLockPrivateKey, CBOR(thisStateTransition))
  "signature":"IBTTgge+/VDa/9+n2q3pb4tAqZYI48AX8X3H/uedRLH5dN8Ekh/sxRRQQS9LaOPwZSCVED6XIYD+vravF2dhYOE=",
  "assetLockProof":{
    "type":0,
    "instantLock":"AQHDHQdekbFZJOQFEe1FnRjoDemL/oPF/v9IME/qphjt5gEAAAB/OlZB9p8vPzPE55MlegR7nwhXRpZC4d5sYnOIypNgzfdDRsW01v8UtlRoORokjoDJ9hA/XFMK65iYTrQ8AAAAGI4q8GxtK9LHOT1JipnIfwiiv8zW+C/sbokbMhi/BsEl51dpoeBQEUAYWT7KRiJ4Atx49zIrqsKvmU1mJQza0Y1YbBSS/b/IPO8StX04bItPpDuTp6zlh/G7YOGzlEoe",
    "transaction":"0300000001c31d075e91b15924e40511ed459d18e80de98bfe83c5feff48304feaa618ede6010000006b483045022100dd0e4a6c25b1c7ed9aec2c93133f6de27b4c695a062f21f0aed1a2999fccf01c0220384aaf84cd5fd1c741fd1739f5c026a492abbfc18cfde296c6d90e98304f2f76012102fb9e87840f7e0a9b01f955d8eb4d1d2a52b32c9c43c751d7a348482c514ad222ffffffff021027000000000000166a14ea15af58c614b050a3b2e6bcc131fe0e7de37b9801710815000000001976a9140ccc680f945e964f7665f57c0108cba5ca77ed1388ac00000000",
    "outputIndex":0
  },
  "publicKeys":[
    {
      "id":0,
      "type":0,
      "purpose":0,
      "securityLevel":0,
      "data":"AkWRfl3DJiyyy6YPUDQnNx5KERRnR8CoTiFUvfdaYSDS",
      "readOnly":false
    }
  ]
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant