Skip to content
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

Vault deletion? #21

Open
DRK3 opened this issue Oct 9, 2020 · 12 comments
Open

Vault deletion? #21

DRK3 opened this issue Oct 9, 2020 · 12 comments
Labels
ready for PR Ready for Pull Request

Comments

@DRK3
Copy link

DRK3 commented Oct 9, 2020

Hi,

Is there a plan to add a method to the REST API to delete a vault? Currently it's missing from the spec.

@dmitrizagidulin
Copy link
Contributor

Hi @DRK3, great question.

I suspect part of the reason that the spec hasn't tackled the subject of deleting a vault is the complexity of - so what should the semantics of that be?

If you're deleting a vault that currently has resources in it, does it mean that those resources are also deleted? If not.. is the implication that only "empty" vaults (ones that have no resources in them currently) are able to be deleted?

@dmitrizagidulin
Copy link
Contributor

Part of what complicates vault deletion, incidentally, is the Replication aspect of vaults. If the semantics of deleting a vault is decided to be "delete all resources contained in the vault", the moment you add replication, should the semantics become "turn all of the resources in the to-be-deleted vault into Tombstone objects, and then propagate those tombstone objects to the replicas"?
Or do you say - it's the EDV Client's responsibility to issue delete commands to each vault that is being replicated to? (Which sort of makes sense for bi-directional replication, but what about one-way? For one-way, you're back to Tombstone objects.)
etc.

@DRK3
Copy link
Author

DRK3 commented Nov 9, 2020

Thanks for replying @dmitrizagidulin! A couple of questions:

I see that replication is a topic under Identity Hubs. Is the EDV REST API going to rely on Identity Hubs? So far in https://github.com/trustbloc/edv we've been implementing an EDV REST server without the concept of Identity Hubs (as the implementation started before Identity Hubs were added to the spec). I'm wondering if the delete vault endpoint needs to be dependent on the replication consideration, or if this is just an implementation detail for another layer.

On a related note, there's currently a delete document endpoint. Would the same questions you have regarding replication apply there too?

@dmitrizagidulin
Copy link
Contributor

@DRK3

I see that replication is a topic under Identity Hubs. Is the EDV REST API going to rely on Identity Hubs?

Ah, good question -- no. The EDV is a lower layer (Hubs may want to depend on it, but EDV does not depend on or know about Hubs). So, EDVs have the replication feature, it's just not really documented in the spec yet.

But back to the original question of vault deletion -- it might be a useful feature!
We just need to agree on the semantics of it, and how it interacts with replication.

@dmitrizagidulin
Copy link
Contributor

On a related note, there's currently a delete document endpoint. Would the same questions you have regarding replication apply there too?

Yes, that's right - same question applies (though in the case of a single document, it's fairly straightforward -- it gets turned into a Tombstone object, to be replicated if applicable).

@agropper
Copy link

agropper commented Nov 11, 2020 via email

@dmitrizagidulin
Copy link
Contributor

@agropper

deletion could be done by discarding the key regardless of replication. Deletion is needed when the storage is not encrypted or when the controller wants to stop paying for the service.

Strong -1 to this. One of the central tenets of the EDV spec is that encryption alone IS NOT sufficient, and requires authorization controls (and actually deleting the data from disk and replicating that deletion) in addition to encryption.

@agropper
Copy link

agropper commented Nov 11, 2020 via email

@dmitrizagidulin
Copy link
Contributor

@agropper

encryption is an ADD-ON that we all recognize is hugely important but it is not the foundation.

See, whereas I think it's exactly the opposite. Encryption is the foundation, and it has huge effect on what kind of authorization and replication is possible. Basically, we start with the fact that everything must be encrypted. And all the other standards align around that.

@agropper
Copy link

agropper commented Nov 11, 2020 via email

@dmitrizagidulin dmitrizagidulin transferred this issue from decentralized-identity/confidential-storage May 13, 2021
@dmitrizagidulin
Copy link
Contributor

dmitrizagidulin commented May 27, 2021

Discussed on the May 27, 2021 call.

  • Seems like there is demand for vault deletion.
  • Question: How should this interact with replication? Specifically, if you delete one vault, AND replication is set up, does the deletion operation propagate to other vaults?
  • Question: Can you re-create a deleted vault with the same identifier? (In other words: which party is responsible for picking the vault ID, on creation? It should be server.)

@dmitrizagidulin
Copy link
Contributor

Revisited on Jun 10, 2021 call.

  • Replication wise: If replication is server-side, then yes, we'd need a section of Vault Config document specifying replication specifics (and whether vault deletion propagates). Waiting for server-side repl implementations, to discuss further.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready for PR Ready for Pull Request
Projects
None yet
Development

No branches or pull requests

3 participants