Skip to content

Commit dc35438

Browse files
CIP-0021 | Add Babbage changes (cardano-foundation#313)
* CIP-0021 | Add Babbage changes * CIP-0021 | Update Status and Type
1 parent 269525c commit dc35438

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

CIP-0021/README.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
CIP: 21
33
Title: Transaction requirements for interoperability with hardware wallets
44
Authors: Gabriel Kerekes <[email protected]>, Rafael Korbas <[email protected]>, Jan Mazak <[email protected]>
5-
Status: Draft
6-
Type: Standards
5+
Status: Active
6+
Type: Informational
77
Created: 2021-06-15
88
License: CC-BY-4.0
99
---
@@ -63,6 +63,7 @@ The number of the following transaction elements individually must not exceed `U
6363
- withdrawals in transaction body
6464
- collateral inputs in transaction body
6565
- required signers in transaction body
66+
- reference inputs in transaction body
6667
- the total number of witnesses
6768

6869
**Optional empty lists and maps**
@@ -71,7 +72,15 @@ Unless mentioned otherwise in this CIP, optional empty lists and maps must not b
7172

7273
**Outputs**
7374

74-
Outputs containing no multi-asset tokens must be serialized as a simple tuple, i.e. `[address, coin, ?datum_hash]` instead of `[address, [coin, {}], ?datum_hash]`. In addition, including `datum_hash` is only allowed if the payment part of the output's `address` is a script hash.
75+
A new, "post Alonzo", output format has been introduced in the Babbage era which uses a map instead of an array to store the output data. For now, both the "legacy" (array) and "post Alonzo" (map) output formats are supported by HW wallets but we encourage everyone to migrate to the "post Alonzo" format as support for the "legacy" output format might be removed in the future. Both formats can be mixed within a single transaction, both in outputs and in the collateral return output.
76+
77+
_Legacy outputs_
78+
79+
Outputs containing no multi-asset tokens must be serialized as a simple tuple, i.e. `[address, coin, ?datum_hash]` instead of `[address, [coin, {}], ?datum_hash]`.
80+
81+
_Post Alonzo outputs_
82+
83+
If the `data` of `datum_option` is included in an output, it must not be empty. `script_ref` (reference script) must also not be empty if it is included in an output.
7584

7685
**Multiassets**
7786

@@ -149,6 +158,10 @@ The specified auxiliary data format was chosen in order to be compatible with ot
149158

150159
Tools interacting with HW wallets might need to be updated in order to continue being compatible with HW wallets because of canonical CBOR serialization format, which is being enforced since multi-sig support.
151160

161+
## Tools
162+
163+
[`cardano-hw-interop-library`](https://github.com/vacuumlabs/cardano-hw-interop-lib) or [`cardano-hw-cli'](https://github.com/vacuumlabs/cardano-hw-cli) (which uses the interop library) can be used to validate or transform transactions into a HW wallet compatible format if possible.
164+
152165
## Copyright
153166

154167
This CIP is licensed under [CC-BY-4.0](https://creativecommons.org/licenses/by/4.0/legalcode)

0 commit comments

Comments
 (0)