Documentation ¶
Overview ¶
Copyright (c) 2021 Cisco Systems, Inc and its affiliates All Rights reserved
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
Cache represents a cache for storing token permissions locally to speed up security actions.
type Config ¶
type Config struct { SsoURL string // URL to User Management Service in your MSX environment. Cache Cache // Cache to use for local caching. TLS *tls.Config // TLS config to use on outgoing client. ClientID string // Credential to use when speaking to MSX. ClientSecret string // Credential to use when speaking to MSX. }
Config represents the config for performing Security on the targeted MSX environment.
func DefaultMsxSecurityConfig ¶
func DefaultMsxSecurityConfig() Config
DefaultMsxSecurityConfig returns a default config. Note this default is not secure and should not be used in a production environment.
type MsxSecurity ¶
func NewMsxSecurity ¶
func NewMsxSecurity(cfg Config) *MsxSecurity
NewMsxSecurity returns an MsxSecurity with default config set.
func (*MsxSecurity) HasPermission ¶
HasPermission will return true or false given an HTTP request and target permission.
Click to show internal directories.
Click to hide internal directories.