ssbc / ssb-db2

A new database for secure-scuttlebutt
47 stars 8 forks source link

Performing delete on an append-only database #267

Closed vinliao closed 3 years ago

vinliao commented 3 years ago

Hi, Scuttlebutt team. I've been looking around the Scuttlebutt project for the past couple days. It's interesting. It seems like deletion is still a big problem in this append-only database. I know a little bit of cryptography. Very little. A tiny nugget. But I'm wondering if it's possible to create a log that "blurs" a previous log through cryptography.

Here's an example of how it might work. Person A says XYZ by creating a log. A decides to retract XYZ by creating another log. When people try to read XYZ after it has been retracted by A, it will return gibberish instead. Is this possible? And is this non-delete issue an important puzzle to solve for Scuttlebutt?

arj03 commented 3 years ago

Hi @vinliao

We do support deleting messages by blanking them out: https://github.com/ssb-ngi-pointer/ssb-db2#delmsgid-cb. This is of course only done locally, we can't force clients to do this over the network.

arj03 commented 3 years ago

Another thing to note is there are never feed formats like bamboo where the actual content is separate from the main log. This means that you can replicate the full log and make sure there are no holes, but you might not have all the content because some of it was decided to be "deleted".

vinliao commented 3 years ago

That's pretty embarrassing. I should've looked around more before creating an issue. Thanks for pointing it out.

I'm still new to these decentralized social media sphere (I know a little bit of Mastodon, but that's about it). I feel like I need to understand more before I can contribute. Are there any other projects you're keeping a close eye on besides Scuttlebutt?

arj03 commented 3 years ago

No worries @vinliao, we are all here to learn. I'm mostly focused on SSB, but I do find https://hypercore-protocol.org/ interesting as well.