Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrBadCreds = errors.New("touchstone: bad credentials")
ErrBadCreds is returned when the given credentials were invalid.
var ErrBadParent = errors.New("touchstone: bad parent in Duo response")
ErrBadParent is returned when the Duo response is for a different parent than Touchstone.
var ErrServer = errors.New("touchstone: server error")
ErrServer is returned when there's an unexpected error with the Touchstone servers.
var ErrUnknownResponse = errors.New("touchstone: unknown response")
ErrUnknownResponse is returned when Touchstone gives a response that couldn't be handled.
Functions ¶
This section is empty.
Types ¶
type Client ¶
A Client handles authentication to Touchstone, and can then be used to authenticate to SSO-enabled services.
func NewClientWithHTTPClient ¶
NewClientWithHTTPClient creates a new Touchstone client, using the provided *http.Client.
func (*Client) AuthenticateToResource ¶
AuthenticateToResource uses the Client's Touchstone session to authenticate to the given resource.
func (*Client) BeginUsernamePasswordAuth ¶
func (c *Client) BeginUsernamePasswordAuth(username string, password string) (*duo.Challenge, error)
BeginUsernamePasswordAuth starts the Touchstone authentication process with a Kerberos username and password.
func (*Client) CompleteAuthWithDuo ¶
func (c *Client) CompleteAuthWithDuo(final *duo.FinalResponse) error
CompleteAuthWithDuo uses the given duo.FinalResponse to finish the Touchstone authnetication process.