Skip to content
This repository has been archived by the owner on Apr 29, 2020. It is now read-only.

What Happens When You Add a File? #236

Closed
glowkeeper opened this issue Mar 12, 2017 · 2 comments
Closed

What Happens When You Add a File? #236

glowkeeper opened this issue Mar 12, 2017 · 2 comments

Comments

@glowkeeper
Copy link

glowkeeper commented Mar 12, 2017

The draft white paper says: "Nodes are identified by a NodeId, the cryptographic hash of a public-key". Is the same process used when I add a file to IPFS? The white paper mentions cryptographic hashes, but not digital signatures. So:

$echo "hello WOOOOOOOORLD" | ipfs add -q

...returns QmdHom8wF6vcMSdWjpFkxCoGcJYPDnKo5qDn3wWn8LGhgN. Is that the signed and hashed id of the file?

@hsanjuan
Copy link
Member

No, QmdHom8wF6vcMSdWjpFkxCoGcJYPDnKo5qDn3wWn8LGhgN is just the [multi]hash for "hello WOOOOOOOORLD\n".

Your node's ID is the [multi]hash for the public key the node is using (that's what the paper says).

So to answer your question, hashes are not signed and everyone can obtain the same hash given the same input.

@madavieb
Copy link

This issue has been moved to https://discuss.ipfs.io/t/what-happens-when-you-add-a-file/418.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants