fleet icon indicating copy to clipboard operation
fleet copied to clipboard

`/hosts` with `device_mapping` returns `idp` for `source` in response after human-device mapping has been manually updated

Open spalmesano0 opened this issue 1 month ago • 2 comments

Fleet version: v4.77.0

Web browser and operating system: N/A: this is in the API


💥  Actual behavior

After manually setting a host's human-device mapping data (either with the UI or API), the source under the host's device_mapping is changed to "idp", instead of remaining as "mdm_idp_accounts".

🛠️ To fix

  • When manually updating human-device mapping, if source parameter is set to "idp", set the end user's source to mdm_idp_accounts.
  • When upgrading, existing end users with "source": "idp" are updated to have "source": "mdm_idp_accounts"

Note that this could potentially be considered a breaking change. Since this is a Premium feature and we know who's using it, we'll go ahead with the change since customer workflows are broken.

🧑‍💻  Steps to reproduce

These steps:

  • [ ] Have been confirmed to consistently lead to reproduction in multiple Fleet instances.
  • [x] Describe the workflow that led to the error, but have not yet been reproduced in multiple Fleet instances.
  1. List a host (with IdP data) with device_mapping = true and see "source": "mdm_idp_accounts".
  2. Manually update a host's human-device mapping data.
  3. List the host again with device_mapping = true, and now see "source": "idp".

🕯️ More info (optional)

spalmesano0 avatar Dec 12 '25 12:12 spalmesano0

FYI @rachaelshaw I assigned this bug to you

noahtalerman avatar Dec 12 '25 14:12 noahtalerman

Hey @rachaelshaw @sharon-fdm we think this bug deserves P1 because it's blocking customer-shackleton's activation (macOS MDM migration).

@spalmesano0 just a reminder to follow the notification step in high priority bug process. I did it this time. ^^

Image

noahtalerman avatar Dec 12 '25 21:12 noahtalerman

Approved and pulled into the sprint. Thanks @ksykulev, for taking it! ❤️

sharon-fdm avatar Dec 15 '25 16:12 sharon-fdm

Was able to reproduce the original issue on an earlier build. With the fix the source always remains mdm_idp_accounts Hosts with idp as a source also get updated to mdm_idp_accounts For any host that didn't have device_mapping configured source is also set to mdm_idp_accounts

AndreyKizimenko avatar Dec 18 '25 18:12 AndreyKizimenko

Manual mapping change, idp to mdm brings range, flexible, not strange.

fleet-release avatar Dec 19 '25 23:12 fleet-release