Documentation
¶
Overview ¶
Package service defines an MDM service
Index ¶
- func CheckinRequest(svc Checkin, r *mdm.Request, bodyBytes []byte) ([]byte, error)
- func CommandAndReportResultsRequest(svc CommandAndReportResults, r *mdm.Request, bodyBytes []byte) ([]byte, error)
- type Checkin
- type CheckinAndCommandService
- type CommandAndReportResults
- type DeclarativeManagement
- type GetToken
- type HTTPStatusError
- type NopService
- func (s *NopService) Authenticate(r *mdm.Request, m *mdm.Authenticate) error
- func (s *NopService) CheckOut(r *mdm.Request, m *mdm.CheckOut) error
- func (s *NopService) CommandAndReportResults(r *mdm.Request, results *mdm.CommandResults) (*mdm.Command, error)
- func (s *NopService) DeclarativeManagement(r *mdm.Request, m *mdm.DeclarativeManagement) ([]byte, error)
- func (s *NopService) GetBootstrapToken(r *mdm.Request, m *mdm.GetBootstrapToken) (*mdm.BootstrapToken, error)
- func (s *NopService) GetToken(r *mdm.Request, m *mdm.GetToken) (*mdm.GetTokenResponse, error)
- func (s *NopService) SetBootstrapToken(r *mdm.Request, m *mdm.SetBootstrapToken) error
- func (s *NopService) TokenUpdate(r *mdm.Request, m *mdm.TokenUpdate) error
- func (s *NopService) UserAuthenticate(r *mdm.Request, m *mdm.UserAuthenticate) ([]byte, error)
- type UserAuthenticate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckinRequest ¶
CheckinRequest is a simple adapter that takes the raw check-in bodyBytes and dispatches to the respective check-in method on svc.
func CommandAndReportResultsRequest ¶
func CommandAndReportResultsRequest(svc CommandAndReportResults, r *mdm.Request, bodyBytes []byte) ([]byte, error)
CommandAndReportResultsRequest is a simple adapter that takes the raw command result report bodyBytes, dispatches to svc, and returns the response.
Types ¶
type Checkin ¶
type Checkin interface {
Authenticate(*mdm.Request, *mdm.Authenticate) error
TokenUpdate(*mdm.Request, *mdm.TokenUpdate) error
CheckOut(*mdm.Request, *mdm.CheckOut) error
SetBootstrapToken(*mdm.Request, *mdm.SetBootstrapToken) error
GetBootstrapToken(*mdm.Request, *mdm.GetBootstrapToken) (*mdm.BootstrapToken, error)
UserAuthenticate
DeclarativeManagement
GetToken
}
Checkin represents the various check-in requests. See https://developer.apple.com/documentation/devicemanagement/check-in
type CheckinAndCommandService ¶
type CheckinAndCommandService interface {
Checkin
CommandAndReportResults
}
CheckinAndCommandService faciliates check-ins and commands.
type CommandAndReportResults ¶
type CommandAndReportResults interface {
CommandAndReportResults(*mdm.Request, *mdm.CommandResults) (*mdm.Command, error)
}
CommandAndReportResults represents the command report and next-command request. See https://developer.apple.com/documentation/devicemanagement/implementing_device_management/sending_mdm_commands_to_a_device
type DeclarativeManagement ¶ added in v0.3.0
type DeclarativeManagement interface {
DeclarativeManagement(*mdm.Request, *mdm.DeclarativeManagement) ([]byte, error)
}
DeclarativeManagement is the interface for handling the Apple Declarative Management protocol via MDM "v1."
type GetToken ¶ added in v0.7.0
GetToken is the interface for handling a GetToken check-in message. See https://developer.apple.com/documentation/devicemanagement/get_token
type HTTPStatusError ¶
func NewHTTPStatusError ¶
func NewHTTPStatusError(status int, err error) *HTTPStatusError
func (*HTTPStatusError) Error ¶
func (e *HTTPStatusError) Error() string
func (*HTTPStatusError) Unwrap ¶
func (e *HTTPStatusError) Unwrap() error
type NopService ¶ added in v0.8.0
type NopService struct{}
NopService is a NanoMDM service that does nothing and returns no errors.
func (*NopService) Authenticate ¶ added in v0.8.0
func (s *NopService) Authenticate(r *mdm.Request, m *mdm.Authenticate) error
Authenticate does nothing and returns nil.
func (*NopService) CommandAndReportResults ¶ added in v0.8.0
func (s *NopService) CommandAndReportResults(r *mdm.Request, results *mdm.CommandResults) (*mdm.Command, error)
CommandAndReportResults does nothing and returns nil, nil.
func (*NopService) DeclarativeManagement ¶ added in v0.8.0
func (s *NopService) DeclarativeManagement(r *mdm.Request, m *mdm.DeclarativeManagement) ([]byte, error)
DeclarativeManagement does nothing and returns nil.
func (*NopService) GetBootstrapToken ¶ added in v0.8.0
func (s *NopService) GetBootstrapToken(r *mdm.Request, m *mdm.GetBootstrapToken) (*mdm.BootstrapToken, error)
GetBootstrapToken does nothing and returns nil, nil.
func (*NopService) GetToken ¶ added in v0.8.0
func (s *NopService) GetToken(r *mdm.Request, m *mdm.GetToken) (*mdm.GetTokenResponse, error)
GetToken does nothing and returns nil, nil.
func (*NopService) SetBootstrapToken ¶ added in v0.8.0
func (s *NopService) SetBootstrapToken(r *mdm.Request, m *mdm.SetBootstrapToken) error
SetBootstrapToken does nothing and returns nil.
func (*NopService) TokenUpdate ¶ added in v0.8.0
func (s *NopService) TokenUpdate(r *mdm.Request, m *mdm.TokenUpdate) error
TokenUpdate does nothing and returns nil.
func (*NopService) UserAuthenticate ¶ added in v0.8.0
func (s *NopService) UserAuthenticate(r *mdm.Request, m *mdm.UserAuthenticate) ([]byte, error)
UserAuthenticate does nothing and returns nil, nil.
type UserAuthenticate ¶ added in v0.7.0
type UserAuthenticate interface {
UserAuthenticate(*mdm.Request, *mdm.UserAuthenticate) ([]byte, error)
}
UserAuthenticate is an interface for processing the UserAuthenticate MDM check-in message.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package certauth
|
Package certauth |
|
Package dmhook provides a NanoMDM Declarative Management service that calls out to an HTTP endpoint for the DM protocol.
|
Package dmhook provides a NanoMDM Declarative Management service that calls out to an HTTP endpoint for the DM protocol. |
|
Pacakge dump is a NanoMDM service that dumps raw responses
|
Pacakge dump is a NanoMDM service that dumps raw responses |
|
Package multi contains a multi-service dispatcher.
|
Package multi contains a multi-service dispatcher. |
|
Pacakge nanomdm is an MDM service.
|
Pacakge nanomdm is an MDM service. |
|
Package webhook is a NanoMDM service for sending HTTP webhook events.
|
Package webhook is a NanoMDM service for sending HTTP webhook events. |