request

package
v0.0.0-...-614d85d Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(httpRequest *http.Request) (*rbac.Request, *authz.Request, error)

Build creates rbac-request and authorization-request from a http request with authorization headers

func GetCustomerName

func GetCustomerName(r *http.Request) (string, error)

GetCustomerName returns customer name set in the http request header

func GetResources

func GetResources(r *http.Request) (bucketName string, keyPath string, err error)

GetResources returns the specific resourceIDs (bucket name and key path) in the http request

func GetS3Action

func GetS3Action(r *http.Request) (s3.ActionType, error)

GetS3Action returns the S3 action type specified in the header 'X-Action'

func GetUserAttributes

func GetUserAttributes(r *http.Request) (id string, groups []string)

GetUserAttributes returns userID and userGroups set in the http request headers

func ToAuthzAction

func ToAuthzAction(s3Action s3.ActionType) (authz.ActionType, error)

ToAuthzAction converts from S3Action type to ACL action type

Types

This section is empty.

Jump to

Keyboard shortcuts

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