Comments (2)
@fazo96 in short: yes! :) This is something we've been wanting to implement for quite some time and will do so at some point. However, this is a bit more complex topic that effects various parts of the system so doing it correctly will take some time.
But to get started and as a first implementation, passing a "onVerify" or smth function to the log which then gets called upon verifying the entry would be a good solution as you propose. Would you want to work on it and submit a PR?
Is proof-of-work based data addition your specific use case for this? Is every update to the DB required to have a corresponding entry in a ledger or are you thinking that there's one entry in the ledger against which all writes to the DB get verified against?
from ipfs-log.
I am working on the Chlu implementation and as part of that, we are using orbit db to keep track of the list of review records that customers submit to the network as well as their updates.
IPFS is immutable but review records can be updated, so I wrote a custom orbit-db store that accepts two operations:
ADD_REVIEW_RECORD
with a multihash for the RRUPDATE_REVIEW_RECORD
with a multihash for the new RR and a multihash for the previous version
Then the store at the moment uses an array for the list of original review records and an object to keep pointers from old version to next, so that the latest version can be resolved using an old one.
This is working great, but the problem is making sure the review records are valid. There is no proof of work involved but the process of validating a RR is quite complex and it includes binary deserialization, checking various signatures, fetching multiple IPFS objects, calculating hashes etc.
I also need to check that the "new version" field in the update is actually an update of the "old version" and not something different.
We have it already implemented, but it needs to be called during the updateIndex
to make sure the operations contain valid data.
I'll try to look at this today and see if I can pass the onVerify
function somehow :)
Another question, is there the possibility of refusing (not joining and not advertising) a log if it has invalid entries?
from ipfs-log.
Related Issues (20)
- issue appending to loaded Log HOT 1
- preparations for js-ipfs 0.40 HOT 2
- importing identity HOT 4
- preparations for js-ipfs 0.41 HOT 1
- Update to js-ipfs 0.43
- [email protected] is breaking old orbit-db releases HOT 5
- Update to Webpack 5
- Update to Standardjs 16
- open collective link is malformed
- tests use undefined config property to name folder
- Ability for bad actor to 'flood' a public log as essentially a denial of service attack? [Question] HOT 1
- Hook to validate log updates [feature request]
- Sort list of items that requires to grant the Write access by their clocks
- Standardize IPLD schema HOT 1
- Time to remove `lib/es5`? HOT 5
- Updating the `p-*` repos HOT 1
- Working example HOT 4
- Supporting atomic and transactional read/writes
- funnily enough, the matrix link to permaweb.io's matrix server is not permanent HOT 2
- bundle.js wrong name
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ipfs-log.