Documentation
¶
Overview ¶
Package onboarding owns the manager's portable display enrollment state.
Index ¶
- Variables
- func MigrateV03(data, source, mobile, address string) error
- type Device
- type OfferDevice
- type Registry
- func (r *Registry) AcceptDevice(ctx context.Context, conn *tls.Conn, offer OfferDevice) error
- func (r *Registry) Device(id [16]byte) (Device, error)
- func (r *Registry) DeviceKey(id [16]byte) ([32]byte, error)
- func (r *Registry) Issue(name, endpoint string) (Device, bootstrap.Record, error)
- func (r *Registry) List() ([]Device, error)
- func (r *Registry) OnlyEnrolled() ([16]byte, error)
- func (r *Registry) Pending(id [16]byte) (bootstrap.Record, error)
- func (r *Registry) Redeem(id [16]byte, code, key [32]byte) error
- type Settings
Constants ¶
This section is empty.
Variables ¶
var ErrEnrollment = errors.New("enrollment unavailable")
Functions ¶
func MigrateV03 ¶
MigrateV03 publishes a complete private state directory in one rename. A failed import never makes partial state visible to serve.
Types ¶
type OfferDevice ¶
OfferDevice takes ownership of a successfully authenticated EPN2 connection.
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry serializes issue and redeem operations for a single manager volume. Each atomic record transitions from a pending bootstrap to a durable device key.
func OpenRegistry ¶
func (*Registry) AcceptDevice ¶
AcceptDevice accepts an optional EPQ1 bootstrap exchange before the existing EPN2 handshake. The caller retains ownership on error. Enrollment is complete only after Redeem durably commits; an ACK lost there is safe to retry.
func (*Registry) OnlyEnrolled ¶
OnlyEnrolled resolves the legacy single-screen API without guessing a target.
type Settings ¶
type Settings struct {
// contains filtered or unexported fields
}
Settings owns one manager's device endpoint and pinned TLS identity. A single manager process owns the volume. Readers see a complete generation.
func OpenSettings ¶
func (*Settings) PinnedEndpoint ¶
func (*Settings) SetAddress ¶
SetAddress keeps existing pins valid. A certificate for a different host requires explicit trust migration, never an implicit identity replacement.
func (*Settings) TLSCertificate ¶
func (s *Settings) TLSCertificate(_ *tls.ClientHelloInfo) (*tls.Certificate, error)
TLSCertificate can be installed as tls.Config.GetCertificate before the operator sets an address.