Skip to content

Conversation

@mishmosh
Copy link
Collaborator

@mishmosh mishmosh commented Dec 12, 2025

  • Adds caveat about CID determinism to "CIDs explained"
  • Minor edits for clarity in the "CIDs explained" section
  • Minor edits for clarity in the "How IPFS works: CIDs" section

Per discussion with @aschmahmann

@mishmosh mishmosh requested a review from aschmahmann December 12, 2025 02:25
@github-actions
Copy link
Contributor

github-actions bot commented Dec 12, 2025

🚀 Build Preview on IPFS ready

@lidel lidel self-assigned this Dec 12, 2025
- add "Why the hashes differ" section explaining root block hashing
- document when CID hash equals file hash (raw codec, single block)
- list factors affecting CID: chunk size, DAG layout, codec, version, hash
- explain flexibility as feature with tradeoffs for different use cases
- add DAG Explorer link alongside CID Inspector in quickstart
- link quickstart caveat to detailed explanation in concepts
- add public gateways link to public-utilities page
@lidel lidel force-pushed the cid-clarifications branch from 947b103 to 549ce0a Compare December 12, 2025 21:35
Copy link
Member

@lidel lidel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm. See changes i pushed to avoid duplicating content

If no concerns, feel free to merge, or I will merge next week.


:::callout
The transformation into a content-addressable representation is a local operation that doesn't require any network connectivity. Many CLI tools perform this transformation locally before uploading.
**Important caveat:** Two identical files can produce different CIDs. The CID reflects the contents *and* how the file is processed: chunk size, DAG layout, hash algorithm, CID version, and other [UnixFS](https://specs.ipfs.tech/unixfs/) parameters. The same file processed with different parameters will produce different CIDs. See [CIDs are not file hashes](../concepts/content-addressing.md#cids-are-not-file-hashes) for details.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ we already had "CIDs are not file hashes" content elsewhere, so adjusted this to link there + expanded there


As we can see, the hash included in the CID does NOT match the hash of the input file `ubuntu-20.04.1-desktop-amd64.iso`.

### Why the hashes differ
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mishmosh @aschmahmann does this extra explainer sound good?

The main point I want to make here is that this is a feature, not a limitation. And at the end we mention community-provided profiles for cases where specific preset is required.

@lidel lidel force-pushed the cid-clarifications branch from 549ce0a to 9c8406c Compare December 12, 2025 21:38
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

Successfully merging this pull request may close these issues.

3 participants