Documentation ¶
Index ¶
- Constants
- func GetVersionBlobFromFile(filename string) ([]byte, error)
- type Bootloader
- func (b *Bootloader) Boot(partition int) error
- func (b *Bootloader) CheckImage(partition int) (uint32, error)
- func (b *Bootloader) GetRandom() (uint32, error)
- func (b *Bootloader) GetSecureCounter() (uint32, error)
- func (b *Bootloader) GetVersionBlob(partition int) ([]byte, error)
- func (b *Bootloader) LoadImage(filename string, partition int) error
- func (b *Bootloader) SetAddress(addr uint8) error
- func (b *Bootloader) SetSecure() error
- type Error
Constants ¶
View Source
const ErrorBadAlignment = Error("Bad Alignment")
View Source
const ErrorBlobMismatch = Error("Signed and unsigned blob don't match")
View Source
const ErrorBootFailed = Error("Boot failed")
View Source
const ErrorDowngradeNotAllowed = Error("Downgrade rejected")
View Source
const ErrorHeaderSizeInvalid = Error("Invalid header size")
View Source
const ErrorHeaderVersionUnknown = Error("Unkown header version")
View Source
const ErrorImageEncryptionMissing = Error("Encryption Missing")
View Source
const ErrorImageHashInvalid = Error("Image hash invalid")
View Source
const ErrorImageHashMissing = Error("Image hash missing")
View Source
const ErrorImageSignatureInvalid = Error("Image signature invalid")
View Source
const ErrorImageSignatureLengthInvalid = Error("Image signature length invalid")
View Source
const ErrorImageSignatureMissing = Error("Image signature missing")
View Source
const ErrorImageTooLarge = Error("Image too large")
View Source
const ErrorParitionDoesNotExist = Error("Partition does not exist")
View Source
const ErrorReadFailed = Error("Read failed")
View Source
const ErrorUnsupportedResult = Error("Unsupported result")
View Source
const ErrorWrongParition = Error("Wrong partition")
View Source
const ErrrorProtocol = Error("Protocol error")
Variables ¶
This section is empty.
Functions ¶
func GetVersionBlobFromFile ¶
Types ¶
type Bootloader ¶
type Bootloader struct {
// contains filtered or unexported fields
}
func NewBootloader ¶
func NewBootloader(device *serialpacket.Device) *Bootloader
func (*Bootloader) Boot ¶
func (b *Bootloader) Boot(partition int) error
func (*Bootloader) CheckImage ¶
func (b *Bootloader) CheckImage(partition int) (uint32, error)
func (*Bootloader) GetRandom ¶
func (b *Bootloader) GetRandom() (uint32, error)
func (*Bootloader) GetSecureCounter ¶
func (b *Bootloader) GetSecureCounter() (uint32, error)
func (*Bootloader) GetVersionBlob ¶
func (b *Bootloader) GetVersionBlob(partition int) ([]byte, error)
func (*Bootloader) SetAddress ¶
func (b *Bootloader) SetAddress(addr uint8) error
func (*Bootloader) SetSecure ¶
func (b *Bootloader) SetSecure() error
Click to show internal directories.
Click to hide internal directories.