Documentation ¶
Index ¶
Constants ¶
const ( IdentifierTotpMfa = "totp" IdentifierDuoMfa = "duo" IdentifierU2F = "webauthn" IdentifierJumpCloudProtect = "push" )
const ( MaxOpenRetries = 10 RetryDelayMS = 200 * time.Millisecond )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthRequest ¶
type AuthRequest struct { Context string RedirectTo string Email string Password string OTP string }
AuthRequest is to be sent to JumpCloud as the auth req body
type Client ¶
type Client struct { provider.ValidateBase // contains filtered or unexported fields }
Client is a wrapper representing a JumpCloud SAML client
func (*Client) Authenticate ¶
func (jc *Client) Authenticate(loginDetails *creds.LoginDetails) (string, error)
Authenticate logs into JumpCloud and returns a SAML response
type DeviceFinder ¶ added in v2.29.0
type DeviceFinder interface {
// contains filtered or unexported methods
}
DeviceFinder is used to mock out finding devices
type FidoClient ¶ added in v2.29.0
type FidoClient struct { Device u2fhost.Device // contains filtered or unexported fields }
FidoClient represents a challenge and the device used to respond
func NewFidoClient ¶ added in v2.29.0
func NewFidoClient(challenge, rpId, keyHandle, token string, deviceFinder DeviceFinder) (FidoClient, error)
NewFidoClient returns a new initialized FIDO1-based WebAuthnClient, representing a single device
func (*FidoClient) ChallengeU2F ¶ added in v2.29.0
func (d *FidoClient) ChallengeU2F() (*JumpCloudResponse, error)
ChallengeU2F takes a FidoClient and returns a signed assertion to send to Okta
type JCRedirect ¶
type JCRedirect struct {
Address string `json:"redirectTo"`
}
JCRedirect is for unmarshalling the redirect address from the response after the auth
type JumpCloudPushResponse ¶ added in v2.33.0
type JumpCloudResponse ¶ added in v2.29.0
type PublicKey ¶ added in v2.29.0
type PublicKey struct { Id string `json:"id"` RawId string `json:"rawId"` Type string `json:"type"` Response PublicKeyResponse `json:"response"` }
type PublicKeyResponse ¶ added in v2.29.0
type U2FDevice ¶ added in v2.29.0
type U2FDevice interface { u2fhost.Device }
U2FDevice is used to support mocking this device with mockery https://github.com/vektra/mockery/issues/210#issuecomment-485026348
type U2FDeviceFinder ¶ added in v2.29.0
type U2FDeviceFinder struct{}
U2FDeviceFinder returns a U2F device