55 Commits

Author SHA1 Message Date
Scott Knight
be837649b3 Do not allow mdmctl config set without args (#421) 2018-05-27 13:08:14 -04:00
Jesse Peterson
10d6d99f9b DEP auto-assignment (v2) (#405)
Support DEP auto-assignment in MicroMDM.

Resolves #227.
Resolves #178.
2018-05-11 13:52:06 -07:00
Brett Demetris
9d15fff516 search a serial out of all serials (#363)
* search a serial out of all serials

* clean up usage

* roll back development code, cleanup

* pull changes to mdmctl and decode url params

* wire up List to accept opts with debugging

* implement forEach without filtering opt

* implement filtering for multiple inbound serials

* drop gorilla/schema in favor of json body

* address comments

* tighten up return

* remove device.Store ref and make use of httputil pkg
2018-05-07 10:22:54 -07:00
Jesse Peterson
5661b62021 Implement mdmcert.download support in mdmctl (#401) 2018-05-02 22:05:32 -07:00
thepriefy
ced71b4e38 fix: Get devices (and most other successful commands) should output to Stdout, not Stderr (#360)
Closes #356
2017-12-13 22:47:03 -05:00
Victor Vrantchan
6e561224d0 refactor dep api endpoints (#355)
Closes #331
Closes #329
Closes #323
2017-12-12 08:31:35 -05:00
Victor Vrantchan
1d8f75e290 refactor device api (#354) 2017-12-10 10:01:03 -05:00
Victor Vrantchan
431a09998c refactor app upload APIs (#353)
Closes #296
2017-12-10 01:21:59 -05:00
Victor Vrantchan
5ff82344be refactor config api (#352)
Closes #300
Closes #303
2017-12-10 00:39:04 -05:00
Victor Vrantchan
c5b1e8ccce refactor user api (#351)
Closes #307
2017-12-09 22:42:03 -05:00
Victor Vrantchan
5ff0a2f7f3 refactor block service for HA (#349) 2017-12-09 19:04:06 -05:00
Victor Vrantchan
c87bca7116 refactor blueprint service for HA (#348)
Cleanup blueprints by moving the service into its own package.

Closes #297
2017-12-09 18:09:06 -05:00
Victor Vrantchan
83ea8491aa reorganize profile service (#347)
Moved all the endpoints into the profile package.
Defined a Store interface which includes all the used BoltDB methods.
Moved the BoltDB implementation into a subpackage.
2017-12-09 16:50:10 -05:00
Victor Vrantchan
ce6e18f18d add checkout middleware (#342)
Implement a connect service middleware which allows an operator to forcefully un-enroll a device. 

Documentation: https://github.com/micromdm/micromdm/wiki/Terminating-a-Management-Relationship-with-a-device-block
2017-11-30 23:17:51 -05:00
Victor Vrantchan
49d2e582d2 move apiserver into api/server. (#340)
re-did the folder structure for the API. The client still lives in the server
packages, but will be gradually moved into api/client to remove coupling and make the APIs clearer.
2017-11-24 11:00:35 -05:00
Victor Vrantchan
91c236c8c3 organize essential APIs into platform, workflow and pkg folders (#337)
Add more logic to the way code is organized.

	/pkg -- library code not directly connected to micromdm
	/mdm -- packages meant for the services devices interract with. The MDM protocol.
	/dep -- DEP API and related packages.
	/platform -- Core APIs the server provides. Commands API, Devices API, queue, pubsub etc.
	/workflow -- Packages/API that build on top of platform. Today that's the webhook package.
		     Depending on what ends up here, the workflow folder might become its own repository.
2017-11-23 22:07:57 -05:00
Nate Walck
a3e228fbbe Added ability to store multiple servers and switch between them (#275)
Added ability to store multiple servers, switch between them and migrate old config format to new config format.

Closes #189
2017-10-30 23:37:12 -04:00
Victor Vrantchan
777f9af8f0 add usage text for dep-profiles (#289)
Closes #288
2017-10-30 22:38:21 -04:00
Victor Vrantchan
3f0238719c correctly encode the pkgurl in the manifest (#287)
Closes #286
2017-10-30 18:04:08 -04:00
Victor Vrantchan
ad4ec6ffdb create push service from TLS cert if there's no cert in the DB (#284) 2017-10-30 08:01:03 -04:00
Victor Vrantchan
1defd8b922 add accountconfiguration flags to blueprint (#269)
Closes #261
2017-10-27 00:23:14 -04:00
Nate Walck
9c9455330a Remove u.Scheme as we are handling that just before parsing (#266)
Added tests
2017-10-26 13:01:53 -04:00
Nate Walck
a0b092af5c Fixed https prepend logic (#265) 2017-10-26 11:16:31 -04:00
Nate Walck
aab6e291eb Changed output file extension to .plist for PushCertificateRequest (#264)
Closes #259
2017-10-26 10:53:21 -04:00
Victor Vrantchan
43d026c970 Add users (#258)
For #248 

Added a User DB similar to the Device DB. 
The user specification be added with the API/mdmctl commands and then referenced with a blueprint. 
If added to the blueprint, the user will be installed as an administrator during the AccountConfiguration step.
2017-10-24 20:34:41 -04:00
Nate Walck
665e2b8bcc Fixed formatting in mdmctl for #240 (#250)
Closes #240
2017-10-17 08:20:56 -04:00
Victor Vrantchan
4b9b004d39 mdmctl dep-tokens provide defaults (#241)
Adds default paths to save the DEP token and public key for the
dep-tokens commands.
2017-10-15 21:44:04 -04:00
Victor Vrantchan
dfc8cca3d8 mdmctl can upload/replace push certificate (#238)
Closes #236
2017-10-15 21:08:48 -04:00
Victor Vrantchan
aacac39945 move certhelper into mdmctl (#235)
Add mdmcert subcommand which helps create new MDM Push certificates.
2017-10-15 14:47:10 -04:00
Victor Vrantchan
fe191eb7cc Added micromdm/go4 as a dependency. (#229)
Improves http debug logging by also logging the sent response.
Converts regular http logs to key-value format.
Changes the http server options to httputil.ListenAndServe, which is antended to be a standard
ListenAndServe method for all micromdm project.

Adds environment variables as configuration options for sensitive values.
Closes #196
2017-09-11 17:14:12 +03:00
Victor Vrantchan
3863829b8e reset used io.Reader for pkg upload (#209) 2017-06-05 14:48:36 -07:00
Victor Vrantchan
d352d6cc95 add package and manifest file uploads (#204)
Add support to manage package imports and generating/editing appmanifest files. 

Closes #93
2017-06-05 00:27:14 -07:00
Jesse Peterson
40ccbefc17 Implement Profile and Blueprint removal APIs and mdmctl UI (#206) 2017-06-03 21:51:22 -07:00
Victor Vrantchan
c30f2806cc mdmctl: support generating appmanifest (#199)
generate an appmanifest. validates and optionally signs packages.

For #93
Closes #203
2017-06-02 00:09:13 -04:00
Jesse Peterson
3bceb796c7 Adjust profiles and blueprints CLIs for get/apply commands to have consistent argument names and usage conventions (#193) 2017-05-30 06:34:19 -04:00
Jesse Peterson
b3a600c5bc Make DEP profile CLI like profiles and blueprints (#195) 2017-05-30 06:32:06 -04:00
Jesse Peterson
b1a26b7761 Update anchor flag text (#197) 2017-05-30 06:28:19 -04:00
Jesse Peterson
8a67b37557 Add anchor certificate to DEP profile template (#181)
* Add anchor certificate to DEP profile template

* Add -use-server-cert flag to generate certificate from server TLS certificate

* Update CHANGELOG

* Support adding certificate chains (rather than just individual certs) to DEP anchor certs

* Resolves #107
2017-05-29 19:43:43 -07:00
Victor Vrantchan
225153cdc5 helper to print mdmctl config (#187) 2017-05-29 22:43:20 -04:00
Victor Vrantchan
891b1a2870 use - for stdin (#190) 2017-05-29 22:43:08 -04:00
Victor Vrantchan
b96c506dce support writing file to stdout (#186) 2017-05-29 21:17:53 -04:00
Victor Vrantchan
5b18fa6a2f update generate blueprint command to print to stdout (#173)
For #162

* add applyAt
2017-05-28 12:56:24 -04:00
Victor Vrantchan
e0efa31d28 implement mdmctl dep commands (#161)
adds subcommands for endpoints implemented in #160
   mdmctl get dep-devices
   mdmctl get dep-account
   mdmctl get dep-profiles
   mdmctl apply dep-profiles
  
Closes #154
2017-05-27 23:22:32 -04:00
Jesse Peterson
284f368353 Blueprint profile integration (#163)
* Integrate Profiles into Blueprints
* Listen for events and deploy blueprints for new enrollments
* Track enrolled status of (re-)enrolling devices and re-issue the Check-In Event under a different topic
* Added references to #149 and #110 for direction/conceptual background
* Closes #149 (largely implemented here)
2017-05-21 22:12:42 -07:00
Jesse Peterson
670b4399db Profile service/store, API, and mdmctl management (#156)
* Profile service/store, API, and mdmctl management
* Group methods with their types
* Centralize error checking and remove profile ID specification on upload (unnecessary)
* Move more error checking into methods
2017-05-17 00:19:26 -07:00
Jesse Peterson
ce1cb87152 Past-due reorganization of some crypto helpers into the crypto package (#148) 2017-05-01 10:14:52 -07:00
Jesse Peterson
6d5fd5e97a Blueprints apply and list/get (#145) 2017-04-26 09:56:32 -07:00
Jesse Peterson
2d90d3b69b Allow self-signed certificates with configuration option in mdmctl (#147) 2017-04-26 09:36:34 -07:00
Jesse Peterson
ad22a7a932 Move dep-token sub-command to mdmctl (#141) 2017-04-19 09:13:27 -07:00
Victor Vrantchan
dc743df878 add support for per-device blueprints (#136)
blueprints are now saved in boltdb with mdmctl
blueprints work in a similar way to munki manifests:
The devices will use a site_default blueprint, otherwise will
look up one based on serial number.
Other blueprints can be nested
2017-04-09 17:43:44 -04:00