ssc-half-light / .github

Half light social network
https://www.bicycle.codes/halflight
0 stars 0 forks source link

factor out IPFS #95

Open nichoth opened 8 months ago

nichoth commented 8 months ago

consider

the scenario of a key leaking

With IPFS, redundancy is at the protocol level. So there is no way to be certain that a blob has been deleted after you request deletion.

This is in comparison to traditional blobs hosts.

We have a 'centralized' store for blobs. If you delete something, it is removed from the central store, and thus any new requests for it fail. Any of your friends who have already requested the blob would technically be able to keep it via their local storage.

local-first blob storage

blob store

nichoth commented 8 months ago

We can use a more bespoke solution for directories/files here. That means we can organize such that every audience gets a unique symmetric key. Adding someone to an audience means adding a record to the audience with a map of

new user's device -> encrypted key
// audience
{
  members: {
    username: {
      deviceName: 'abc123',
      deviceName2: 'abc123',
      deviceName3: 'abc123'
    },
    username2: { /*...*/ }
  }
}

Removing someone from an audience would mean creating a new key and encrypting it to the new set of audience members.