Open mattsb42-aws opened 4 years ago
+1 on both inclinations. I think the combination of the sequential, generation-supporting multi-keyring with the fully-parallel non-generating multi-keyring should support all possible concurrency scenarios.
It's also worth thinking about how other flavours of multi-keyrings would interact with this though (such as N-of-M). Should there be separate sequential and parallel versions of that?
N-of-M decrypt is a completely different beast and (at least as I envision it in my head) will result in a single "EDK". From the perspective of anything outside of it, it will manifest as a single keyring, not a collection of keyrings.
N-of-M encrypt is an interesting question, because it would need to answer similar questions as both the multi-keyring and the parallel multi-keyring, but also additional questions (ex: is one group required? what is the threshold?) I suspect that some of these will fall into similar collapsing patterns as explored above. Maybe it would collapse into a "require N EDKs" keyring that just passes through to an underlying keyring and analyses the results and a "allow encrypt to fail" keyring that allows encrypt to proceed when the keyring it wraps fails?
Collecting some thoughts here for the parallel multi-keyring whenever that happens.