Documentation ¶
Overview ¶
Package oidc is a generated GoMock package.
Index ¶
- type AuthResult
- type Authenticator
- type MockAuthenticator
- func (m *MockAuthenticator) Callback(ctx context.Context, expectedState, actualState, code string) (*AuthResult, error)
- func (m *MockAuthenticator) EXPECT() *MockAuthenticatorMockRecorder
- func (m *MockAuthenticator) Login(ctx context.Context) (string, string, error)
- func (m *MockAuthenticator) Logout(ctx context.Context) (string, error)
- type MockAuthenticatorMockRecorder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthResult ¶
AuthResult - OpenID ConnectによるID Token取得の結果
type Authenticator ¶
type Authenticator interface { // Login - OpenID Connect Providerへのredirect URLとstateを生成する Login(ctx context.Context) (redirectURL, state string, err error) // Logout - OpenID Connectでログアウトする Logout(ctx context.Context) (logoutURL string, err error) // Callback - 外部からのCallbackを検証する Callback(ctx context.Context, expectedState, actualState, code string) (*AuthResult, error) }
Authenticator - OpenID Connectによる認証を行う
func NewAuthenticator ¶
func NewAuthenticator(ctx context.Context, clientID, clientSecret, redirectURL, providerURL string, scopes []string) (Authenticator, error)
NewAuthenticator initializes an Authenticator
type MockAuthenticator ¶
type MockAuthenticator struct {
// contains filtered or unexported fields
}
MockAuthenticator is a mock of Authenticator interface.
func NewMockAuthenticator ¶
func NewMockAuthenticator(ctrl *gomock.Controller) *MockAuthenticator
NewMockAuthenticator creates a new mock instance.
func (*MockAuthenticator) Callback ¶
func (m *MockAuthenticator) Callback(ctx context.Context, expectedState, actualState, code string) (*AuthResult, error)
Callback mocks base method.
func (*MockAuthenticator) EXPECT ¶
func (m *MockAuthenticator) EXPECT() *MockAuthenticatorMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockAuthenticatorMockRecorder ¶
type MockAuthenticatorMockRecorder struct {
// contains filtered or unexported fields
}
MockAuthenticatorMockRecorder is the mock recorder for MockAuthenticator.
func (*MockAuthenticatorMockRecorder) Callback ¶
func (mr *MockAuthenticatorMockRecorder) Callback(ctx, expectedState, actualState, code interface{}) *gomock.Call
Callback indicates an expected call of Callback.
func (*MockAuthenticatorMockRecorder) Login ¶
func (mr *MockAuthenticatorMockRecorder) Login(ctx interface{}) *gomock.Call
Login indicates an expected call of Login.
func (*MockAuthenticatorMockRecorder) Logout ¶
func (mr *MockAuthenticatorMockRecorder) Logout(ctx interface{}) *gomock.Call
Logout indicates an expected call of Logout.
Click to show internal directories.
Click to hide internal directories.