Versions in this module Expand all Collapse all v0 v0.4.0 Nov 28, 2026 v0.3.4 Nov 26, 2026 v0.3.3 Nov 25, 2026 v0.3.2 Nov 25, 2026 v0.3.1 Nov 25, 2026 v0.3.0 Nov 23, 2026 v0.2.0 Nov 19, 2026 Changes in this version type Capabilities + AuthSession bool + BackgroundLocation bool + Location bool + Motion bool + Purchases bool + Secrets bool + SignInWithApple bool + TextToSpeech bool v0.1.0 Nov 16, 2026 Changes in this version + const RuntimeVersion + var ErrCertificate = errors.New("pkg: the release key's certificate does not cover the package") + var ErrExpired = errors.New("pkg: a trusted root's revocation list has expired or is missing") + var ErrFormat = errors.New("pkg: not a valid package") + var ErrIntegrity = errors.New("pkg: a file does not match its hash") + var ErrKey = errors.New("pkg: not a key") + var ErrRevoked = errors.New("pkg: revoked") + var ErrRollback = errors.New("pkg: older than a build accepted before") + var ErrRuntime = errors.New("pkg: the package needs a newer runtime") + var ErrSignature = errors.New("pkg: the signature does not verify") + var ErrStale = errors.New("pkg: the revocation list is not newer than the one held") + var ErrState = errors.New("pkg: the trust state") + var ErrUntrusted = errors.New("pkg: signed by a key that is not trusted") + func Build(contents Contents, key ed25519.PrivateKey, cert *Certificate) ([]byte, error) + func DecodePublicKey(text string) (ed25519.PublicKey, error) + func DecodeSecretKey(text string) (ed25519.PrivateKey, error) + func EncodePublicKey(key ed25519.PublicKey) string + func EncodeSecretKey(key ed25519.PrivateKey) string + func GenerateKey() (ed25519.PrivateKey, error) + func KeyID(key ed25519.PublicKey) string + func Resign(data []byte, key ed25519.PrivateKey, cert *Certificate) ([]byte, error) + type App struct + Build uint64 + ID string + Name string + Version string + type Capabilities struct + Audio bool + Biometrics bool + Clipboard bool + Host []string + Network *Network + Notifications bool + OpenURL *OpenURL + Picker bool + Speech bool + StatusBar bool + WebView *WebView + func ParseCapabilities(data []byte, strict bool) (c Capabilities, ignored []string, err error) + func (c *Capabilities) Allows(permission, resource, method string) bool + func (c *Capabilities) WebHosts() []string + type Certificate struct + func Certify(root ed25519.PrivateKey, release ed25519.PublicKey, apps []string, ...) (*Certificate, error) + func ParseCertificate(data []byte) (*Certificate, error) + func (c *Certificate) Info() (CertificateInfo, error) + func (c *Certificate) MarshalJSON() ([]byte, error) + func (c *Certificate) UnmarshalJSON(data []byte) error + type CertificateInfo struct + Apps []string + Key ed25519.PublicKey + NotAfter time.Time + NotBefore time.Time + Signer string + type Contents struct + App App + Capabilities Capabilities + MinRuntime string + Source string + type HTTPRule struct + Host string + Methods []string + PathPrefixes []string + Paths []string + Port int + Schemes []string + type Info struct + App App + Capabilities Capabilities + Certificate *Certificate + CreatedAt time.Time + Ignored []string + KeyID string + MinRuntime string + SHA256 string + func Inspect(data []byte) (*Info, error) + type Network struct + HTTP []HTTPRule + Hosts []string + type OpenURL struct + Schemes []string + type Package struct + ExpiredRevocations []string + func (p *Package) Source() string + type Revocations struct + func ParseRevocations(data []byte) (*Revocations, error) + func Revoke(root ed25519.PrivateKey, sequence uint64, notAfter time.Time, ...) (*Revocations, error) + func (r *Revocations) Info() (RevocationsInfo, error) + func (r *Revocations) MarshalJSON() ([]byte, error) + func (r *Revocations) UnmarshalJSON(data []byte) error + type RevocationsInfo struct + IssuedAt time.Time + Keys []string + NotAfter time.Time + Packages []string + Sequence uint64 + type Trust struct + func NewTrust() *Trust + func OpenTrust(dir string) (*Trust, error) + func (t *Trust) Accept(p *Package) error + func (t *Trust) AcceptedBuild(app string) (uint64, bool) + func (t *Trust) AddRoot(root ed25519.PublicKey) + func (t *Trust) RequireFreshRevocations(require bool) + func (t *Trust) UpdateRevocations(list *Revocations) error + func (t *Trust) Verify(data []byte) (*Package, error) + type WebView struct + Hosts []string + Input bool + Media []string