umcontroller

package
v0.0.0-...-2b5bdcb Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CertificateProvider

type CertificateProvider interface {
	GetCertificate(certType string, issuer []byte, serial string) (certURL, keyURL string, err error)
}

CertificateProvider certificate and key provider interface.

type Controller

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

Controller update managers controller.

func New

func New(config *config.Config, storage storage, certProvider CertificateProvider,
	cryptocontext *cryptutils.CryptoContext, decrypter Decrypter, insecure bool) (
	umCtrl *Controller, err error,
)

New creates new update managers controller.

func (*Controller) Close

func (umCtrl *Controller) Close()

Close close server.

func (*Controller) GetStatus

func (umCtrl *Controller) GetStatus() ([]cloudprotocol.ComponentStatus, error)

GetStatus returns list of system components information.

func (*Controller) UpdateComponents

func (umCtrl *Controller) UpdateComponents(
	components []cloudprotocol.ComponentInfo, chains []cloudprotocol.CertificateChain,
	certs []cloudprotocol.Certificate,
) ([]cloudprotocol.ComponentStatus, error)

UpdateComponents updates components.

type Decrypter

type Decrypter interface {
	DecryptAndValidate(encryptedFile, decryptedFile string, params fcrypt.DecryptParams) error
}

Decrypter interface to decrypt and validate image.

type SystemComponent

type SystemComponent struct {
	ID            string `json:"id"`
	VendorVersion string `json:"vendorVersion"`
	AosVersion    uint64 `json:"aosVersion"`
	Annotations   string `json:"annotations,omitempty"`
	URL           string `json:"url"`
	Sha256        []byte `json:"sha256"`
	Sha512        []byte `json:"sha512"`
	Size          uint64 `json:"size"`
}

SystemComponent information about system component update.

Jump to

Keyboard shortcuts

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