-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Discussion: Versions should use hashes #54
Comments
Good ideas. Maf and I have been discussing this. I'll let maf comment on what you're suggesting but I'll dump what I know has been done in this area:
|
👋 just seeing this and the last working group notes. I put a little experiment together that tries to define a deep link based on hypercore strong links: https://github.com/jwerle/dat-deep-link [Edit] also happy to make the module conform to whatever ends up being the spec |
Ping @mafintosh :) |
Reference to the meeting notes: https://github.com/datprotocol/working-group/blob/master/meeting-notes/24-08May2019.md#meeting-notes Take-aways:
|
Currently in hyperdrive, hypercore, beaker browser (and probably at a few other tools) versions are specified as
length of the append-log
(a number). However, that is not a safe specification of a version.Problem case: a researcher wants to specify exactly which version of a DAT is used, and specifies it like
dat://ab...ef+234
. The researcher notices that the data-set doesn't fit the output, reverts to version 1 and creates a new DAT with exactly 234 versions to fit the output. With this the researcher just managed to specify false claims.How to make sure this never happens? Each version of a hypercore creates a hash.
Which makes one version of a hyperdrive a combinations of various hypercore versions.
Specifying a dat version like this though:
... for a single-writer-dat. Which would become even more of a hassle with a
multi-writer-dat (1 key for the channel + 2 hashes per writer). Note: I know that it could be okay to have only the first 8 characters as version identification, but that would probably not be good enough for a researcher.
Thinking about this for a little, I got following solution which might be a good idea for a new DEP:
(Single-writer for the sake of simplicity)
We could add another
version
hypercore to a hyperdrive, that keeps an index of the versions and hashes:This way a version checkout could download all versions of the version hypercore, create a lookup-table and select the version based on that lookup-table.
My questions now are:
The text was updated successfully, but these errors were encountered: