Documentation ¶
Overview ¶
Package devicestate implements the manager and state aspects responsible for the device identity and policies.
Index ¶
- func Model(st *state.State) (*asserts.Model, error)
- func Serial(st *state.State) (*asserts.Serial, error)
- type DeviceManager
- func (m *DeviceManager) DeviceSessionRequest(nonce string) (*asserts.DeviceSessionRequest, *asserts.Serial, error)
- func (m *DeviceManager) Ensure() error
- func (m *DeviceManager) Model() (*asserts.Model, error)
- func (m *DeviceManager) Serial() (*asserts.Serial, error)
- func (m *DeviceManager) Stop()
- func (m *DeviceManager) Wait()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DeviceManager ¶
type DeviceManager struct {
// contains filtered or unexported fields
}
DeviceManager is responsible for managing the device identity and device policies.
func Manager ¶
func Manager(s *state.State) (*DeviceManager, error)
Manager returns a new device manager.
func (*DeviceManager) DeviceSessionRequest ¶
func (m *DeviceManager) DeviceSessionRequest(nonce string) (*asserts.DeviceSessionRequest, *asserts.Serial, error)
DeviceSessionRequest produces a device-session-request with the given nonce, it also returns the device serial assertion.
func (*DeviceManager) Ensure ¶
func (m *DeviceManager) Ensure() error
Ensure implements StateManager.Ensure.
func (*DeviceManager) Model ¶
func (m *DeviceManager) Model() (*asserts.Model, error)
Model returns the device model assertion.
Click to show internal directories.
Click to hide internal directories.