Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List certificates on macOS, iOS, iPadOS hosts #22802

Open
harrisonravazzolo opened this issue Oct 9, 2024 · 12 comments
Open

List certificates on macOS, iOS, iPadOS hosts #22802

harrisonravazzolo opened this issue Oct 9, 2024 · 12 comments
Labels
~customer promise A feature request from a Fleet customer that Fleet has contractually agreed to deliver ~customer request A prioritized, customer feature request. Has ≥ 1 customer codename label(s) customer-pingali #g-mdm MDM product group

Comments

@harrisonravazzolo
Copy link
Member

harrisonravazzolo commented Oct 9, 2024

customer-pingali: Gong snippet: https://us-65885.app.gong.io/call?id=2699116120479648557&highlights=%5B%7B%22type%22%3A%22SHARE%22%2C%22from%22%3A370%2C%22to%22%3A458%7D%5D

  • @noahtalerman: User requested this because they can see a list the certificates on macOS, iOS, iPadOS hosts in their current MDM solution. They want to see the same list in Fleet.

User stories

@harrisonravazzolo
Copy link
Member Author

Similar to #20717

@noahtalerman
Copy link
Member

Problem

customer-pingali would like the ability to surface this information about a device directly from MDM and not rely on osquery.

Use case: an employee with a BYOD leaves the organization and CorpIT wants to know which certs the device has and revoke them. While this is possible through osquery on Mac/Windows, it's not possible to use this method on iOS. The security queries will return the value they are looking for, certificates, but also data that would be useful for other customers to be able to query and unlock some GitOps lifecylces - i.e. Find My, Management status, Hardware encryption type

All available values: https://support.apple.com/en-gb/guide/deployment/dep5872f7b3c/1/web/1.0

What have you tried?

Not possible through Fleet.

Potential solutions

Could use osquery on supported platforms or use a custom MDM command, like what this customer is trying to do with certs - https://developer.apple.com/documentation/devicemanagement/list_the_certificates

What is the expected workflow as a result of your proposal?

Being able to hit an API, similar to the List MDM Command https://fleetdm.com/docs/rest-api/rest-api#list-mdm-commands and parse the data returned.

@noahtalerman
Copy link
Member

  • @noahtalerman: User requested this because they want to be able to list the certificates on macOS, iOS, iPadOS hosts. What are they doing w/ this list? Building some automation? Just looking to confirm that a certificate is there?

@harrisonravazzolo can you please ask the above on your next call w/ pingali? Thanks!

Also check out the "in the interim" below:

@noahtalerman noahtalerman changed the title Support Security MDM queries for Apple Devices List certificates on macOS, iOS, iPadOS hosts Oct 18, 2024
@noahtalerman
Copy link
Member

  • @noahtalerman: User requested this because they want to be able to list the certificates on macOS, iOS, iPadOS hosts. What are they doing w/ this list? Building some automation? Just looking to confirm that a certificate is there?

@harrisonravazzolo just following up to say that I don't think we can move this request forward to drafting/design until we understand the above.

Can you please ask the above on your next call w/ pingali? Thanks!

@harrisonravazzolo
Copy link
Member Author

https://us-65885.app.gong.io/call?id=4502089861812328304&highlights=%5B%7B%22type%22%3A%22SHARE%22%2C%22from%22%3A1366%2C%22to%22%3A1418%7D%5D

The downstream use case for the data returned is not clear on this snippet but they have potentially turned this into a requirement.

@noahtalerman noahtalerman removed the ~feature fest Will be reviewed at next Feature Fest label Oct 24, 2024
@noahtalerman
Copy link
Member

@harrisonravazzolo it's still unclear what the desired workflow is.

Do they want to see a list of certificates on the Host details page? You can imagine we'd show a list like the list of users:

Screenshot 2024-10-24 at 2 23 43 PM

@harrisonravazzolo
Copy link
Member Author

Hey @noahtalerman - I can ask Pingali but yeah, I would imagine something like that, but that it's also included in the api.

Don't know how helpful this screenshot is but this is me running the command on my iPhone and getting the certs.

cert_payload

@harrisonravazzolo
Copy link
Member Author

Access to a lot of resources are through certs - so knowing if a device has a particular cert might mean the end user has access to the dev test wifi network, or, they have a kerberos identity for the iOS app test services, or something like that.

@noahtalerman noahtalerman added the ~feature fest Will be reviewed at next Feature Fest label Oct 24, 2024
@noahtalerman noahtalerman added ~feature fest Will be reviewed at next Feature Fest and removed ~feature fest Will be reviewed at next Feature Fest :product Product Design department (shows up on 🦢 Drafting board) labels Oct 24, 2024
@noahtalerman
Copy link
Member

@harrisonravazzolo heads up, we peeled this user story off this request and brought it into the current design sprint.

Keep in mind that the user story might not address the entire request. It may just be a small, iterative piece of it.

@noahtalerman noahtalerman added Epic DO NOT USE. Auto-created by ZenHub, cannot be disabled. and removed ~feature fest Will be reviewed at next Feature Fest Epic DO NOT USE. Auto-created by ZenHub, cannot be disabled. labels Oct 25, 2024
@rachaelshaw
Copy link
Member

@harrisonravazzolo @noahtalerman wondering if we ever got the answer to this question in the issue description:

What are they doing w/ this list? Building some automation? Just looking to confirm that a certificate is there?

@noahtalerman
Copy link
Member

@rachaelshaw I don't think we know for sure if pingali is building an automation.

That said, I chatted w/ Allen (subject matter expert), and other MDM solutions present a list of certificates on their equivalent of the Host details page. This way, the IT admin can confirm they're present on the device. So, I think it's safe to assume that pingali is at least looking for this.

In the user story we're working on now, I think we start w/ adding certificates to the Host details page (host vitals API too).

Later, we might add a view that shows all certificates across hosts or fire webhooks when a certificate fails to install (to aid automations if they exist).

@noahtalerman noahtalerman added the ~customer request A prioritized, customer feature request. Has ≥ 1 customer codename label(s) label Nov 12, 2024
@noahtalerman noahtalerman added ~feature fest Will be reviewed at next Feature Fest and removed ~feature fest Will be reviewed at next Feature Fest labels Nov 14, 2024
@allenhouchins
Copy link
Member

allenhouchins commented Nov 19, 2024

I was able to look into this a little more.

When you run a query like SELECT * FROM certificates; it is pulling all certificates, even system root certificates that are the default, built-in certificates provided by the operating system. Admins likely don't want these listed on a host record since every host will have them and know they can dig them up through osquery if needed.

What admins are likely asking for is a UI that shows the results of SELECT * FROM certificates where path = '/Library/Keychains/System.keychain'; attached to a host since these are certificates installed on top of the defaults.

Here is what other MDMs show:
Screenshot 2024-11-19 at 1 45 30 PM

Here is the osquery result of the command I suggested -- the discrepancy in results is because certificates that were installed by Jamf have been removed from the device:
Screenshot 2024-11-19 at 1 46 23 PM

Here is the list of System certificates on the device:
Screenshot 2024-11-19 at 1 46 36 PM

Here is the list of System Roots installed on the device which come up when running SELECT * FROM certificates; in addition to the ones in the previous screenshot:
Screenshot 2024-11-19 at 1 46 41 PM

Summary: The UI should not show all certificates, only the results of SELECT * FROM certificates where path = '/Library/Keychains/System.keychain'; since these are certificates that had to be installed through some process.

@noahtalerman noahtalerman added the ~customer promise A feature request from a Fleet customer that Fleet has contractually agreed to deliver label Nov 22, 2024
@noahtalerman noahtalerman added ~feature fest Will be reviewed at next Feature Fest and removed ~feature fest Will be reviewed at next Feature Fest labels Dec 5, 2024
@noahtalerman noahtalerman added ~feature fest Will be reviewed at next Feature Fest #g-mdm MDM product group labels Dec 19, 2024
@noahtalerman noahtalerman removed the ~feature fest Will be reviewed at next Feature Fest label Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
~customer promise A feature request from a Fleet customer that Fleet has contractually agreed to deliver ~customer request A prioritized, customer feature request. Has ≥ 1 customer codename label(s) customer-pingali #g-mdm MDM product group
Development

No branches or pull requests

4 participants