middleware

package
v0.0.1-0...-ff937d3 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Copyright © 2022 Roberto Hidalgo <joao@un.rob.mx> SPDX-License-Identifier: Apache-2.0

Copyright © 2022 Roberto Hidalgo <joao@un.rob.mx> SPDX-License-Identifier: Apache-2.0

Index

Constants

View Source
const (
	ConfigPath = "1password"
)

Variables

View Source
var ErrorNoVaultProvided = fmt.Errorf("no vault has been specified, provide one reading from MOUNT/tree/VAULT/ITEM, or configure a default writing to MOUNT/1password")

Functions

func ListTrees

func ListTrees(client connect.Client, req *logical.Request, data *framework.FieldData) (*logical.Response, error)

func ReadConfig

func ReadConfig(ctx context.Context, req *logical.Request, data *framework.FieldData) (*logical.Response, error)

func ReadTree

func ReadTree(client connect.Client, req *logical.Request, data *framework.FieldData) (*logical.Response, error)

func WriteConfig

func WriteConfig(ctx context.Context, req *logical.Request, data *framework.FieldData) (*logical.Response, error)

Types

type Config

type Config struct {
	Host  string `json:"host"`
	Token string `json:"token"`
	Vault string `json:"vault"`
}

func ConfigFromStorage

func ConfigFromStorage(ctx context.Context, s logical.Storage) (*Config, error)

Jump to

Keyboard shortcuts

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