Skip to content

Question: Is it worth to get rid of passwordcredentials/retrieveToken using oauth2.PasswordCredentialsToken #98

@gogolok

Description

@gogolok

In one of my projects we use WithPasswordCredentials
https://github.com/cloudfoundry/go-uaa/blame/018e3af20f551bc2765b9d745e23d974b1e6171a/api.go#L332

I saw the token refresh is being handled via
https://github.com/cloudfoundry/go-uaa/tree/master/passwordcredentials

It looks to me that retrieveToken

return retrieveToken(c.ctx, c.conf.ClientID, c.conf.ClientSecret, c.conf.Endpoint.TokenURL, v)

could make use of (or completley be replaced by)
https://github.com/golang/oauth2/blob/314ee5b92bf23c4973aa8e61eba3ff458e80eef2/oauth2.go#L198
or am I wrong and it's not worth investing to replace it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    Inbox

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions