Skip to content

Commit

Permalink
CIP-5: script prefixes extension (#31)
Browse files Browse the repository at this point in the history
* script prefixes

add script_vk

* add contents

rewrite contents

* apply Rodney's patch

* give details about the cryptographic objects of each bech32 item.

* move 'script' under the 'Hashes' section

* add 'asset' from CIP-0014 to the 'Hashes' section

Co-authored-by: KtorZ <[email protected]>
  • Loading branch information
paweljakubas and KtorZ authored Feb 18, 2021
1 parent 4e446f3 commit d81b10b
Showing 1 changed file with 55 additions and 25 deletions.
80 changes: 55 additions & 25 deletions CIP-0005/CIP-0005.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,59 @@ Therefore, we can leverage bech32 for binary data encoding, with a set of common

We define the following set of common prefixes with their corresponding semantic. Any software willing to represent binary data in a human-friendly way should abide by these guidelines. Should a data-type be missing, we encourage developers to update this CIP and register a new prefix.

| Prefix | Semantic |
| --- | --- |
| `addr_vk` | Address verification key |
| `addr_vkh` | Address verification key hash |
| `addr_sk` | Address signing key |
| `addr_xvk` | Address extended verification key |
| `addr_xsk` | Address extended signing key |
| `addr` | Mainnet address |
| `addr_test` | Testnet address |
| `stake_vk` | Stake address verification key |
| `stake_vkh` | Stake address verification key hash |
| `stake_sk` | Stake address signing key |
| `stake_xvk` | Stake address extended verification key |
| `stake_xsk` | Stake address extended signing key |
| `stake` | Mainnet stake address |
| `stake_test` | Testnet stake address |
| `pool` | Pool operator verification key hash (pool ID) |
| `pool_vk` | Pool operator verification key |
| `pool_sk` | Pool operator signing key |
| `kes_vk` | KES verification key |
| `kes_vkh` | KES verification key hash |
| `kes_sk` | KES signing key |
| `vrf_vk` | VRF verification key |
| `vrf_vkh` | VRF verification key hash |
| `vrf_sk` | VRF signing key |
#### Keys

| Prefix | Meaning | Contents |
| --- | --- | --- |
| `acct_sk` | CIP-1852's Account private key | Ed25519 private key |
| `acct_vk` | CIP-1852's Account public key | Ed25519 public key |
| `acct_xsk` | CIP-1852's extended Account private key | Ed25519-bip32 extended private key |
| `acct_xvk` | CIP-1852's extended Account public key | Ed25519 public key with chain code |
| `addr_sk` | Address signing key | Ed25519 private key |
| `addr_vk` | Address verification key | Ed25519 public key |
| `addr_xsk` | Address extended signing key | Ed25519-bip32 extended private key |
| `addr_xvk` | Address extended verification key | Ed25519 public key with chain code |
| `kes_sk` | KES signing key | KES signing key |
| `kes_vk` | KES verification key | KES verification key |
| `pool_sk` | Pool operator signing key | Ed25519 private key |
| `pool_vk` | Pool operator verification key | Ed25519 public key |
| `root_sk` | CIP-1852's root private key | Ed25519 private key |
| `root_vk` | CIP-1852's root public key | Ed25519 public key |
| `root_xsk` | CIP-1852's extended root private key | Ed25519-bip32 extended private key |
| `root_xvk` | CIP-1852's extended root public key | Ed25519 public key with chain code |
| `script_sk` | Script signing key | Ed25519 private key |
| `script_vk` | Script verification key | Ed25519 public key |
| `script_xsk` | Extended script signing key | Ed25519-bip32 extended private key |
| `script_xvk` | Extended script verification key | Ed25519 public key with chain code |
| `stake_sk` | Stake address signing key | Ed25519 private key |
| `stake_vk` | Stake address verification key | Ed25519 public key |
| `stake_xsk` | Extended stake address signing key | Ed25519-bip32 extended private key |
| `stake_xvk` | Extended stake address verification key | Ed25519 public key with chain code |
| `vrf_sk` | VRF signing key | VRF signing key |
| `vrf_vk` | VRF verification key | VRF verification key |

#### Hashes

| Prefix | Meaning | Contents |
| --- | --- | --- |
| `asset` | Fingerprint of a native asset for human comparison | See [CIP-0014] |
| `pool` | Pool operator verification key hash (pool ID) | blake2b\_224 digest of an operator verification key |
| `script` | Script hash | blake2b\_224 digest of a serialized transaction script |
| `addr_vkh` | Address verification key hash | blake2b\_224 digest of a payment verification key |
| `script_vkh` | Script verification key hash | blake2b\_224 digest of a script verification key |
| `stake_vkh` | Stake address verification key hash | blake2b\_224 digest of a delegation verification key |
| `vrf_vkh` | VRF verification key hash | blake2b\_256 digest of a VRF verification key |


#### Miscellaneous

| Prefix | Meaning | Contents |
| --- | --- | --- |
| `addr` | Mainnet address | Network tag, payment credential and optional stake credential |
| `addr_test` | Testnet address | Network tag, payment credential and optional stake credential |
| `stake` | Mainnet stake address | Network tag and stake credential |
| `stake_test` | Testnet stake address | Network tag and stake credential |


## Rationale

Expand Down Expand Up @@ -97,3 +125,5 @@ N/A
## Copyright

This CIP is licensed under Apache-2.0.

[CIP-0014]: https://github.com/cardano-foundation/CIPs/blob/645243e30b5aae109a70ec2b47af70dcc808bc56/CIP-0014/CIP-0014.md

0 comments on commit d81b10b

Please sign in to comment.