config

package
v0.0.1-alpha.1 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2024 License: Apache-2.0 Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attestation

type Attestation struct {
	AllowAttestorSelfCA bool     `yaml:"allow-attestor-self-ca" json:"allow_attestor_self_ca" mapstructure:"allow-attestor-self-ca"`
	AllowOpenEnrollment bool     `yaml:"allow-open-enrollment" json:"allow-open-enrollment" mapstructure:"allow-open-enrollment"`
	AllowedVerifiers    []string `yaml:"allowed-verifiers" json:"allowed_verifiers" mapstructure:"allowed-verifiers"`
	ClientCACert        string   `yaml:"client-ca-cert" json:"client_ca_cert" mapstructure:"client-ca-cert"`
	InsecurePort        int      `yaml:"insecure-port" json:"insecure_port" mapstructure:"insecure-port"`
	InsecureSkipVerify  bool     `yaml:"insecure-skip-verify" json:"insecure_skip_verify" mapstructure:"insecure-skip-verify"`
	TLSPort             int      `yaml:"tls-port" json:"tls_port" mapstructure:"tls-port"`
	QuotePCRs           []int32  `yaml:"quote-pcrs" json:"quote-pcrs" mapstructure:"quote-pcrs"`
}

type Identity

type Identity struct {
	SANS    *ca.SubjectAlternativeNames `yaml:"sans" json:"sans" mapstructure:"sans"`
	Subject ca.Subject                  `yaml:"subject" json:"subject" mapstructure:"subject"`
	Valid   int                         `yaml:"valid" json:"valid" mapstructure:"valid"`
}

type KeyValueEntity

type KeyValueEntity interface {
	SetID(id uint64)
	Identifier() uint64
}

type License

type License interface {
	Quota() int
}

type LicenseStruct

type LicenseStruct struct {
	// contains filtered or unexported fields
}

func (*LicenseStruct) Quota

func (license *LicenseStruct) Quota() int

type Server

type Server struct {
	ID             uint64
	IpAddress      string
	Hostname       string
	License        *LicenseStruct `yaml:"license" json:"license" mapstructure:"license"`
	ServiceRefs    []uint64       `yaml:"services" json:"services" mapstructure:"services"`
	KeyValueEntity `sql:"-" gorm:"-" yaml:"-" json:"-"`
}

func NewServer

func NewServer() *Server

func (*Server) AddServiceRef

func (server *Server) AddServiceRef(serviceID uint64)

func (*Server) GetLicense

func (server *Server) GetLicense() *LicenseStruct

func (*Server) GetServiceRefs

func (server *Server) GetServiceRefs() []uint64

func (*Server) Identifier

func (server *Server) Identifier() uint64

func (*Server) RemoveServiceRef

func (server *Server) RemoveServiceRef(serviceID uint64)

func (*Server) SetID

func (server *Server) SetID(id uint64)

func (*Server) SetLicense

func (server *Server) SetLicense(license *LicenseStruct)

func (*Server) SetServiceRefs

func (server *Server) SetServiceRefs(refs []uint64)

type WebService

type WebService struct {
	Certificate   Identity            `yaml:"certificate" json:"certificate" mapstructure:"certificate"`
	Home          string              `yaml:"home" json:"home" mapstructure:"home"`
	JWTExpiration int                 `yaml:"jwt-expiration" json:"jwt_expiration" mapstructure:"jwt-expiration"`
	Key           *keystore.KeyConfig `yaml:"key" json:"key" mapstructure:"key"`
	Port          int                 `yaml:"port" json:"port" mapstructure:"port"`
	TLSPort       int                 `yaml:"tls-port" json:"tls_port" mapstructure:"tls-port"`
}

Jump to

Keyboard shortcuts

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