Versions in this module Expand all Collapse all v0 v0.1.0 Nov 12, 2022 v0.0.1 Nov 10, 2022 Changes in this version + const MaxBodySize + const MaxHeadersSize + const MaxSignatureSize + const MediaType + const RevisionNotKnown + var AccountKeyRequestType = &AssertionType + var AccountKeyType = &AssertionType + var AccountType = &AssertionType + var AlwaysMatchAttributes = &AttributeConstraints + var BaseDeclarationType = &AssertionType + var DefaultCheckers = []Checker + var DeviceSessionRequestType = &AssertionType + var ErrUnknownPoolGroup = errors.New("unknown pool group") + var ErrUnresolved = errors.New("unresolved assertion") + var MetaHeaders = [...]string + var ModelType = &AssertionType + var NeverMatchAttributes = &AttributeConstraints + var PreseedType = &AssertionType + var RepairType = &AssertionType + var SerialRequestType = &AssertionType + var SerialType = &AssertionType + var SnapBuildType = &AssertionType + var SnapDeclarationType = &AssertionType + var SnapDeveloperType = &AssertionType + var SnapRevisionType = &AssertionType + var StoreType = &AssertionType + var SystemUserType = &AssertionType + var ValidationSetType = &AssertionType + var ValidationType = &AssertionType + func CheckCrossConsistency(assert Assertion, signingKey *AccountKey, roDB RODatabase, ...) error + func CheckSignature(assert Assertion, signingKey *AccountKey, roDB RODatabase, ...) (err error) + func CheckSigningKeyIsNotExpired(assert Assertion, signingKey *AccountKey, roDB RODatabase, ...) error + func CheckTimestampVsSigningKeyValidity(assert Assertion, signingKey *AccountKey, roDB RODatabase, ...) error + func Encode(assert Assertion) []byte + func EncodeDigest(hash crypto.Hash, hashDigest []byte) (string, error) + func EncodePublicKey(pubKey PublicKey) ([]byte, error) + func HeadersFromPrimaryKey(assertType *AssertionType, primaryKey []string) (headers map[string]string, err error) + func HeadersFromSequenceKey(assertType *AssertionType, sequenceKey []string) (headers map[string]string, err error) + func InitBuiltinBaseDeclaration(headers []byte) error + func IsKeyNotFound(err error) bool + func IsNotFound(err error) bool + func IsUnaccceptedUpdate(err error) bool + func IsValidAccountID(accountID string) bool + func IsValidAccountKeyName(name string) bool + func IsValidSystemLabel(label string) error + func IsValidValidationSetName(name string) bool + func MaxSupportedFormats(min int) (maxFormats map[string]int) + func MockMaxSupportedFormat(assertType *AssertionType, maxFormat int) (restore func()) + func MockOptionalPrimaryKey(assertType *AssertionType, key, defaultValue string) (restore func()) + func PrimaryKeyFromHeaders(assertType *AssertionType, headers map[string]string) (primaryKey []string, err error) + func ReducePrimaryKey(assertType *AssertionType, primaryKey []string) []string + func SignatureCheck(assert Assertion, pubKey PublicKey) error + func SnapFileSHA3_384(snapPath string) (digest string, size uint64, err error) + func SuggestFormat(assertType *AssertionType, headers map[string]interface{}, body []byte) (formatnum int, err error) + func TypeNames() []string + type Account struct + func (ab *Account) At() *AtRevision + func (ab *Account) AuthorityID() string + func (ab *Account) Body() []byte + func (ab *Account) Format() int + func (ab *Account) Header(name string) interface{} + func (ab *Account) HeaderString(name string) string + func (ab *Account) Headers() map[string]interface{} + func (ab *Account) Prerequisites() []*Ref + func (ab *Account) Ref() *Ref + func (ab *Account) Revision() int + func (ab *Account) SignKeyID() string + func (ab *Account) Signature() (content, signature []byte) + func (ab *Account) SupportedFormat() bool + func (ab *Account) Type() *AssertionType + func (acc *Account) AccountID() string + func (acc *Account) DisplayName() string + func (acc *Account) Timestamp() time.Time + func (acc *Account) Username() string + func (acc *Account) Validation() string + type AccountKey struct + func (ab *AccountKey) At() *AtRevision + func (ab *AccountKey) AuthorityID() string + func (ab *AccountKey) Body() []byte + func (ab *AccountKey) Format() int + func (ab *AccountKey) Header(name string) interface{} + func (ab *AccountKey) HeaderString(name string) string + func (ab *AccountKey) Headers() map[string]interface{} + func (ab *AccountKey) Ref() *Ref + func (ab *AccountKey) Revision() int + func (ab *AccountKey) SignKeyID() string + func (ab *AccountKey) Signature() (content, signature []byte) + func (ab *AccountKey) SupportedFormat() bool + func (ab *AccountKey) Type() *AssertionType + func (ak *AccountKey) AccountID() string + func (ak *AccountKey) Name() string + func (ak *AccountKey) Prerequisites() []*Ref + func (ak *AccountKey) PublicKeyID() string + func (ak *AccountKey) Since() time.Time + func (ak *AccountKey) Until() time.Time + type AccountKeyRequest struct + func (ab *AccountKeyRequest) At() *AtRevision + func (ab *AccountKeyRequest) AuthorityID() string + func (ab *AccountKeyRequest) Body() []byte + func (ab *AccountKeyRequest) Format() int + func (ab *AccountKeyRequest) Header(name string) interface{} + func (ab *AccountKeyRequest) HeaderString(name string) string + func (ab *AccountKeyRequest) Headers() map[string]interface{} + func (ab *AccountKeyRequest) Ref() *Ref + func (ab *AccountKeyRequest) Revision() int + func (ab *AccountKeyRequest) SignKeyID() string + func (ab *AccountKeyRequest) Signature() (content, signature []byte) + func (ab *AccountKeyRequest) SupportedFormat() bool + func (ab *AccountKeyRequest) Type() *AssertionType + func (akr *AccountKeyRequest) AccountID() string + func (akr *AccountKeyRequest) Name() string + func (akr *AccountKeyRequest) Prerequisites() []*Ref + func (akr *AccountKeyRequest) PublicKeyID() string + func (akr *AccountKeyRequest) Since() time.Time + func (akr *AccountKeyRequest) Until() time.Time + type Assertion interface + At func() *AtRevision + AuthorityID func() string + Body func() []byte + Format func() int + Header func(name string) interface{} + HeaderString func(name string) string + Headers func() map[string]interface{} + Prerequisites func() []*Ref + Ref func() *Ref + Revision func() int + SignKeyID func() string + Signature func() (content, signature []byte) + SupportedFormat func() bool + Type func() *AssertionType + func Assemble(headers map[string]interface{}, body, content, signature []byte) (Assertion, error) + func Decode(serializedAssertion []byte) (Assertion, error) + func SignWithoutAuthority(assertType *AssertionType, headers map[string]interface{}, body []byte, ...) (Assertion, error) + type AssertionType struct + Name string + OptionalPrimaryKeyDefaults map[string]string + PrimaryKey []string + func Type(name string) *AssertionType + func (at *AssertionType) AcceptablePrimaryKey(key []string) bool + func (at *AssertionType) MaxSupportedFormat() int + func (at *AssertionType) SequenceForming() bool + type AtRevision struct + Revision int + func (at *AtRevision) String() string + type AtSequence struct + Pinned bool + Revision int + Sequence int + SequenceKey []string + Type *AssertionType + func (at *AtSequence) Resolve(...) (Assertion, error) + func (at *AtSequence) String() string + func (at *AtSequence) Unique() string + type AttrMatchContext interface + PlugAttr func(arg string) (interface{}, error) + SlotAttr func(arg string) (interface{}, error) + type Attrer interface + Lookup func(path string) (interface{}, bool) + type AttributeConstraints struct + func (c *AttributeConstraints) Check(attrer Attrer, helper AttrMatchContext) error + type Backstore interface + Get func(assertType *AssertionType, key []string, maxFormat int) (Assertion, error) + Put func(assertType *AssertionType, assert Assertion) error + Search func(assertType *AssertionType, headers map[string]string, foundCb func(Assertion), ...) error + SequenceMemberAfter func(assertType *AssertionType, sequenceKey []string, after, maxFormat int) (SequenceMember, error) + func NewMemoryBackstore() Backstore + func OpenFSBackstore(path string) (Backstore, error) + type BaseDeclaration struct + func BuiltinBaseDeclaration() *BaseDeclaration + func (ab *BaseDeclaration) At() *AtRevision + func (ab *BaseDeclaration) AuthorityID() string + func (ab *BaseDeclaration) Body() []byte + func (ab *BaseDeclaration) Format() int + func (ab *BaseDeclaration) Header(name string) interface{} + func (ab *BaseDeclaration) HeaderString(name string) string + func (ab *BaseDeclaration) Headers() map[string]interface{} + func (ab *BaseDeclaration) Prerequisites() []*Ref + func (ab *BaseDeclaration) Ref() *Ref + func (ab *BaseDeclaration) Revision() int + func (ab *BaseDeclaration) SignKeyID() string + func (ab *BaseDeclaration) Signature() (content, signature []byte) + func (ab *BaseDeclaration) SupportedFormat() bool + func (ab *BaseDeclaration) Type() *AssertionType + func (basedcl *BaseDeclaration) PlugRule(interfaceName string) *PlugRule + func (basedcl *BaseDeclaration) Series() string + func (basedcl *BaseDeclaration) SlotRule(interfaceName string) *SlotRule + func (basedcl *BaseDeclaration) Timestamp() time.Time + type Batch struct + func NewBatch(unsupported func(u *Ref, err error) error) *Batch + func (b *Batch) Add(a Assertion) error + func (b *Batch) AddStream(r io.Reader) ([]*Ref, error) + func (b *Batch) CommitTo(db *Database, opts *CommitOptions) error + func (b *Batch) CommitToAndObserve(db *Database, observe func(Assertion), opts *CommitOptions) error + func (b *Batch) Fetch(trustedDB RODatabase, retrieve func(*Ref) (Assertion, error), ...) error + type Checker func(assert Assertion, signingKey *AccountKey, roDB RODatabase, ...) error + type CommitOptions struct + Precheck bool + type Database struct + func OpenDatabase(cfg *DatabaseConfig) (*Database, error) + func (db *Database) Add(assert Assertion) error + func (db *Database) Check(assert Assertion) error + func (db *Database) Find(assertionType *AssertionType, headers map[string]string) (Assertion, error) + func (db *Database) FindMany(assertionType *AssertionType, headers map[string]string) ([]Assertion, error) + func (db *Database) FindManyPredefined(assertionType *AssertionType, headers map[string]string) ([]Assertion, error) + func (db *Database) FindMaxFormat(assertionType *AssertionType, headers map[string]string, maxFormat int) (Assertion, error) + func (db *Database) FindPredefined(assertionType *AssertionType, headers map[string]string) (Assertion, error) + func (db *Database) FindSequence(assertType *AssertionType, sequenceHeaders map[string]string, ...) (SequenceMember, error) + func (db *Database) FindTrusted(assertionType *AssertionType, headers map[string]string) (Assertion, error) + func (db *Database) ImportKey(privKey PrivateKey) error + func (db *Database) IsTrustedAccount(accountID string) bool + func (db *Database) PublicKey(keyID string) (PublicKey, error) + func (db *Database) SetEarliestTime(earliest time.Time) + func (db *Database) Sign(assertType *AssertionType, headers map[string]interface{}, body []byte, ...) (Assertion, error) + func (db *Database) WithStackedBackstore(backstore Backstore) *Database + type DatabaseConfig struct + Backstore Backstore + Checkers []Checker + KeypairManager KeypairManager + OtherPredefined []Assertion + Trusted []Assertion + type Decoder struct + func NewDecoder(r io.Reader) *Decoder + func NewDecoderWithTypeMaxBodySize(r io.Reader, typeMaxBodySize map[*AssertionType]int) *Decoder + func (d *Decoder) Decode() (Assertion, error) + type DeviceScopeConstraint struct + Brand []string + Model []string + Store []string + func (c *DeviceScopeConstraint) Check(model *Model, store *Store, opts *DeviceScopeConstraintCheckOptions) error + type DeviceScopeConstraintCheckOptions struct + UseFriendlyStores bool + type DeviceSessionRequest struct + func (ab *DeviceSessionRequest) At() *AtRevision + func (ab *DeviceSessionRequest) AuthorityID() string + func (ab *DeviceSessionRequest) Body() []byte + func (ab *DeviceSessionRequest) Format() int + func (ab *DeviceSessionRequest) Header(name string) interface{} + func (ab *DeviceSessionRequest) HeaderString(name string) string + func (ab *DeviceSessionRequest) Headers() map[string]interface{} + func (ab *DeviceSessionRequest) Prerequisites() []*Ref + func (ab *DeviceSessionRequest) Ref() *Ref + func (ab *DeviceSessionRequest) Revision() int + func (ab *DeviceSessionRequest) SignKeyID() string + func (ab *DeviceSessionRequest) Signature() (content, signature []byte) + func (ab *DeviceSessionRequest) SupportedFormat() bool + func (ab *DeviceSessionRequest) Type() *AssertionType + func (req *DeviceSessionRequest) BrandID() string + func (req *DeviceSessionRequest) Model() string + func (req *DeviceSessionRequest) Nonce() string + func (req *DeviceSessionRequest) Serial() string + func (req *DeviceSessionRequest) Timestamp() time.Time + type Encoder struct + func NewEncoder(w io.Writer) *Encoder + func (enc *Encoder) Encode(assert Assertion) error + func (enc *Encoder) WriteContentSignature(content, signature []byte) error + func (enc *Encoder) WriteEncoded(encoded []byte) error + type ExternalKeyInfo struct + ID string + Name string + type ExternalKeypairManager struct + func NewExternalKeypairManager(keyMgrPath string) (*ExternalKeypairManager, error) + func (em *ExternalKeypairManager) Delete(keyID string) error + func (em *ExternalKeypairManager) DeleteByName(keyName string) error + func (em *ExternalKeypairManager) Export(keyName string) ([]byte, error) + func (em *ExternalKeypairManager) Generate(keyName string) error + func (em *ExternalKeypairManager) Get(keyID string) (PrivateKey, error) + func (em *ExternalKeypairManager) GetByName(keyName string) (PrivateKey, error) + func (em *ExternalKeypairManager) List() ([]ExternalKeyInfo, error) + func (em *ExternalKeypairManager) Put(privKey PrivateKey) error + type ExternalUnsupportedOpError struct + func (euoe *ExternalUnsupportedOpError) Error() string + type Fetcher interface + Fetch func(*Ref) error + Save func(Assertion) error + func NewFetcher(trustedDB RODatabase, retrieve func(*Ref) (Assertion, error), ...) Fetcher + type GPGKeypairManager struct + func NewGPGKeypairManager() *GPGKeypairManager + func (gkm *GPGKeypairManager) Delete(keyID string) error + func (gkm *GPGKeypairManager) DeleteByName(name string) error + func (gkm *GPGKeypairManager) Export(name string) ([]byte, error) + func (gkm *GPGKeypairManager) Generate(passphrase string, name string) error + func (gkm *GPGKeypairManager) Get(keyID string) (PrivateKey, error) + func (gkm *GPGKeypairManager) GetByName(name string) (PrivateKey, error) + func (gkm *GPGKeypairManager) List() (res []ExternalKeyInfo, err error) + func (gkm *GPGKeypairManager) Put(privKey PrivateKey) error + func (gkm *GPGKeypairManager) Walk(consider func(privk PrivateKey, fingerprint string, uid string) error) error + type Grouping string + type KeypairManager interface + Delete func(keyID string) error + Get func(keyID string) (PrivateKey, error) + Put func(privKey PrivateKey) error + func NewMemoryKeypairManager() KeypairManager + func OpenFSKeypairManager(path string) (KeypairManager, error) + type Model struct + func (ab *Model) At() *AtRevision + func (ab *Model) AuthorityID() string + func (ab *Model) Body() []byte + func (ab *Model) Format() int + func (ab *Model) Header(name string) interface{} + func (ab *Model) HeaderString(name string) string + func (ab *Model) Headers() map[string]interface{} + func (ab *Model) Prerequisites() []*Ref + func (ab *Model) Ref() *Ref + func (ab *Model) Revision() int + func (ab *Model) SignKeyID() string + func (ab *Model) Signature() (content, signature []byte) + func (ab *Model) SupportedFormat() bool + func (ab *Model) Type() *AssertionType + func (mod *Model) Architecture() string + func (mod *Model) Base() string + func (mod *Model) BaseSnap() *ModelSnap + func (mod *Model) BrandID() string + func (mod *Model) Classic() bool + func (mod *Model) DisplayName() string + func (mod *Model) Distribution() string + func (mod *Model) EssentialSnaps() []*ModelSnap + func (mod *Model) Gadget() string + func (mod *Model) GadgetSnap() *ModelSnap + func (mod *Model) GadgetTrack() string + func (mod *Model) Grade() ModelGrade + func (mod *Model) Kernel() string + func (mod *Model) KernelSnap() *ModelSnap + func (mod *Model) KernelTrack() string + func (mod *Model) Model() string + func (mod *Model) RequiredNoEssentialSnaps() []naming.SnapRef + func (mod *Model) RequiredWithEssentialSnaps() []naming.SnapRef + func (mod *Model) SerialAuthority() []string + func (mod *Model) Series() string + func (mod *Model) SnapsWithoutEssential() []*ModelSnap + func (mod *Model) StorageSafety() StorageSafety + func (mod *Model) Store() string + func (mod *Model) SystemUserAuthority() []string + func (mod *Model) Timestamp() time.Time + type ModelGrade string + const ModelDangerous + const ModelGradeUnset + const ModelSecured + const ModelSigned + func (mg ModelGrade) Code() uint32 + type ModelSnap struct + Classic bool + DefaultChannel string + Modes []string + Name string + PinnedTrack string + Presence string + SnapID string + SnapType string + func (s *ModelSnap) ID() string + func (s *ModelSnap) SnapName() string + type NameConstraints struct + func (nc *NameConstraints) Check(whichName, name string, special map[string]string) error + type NotFoundError struct + Headers map[string]string + Type *AssertionType + func (e *NotFoundError) Error() string + func (e *NotFoundError) Is(err error) bool + type OnClassicConstraint struct + Classic bool + SystemIDs []string + type PlugConnectionConstraints struct + DeviceScope *DeviceScopeConstraint + OnClassic *OnClassicConstraint + PlugAttributes *AttributeConstraints + PlugNames *NameConstraints + PlugsPerSlot SideArityConstraint + SlotAttributes *AttributeConstraints + SlotNames *NameConstraints + SlotPublisherIDs []string + SlotSnapIDs []string + SlotSnapTypes []string + SlotsPerPlug SideArityConstraint + type PlugInstallationConstraints struct + DeviceScope *DeviceScopeConstraint + OnClassic *OnClassicConstraint + PlugAttributes *AttributeConstraints + PlugNames *NameConstraints + PlugSnapIDs []string + PlugSnapTypes []string + type PlugRule struct + AllowAutoConnection []*PlugConnectionConstraints + AllowConnection []*PlugConnectionConstraints + AllowInstallation []*PlugInstallationConstraints + DenyAutoConnection []*PlugConnectionConstraints + DenyConnection []*PlugConnectionConstraints + DenyInstallation []*PlugInstallationConstraints + Interface string + type Pool struct + func NewPool(groundDB RODatabase, n int) *Pool + func (p *Pool) Add(a Assertion, grouping Grouping) (ok bool, err error) + func (p *Pool) AddBatch(b *Batch, grouping Grouping) (ok bool, err error) + func (p *Pool) AddError(e error, ref *Ref) error + func (p *Pool) AddGroupingError(e error, grouping Grouping) error + func (p *Pool) AddSequenceError(e error, atSeq *AtSequence) error + func (p *Pool) AddSequenceToUpdate(toUpdate *AtSequence, group string) error + func (p *Pool) AddToUpdate(toUpdate *Ref, group string) error + func (p *Pool) AddUnresolved(unresolved *AtRevision, group string) error + func (p *Pool) AddUnresolvedSequence(unresolved *AtSequence, group string) error + func (p *Pool) Backstore() Backstore + func (p *Pool) ClearGroups() error + func (p *Pool) CommitTo(db *Database) error + func (p *Pool) Err(group string) error + func (p *Pool) Errors() map[string]error + func (p *Pool) Singleton(group string) (Grouping, error) + func (p *Pool) ToResolve() (map[Grouping][]*AtRevision, map[Grouping][]*AtSequence, error) + type Preseed struct + func (ab *Preseed) At() *AtRevision + func (ab *Preseed) AuthorityID() string + func (ab *Preseed) Body() []byte + func (ab *Preseed) Format() int + func (ab *Preseed) Header(name string) interface{} + func (ab *Preseed) HeaderString(name string) string + func (ab *Preseed) Headers() map[string]interface{} + func (ab *Preseed) Prerequisites() []*Ref + func (ab *Preseed) Ref() *Ref + func (ab *Preseed) Revision() int + func (ab *Preseed) SignKeyID() string + func (ab *Preseed) Signature() (content, signature []byte) + func (ab *Preseed) SupportedFormat() bool + func (ab *Preseed) Type() *AssertionType + func (p *Preseed) ArtifactSHA3_384() string + func (p *Preseed) BrandID() string + func (p *Preseed) Model() string + func (p *Preseed) Series() string + func (p *Preseed) Snaps() []*PreseedSnap + func (p *Preseed) SystemLabel() string + func (p *Preseed) Timestamp() time.Time + type PreseedSnap struct + Name string + Revision int + SnapID string + func (s *PreseedSnap) ID() string + func (s *PreseedSnap) SnapName() string + type Presence string + const PresenceInvalid + const PresenceOptional + const PresenceRequired + type PrivateKey interface + PublicKey func() PublicKey + func GenerateKey() (PrivateKey, error) + func RSAPrivateKey(privk *rsa.PrivateKey) PrivateKey + type PublicKey interface + ID func() string + func DecodePublicKey(pubKey []byte) (PublicKey, error) + func RSAPublicKey(pubKey *rsa.PublicKey) PublicKey + type RODatabase interface + Check func(assert Assertion) error + Find func(assertionType *AssertionType, headers map[string]string) (Assertion, error) + FindMany func(assertionType *AssertionType, headers map[string]string) ([]Assertion, error) + FindManyPredefined func(assertionType *AssertionType, headers map[string]string) ([]Assertion, error) + FindPredefined func(assertionType *AssertionType, headers map[string]string) (Assertion, error) + FindSequence func(assertType *AssertionType, sequenceHeaders map[string]string, ...) (SequenceMember, error) + FindTrusted func(assertionType *AssertionType, headers map[string]string) (Assertion, error) + IsTrustedAccount func(accountID string) bool + type Ref struct + PrimaryKey []string + Type *AssertionType + func (ref *Ref) Resolve(...) (Assertion, error) + func (ref *Ref) String() string + func (ref *Ref) Unique() string + type Repair struct + func (ab *Repair) At() *AtRevision + func (ab *Repair) AuthorityID() string + func (ab *Repair) Body() []byte + func (ab *Repair) Format() int + func (ab *Repair) Header(name string) interface{} + func (ab *Repair) HeaderString(name string) string + func (ab *Repair) Headers() map[string]interface{} + func (ab *Repair) Prerequisites() []*Ref + func (ab *Repair) Ref() *Ref + func (ab *Repair) Revision() int + func (ab *Repair) SignKeyID() string + func (ab *Repair) Signature() (content, signature []byte) + func (ab *Repair) SupportedFormat() bool + func (ab *Repair) Type() *AssertionType + func (r *Repair) Architectures() []string + func (r *Repair) Bases() []string + func (r *Repair) BrandID() string + func (r *Repair) Disabled() bool + func (r *Repair) Models() []string + func (r *Repair) Modes() []string + func (r *Repair) RepairID() int + func (r *Repair) Sequence() int + func (r *Repair) Series() []string + func (r *Repair) Summary() string + func (r *Repair) Timestamp() time.Time + type RevisionAuthority struct + AccountID string + DeviceScope *DeviceScopeConstraint + MaxRevision int + MinRevision int + Provenance []string + func (ra *RevisionAuthority) Check(rev *SnapRevision, model *Model, store *Store) error + type RevisionError struct + Current int + Used int + func (e *RevisionError) Error() string + type SequenceMember interface + Sequence func() int + type Serial struct + func (ab *Serial) At() *AtRevision + func (ab *Serial) AuthorityID() string + func (ab *Serial) Body() []byte + func (ab *Serial) Format() int + func (ab *Serial) Header(name string) interface{} + func (ab *Serial) HeaderString(name string) string + func (ab *Serial) Headers() map[string]interface{} + func (ab *Serial) Prerequisites() []*Ref + func (ab *Serial) Ref() *Ref + func (ab *Serial) Revision() int + func (ab *Serial) SignKeyID() string + func (ab *Serial) Signature() (content, signature []byte) + func (ab *Serial) SupportedFormat() bool + func (ab *Serial) Type() *AssertionType + func (ser *Serial) BrandID() string + func (ser *Serial) DeviceKey() PublicKey + func (ser *Serial) Model() string + func (ser *Serial) Serial() string + func (ser *Serial) Timestamp() time.Time + type SerialRequest struct + func (ab *SerialRequest) At() *AtRevision + func (ab *SerialRequest) AuthorityID() string + func (ab *SerialRequest) Body() []byte + func (ab *SerialRequest) Format() int + func (ab *SerialRequest) Header(name string) interface{} + func (ab *SerialRequest) HeaderString(name string) string + func (ab *SerialRequest) Headers() map[string]interface{} + func (ab *SerialRequest) Prerequisites() []*Ref + func (ab *SerialRequest) Ref() *Ref + func (ab *SerialRequest) Revision() int + func (ab *SerialRequest) SignKeyID() string + func (ab *SerialRequest) Signature() (content, signature []byte) + func (ab *SerialRequest) SupportedFormat() bool + func (ab *SerialRequest) Type() *AssertionType + func (sreq *SerialRequest) BrandID() string + func (sreq *SerialRequest) DeviceKey() PublicKey + func (sreq *SerialRequest) Model() string + func (sreq *SerialRequest) RequestID() string + func (sreq *SerialRequest) Serial() string + type SideArityConstraint struct + N int + func (ac SideArityConstraint) Any() bool + type SlotConnectionConstraints struct + DeviceScope *DeviceScopeConstraint + OnClassic *OnClassicConstraint + PlugAttributes *AttributeConstraints + PlugNames *NameConstraints + PlugPublisherIDs []string + PlugSnapIDs []string + PlugSnapTypes []string + PlugsPerSlot SideArityConstraint + SlotAttributes *AttributeConstraints + SlotNames *NameConstraints + SlotsPerPlug SideArityConstraint + type SlotInstallationConstraints struct + DeviceScope *DeviceScopeConstraint + OnClassic *OnClassicConstraint + SlotAttributes *AttributeConstraints + SlotNames *NameConstraints + SlotSnapIDs []string + SlotSnapTypes []string + type SlotRule struct + AllowAutoConnection []*SlotConnectionConstraints + AllowConnection []*SlotConnectionConstraints + AllowInstallation []*SlotInstallationConstraints + DenyAutoConnection []*SlotConnectionConstraints + DenyConnection []*SlotConnectionConstraints + DenyInstallation []*SlotInstallationConstraints + Interface string + type SnapBuild struct + func (ab *SnapBuild) At() *AtRevision + func (ab *SnapBuild) AuthorityID() string + func (ab *SnapBuild) Body() []byte + func (ab *SnapBuild) Format() int + func (ab *SnapBuild) Header(name string) interface{} + func (ab *SnapBuild) HeaderString(name string) string + func (ab *SnapBuild) Headers() map[string]interface{} + func (ab *SnapBuild) Prerequisites() []*Ref + func (ab *SnapBuild) Ref() *Ref + func (ab *SnapBuild) Revision() int + func (ab *SnapBuild) SignKeyID() string + func (ab *SnapBuild) Signature() (content, signature []byte) + func (ab *SnapBuild) SupportedFormat() bool + func (ab *SnapBuild) Type() *AssertionType + func (snapbld *SnapBuild) Grade() string + func (snapbld *SnapBuild) SnapID() string + func (snapbld *SnapBuild) SnapSHA3_384() string + func (snapbld *SnapBuild) SnapSize() uint64 + func (snapbld *SnapBuild) Timestamp() time.Time + type SnapDeclaration struct + func (ab *SnapDeclaration) At() *AtRevision + func (ab *SnapDeclaration) AuthorityID() string + func (ab *SnapDeclaration) Body() []byte + func (ab *SnapDeclaration) Format() int + func (ab *SnapDeclaration) Header(name string) interface{} + func (ab *SnapDeclaration) HeaderString(name string) string + func (ab *SnapDeclaration) Headers() map[string]interface{} + func (ab *SnapDeclaration) Ref() *Ref + func (ab *SnapDeclaration) Revision() int + func (ab *SnapDeclaration) SignKeyID() string + func (ab *SnapDeclaration) Signature() (content, signature []byte) + func (ab *SnapDeclaration) SupportedFormat() bool + func (ab *SnapDeclaration) Type() *AssertionType + func (snapdcl *SnapDeclaration) Aliases() map[string]string + func (snapdcl *SnapDeclaration) AutoAliases() []string + func (snapdcl *SnapDeclaration) PlugRule(interfaceName string) *PlugRule + func (snapdcl *SnapDeclaration) Prerequisites() []*Ref + func (snapdcl *SnapDeclaration) PublisherID() string + func (snapdcl *SnapDeclaration) RefreshControl() []string + func (snapdcl *SnapDeclaration) RevisionAuthority(provenance string) []*RevisionAuthority + func (snapdcl *SnapDeclaration) Series() string + func (snapdcl *SnapDeclaration) SlotRule(interfaceName string) *SlotRule + func (snapdcl *SnapDeclaration) SnapID() string + func (snapdcl *SnapDeclaration) SnapName() string + func (snapdcl *SnapDeclaration) Timestamp() time.Time + type SnapDeveloper struct + func (ab *SnapDeveloper) At() *AtRevision + func (ab *SnapDeveloper) AuthorityID() string + func (ab *SnapDeveloper) Body() []byte + func (ab *SnapDeveloper) Format() int + func (ab *SnapDeveloper) Header(name string) interface{} + func (ab *SnapDeveloper) HeaderString(name string) string + func (ab *SnapDeveloper) Headers() map[string]interface{} + func (ab *SnapDeveloper) Ref() *Ref + func (ab *SnapDeveloper) Revision() int + func (ab *SnapDeveloper) SignKeyID() string + func (ab *SnapDeveloper) Signature() (content, signature []byte) + func (ab *SnapDeveloper) SupportedFormat() bool + func (ab *SnapDeveloper) Type() *AssertionType + func (snapdev *SnapDeveloper) Prerequisites() []*Ref + func (snapdev *SnapDeveloper) PublisherID() string + func (snapdev *SnapDeveloper) SnapID() string + type SnapRevision struct + func (ab *SnapRevision) At() *AtRevision + func (ab *SnapRevision) AuthorityID() string + func (ab *SnapRevision) Body() []byte + func (ab *SnapRevision) Format() int + func (ab *SnapRevision) Header(name string) interface{} + func (ab *SnapRevision) HeaderString(name string) string + func (ab *SnapRevision) Headers() map[string]interface{} + func (ab *SnapRevision) Ref() *Ref + func (ab *SnapRevision) Revision() int + func (ab *SnapRevision) SignKeyID() string + func (ab *SnapRevision) Signature() (content, signature []byte) + func (ab *SnapRevision) SupportedFormat() bool + func (ab *SnapRevision) Type() *AssertionType + func (snaprev *SnapRevision) DeveloperID() string + func (snaprev *SnapRevision) Prerequisites() []*Ref + func (snaprev *SnapRevision) Provenance() string + func (snaprev *SnapRevision) SnapID() string + func (snaprev *SnapRevision) SnapRevision() int + func (snaprev *SnapRevision) SnapSHA3_384() string + func (snaprev *SnapRevision) SnapSize() uint64 + func (snaprev *SnapRevision) Timestamp() time.Time + type StorageSafety string + const StorageSafetyEncrypted + const StorageSafetyPreferEncrypted + const StorageSafetyPreferUnencrypted + const StorageSafetyUnset + type Store struct + func (ab *Store) At() *AtRevision + func (ab *Store) AuthorityID() string + func (ab *Store) Body() []byte + func (ab *Store) Format() int + func (ab *Store) Header(name string) interface{} + func (ab *Store) HeaderString(name string) string + func (ab *Store) Headers() map[string]interface{} + func (ab *Store) Ref() *Ref + func (ab *Store) Revision() int + func (ab *Store) SignKeyID() string + func (ab *Store) Signature() (content, signature []byte) + func (ab *Store) SupportedFormat() bool + func (ab *Store) Type() *AssertionType + func (store *Store) FriendlyStores() []string + func (store *Store) Location() string + func (store *Store) OperatorID() string + func (store *Store) Prerequisites() []*Ref + func (store *Store) Store() string + func (store *Store) Timestamp() time.Time + func (store *Store) URL() *url.URL + type SystemUser struct + func (ab *SystemUser) At() *AtRevision + func (ab *SystemUser) AuthorityID() string + func (ab *SystemUser) Body() []byte + func (ab *SystemUser) Format() int + func (ab *SystemUser) Header(name string) interface{} + func (ab *SystemUser) HeaderString(name string) string + func (ab *SystemUser) Headers() map[string]interface{} + func (ab *SystemUser) Prerequisites() []*Ref + func (ab *SystemUser) Ref() *Ref + func (ab *SystemUser) Revision() int + func (ab *SystemUser) SignKeyID() string + func (ab *SystemUser) Signature() (content, signature []byte) + func (ab *SystemUser) SupportedFormat() bool + func (ab *SystemUser) Type() *AssertionType + func (su *SystemUser) BrandID() string + func (su *SystemUser) Email() string + func (su *SystemUser) ForcePasswordChange() bool + func (su *SystemUser) Models() []string + func (su *SystemUser) Name() string + func (su *SystemUser) Password() string + func (su *SystemUser) SSHKeys() []string + func (su *SystemUser) Serials() []string + func (su *SystemUser) Series() []string + func (su *SystemUser) Since() time.Time + func (su *SystemUser) Until() time.Time + func (su *SystemUser) UserExpiration() time.Time + func (su *SystemUser) Username() string + func (su *SystemUser) ValidAt(when time.Time) bool + type UnsupportedFormatError struct + Format int + Ref *Ref + Update bool + func (e *UnsupportedFormatError) Error() string + type Validation struct + func (ab *Validation) At() *AtRevision + func (ab *Validation) AuthorityID() string + func (ab *Validation) Body() []byte + func (ab *Validation) Format() int + func (ab *Validation) Header(name string) interface{} + func (ab *Validation) HeaderString(name string) string + func (ab *Validation) Headers() map[string]interface{} + func (ab *Validation) Ref() *Ref + func (ab *Validation) Revision() int + func (ab *Validation) SignKeyID() string + func (ab *Validation) Signature() (content, signature []byte) + func (ab *Validation) SupportedFormat() bool + func (ab *Validation) Type() *AssertionType + func (validation *Validation) ApprovedSnapID() string + func (validation *Validation) ApprovedSnapRevision() int + func (validation *Validation) Prerequisites() []*Ref + func (validation *Validation) Revoked() bool + func (validation *Validation) Series() string + func (validation *Validation) SnapID() string + func (validation *Validation) Timestamp() time.Time + type ValidationSet struct + func (ab *ValidationSet) At() *AtRevision + func (ab *ValidationSet) AuthorityID() string + func (ab *ValidationSet) Body() []byte + func (ab *ValidationSet) Format() int + func (ab *ValidationSet) Header(name string) interface{} + func (ab *ValidationSet) HeaderString(name string) string + func (ab *ValidationSet) Headers() map[string]interface{} + func (ab *ValidationSet) Prerequisites() []*Ref + func (ab *ValidationSet) Ref() *Ref + func (ab *ValidationSet) Revision() int + func (ab *ValidationSet) SignKeyID() string + func (ab *ValidationSet) Signature() (content, signature []byte) + func (ab *ValidationSet) SupportedFormat() bool + func (ab *ValidationSet) Type() *AssertionType + func (vs *ValidationSet) AccountID() string + func (vs *ValidationSet) Name() string + func (vs *ValidationSet) Sequence() int + func (vs *ValidationSet) Series() string + func (vs *ValidationSet) Snaps() []*ValidationSetSnap + func (vs *ValidationSet) Timestamp() time.Time + type ValidationSetSnap struct + Name string + Presence Presence + Revision int + SnapID string + func (s *ValidationSetSnap) ID() string + func (s *ValidationSetSnap) SnapName() string