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

Suggestion to implement cosmos ADR 036 #362

Open
xpt1x opened this issue Dec 21, 2022 · 0 comments
Open

Suggestion to implement cosmos ADR 036 #362

xpt1x opened this issue Dec 21, 2022 · 0 comments

Comments

@xpt1x
Copy link

xpt1x commented Dec 21, 2022

Cosmos's ADR 036 Arbitrary Message Signature Specification allows to easily sign offchain messages and can be very helpful integrating aleph with cosmos chains

Instead of using a hardcoded msg structure and chain-id as (current):

"type": "signutil/MsgSignText",

We can abide by ADR 036 and follow it's structure which is very much similar to current one
Hence yielding a transaction like this

{
  "type": "cosmos-sdk/StdTx",
  "value": {
    "msg": [
      {
        "type": "sign/MsgSignData",
        "value": {
          "signer": "cosmos1hftz5ugqmpg9243xeegsqqav62f8hnywsjr4xr",
          "data": "cmFuZG9t"
        }
      }
    ],
    "fee": {
      "amount": [],
      "gas": "0"
    },
    "signatures": [
      {
        "pub_key": {
          "type": "tendermint/PubKeySecp256k1",
          "value": "AqnDSiRoFmTPfq97xxEb2VkQ/Hm28cPsqsZm9jEVsYK9"
        },
        "signature": "8y8i34qJakkjse9pOD2De+dnlc4KvFgh0wQpes4eydN66D9kv7cmCEouRrkka9tlW9cAkIL52ErB+6ye7X5aEg=="
      }
    ],
    "memo": ""
  }
}

#308
#353
aleph-im/aleph-js#48

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