WIP: Allow DelegatedIdentity API clients to subscribe by PID #58
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is designed to provoke discussion around the DelegateIdentity API changes required for spiffe/spire#5019
This is following the "pass PIDs" approach settled on in the RFC doc: https://docs.google.com/document/d/1A1oQHuR6z3bvQtXN17r2EwBr5lazGGPbUPkxoURAAh4/edit
This assumes that the caller/client is ensuring that the PID is not recycled for the duration of the stream/call, using
pidfd
or similar.Looking for the following feedbacks:
Is this additional functionality a good fit for the DelegateIdentity API or should we add a new API? I think we should just extend DI.
Do we object to supporting
stream
/subscriber based APIs? I think we should support them, even though the PID recycling protection requirement puts more onus on the client.Do we want to do this for both JWT and x509 SVIDs? I assume so, and added new calls for both of the ones that previously required selectors.
Rather than make currently-required fields optional (selectors), I added parallel calls with new, parallel messages/fields. Do we want to do it like this, or do we want to use a single message/call and deprecate the old fields?