atlassiancrowd

package
v0.0.0-...-08e2f75 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 20, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package atlassiancrowd provides authentication strategies using Atlassian Crowd.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BaseURL      string   `json:"baseURL"`
	ClientID     string   `json:"clientID"`
	ClientSecret string   `json:"clientSecret"`
	Groups       []string `json:"groups"`

	// PreferredUsernameField allows users to set the field to any of the
	// following values: "key", "name" or "email".
	// If unset, the preferred_username field will remain empty.
	PreferredUsernameField string `json:"preferredUsernameField"`

	// UsernamePrompt allows users to override the username attribute (displayed
	// in the username/password prompt). If unset, the handler will use.
	// "Username".
	UsernamePrompt string `json:"usernamePrompt"`
}

Config holds configuration options for Atlassian Crowd connector. Crowd connectors require executing two queries, the first to find the user based on the username and password given to the connector. The second to use the user entry to search for groups.

An example config:

    type: atlassian-crowd
    config:
      baseURL: https://crowd.example.com/context
      clientID: applogin
      clientSecret: appP4$$w0rd
      # users can be restricted by a list of groups
      groups:
      - admin
      # Prompt for username field
      usernamePrompt: Login
		 preferredUsernameField: name

func (*Config) Open

func (c *Config) Open(_ string, logger log.Logger) (connector.Connector, error)

Open returns a strategy for logging in through Atlassian Crowd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL