cosmos / ledger-cosmos-obsolete

Ledger Nano S support for Tendermint/Cosmos
Apache License 2.0
42 stars 29 forks source link

Json validation #52

Closed brejski closed 6 years ago

brejski commented 6 years ago

According to the json parsing specification (from TXSPEC.md):

The Ledger device MUST validate that supplied JSON is valid. Our JSON specification is a subset of RFC 7159 - invalid RFC 7159 JSON is invalid Ledger JSON, but not all valid RFC 7159 JSON is valid Ledger JSON.

We add the following two rules:

Currently only basic validation is implemented based on the jsmn library. We either need to update jsmn or add extra validation layer in the app along with negative tests that demonstrate malformed messages.

jleni commented 6 years ago

Consolidating issue https://github.com/cosmos/ledger-cosmos/issues/40 here

jleni commented 6 years ago

Linking to PR https://github.com/cosmos/ledger-cosmos/pull/77

jleni commented 6 years ago

Linking to PR https://github.com/cosmos/ledger-cosmos/pull/79

jleni commented 6 years ago

I guess that after #81 #80 we can close this ticket? @brejski @cwgoes

cwgoes commented 6 years ago

Yes; I think we can close this.

brejski commented 6 years ago

Yes