Skip to content

Commit ce7d207

Browse files
authored
Merge branch 'master' into feat/commp-multihash
2 parents 1ddfc28 + 2f10269 commit ce7d207

File tree

4 files changed

+124
-9
lines changed

4 files changed

+124
-9
lines changed

.github/workflows/generated-pr.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Close Generated PRs
2+
3+
on:
4+
schedule:
5+
- cron: '0 0 * * *'
6+
workflow_dispatch:
7+
8+
permissions:
9+
issues: write
10+
pull-requests: write
11+
12+
jobs:
13+
stale:
14+
uses: ipdxco/unified-github-workflows/.github/workflows/reusable-generated-pr.yml@v1

.github/workflows/stale.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Close Stale Issues
2+
3+
on:
4+
schedule:
5+
- cron: '0 0 * * *'
6+
workflow_dispatch:
7+
8+
permissions:
9+
issues: write
10+
pull-requests: write
11+
12+
jobs:
13+
stale:
14+
uses: ipdxco/unified-github-workflows/.github/workflows/reusable-stale-issue.yml@v1

README.md

Lines changed: 33 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,28 @@ Each multicodec is marked with a status:
4646

4747
NOTE: Just because a codec is marked draft, don't assume that it can be re-assigned. Check to see if it ever gained wide adoption and, if so, mark it as permanent.
4848

49+
### Tag Categories
50+
51+
Each multicodec entry in the table.csv has a "tag" column that helps categorize the entry type. When adding a new multicodec, it's important to assign the correct tag. Here are descriptions of the most common tags:
52+
53+
* **multihash**: Entries for cryptographic hash functions as described in [multihash](https://github.com/multiformats/multihash). Multihash is a protocol for differentiating outputs from various well-established cryptographic hash functions, addressing size and encoding considerations.
54+
55+
* **hash**: Non-cryptographic hash functions, which are not suitable for content addressing systems but may have other uses. As noted in the [multihash documentation](https://github.com/multiformats/multihash#non-cryptographic-hash-functions), these have specialized use-cases where identifying non-cryptographic hash functions by multihash may be desirable.
56+
57+
* **key**: Cryptographic key types, including public and private keys for various cryptographic algorithms.
58+
59+
* **multiaddr**: Network address formats as defined in [multiaddr](https://github.com/multiformats/multiaddr). Multiaddr aims to make network addresses future-proof, composable, and efficient.
60+
61+
* **ipld**: [InterPlanetary Linked Data](https://ipld.io/) formats. These codecs are suitable for use as a codec in a [CID](https://github.com/multiformats/cid) and will deserialize linked data that may contain links to other data.
62+
63+
* **serialization**: Similar to "ipld" but does not materialize links. For example, JSON and CBOR have the "serialization" tag, while DAG-JSON and DAG-CBOR have the "ipld" tag because they handle links.
64+
65+
* **varsig**: Signature formats as described in [varsig](https://github.com/ChainAgnostic/varsig). Varsig is a multiformat for describing signatures over IPLD data and raw bytes in a way that preserves information about the payload and canonicalization information.
66+
67+
* **namespace**: Namespace identifiers for various protocols and systems.
68+
69+
Selecting the appropriate tag helps maintain organization in the table and provides context for how a codec is expected to be used.
70+
4971
### Adding new multicodecs to the table
5072

5173
The process to add a new multicodec to the table is the following:
@@ -62,7 +84,7 @@ This ["first come, first assign"](https://github.com/multiformats/multicodec/pul
6284

6385
The first 127 bits are encoded as a single-byte varint, hence they are reserved for the most widely used multicodecs. So if you are adding your own codec to the table, you most likely would want to ask for a codec bigger than `0x80`.
6486

65-
Codec names should be easily convertible to constants in common programming languages using basic transformation rules (e.g. upper-case, conversion of `-` to `_`, etc.). Therefore they should contain alphanumeric characters, with the first character being alphabetic. The primary delimiter for multi-part names should be `-`, with `_` reserved for cases where a secondary delimiter is required. For example: `bls12_381-g1-pub` contains 3 parts: `bls_381`, `g1` and `pub`, where `bls_381` is "BLS 381" which is not commonly written as "BLS381" and therefore requires a secondary separator.
87+
Codec names should be easily convertible to constants in common programming languages using basic transformation rules (e.g. upper-case, conversion of `-` to `_`, etc.). Therefore they should contain alphanumeric characters, with the first character being alphabetic. The primary delimiter for multi-part names should be `-`, with `_` reserved for cases where a secondary delimiter is required. For example: `bls12_381-g1-pub` contains 3 parts: `bls12_381`, `g1` and `pub`, where `bls12_381` is "BLS12 381" which is not commonly written as "BLS12381" and therefore requires a secondary separator.
6688

6789
The `validate.py` script can be used to validate the table once it's edited.
6890

@@ -77,7 +99,15 @@ The `validate.py` script can be used to validate the table once it's edited.
7799
- [Elixir](https://github.com/nocursor/ex-multicodec)
78100
- [Scala](https://github.com/fluency03/scala-multicodec)
79101
- [Ruby](https://github.com/sleeplessbyte/ruby-multicodec)
80-
- [Java](https://github.com/richardbergquist/java-multicodec)
102+
- Java
103+
- [java-multicodec](https://github.com/richardbergquist/java-multicodec)
104+
- [copper-multicodec](https://github.com/filip26/copper-multicodec)
105+
- Kotlin
106+
- `multicodec` part of Kotlin project [multiformat](https://github.com/erwin-kok/multiformat)
107+
- Zig
108+
- `multicodec` part of Zig project [multiformats-zig](https://github.com/zen-eth/multiformats-zig)
109+
- Swift
110+
- `Multicodec` part of [MultiformatsKit](https://github.com/ATProtoKit/MultiformatsKit)
81111
- [Add yours today!](https://github.com/multiformats/multicodec/edit/master/table.csv)
82112

83113
## Reserved Code Ranges
@@ -112,7 +142,7 @@ You can still find the table in [multibase.csv](https://github.com/multiformats/
112142

113143
> Can I use multicodec for my own purpose?
114144
115-
Sure, you can use multicodec whenever you have the need for self-identifiable data. Just prefix your own data with the corresponding varint encodec multicodec.
145+
Sure, you can use multicodec whenever you have the need for self-identifiable data. Just prefix your own data with the corresponding varint encoded multicodec.
116146

117147
## Contribute
118148

0 commit comments

Comments
 (0)