Documentation ¶
Index ¶
- func AnotherValidation(respWriter http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func CrendentialedDbInstance(fn, profile string) *dynamodb.DynamoDB
- func GetNodeSecret() (string, error)
- func GetPass() ([]byte, error)deprecated
- func GetSsmParam(s string) (string, error)
- func GetTokenHandler(dyn AuthDB) http.Handler
- func NewUser(credentialsFile, profile, username, role string, dyn AuthDB) error
- func SsmClient() *ssm.SSM
- func ValidNodeKey(respWriter http.ResponseWriter, req *http.Request, next http.HandlerFunc)
- func ValidateUser(request *http.Request, dyn AuthDB) error
- type AuthDB
- type NodeConfigurePost
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AnotherValidation ¶
func AnotherValidation(respWriter http.ResponseWriter, req *http.Request, next http.HandlerFunc)
AnotherValidation validates authorization tokens. Is poorly named and up for refactor as time permits
func CrendentialedDbInstance ¶
CrendentialedDbInstance returns an instance of dynamodb using an aws credential profile
func GetNodeSecret ¶
GetNodeSecret gets current node secret from ssm parameter store
func GetSsmParam ¶
GetSsmParam returns value of a named ssm parameter
func GetTokenHandler ¶
GetTokenHandler handles requests to get-token api endpoint
func SsmClient ¶
SsmClient returns an instance of ssm client with credentials provided by ec2 assumed role
func ValidNodeKey ¶
func ValidNodeKey(respWriter http.ResponseWriter, req *http.Request, next http.HandlerFunc)
Types ¶
type AuthDB ¶
type AuthDB interface { NewUser(u osquery_types.User) error GetUser(username string) (osquery_types.User, error) ValidNode(nodeKey string) error }
type NodeConfigurePost ¶
type NodeConfigurePost struct { EnrollSecret string `json:"enroll_secret"` NodeKey string `json:"node_key"` HostIdentifier string `json:"host_identifier"` }
NodeConfigurePost type for handling post requests made by node
Click to show internal directories.
Click to hide internal directories.