MCPcopy Create free account
hub / github.com/ContainerSSH/ContainerSSH / AuthConfig

Struct AuthConfig

config/auth.go:13–51  ·  view source on GitHub ↗

AuthConfig is the configuration of the authentication client.

Source from the content-addressed store, hash-verified

11
12// AuthConfig is the configuration of the authentication client.
13type AuthConfig struct {
14 // PasswordAuth configures how users are authenticated with passwords. If not set, password authentication is
15 // disabled.
16 PasswordAuth PasswordAuthConfig `json:"password" yaml:"password"`
17
18 // PublicKeyAuth configures how users are authenticated with their public keys. If not set, public key
19 // authentication is disabled.
20 PublicKeyAuth PublicKeyAuthConfig `json:"publicKey" yaml:"publicKey"`
21
22 // KeyboardInteractiveAuth configures how users are authenticated using the keyboard-interactive (question-answer)
23 // method. If this is empty, keyboard-interactive is disabled.
24 KeyboardInteractiveAuth KeyboardInteractiveAuthConfig `json:"keyboardInteractive" yaml:"keyboardInteractive"`
25
26 // GSSAPIAuth configures how users are authenticated using the GSSAPI (typically Kerberos) method. If this is empty,
27 // GSSAPI authentication is disabled.
28 GSSAPIAuth GSSAPIAuthConfig `json:"gssapi" yaml:"gssapi"`
29
30 // Authz is the authorization configuration. The authorization server will receive a webhook after successful user
31 // authentication to determine whether the specified user has access to the service. If not set authorization is
32 // disabled. It is strongly recommended you configure AuthZ in case of oAuth2 and GSSAPI methods as these methods
33 // do not verify the provided SSH username.
34 Authz AuthzConfig `json:"authz" yaml:"authz"`
35
36 // AuthTimeout is the timeout for the overall authentication call (e.g. verifying a password). If the server
37 // responds with a non-200 response the call will be retried until this timeout is reached. This timeout
38 // should be increased to ~180s for OAuth2 login.
39 // Deprecated: please use the individual authentication methods instead.
40 AuthTimeout time.Duration `json:"authTimeout" yaml:"authTimeout" default:"60s"`
41
42 // Deprecated: please use the individual authentication configurations instead.
43 HTTPClientConfiguration `json:",inline" yaml:",inline"`
44
45 // Password is a flag to enable password authentication.
46 // Deprecated: use PasswordAuth instead.
47 Password *bool `json:"-" yaml:"-" comment:"Perform password authentication" default:"true"`
48 // PubKey is a flag to enable public key authentication.
49 // Deprecated: use PublicKeyAuth instead.
50 PubKey *bool `json:"pubkey" yaml:"pubkey" comment:"Perform public key authentication" default:"true"`
51}
52
53type legacyAuthConfig struct {
54 PasswordAuth PasswordAuthConfig `json:"-" yaml:"-"`

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected