* Partial implementation of Bootstrap Token
Fetching the token from the db and sending it back to the client when the client asks for it ie sends the GetBootstrapTokenRequest is not implemented
Also earlier code for Bootstrap Token from commit 58c3782 "mdm: add SetBootstrapToken command." is removed
* implements rest of the bootstrap token feature - micromdm now sends bootstrap token back to the client, when client requests it
* regenerate some proto files
* use original proto generator versions
checkin.pb.go: golang/protobuf@v1.2.0
mdm.pb.go: gogo/protobuf@v1.3.2
device.pb.go: golang/protobuf@v1.0.0
* cleanup syntax
* use more idiomatic naming
* clean up BootstrapToken storage
* add GetBootstrapToken test
* remove extra newline
Co-authored-by: Jesse Peterson <jessepeterson@users.noreply.github.com>
* add doc comments
Co-authored-by: Ilkka Vanhatalo <ilkka.vanhatalo@helsinki.fi>
Co-authored-by: Jesse Peterson <jessepeterson@users.noreply.github.com>
* Refactor MDM service to return a payload from check-ins
* Documented public methods, add documentation to main service interface
* Remove interface-implementing comments
- Upgrade to micromdm/scep v2 & updated API usage
- Use interfaces rather than concrete types in a few places
- Switch to Mozilla's PKCS7 fork (actually @omorsi's fork of that fork)
- Import order: stdlib, project/self, 3rd party
Marshal Assets of InstallEnterpriseApplication embedded manifest
Update to support SHA256, Metadata, and other related fields. Update tests to use and test for new fields.
Match JSON field names to the plist field names. The manifest field names don't follow typical CamelCase key names like normal Plists. It looks more like JSON. To avoid confusion just make them match. This makes it simpler to follow along with Apple's documentation when composing commands in JSON for the MicroMDM API. Otherwise we have to use our Go struct field names which are specific to us and nobody should need to figure that out (or really have to translate between the two). Update the test case to match.
In iOS 10.13/macOS 10.15 a new, BYOD specific enrollment type was added, called User Enrollment.
This enrollment type replaces the typical UDID field in checkin and acknowledge requests with a EnrollmentID field which is unique per each enrollment. One important aspect of this enrollment type is that no personally identifiable information is available to the MDM (UDID, SerialNumber).
The implementation implemented here adds the new EnrollmentID field where appropriate, and ensures that the device tables do not store the enrollment ID.
I will follow up this change set with one that allows listing/removing current enrollment IDs in a similar way that mdmctl get devices and mdmctl get users does.
* add ActivationLockBypassCode Request
* Update mdm.pb.go
fixed typo
* Update mdm.pb.go
add Size method
* Update unmarshal_proto.go
remove pbc
* add api script for activation_lock_bypass_code
* update Changelog
* Simplify Code
I was able to simplify the code as ActivationLockBypassCode does not have any additional fields.
* Update command.go
Remove ActivationLockBypassCode struct as ActivationLockBypassCode does not include any extra fields.
The ApplicationConfiguration setting is implemented by storing the values for Configuration as a plist, and then marshaling it into the settings command as a dictionary.
The SCEP CA certificate is not needed to establish trust between the client and MDM server. Thus including it in the enrollment profile is unnecessary. Separately, and since we don't need it, we can clean up the enrollment service a little by not reading the certificate from disk. Finally — just don't write it out to disk at all. Its usefulness on disk (for the sake of being in its own file) is debatable.
Both KeyType and KeyUsage were being defined with spaces in the name.
According to the spec this is incorrect. The clients were most likely just
ignoring these fields and everything still worked but it makes sense to correct
the profile.