Documentation ¶
Index ¶
- Constants
- Variables
- func NewWebAuthnConnectionInput() *node.Node
- func NewWebAuthnConnectionName() *node.Node
- func NewWebAuthnConnectionTrigger(options string) *node.Node
- func NewWebAuthnLoginInput() *node.Node
- func NewWebAuthnLoginTrigger(options string) *node.Node
- func NewWebAuthnScript(src string, contents []byte) *node.Node
- func NewWebAuthnUnlink(c *identity.CredentialWebAuthn) *node.Node
- type Strategy
- func (s *Strategy) CompletedAuthenticationMethod(ctx context.Context, _ session.AuthenticationMethods) session.AuthenticationMethod
- func (s *Strategy) CountActiveFirstFactorCredentials(cc map[identity.CredentialsType]identity.Credentials) (count int, err error)
- func (s *Strategy) CountActiveMultiFactorCredentials(cc map[identity.CredentialsType]identity.Credentials) (count int, err error)
- func (s *Strategy) ID() identity.CredentialsType
- func (s *Strategy) Login(w http.ResponseWriter, r *http.Request, f *login.Flow, sess *session.Session) (i *identity.Identity, err error)
- func (s *Strategy) NodeGroup() node.UiNodeGroup
- func (s *Strategy) PopulateLoginMethod(r *http.Request, requestedAAL identity.AuthenticatorAssuranceLevel, ...) error
- func (s *Strategy) PopulateRegistrationMethod(r *http.Request, f *registration.Flow) error
- func (s *Strategy) PopulateSettingsMethod(r *http.Request, id *identity.Identity, f *settings.Flow) error
- func (s *Strategy) Register(w http.ResponseWriter, r *http.Request, f *registration.Flow, ...) (err error)
- func (s *Strategy) RegisterLoginRoutes(r *x.RouterPublic)
- func (s *Strategy) RegisterRegistrationRoutes(_ *x.RouterPublic)
- func (s *Strategy) RegisterSettingsRoutes(_ *x.RouterPublic)
- func (s *Strategy) Settings(w http.ResponseWriter, r *http.Request, f *settings.Flow, ss *session.Session) (*settings.UpdateContext, error)
- func (s *Strategy) SettingsStrategyID() string
- type User
Constants ¶
View Source
const (
InternalContextKeySessionData = "session_data"
)
Variables ¶
View Source
var ErrNoCredentials = errors.New("required credentials not found")
View Source
var ErrNotEnoughCredentials = &jsonschema.ValidationError{
Message: "unable to remove this security key because it would lock you out of your account", InstancePtr: "#/webauthn_remove"}
Functions ¶
func NewWebAuthnLoginInput ¶
func NewWebAuthnLoginTrigger ¶
func NewWebAuthnUnlink ¶
func NewWebAuthnUnlink(c *identity.CredentialWebAuthn) *node.Node
Types ¶
type Strategy ¶
type Strategy struct {
// contains filtered or unexported fields
}
func NewStrategy ¶
func (*Strategy) CompletedAuthenticationMethod ¶
func (s *Strategy) CompletedAuthenticationMethod(ctx context.Context, _ session.AuthenticationMethods) session.AuthenticationMethod
func (*Strategy) CountActiveFirstFactorCredentials ¶
func (s *Strategy) CountActiveFirstFactorCredentials(cc map[identity.CredentialsType]identity.Credentials) (count int, err error)
func (*Strategy) CountActiveMultiFactorCredentials ¶
func (s *Strategy) CountActiveMultiFactorCredentials(cc map[identity.CredentialsType]identity.Credentials) (count int, err error)
func (*Strategy) ID ¶
func (s *Strategy) ID() identity.CredentialsType
func (*Strategy) NodeGroup ¶
func (s *Strategy) NodeGroup() node.UiNodeGroup
func (*Strategy) PopulateLoginMethod ¶
func (*Strategy) PopulateRegistrationMethod ¶
func (*Strategy) PopulateSettingsMethod ¶
func (*Strategy) Register ¶
func (s *Strategy) Register(w http.ResponseWriter, r *http.Request, f *registration.Flow, i *identity.Identity) (err error)
func (*Strategy) RegisterLoginRoutes ¶
func (s *Strategy) RegisterLoginRoutes(r *x.RouterPublic)
swagger:route GET /.well-known/ory/webauthn.js frontend getWebAuthnJavaScript
Get WebAuthn JavaScript ¶
This endpoint provides JavaScript which is needed in order to perform WebAuthn login and registration.
If you are building a JavaScript Browser App (e.g. in ReactJS or AngularJS) you will need to load this file:
```html <script src="https://public-kratos.example.org/.well-known/ory/webauthn.js" type="script" async /> ```
More information can be found at [Ory Kratos User Login](https://www.ory.sh/docs/kratos/self-service/flows/user-login) and [User Registration Documentation](https://www.ory.sh/docs/kratos/self-service/flows/user-registration).
Produces: - text/javascript Schemes: http, https Responses: 200: webAuthnJavaScript
func (*Strategy) RegisterRegistrationRoutes ¶
func (s *Strategy) RegisterRegistrationRoutes(_ *x.RouterPublic)
func (*Strategy) RegisterSettingsRoutes ¶
func (s *Strategy) RegisterSettingsRoutes(_ *x.RouterPublic)
func (*Strategy) SettingsStrategyID ¶
type User ¶ added in v0.13.0
type User struct {
// contains filtered or unexported fields
}
func (*User) WebAuthnCredentials ¶ added in v0.13.0
func (u *User) WebAuthnCredentials() []webauthn.Credential
func (*User) WebAuthnDisplayName ¶ added in v0.13.0
func (*User) WebAuthnID ¶ added in v0.13.0
func (*User) WebAuthnIcon ¶ added in v0.13.0
func (*User) WebAuthnName ¶ added in v0.13.0
Click to show internal directories.
Click to hide internal directories.