-
Notifications
You must be signed in to change notification settings - Fork 218
Add OpenAuth client in golang #251
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
base: 1.0
Are you sure you want to change the base?
Conversation
|
|
Hi @natac13, are you still working on this? I've forked your branch and tested it myself, and it's been working well! Though I got some comments that I'd like to add. |
@muhwyndhamhp Any feedback is welcome. I was 'done' with this to the point of waiting for a review. 🤞 |
wyndhamharyata
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's already good IMO, just had one minor implementation nitpick
| return nil, ErrInvalidAccessToken | ||
| } | ||
|
|
||
| var typ interface{} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would assume that the usage of interface{} here is to avoid panic due to type mismatch.
I've checked internal implementation on Token.Get() and it should be safe to declare typ directly as string and it won't cause panic but will return error as value.
| issuerCache: map[string]WellKnown{}, | ||
| jwksCache: map[string]jwk.Set{}, | ||
| mu: sync.RWMutex{}, | ||
| subjectSchema: &input.SubjectSchema, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not a critique, but I'd say this is an uncommon but very neat way to validate Subject. Never think of it this way!
Fixes sst#250 - [x] handle form POST - [x] resolve AWS marketplace token w/ AWS `ResolveCustomer` - [x] store AWS marketplace info in tenants table - [x] notify Fabric of AWS subscription through Hasura events (cf. existing Stripe hooks); see DefangLabs/defang-mvp#2096 - [ ] handle `x-amzn-marketplace-offer-type=free-trial` form param --------- Co-authored-by: Raphael Titsworth-Morin <[email protected]> Co-authored-by: Eric Liu <[email protected]> Co-authored-by: Eric Liu <[email protected]>
No description provided.