doryBackend

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2018 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DORY_ADMIN_TOKEN = golenv.OverrideIfEnv("DORY_ADMIN_TOKEN", "")
)

Functions

func DoryHelp

func DoryHelp(ctx *gin.Context)

doryHelp to serve help file for Dory.

func Wip

func Wip(ctx *gin.Context)

wip sets response handling at API Paths yet WIP.

Types

type ExitResponse

type ExitResponse struct {
	Msg  string `json:"exit-message"`
	Data []byte `json:"data,omitempty"`
}

ExitResponse is a struct to create custom JSON HTTP response.

func (ExitResponse) JSON

func (response ExitResponse) JSON() (jsonResponse []byte)

JSON returns []byte mapped json response of ExitResponse/

type LocalAuth

type LocalAuth struct {
	Cache doryMemory.DataStore
	Disk  doryMemory.DataStore
	Item  doryMemory.LocalAuth
}

LocalAuth is a struct to maintain connection details for a Local-Auth and single item construct for actions.

func NewLocalAuth

func NewLocalAuth(cacheName string) LocalAuth

NewLocalAuth instantiates and return a LocalAuth struct in reference to any usable secret backend.

func (LocalAuth) AuthMount

func (localAuth LocalAuth) AuthMount(ctx *gin.Context)

AuthMount stores a secret mapped with a new auth-path only at Local-Auth with unique auth-token.

func (LocalAuth) AuthUnmount

func (localAuth LocalAuth) AuthUnmount(ctx *gin.Context)

AuthUnmount purges a previously local-auth stored mapped to a auth-path if not yet purged by TTL.

func (LocalAuth) DoryPing

func (localAuth LocalAuth) DoryPing(ctx *gin.Context)

doryPing to return status for Dory

func (LocalAuth) Get

func (localAuth LocalAuth) Get(ctx *gin.Context)

Get fetchs required auth mapped secret from Local-Auth backend.

func (LocalAuth) List

func (localAuth LocalAuth) List(ctx *gin.Context)

List shows all keys registered with Dory for datatsore enquired.

func (LocalAuth) Purge

func (localAuth LocalAuth) Purge(ctx *gin.Context)

Purge removes all keys from datastore enquired, without decryption required.

func (LocalAuth) PurgeOne

func (localAuth LocalAuth) PurgeOne(ctx *gin.Context)

PurgeOne removes only one provided key from datastore enquired, without decryption required.

Jump to

Keyboard shortcuts

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