Commit Graph
2249 Commits
Author SHA1 Message Date
Martin Angers ea0da5e2fa Add tool to get a profile as defined in Apple BM (#18274) 2024-04-15 15:11:46 -04:00
Tim Lee a47f59ef36 Implement NVD Feed with Vulncheck Data (#18168) 2024-04-15 09:44:44 -06:00
Dante Catalfamo 80c906aa69 Windows careful bitlocker selection (#18189)
#17796

Fixes an issue in windows server where selecting from `bitlocker_info`
will cause the query to abort. Bitlocker is not available by default
on some version of windows server, so we first check if the optional
component is enabled before making our query
2024-04-12 10:00:46 -04:00
Jacob ShandlingandJacob Shandling 3f32c870a6 Ignore leading/trailing whitespace when filtering entities; fix url param handling; test broad range of affected endpoints (#17455)
## Addresses #16615 and #18041

### #16615:
- Trim whitespace for backend filtered tables
- Trim whitespace in UI for Queries table search string
<img width="1271" alt="Screenshot 2024-03-06 at 11 46 56 AM"
src="https://github.com/fleetdm/fleet/assets/61553566/b818591c-a977-4203-8adb-3a0d909fcfbb">
<img width="1271" alt="Screenshot 2024-03-06 at 11 47 21 AM"
src="https://github.com/fleetdm/fleet/assets/61553566/3c95b992-31ed-4c12-9763-6f5fc7d78b1f">
<img width="1800" alt="Screenshot 2024-03-06 at 3 18 31 PM"
src="https://github.com/fleetdm/fleet/assets/61553566/05c677a4-80e8-4f94-8abc-235cab4145b7">
<img width="1800" alt="Screenshot 2024-03-06 at 5 05 25 PM"
src="https://github.com/fleetdm/fleet/assets/61553566/4a5529a4-dd5f-463c-97ae-6ceaaaff7f93">


_______________________
### #18041:
#### Global:
![Screenshot 2024-04-03 at 12 21
19 PM](https://github.com/fleetdm/fleet/assets/61553566/9a45a3a6-4136-4851-b887-bd176299d0c2)
 
#### Team:
![Screenshot 2024-04-03 at 12 56
36 PM](https://github.com/fleetdm/fleet/assets/61553566/793c70e7-384b-4705-a373-7e30a5188b03)

#### **Similar fix for `GET` ...`vulnerabilities`**


- [x] Changes file added for user-visible changes in `changes/`
- [x] Add integration tests for all affected endpoints
- [x] Manual QA for all new/changed functionality

---------

Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2024-04-10 11:50:08 -07:00
Jacob ShandlingandJacob Shandling dfe51474cd BadRequest when no payloads present; BadRequest for invalid payload types (#18169)
## Addresses #17157 
![Screenshot 2024-04-09 at 4 53
22 PM](https://github.com/fleetdm/fleet/assets/61553566/a6a57f55-275f-4a06-89e7-085262d2672c)

- [x] Changes file added for user-visible changes in `changes/`
- [x] Added/updated tests
- [x] Manual QA for all new/changed functionality

---------

Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2024-04-10 10:55:38 -07:00
Victor Lyuboslavsky 3859c971cf Added error messages when scripts are disabled. (#18174)
#17148

Added error messages to lock/unlock/wipe when scripts are disabled.

# Checklist for submitter
- [x] Added/updated tests
- [x] Manual QA for all new/changed functionality
2024-04-10 11:29:46 -05:00
George Karr e73fd55c5b Updating vuln check support (#15174) 2024-04-10 10:04:50 -05:00
Martin Angers f4d6136236 Ignore pending DDM profiles when waiting to release a device (#18159)
#18160 

# Checklist for submitter

- [x] Changes file added for user-visible changes in `changes/` or
`orbit/changes/`.
- [x] Manual QA for all new/changed functionality
2024-04-09 17:12:51 -05:00
Victor Lyuboslavsky 3367b7e036 Added orbit_version, fleet_desktop_version, and scripts_enabled to host details. (#18123)
#17361
#17148

In GET fleet/hosts/:id response, added the following fields:
- orbit_version
  - `orbit_version == null` means this agent is not an orbit agent
- fleet_desktop_version
- `fleet_desktop_version == null` means this agent is not an orbit agent
or it is an older version which is not collecting the desktop version
- `fleet_desktop_version == ""` means this agent is an orbit agent but
does not have fleet desktop
- scripts_enabled
- `scripts_enabled == null` means this agent is not an orbit agent or it
is an older version which is not collecting scripts_enabled

In orbit_info table, added the following fields:
- desktop_version
- scripts_enabled

Updated docs for orbit_info PR:
https://github.com/fleetdm/fleet/pull/18135

Updated API docs: https://github.com/fleetdm/fleet/pull/17814

MDM lock/unlock/wipe error messages are not part of this PR. They will
be in a separate PR.

# Checklist for submitter
- [x] Changes file added for user-visible changes in `changes/` or
`orbit/changes/`.
See [Changes
files](https://fleetdm.com/docs/contributing/committing-changes#changes-files)
for more information.
- [x] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.
- [x] Added/updated tests
- [x] If database migrations are included, checked table schema to
confirm autoupdate
- [x] Manual QA for all new/changed functionality
  - For Orbit and Fleet Desktop changes:
- [x] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.
- [x] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).
2024-04-09 16:33:44 -05:00
Martin Angers c263923eab Explicitly set collation for character columns 2024-04-09 13:17:33 -04:00
Roberto Dip f827a4727e use license.IsPremium to check for premium licenses (#18141)
a license can be considered premium for trials, this replaces
occurrences that used comparison operators to check for premium
licences.
2024-04-09 11:15:22 -03:00
Sarah Gillespie 05ccf9ee23 Fix issues related to Fleet builtin labels and reserved MDM profile names (#18043) 2024-04-08 14:34:55 -05:00
Roberto Dip bac13b4af2 Prevent MDM migration without assigned ADE profile (#17999)
for #15929 this prevents us sending the notification to start the MDM
migration if the device doesn't have the right JSON profile assigned.
2024-04-08 11:10:29 -03:00
Martin Angers 66f90ccd93 Merge branch 'main' into mna-17401-puppet-related-integration-tests 2024-04-08 08:45:56 -04:00
Roberto Dip f1b45a3865 friday tidy up party (#18106)
- add missing tests
- remove unused code
- remove unnecessary nested branches
2024-04-08 08:42:42 -03:00
Victor Lyuboslavsky 5a6c407e1b Calendar webhook will retry if it receives response 429 (#18067)
#18044 
Calendar webhook will retry if it receives response 429 Too Many
Requests. Webhook request will retry for 30 minutes with a 1 minute max
delay between retries.

# Checklist for submitter

If some of the following don't apply, delete the relevant line.

<!-- Note that API documentation changes are now addressed by the
product design team. -->

- [x] Changes file added for user-visible changes in `changes/` or
`orbit/changes/`.
See [Changes
files](https://fleetdm.com/docs/contributing/committing-changes#changes-files)
for more information.
- [ ] Added/updated tests
- [x] Manual QA for all new/changed functionality
2024-04-05 12:44:56 -05:00
Victor Lyuboslavsky f476ddcfd6 Fix panic due to nil calendar config. (#18065)
#18063

Fixing potential server panic when events are created with calendar
integration, but then global calendar integration is disabled.

Could not do a PR directly from
[fleet-v4.48.0](https://github.com/fleetdm/fleet/releases/tag/fleet-v4.48.0)
due to merge conflicts.

# Checklist for submitter

- [x] Changes file added for user-visible changes in `changes/` or
`orbit/changes/`.
See [Changes
files](https://fleetdm.com/docs/contributing/committing-changes#changes-files)
for more information.
- [ ] Added/updated tests
- [x] Manual QA for all new/changed functionality
2024-04-04 16:18:41 -05:00
Lucas Manuel Rodriguez e8ca959888 Add enterprise integration test for calendar events (#17900)
Integration tests for the calendar feature: #17441.

Adding coverage screenshots for the calendar cron and the osquery
distributed/write coverage:

![Screenshot 2024-03-27 at 14 20
44](https://github.com/fleetdm/fleet/assets/2073526/40d394ab-2208-4bec-981b-fe22fae8b5c1)
![Screenshot 2024-03-27 at 14 21
20](https://github.com/fleetdm/fleet/assets/2073526/1e4c8611-21ba-48a6-82f8-a163594f7f01)
2024-04-04 14:58:31 -03:00
Jacob ShandlingandJacob Shandling 74761b75d8 Update carve request block id mismatch error code from 500 –> 400 (#17974)
## Addresses #16951

# Checklist for submitter

If some of the following don't apply, delete the relevant line.

<!-- Note that API documentation changes are now addressed by the
product design team. -->

- [x] Changes file added for user-visible changes in `changes/`
- [x] Added/updated tests
- [ ] Manual QA for all new/changed functionality – @ksatter can you
please add reproduction steps to the issue to aid in manual QA?

---------

Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2024-04-04 09:38:10 -07:00
Victor Lyuboslavsky 0bca241680 Mark calendar webhook as errored so that it doesn't get stuck in pending and keeps logging warnings. 2024-04-02 16:03:51 -05:00
Martin Angers 0f55bf241d Merge branch 'main' into mna-17401-puppet-related-integration-tests 2024-04-02 09:21:51 -04:00
Roberto Dip 7186cd9342 update tests 2024-04-01 13:42:27 -03:00
Noah Talerman 85a6d6f7a4 Update tests 2024-03-29 17:03:12 -04:00
Noah Talerman 9217625387 Update error message for OS updates declaration profile
- In Fleet 4.48, we'll ship ""
- OS updates w/ DDM will ship in 4.49
- Update error message to let user know OS updates w/ DDM are coming soon.
- In the Figma wireframes here for () add designs for new error message copy.
2024-03-29 16:44:36 -04:00
Sarah Gillespie 841350f556 Add cross-platform check for duplicate MDM profile names (#17916) 2024-03-29 14:55:03 -05:00
Roberto Dip 140dde17b7 add missing activity items, fix CLI error messages (#17961)
for #17954
2024-03-29 15:55:26 -03:00
Roberto Dip 9af01e53e9 add missing activity items, fix CLI error messages
for #17954
2024-03-29 14:43:28 -03:00
Roberto Dip e39d5d9341 fix tests 2024-03-29 14:18:26 -03:00
Roberto Dip 4e11b3574c missing table cleanups for DDM
for #17953, this adds missing cleanups when:

- teams are deleted
- hosts are deleted

also includes a few extra tests.
2024-03-29 12:40:47 -03:00
1833e1fc5b Reset query report when platform/min_osquery_version is changed (#17847)
#17018

- [X] Changes file added for user-visible changes in `changes/` or
`orbit/changes/`.
See [Changes
files](https://fleetdm.com/docs/contributing/committing-changes#changes-files)
for more information.
- [X] Added/updated tests
- [X] Manual QA for all new/changed functionality

---------

Co-authored-by: RachelElysia <rachel@fleetdm.com>
Co-authored-by: RachelElysia <71795832+RachelElysia@users.noreply.github.com>
2024-03-29 12:17:52 -03:00
Sarah Gillespie bb0d031ea8 Populate host.MDMInfo when getting host details for Windows host (#17893) 2024-03-29 09:48:31 -05:00
Roberto Dip 1158ad2559 Merge branch 'main' into ddm-unreleased-bugs 2024-03-28 16:58:33 -03:00
Roberto Dip dacdac904c fix test 2024-03-28 16:57:51 -03:00
Roberto Dip aabca1e40d lint 2024-03-28 16:08:59 -03:00
Roberto Dip 48ee019507 fix unreleased issues for macOS DDM
for #17924 and #17923
2024-03-28 15:44:14 -03:00
Tim Lee d984de41e7 Add batch gitops processing for policies and queries (#17714) 2024-03-28 11:39:27 -06:00
Martin Angers 9d878f1fd2 Merge branch 'main' into mna-17401-puppet-related-integration-tests 2024-03-27 12:42:31 -04:00
Martin Angers 10b6365874 Remove debug println 2024-03-27 11:44:26 -04:00
Martin Angers dc81c2154b Add assertion for enable release device manually to puppet flow integration test 2024-03-27 11:24:06 -04:00
Roberto Dip 0d15132ae4 fix tests and lint 2024-03-27 12:21:08 -03:00
Martin Angers 36aeeddf92 Fix / stabilize the puppet flow integration test 2024-03-27 11:06:23 -04:00
Roberto Dip e34b320ed5 Merge remote-tracking branch 'origin/main' into feat-macos-ddm 2024-03-27 11:58:22 -03:00
Roberto Dip 15e671da9a add missing activities 2024-03-27 11:04:47 -03:00
Martin Angers 8abee3e72d Merge branch 'main' into feat-prefill-account-name 2024-03-27 09:53:02 -04:00
Roberto Dip 0be9f085b0 batch set declarations as pending when they're uploaded (#17876)
#17685
2024-03-27 10:44:22 -03:00
Lucas Manuel Rodriguez ea92433c34 Disabling calendar policies removes scheduled calendar events (#17882)
#17230

Fix for the following scenarios:
- Team has only one policy with calendar enabled. Events are created on
user calendars. Then the user disables the calendar on such policy.
Expected behavior: Events on the user calendar should be cleaned up in
that scenario.
- Policy `platform` is edited (which removes `policy_membership`
entries) and we'd like to have the calendar event removed for the hosts
that do not apply anymore.

To cover these scenarios I changed `ds.GetTeamHostsPolicyMemberships` so
that it also returns hosts that have a calendar event AND have no
results on policies (returned as passing=1).
E.g. this could happen if there ARE calendar events for a team but with
a platform that doesn't match the host (so it has no results).
2024-03-27 10:33:09 -03:00
Roberto Dip fdc5aa57c2 add ddm declarations in the API (#17880)
for #17409
2024-03-27 09:53:43 -03:00
Martin Angers b449900602 Regenerate schema.sql 2024-03-27 08:19:21 -04:00
Dante Catalfamo 7b13d9ce17 Add mdm_apple_declarative_requests table to log DDM requests (#17844)
#17792
2024-03-27 00:09:09 -03:00
Sarah GillespieandRoberto Dip 1edd9f07bb Update host details, list host filters, and MDM summary to include macOS declarations (#17866)
Issue #17619

---------

Co-authored-by: Roberto Dip <dip.jesusr@gmail.com>
2024-03-26 21:54:47 -03:00