go-oauth2 / oauth2

OAuth 2.0 server library for the Go programming language.
https://pkg.go.dev/github.com/go-oauth2/oauth2/v4
MIT License
3.31k stars 563 forks source link

Per client authorization #220

Closed aurelien-semence closed 2 years ago

aurelien-semence commented 2 years ago

Just add clientID in PasswordAuthorizationHandler if we need to customize password authorization per client.

aurelien-semence commented 2 years ago

@realbucksavage it's done.

I was thinking that optional parameter should be the last but as you whish.

realbucksavage commented 2 years ago

@aurelien-semence seems like you missed a change on line 360 in server/server.go.

Also, since you're always passing clientID to the handler, it pretty much makes it a value that is always present. That was my reasoning behind rearranging the sequence.

aurelien-semence commented 2 years ago

@realbucksavage fixed