Commit Graph

82 Commits

Author SHA1 Message Date
Mike Arpaia
d7f07bb022 Move the server type to it's own package (#458) 2018-07-13 21:40:13 +00:00
Scott Knight
529860bf15 Allow removal of device records (#444)
The new remove devices command takes a UDID or list of UDIDs
as input and calls the devices delete endpoint. Since serial number
isn't strictly required by the spec it seemed to make more sense
to keep the remove working with only UDIDs. The get devices command
with a serial number filter can always be used to look up a UDID
from a serial number.
2018-06-21 11:43:16 -04:00
Scott Knight
f13953790b Create pushinfo Worker separate from DB implementation (#445) 2018-06-21 11:34:19 -04:00
Jesse Peterson
24efe18538 Use micromdm/scep master (for newer pkcs7 lib) (#440)
Resolves #436.
2018-06-15 14:35:45 -07:00
Clayton Burlison
08aa5151dc fix: Smallest typo in the world (#439) 2018-06-14 11:17:50 -04:00
Jesse Peterson
8bdc5e3ffe Don't hide error (#435) 2018-06-13 21:43:35 -04:00
Jesse Peterson
b857046412 Use constant time (#430) 2018-06-09 11:09:28 -07:00
Victor Vrantchan
ee3f43d4c6 create user worker separate from DB implementation. (#426) 2018-05-30 09:18:04 -07:00
Victor Vrantchan
1ccf1c8ca1 decouple device updates from db CRUD (#427)
Move the code for polling topics and updating device records into an independent worker.
Cleans up the code and makes it possible to swap the db backend.
2018-05-30 09:14:41 -07:00
Victor Vrantchan
35051e7d9b Add a more complete webhook worker. (#424)
Adds a webhook worker which is scaffolded to support multiple event types.
Supports Checkin And Acknowledge events from the start.
2018-05-30 09:14:19 -07:00
Victor Vrantchan
1916f2a2f5 add logging to device block service (#425) 2018-05-29 07:41:57 -04:00
Victor Vrantchan
dcd0ec4a41 reorganize MDM service into a single package. (#423) 2018-05-27 17:47:21 -04:00
Scott Knight
be837649b3 Do not allow mdmctl config set without args (#421) 2018-05-27 13:08:14 -04:00
Jesse Peterson
6507d2edd2 Switch for hosting homepage (#420) 2018-05-15 04:49:59 -07:00
Victor Vrantchan
b6bb81f569 reduce unnecessary boilerplate 2018-05-12 19:36:24 -04:00
Victor Vrantchan
70d26149ae only register HTTP routes once (#418)
Simplified the registration of HTTP routes.
Moved basic auth middleware to use the provided go-kit library.
2018-05-12 19:17:40 -04:00
Jesse Peterson
887754922c apns command switches are deprecated, warn user (#412) 2018-05-12 14:27:52 -07:00
Jesse Peterson
6cda0a214b Guard aginst tls=false and supplying cert&key (#414) 2018-05-12 14:21:21 -07:00
Victor Vrantchan
c1c1cfb175 refactor command service to use one method per file (#416)
Updated the command service to have the same structure as all the other services within platform/...
2018-05-12 17:04:05 -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
8118bf6333 correct header and format for json decoding of error (#411) 2018-05-09 09:53:56 -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
e32d2bea1b Add explicit DEP sync now (#404)
Fixes #175.
2018-05-05 11:57:50 -07:00
Jesse Peterson
1c7c9f0098 Structured logging for depsync (#403) 2018-05-05 11:51:33 -07:00
Jesse Peterson
5661b62021 Implement mdmcert.download support in mdmctl (#401) 2018-05-02 22:05:32 -07:00
Brett Demetris
27786e12a1 must start server with api-key (#396)
log if no api key is specified
2018-04-19 21:14:50 -04:00
Victor Vrantchan
175b84e631 refactor apns API and datastore (#359)
Closes #306
2017-12-14 20:35:50 -05: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
3d77b69b67 add deptoken to the platform folder. (#338)
I noticed that all deptoken is is a store for DEP tokens, which fits nicely with
the rest of the storage/api packages in platform.

The next step will be to move the deptoken store into the config package, but it must be
done in a gradual way since people are already using it today.
2017-11-24 10:26:26 -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
Victor Vrantchan
bc34ace413 organize dep packages in a dep subfolder (#336)
Moves deptoken and depsync into dep.
2017-11-23 15:47:53 -05:00
Victor Vrantchan
591dbe37fc Organize MDM server packages into mdm folder (#335)
Organize the packages essential to the MDM server into a mdm folder.
This includes the enroll, checkin and connect services. The packages in this folder make up the
APIs that a device will directly interact with.
2017-11-23 15:37:49 -05:00
Victor Vrantchan
1169794f71 move main into cmd subdirectory (#333)
Moved all the go files from the top level directory into the cmd/ package.
Updated Makefile so that all the commands still work.

The common pattern in Go programs, and one we adapted with the addition with the mdmdctl binary is that binaries live in cmd/binary-name/binary-name.go while libraries live in folders at the top level.
2017-11-23 13:45:53 -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