Documentation
¶
Index ¶
- func GenDIDKey() (did string, privateKey jwk.Key, err error)
- func GenerateRandomKey(length int) []byte
- func LookupEnvOrString(key string, defaultVal string) string
- func PubKeyToDIDKey(pubKeyJWK jwk.Key) (did string, err error)
- func Render(ctx echo.Context, statusCode int, t templ.Component) error
- func RequireAdminOrX509Auth() echo.MiddlewareFunc
- type Config
- type IssuerServer
- type SMTPConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateRandomKey ¶
func LookupEnvOrString ¶
LookupEnvOrString gets a value from the environment or returns the specified default value
func Render ¶
This custom Render replaces Echo's echo.Context.Render() with templ's templ.Component.Render().
func RequireAdminOrX509Auth ¶
func RequireAdminOrX509Auth() echo.MiddlewareFunc
RequireAdminOrX509Auth middleware requires a request to have a valid admin Authorization header or x509 client certification set.
Types ¶
type Config ¶
type Config struct { ListenAddress string `json:"listenAddress,omitempty"` AppName string `json:"appName,omitempty"` IssuerURL string `json:"issuerURL,omitempty"` IssuerCertificateURL string `json:"issuerCertificateURL,omitempty"` SenderName string `json:"senderName,omitempty"` SenderAddress string `json:"senderAddress,omitempty"` VerifierURL string `json:"verifierURL,omitempty"` CallbackPath string `json:"callbackPath,omitempty"` Scopes string `json:"scopes,omitempty"` AdminEmail string `json:"adminEmail,omitempty"` SMTP SMTPConfig `json:"smtp,omitempty"` SamedeviceWallet string `json:"samedeviceWallet,omitempty"` CredentialTemplatesDir string `json:"credentialTemplatesDir,omitempty"` ClientID string `json:"clientID,omitempty"` }
func (*Config) OverrideWith ¶
func (*Config) SetDefaults ¶
func (s *Config) SetDefaults()
type IssuerServer ¶
type IssuerServer struct { App *pocketbase.PocketBase // contains filtered or unexported fields }
func New ¶
func New(cfg *my.YAML) *IssuerServer
func (*IssuerServer) GeneralLoginScreen ¶
func (is *IssuerServer) GeneralLoginScreen(c echo.Context) error
func (*IssuerServer) LEARHomeHandler ¶
func (is *IssuerServer) LEARHomeHandler(c echo.Context) error
func (*IssuerServer) Start ¶
func (is *IssuerServer) Start() error
Start initializes the Issuer hooks and adds routes and spawns the server to handle them
Source Files
¶
Click to show internal directories.
Click to hide internal directories.