Coder Social home page Coder Social logo

Comments (4)

dylankb avatar dylankb commented on August 25, 2024

Yes, we should definitely do this! I'd add two small things. One, we should couple this change with creating a system to alert hosts that their modified shard has now become a "zombie". A log file with the original filename and SHA of the original shard will hopefully be enough to alert hosts that they are free to delete the hosted file. This isn't important for bad actors, but helps good ones keep their file systems clean.

Two, I think there's a fourth possible state for file accessibility - the file was deleted or the file name was changed. We should make sure to handle those as well.

from layr.

WilfredTA avatar WilfredTA commented on August 25, 2024

For the first case, if a host modified a file, wouldn't you consider them a bad actor?

Also, the second case is already handled.

from layr.

dylankb avatar dylankb commented on August 25, 2024

I think it's certainly possible that someone could accidentally edit a shard without meaning to. For example, if you open a shard file in the Atom text editor and save the file, Atom will automatically insert a new line character by default. This is a pretty subtle change, but would make the shard fail the audit. But what do you think?

Oh good! I see that was added to my auditing branch yesterday. What I wrote didn't consider that case so 👍

from layr.

WilfredTA avatar WilfredTA commented on August 25, 2024

That's a fair point, yeah. I believe that if the newline was deleted, the shard would still fail the audit, but I'm not sure. I tried experimenting with adding and deleting content of a shard and the audit failed even after the added content was removed. It's worth experimenting and researching that.

Yeah, it does seem pretty easy to accidentally manipulate a file, then. We can certainly implement a notification system to take care of zombie shards, then.

So, if an audit fails we can let the failing host node know (if they're online), and if they're not online, well the result of the shard audit will be that 3rd state, which is handled by generating a new copy which is then distributed, but keeping it in the manifest file

from layr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.