fleet/changes
Roberto Dip 19f995d3b5
only include policies in device endpoints for premium users (#6077)
This removes policy information from `GET /api/_version_/fleet/device/{token}` from non-premium Fleet instances.

Starting the server with `./build/fleet serve --dev --dev_license`

```bash
$ curl -s https://localhost:8080/api/latest/fleet/device/1804e808-171f-4dda-9bec-f695b2f2371a | jq '.host.policies // "not present"'
[
  {
    "id": 3,
    "name": "Antivirus healthy (Linux)",
    "query": "SELECT score FROM (SELECT case when COUNT(*) = 2 then 1 ELSE 0 END AS score FROM processes WHERE (name = 'clamd') OR (name = 'freshclam')) WHERE score == 1;",
    "description": "Checks that both ClamAV's daemon and its updater service (freshclam) are running.",
    "author_id": 1,
    "author_name": "Roberto",
    "author_email": "test@example.com",
    "team_id": null,
    "resolution": "Ensure ClamAV and Freshclam are installed and running.",
    "platform": "darwin,linux",
    "created_at": "2022-05-23T20:53:36Z",
    "updated_at": "2022-06-03T13:17:42Z",
    "response": ""
  }
]
```

Starting the server with `./build/fleet serve --dev`

```bash
$ curl -s https://localhost:8080/api/latest/fleet/device/1804e808-171f-4dda-9bec-f695b2f2371a | jq '.host.policies // "not present"'
"not present"
```
2022-06-07 13:27:13 -03:00
..
.keep Issue 1009 calculate diff software (#1305) 2021-07-08 13:57:43 -03:00
issue-4733-improve-fleet-desktop-my-device-url Improve Fleet Desktop "My Device" menu item UX at install time (#5915) 2022-05-31 12:56:51 -03:00
issue-5291-support-failing-policies-automation Support failing policies integrations (#5973) 2022-06-06 10:41:51 -04:00
issue-5380-software-ui-epss Add probability of exploit (EPSS score) to Software page in Fleet Premium (#5925) 2022-06-02 17:32:13 -05:00
issue-5405-api-token-modal Update API token modal to include more information (#5994) 2022-06-02 18:03:03 -05:00
issue-5514-orphan-software Don't return orphaned software from the API (#5840) 2022-05-30 09:23:27 -06:00
issue-5585-cve-data-sync Sync CVE scores periodically (#5838) 2022-06-01 10:06:57 -06:00
issue-5685-device-policies-endpoint add premium, device authed endpoint to retrieve policies (#5967) 2022-05-31 14:54:43 -03:00
issue-5685-policies-in-premium-only only include policies in device endpoints for premium users (#6077) 2022-06-07 13:27:13 -03:00
issue-5734-fix-orbit-shell-root Add automation for orbit shell (with TUF) (#5856) 2022-06-01 13:54:16 -03:00
issue-5776-fix-orphaned-policies ensure previous host membership policies are deleted on enrollment (#5890) 2022-05-30 10:30:15 -03:00
issue-5836-fix-device-redirect Fix device page redirect on expired token (#5976) 2022-06-02 17:56:26 -05:00