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

Confusion about the origin of the 'aud' value in the stream configuration #230

Open
beyond-james-slocum opened this issue Jan 28, 2025 · 1 comment

Comments

@beyond-james-slocum
Copy link

beyond-james-slocum commented Jan 28, 2025

While on the Conformance Test Suite conference call, it became clear that there is some confusion around the origin of where the receivers aud value comes from.

While the spec says:

aud

Transmitter-Supplied, REQUIRED. A string or an array of strings containing an audience claim as defined in JSON Web Token (JWT)[RFC7519] that identifies the Event Receiver(s) for the Event Stream. This property cannot be updated. If multiple Receivers are specified then the Transmitter SHOULD know that these Receivers are the same entity.

The "transmitter-supplied", while correct in the sense this is a response object from the transmitter, is causing confusing that the transmitter is expected to "just know" this value. However this is really part of the "Receiver Configuration" which is NOT IN SPEC.

Basically there exists some flow before the spec that associates a receiver to a transmitter, during this time the receiver would share the audience it wants to set, and would get back a Bearer token to be used for all proceeding calls.

This should be noted in the description that this is a "pre-established" field while associating a receiver and transmitter.

                                                                            
                                                                            
   ┌─────────────────┐   /reg?aud="https://example.com"┌─────────────────┐  
   │                 ┼────────────────────────────────►│                 │  
   │                 │                                 │                 │  
   │   Receiver      │      Register  Receiver         │   Transmitter   │  
   │                 │                                 │                 │  
   │                 │                                 │                 │  
   │                 │◄────────────────────────────────┼                 │  
   │                 │    id=123, token="eyBQe..."     │                 │  
   │                 │                                 │                 │  
   └─────────────────┘                                 └─────────────────┘  
                                                                            
                                                                            
                                                                            
   ┌─────────────────┐  /stream {Bearer eyBQe..."}     ┌─────────────────┐  
   │                 ┼────────────────────────────────►│                 │  
   │                 │                                 │                 │  
   │   Receiver      │     Create New Stream           │   Transmitter   │  
   │                 │                                 │                 │  
   │                 │                                 │                 │  
   │                 │◄────────────────────────────────┼                 │  
   │                 │    {"stream_id":"XYZ", ...}     │                 │  
   │                 │                                 │                 │  
   └─────────────────┘                                 └─────────────────┘  
                                                                            
@FragLegs
Copy link
Contributor

FragLegs commented Feb 4, 2025

See this comment on a different issue: #207 (comment)

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

No branches or pull requests

2 participants