mirror of
https://github.com/davidallendj/opaal.git
synced 2025-12-20 03:27:02 -07:00
Made changes to get client credentials grant working
This commit is contained in:
parent
e67bc3e010
commit
5173701fa0
7 changed files with 135 additions and 64 deletions
|
|
@ -72,13 +72,13 @@ func NewClientWithConfigById(config *Config, id string) *oauth.Client {
|
|||
return nil
|
||||
}
|
||||
|
||||
func NewClientCredentialsFlowWithConfig(config *Config, client *oauth.Client) error {
|
||||
func NewClientCredentialsFlowWithConfig(config *Config, params flows.ClientCredentialsFlowParams) (string, error) {
|
||||
eps := flows.ClientCredentialsFlowEndpoints{
|
||||
Create: config.Authorization.Endpoints.Clients,
|
||||
Clients: config.Authorization.Endpoints.Clients,
|
||||
Authorize: config.Authorization.Endpoints.Authorize,
|
||||
Token: config.Authorization.Endpoints.Token,
|
||||
}
|
||||
return flows.NewClientCredentialsFlow(eps, client)
|
||||
return flows.NewClientCredentialsFlow(eps, params)
|
||||
}
|
||||
|
||||
func NewServerWithConfig(conf *Config) *server.Server {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue