Commit Graph

446 Commits

Author SHA1 Message Date
Roberto Dip
666ae8d787
ensure ds.TeamByName returns a 4xx response if no team is found (#12620)
this helps consumer of the datastore method handle the not found
scenario better and ensures we always return a 4xx code by default if we
can't find a matching team.

seems like calls to this method were special-cased everywhere except in
the apply user roles endpoint, where we returned a `500` status code if
we couldn't find a team.
2023-07-13 11:55:05 -03:00
Roberto Dip
53f0e281bf
set DeferForceAtUserLoginMaxBypassAttempts in FV profile (#12729)
Related to #12608, this automatically sets the
`DeferForceAtUserLoginMaxBypassAttempts` property to `1` on the
FileVault profile that's generated by Fleet.

This changeset also includes a migration to modify old FileVault
profiles that already exist in the database, and by virtue of that a
`InstallProfile` command will be issued to hosts that already have FV
enabled. During testing we found:

1. This doesn't affect users with FV already installed, they silently
get the profile updated without any changes.
2. Since the profile needs to be re-delivered, it'll go through the full
"pending" -> "verifying" -> "verified" cycle.
2023-07-13 11:54:05 -03:00
Lucas Manuel Rodriguez
810eb58b95
macOS CIS: Use find command (exposed as fleetd table) instead of relying on the osquery core file table (#12560)
#10292, #12554

When scanning tens of thousands of files for permissions, using the
`find` command exposed as a fleetd table is more performant than trying
to use the `file` table. This change caused the watchdog to *stop*
killing osquery because of exceeding memory or CPU limit.

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-06-29 16:22:41 -03:00
Martin Angers
1db2f7646a
Implement Windows MDM programmatic unenrollment (notification + orbit trigger) (#12505) 2023-06-28 09:13:37 -04:00
Kenny Botelho
31dfcc1e1a
Add Puppet function for sending custom MDM commands (#12534) 2023-06-27 13:17:37 -03:00
Lucas Manuel Rodriguez
feb4e65be6
Optimize macOS CIS query 5.1.5 (#12506)
#10292

The query was processing *every* file under `/Applications/`, which
makes it super expensive both in CPU usage and Memory footprint. This
query was the main culprit of triggering worker process kills by the
watchdog.

On some runs it triggered CPU usage alerts:
```
7716:W0623 15:38:05.402959 221732864 watcher.cpp:415] osqueryd worker (72976) stopping:
Maximum sustainable CPU utilization limit 1200ms exceeded for 12 seconds
```
And on other runs it triggered memory usage alerts:
```
4431 W0626 07:28:50.868021 147312640 watcher.cpp:424] osqueryd worker (21453) stopping:
Memory limits exceeded: 214020096 bytes (limit is 200MB)
```

For the above logs I used a custom osqueryd branch to be able to print
more information: https://github.com/osquery/osquery/pull/8070

The metrics for the old query were CPU usage: ~4521 ms
```
435:level=warn ts=2023-06-26T09:58:29.665712Z query=fleet_policy_query_1233 queryTime=4521 memory=12226560 msg="distributed query performance is excessive" hostID=308 platform=darwin
```
With the new query, CPU usage: ~210 ms.
```
23893:level=debug ts=2023-06-26T18:06:08.242456Z query=fleet_policy_query_1233 queryTime=210 msg=stats memory=0 hostID=308 platform=darwin
```
Basically a ~20x improvement.

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- ~[ ] Added/updated tests~
- [X] Manual QA for all new/changed functionality
  - For Orbit and Fleet Desktop changes:
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-06-27 11:06:26 -03:00
Sharon Katz
519982990c
Add disk_info table to chromeos (#12344) 2023-06-26 15:40:37 -04:00
RachelElysia
044935b02f
ChromeOS support: ChromeOS tables (add chromeos to existing table: screenlock, new table: system_state) (#12358) 2023-06-26 11:18:12 -07:00
Jacob Shandling
2855bc8f7f
ChromeOS privacy_preferences table (#12441)
## Addresses #11037 

### Implement the `privacy_preferences` table for the Fleetd Chrome
extension. Columns correspond to the available properties of
[`chrome.privacy`](https://developer.chrome.com/docs/extensions/reference/privacy/).

Chrome on mac:
<img width="816" alt="Screenshot 2023-06-23 at 11 55 21 AM"
src="https://github.com/fleetdm/fleet/assets/61553566/a4700749-6325-442e-acf2-c14b1c9adf8f">

Chromebook with enterprise access (actual use case):
![Image from
iOS](https://github.com/fleetdm/fleet/assets/61553566/93f2243d-357a-4d85-bd20-0aebd178388c)

* Chromebook w/o enterprise access: as you can see, sometimes certain
APIs are not available - this error occurs because the expected API
object that would have a `get` method is actually `undefined` TODO – How
to handle this case given that we want to let errors bubble up to the
level at which Fleet can catch them? Maybe it would be nice to catch
such errors and send them up to the Fleet layer, and still allow the
loop to continue to populate the columns whose APIs _are_ available.
_Decision: catch API errors here to preserve functionality of the
remaining columns_

![IMG_9407](https://github.com/fleetdm/fleet/assets/61553566/7fb26eb4-44e8-43f8-90c0-8b3d718c5ace)

- [x] Changes file
- [x] Manual QA

---------

Co-authored-by: Jacob Shandling <jacob@fleetdm.com>
2023-06-23 14:52:16 -07:00
dependabot[bot]
bd5071058e
Bump semver from 7.3.8 to 7.5.3 in /ee/tools/license (#12470)
Bumps [semver](https://github.com/npm/node-semver) from 7.3.8 to 7.5.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/npm/node-semver/releases">semver's
releases</a>.</em></p>
<blockquote>
<h2>v7.5.3</h2>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.2...v7.5.3">7.5.3</a>
(2023-06-22)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="abdd93d554"><code>abdd93d</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/571">#571</a>
set max lengths in regex for numeric and build identifiers (<a
href="https://redirect.github.com/npm/node-semver/issues/571">#571</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
</ul>
<h3>Documentation</h3>
<ul>
<li><a
href="bf53dd8da1"><code>bf53dd8</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/569">#569</a>
add example for <code>&gt;</code> comparator (<a
href="https://redirect.github.com/npm/node-semver/issues/569">#569</a>)
(<a href="https://github.com/mbtools"><code>@​mbtools</code></a>)</li>
</ul>
<h2>v7.5.2</h2>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.1...v7.5.2">7.5.2</a>
(2023-06-15)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="58c791f40b"><code>58c791f</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/566">#566</a>
diff when detecting major change from prerelease (<a
href="https://redirect.github.com/npm/node-semver/issues/566">#566</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
<li><a
href="5c8efbcb3c"><code>5c8efbc</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/565">#565</a>
preserve build in raw after inc (<a
href="https://redirect.github.com/npm/node-semver/issues/565">#565</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
<li><a
href="717534ee35"><code>717534e</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/564">#564</a>
better handling of whitespace (<a
href="https://redirect.github.com/npm/node-semver/issues/564">#564</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
</ul>
<h2>v7.5.1</h2>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.0...v7.5.1">7.5.1</a>
(2023-05-12)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="d30d25a5c1"><code>d30d25a</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/559">#559</a>
show type on invalid semver error (<a
href="https://redirect.github.com/npm/node-semver/issues/559">#559</a>)
(<a
href="https://github.com/tjenkinson"><code>@​tjenkinson</code></a>)</li>
</ul>
<h2>v7.5.0</h2>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.4.0...v7.5.0">7.5.0</a>
(2023-04-17)</h2>
<h3>Features</h3>
<ul>
<li><a
href="503a4e52fe"><code>503a4e5</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/548">#548</a>
allow identifierBase to be false (<a
href="https://redirect.github.com/npm/node-semver/issues/548">#548</a>)
(<a href="https://github.com/lsvalina"><code>@​lsvalina</code></a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="e219bb4540"><code>e219bb4</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/552">#552</a>
throw on bad version with correct error message (<a
href="https://redirect.github.com/npm/node-semver/issues/552">#552</a>)
(<a
href="https://github.com/wraithgar"><code>@​wraithgar</code></a>)</li>
<li><a
href="fc2f3df0b5"><code>fc2f3df</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/546">#546</a>
incorrect results from diff sometimes with prerelease versions (<a
href="https://redirect.github.com/npm/node-semver/issues/546">#546</a>)
(<a
href="https://github.com/tjenkinson"><code>@​tjenkinson</code></a>)</li>
<li><a
href="2781767779"><code>2781767</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/547">#547</a>
avoid re-instantiating SemVer during diff compare (<a
href="https://redirect.github.com/npm/node-semver/issues/547">#547</a>)
(<a href="https://github.com/macno"><code>@​macno</code></a>)</li>
</ul>
<h2>v7.4.0</h2>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.3.8...v7.4.0">7.4.0</a>
(2023-04-10)</h2>
<h3>Features</h3>
<ul>
<li><a
href="113f51312a"><code>113f513</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/532">#532</a>
identifierBase parameter for .inc (<a
href="https://redirect.github.com/npm/node-semver/issues/532">#532</a>)
(<a href="https://github.com/wraithgar"><code>@​wraithgar</code></a>, <a
href="https://github.com/b-bly"><code>@​b-bly</code></a>)</li>
<li><a
href="48d8f8fa63"><code>48d8f8f</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/530">#530</a>
export new RELEASE_TYPES constant (<a
href="https://github.com/hcharley"><code>@​hcharley</code></a>)</li>
</ul>
<h3>Bug Fixes</h3>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/npm/node-semver/blob/main/CHANGELOG.md">semver's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.2...v7.5.3">7.5.3</a>
(2023-06-22)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="abdd93d554"><code>abdd93d</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/571">#571</a>
set max lengths in regex for numeric and build identifiers (<a
href="https://redirect.github.com/npm/node-semver/issues/571">#571</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
</ul>
<h3>Documentation</h3>
<ul>
<li><a
href="bf53dd8da1"><code>bf53dd8</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/569">#569</a>
add example for <code>&gt;</code> comparator (<a
href="https://redirect.github.com/npm/node-semver/issues/569">#569</a>)
(<a href="https://github.com/mbtools"><code>@​mbtools</code></a>)</li>
</ul>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.1...v7.5.2">7.5.2</a>
(2023-06-15)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="58c791f40b"><code>58c791f</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/566">#566</a>
diff when detecting major change from prerelease (<a
href="https://redirect.github.com/npm/node-semver/issues/566">#566</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
<li><a
href="5c8efbcb3c"><code>5c8efbc</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/565">#565</a>
preserve build in raw after inc (<a
href="https://redirect.github.com/npm/node-semver/issues/565">#565</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
<li><a
href="717534ee35"><code>717534e</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/564">#564</a>
better handling of whitespace (<a
href="https://redirect.github.com/npm/node-semver/issues/564">#564</a>)
(<a
href="https://github.com/lukekarrys"><code>@​lukekarrys</code></a>)</li>
</ul>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.5.0...v7.5.1">7.5.1</a>
(2023-05-12)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="d30d25a5c1"><code>d30d25a</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/559">#559</a>
show type on invalid semver error (<a
href="https://redirect.github.com/npm/node-semver/issues/559">#559</a>)
(<a
href="https://github.com/tjenkinson"><code>@​tjenkinson</code></a>)</li>
</ul>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.4.0...v7.5.0">7.5.0</a>
(2023-04-17)</h2>
<h3>Features</h3>
<ul>
<li><a
href="503a4e52fe"><code>503a4e5</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/548">#548</a>
allow identifierBase to be false (<a
href="https://redirect.github.com/npm/node-semver/issues/548">#548</a>)
(<a href="https://github.com/lsvalina"><code>@​lsvalina</code></a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="e219bb4540"><code>e219bb4</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/552">#552</a>
throw on bad version with correct error message (<a
href="https://redirect.github.com/npm/node-semver/issues/552">#552</a>)
(<a
href="https://github.com/wraithgar"><code>@​wraithgar</code></a>)</li>
<li><a
href="fc2f3df0b5"><code>fc2f3df</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/546">#546</a>
incorrect results from diff sometimes with prerelease versions (<a
href="https://redirect.github.com/npm/node-semver/issues/546">#546</a>)
(<a
href="https://github.com/tjenkinson"><code>@​tjenkinson</code></a>)</li>
<li><a
href="2781767779"><code>2781767</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/547">#547</a>
avoid re-instantiating SemVer during diff compare (<a
href="https://redirect.github.com/npm/node-semver/issues/547">#547</a>)
(<a href="https://github.com/macno"><code>@​macno</code></a>)</li>
</ul>
<h2><a
href="https://github.com/npm/node-semver/compare/v7.3.8...v7.4.0">7.4.0</a>
(2023-04-10)</h2>
<h3>Features</h3>
<ul>
<li><a
href="113f51312a"><code>113f513</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/532">#532</a>
identifierBase parameter for .inc (<a
href="https://redirect.github.com/npm/node-semver/issues/532">#532</a>)
(<a href="https://github.com/wraithgar"><code>@​wraithgar</code></a>, <a
href="https://github.com/b-bly"><code>@​b-bly</code></a>)</li>
<li><a
href="48d8f8fa63"><code>48d8f8f</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/530">#530</a>
export new RELEASE_TYPES constant (<a
href="https://github.com/hcharley"><code>@​hcharley</code></a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><a
href="940723d22b"><code>940723d</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/538">#538</a>
intersects with v0.0.0 and v0.0.0-0 (<a
href="https://redirect.github.com/npm/node-semver/issues/538">#538</a>)
(<a
href="https://github.com/wraithgar"><code>@​wraithgar</code></a>)</li>
<li><a
href="aa516b50b3"><code>aa516b5</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/535">#535</a>
faster parse options (<a
href="https://redirect.github.com/npm/node-semver/issues/535">#535</a>)
(<a href="https://github.com/H4ad"><code>@​H4ad</code></a>)</li>
<li><a
href="61e6ea1e9b"><code>61e6ea1</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/536">#536</a>
faster cache key factory for range (<a
href="https://redirect.github.com/npm/node-semver/issues/536">#536</a>)
(<a href="https://github.com/H4ad"><code>@​H4ad</code></a>)</li>
<li><a
href="f8b8b619e7"><code>f8b8b61</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/541">#541</a>
optimistic parse (<a
href="https://redirect.github.com/npm/node-semver/issues/541">#541</a>)
(<a href="https://github.com/H4ad"><code>@​H4ad</code></a>)</li>
<li><a
href="796cbe29b0"><code>796cbe2</code></a>
<a href="https://redirect.github.com/npm/node-semver/pull/533">#533</a>
semver.diff prerelease to release recognition (<a
href="https://redirect.github.com/npm/node-semver/issues/533">#533</a>)
(<a href="https://github.com/wraithgar"><code>@​wraithgar</code></a>, <a
href="https://github.com/dominique-blockchain"><code>@​dominique-blockchain</code></a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7fdf1ef223"><code>7fdf1ef</code></a>
chore: release 7.5.3</li>
<li><a
href="bf53dd8da1"><code>bf53dd8</code></a>
docs: add example for <code>&gt;</code> comparator (<a
href="https://redirect.github.com/npm/node-semver/issues/569">#569</a>)</li>
<li><a
href="abdd93d554"><code>abdd93d</code></a>
fix: set max lengths in regex for numeric and build identifiers (<a
href="https://redirect.github.com/npm/node-semver/issues/571">#571</a>)</li>
<li><a
href="e7b78de06e"><code>e7b78de</code></a>
chore: release 7.5.2</li>
<li><a
href="58c791f40b"><code>58c791f</code></a>
fix: diff when detecting major change from prerelease (<a
href="https://redirect.github.com/npm/node-semver/issues/566">#566</a>)</li>
<li><a
href="5c8efbcb3c"><code>5c8efbc</code></a>
fix: preserve build in raw after inc (<a
href="https://redirect.github.com/npm/node-semver/issues/565">#565</a>)</li>
<li><a
href="717534ee35"><code>717534e</code></a>
fix: better handling of whitespace (<a
href="https://redirect.github.com/npm/node-semver/issues/564">#564</a>)</li>
<li><a
href="2f738e9a70"><code>2f738e9</code></a>
chore: bump <code>@​npmcli/template-oss</code> from 4.14.1 to 4.15.1 (<a
href="https://redirect.github.com/npm/node-semver/issues/558">#558</a>)</li>
<li><a
href="aa016a6716"><code>aa016a6</code></a>
chore: release 7.5.1</li>
<li><a
href="d30d25a5c1"><code>d30d25a</code></a>
fix: show type on invalid semver error (<a
href="https://redirect.github.com/npm/node-semver/issues/559">#559</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/npm/node-semver/compare/v7.3.8...v7.5.3">compare
view</a></li>
</ul>
</details>
<details>
<summary>Maintainer changes</summary>
<p>This version was pushed to npm by <a
href="https://www.npmjs.com/~npm-cli-ops">npm-cli-ops</a>, a new
releaser for semver since your current version.</p>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=semver&package-manager=npm_and_yarn&previous-version=7.3.8&new-version=7.5.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/fleetdm/fleet/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-23 12:27:36 -07:00
Sharon Katz
b754cb096c
Add "username=''" to managed_policies queries (#10710)
https://github.com/fleetdm/fleet/issues/10602


@xpkoala this PR will require testing of all modified items.
Preferably, we should perform the tests before merging to master. Can we
use the dev branch for that? -- Items were tested locally.
2023-06-21 13:00:25 -05:00
Roberto Dip
835491d029
update puppet metadata.json file for publishing (#12418) 2023-06-20 19:08:46 -03:00
Roberto Dip
32acf4230c
improve matching resiliency of puppet endpoints (#12402)
this PR modifies the `external_host_identifier` parameter that's used to
match hosts to Puppet runs to use an identifier that's *unique per run*
(instead of an identifier that's *unique per host*)

this has the adventage to:

1. allow for concurrent Puppet runs that don't interfere with each
other.
2. allow for failed/orphaned Puppet runs to not interfere with new runs
(the keys will eventually get expired)

all the existent behavior should be preserved.

> Note: I have verified that the value that the reporter gets is the one
  associated with the right puppet run, even if multiple runs happen
  simultaneously.
2023-06-20 18:24:54 -03:00
Martin Angers
1c249b60da
Add support to configure and enable Windows MDM, notify elegible hosts (#12340) 2023-06-20 14:06:45 -04:00
Martin Angers
96aec85a0a
Add mechanism to force read from primary DB, use it for puppet matching (#12396) 2023-06-19 13:55:15 -04:00
Roberto Dip
6d789d6e19
improve logging and error reporting in the puppet module (#12369)
For #12355
2023-06-16 12:40:50 -03:00
Roberto Dip
5f30add863
remove puppet PoC (#12317)
The puppet module lives in
https://github.com/fleetdm/fleet/tree/main/ee/tools/puppet/fleetdm, I'm
removing this PoC to avoid any confusion
2023-06-15 10:28:35 -03:00
Lucas Manuel Rodriguez
23eed2c872
Add the extra step to install extension manually (#12299) 2023-06-14 09:36:18 -03:00
Roberto Dip
82be92add9
properly encode release device command (#12275)
for #12272
2023-06-09 18:17:49 -03:00
Mo Zhu
50746c6b48
Chrome docs (#11747) 2023-06-09 10:03:01 -07:00
Juan Fernandez
98d9f1b068
If user is a global/team observer/observer+, 'teams' endpoints should not include secrets (#12216)
Fixed auth. issue with Obs/Obs+
2023-06-08 17:30:34 -04:00
Roberto Dip
1ad80fa251
bugfixes + adjustments for the puppet module (#12221)
A few minor things going on:

1. Adjusted the Puppet module to send the profiles base64 encoded
2. Enabled FileVault by default on teams created using the `/match`
endpoint.
3. Remove profiles when a team is removed. We can't do a foreign key
because the global team.id is NULL. I also included a migration to
cleanup orphaned profiles.
2023-06-08 18:05:44 -03:00
Marcos Oviedo
05c24caa95
Addressing system test findings (#12210)
This relates to #11245
2023-06-08 10:47:04 -03:00
Marcos Oviedo
ebac8705ac
Addressing issues found during system test (#12205)
This relates to #11312 

`18.9.17.6`: Fixing the issue with policy pointing to a different GPO
and Registry value
`18.9.47.4.2`: Adding COLLATE NOCASE to avoid case sensitive issue with
SpynetReporting value
2023-06-08 10:45:43 -03:00
Lucas Manuel Rodriguez
2a532ede94
Do not return empty SSO and SMTP settings for non-global-admins (#12180)
#11266

PS: I first attempted a serialization trick by introducing a new
`appConfigResponse` and implementing `json.Marshal` to exclude these
fields but it was too hacky and hard to maintain moving forward, so I'm
bitting the bullet now. Happy to hear other ideas.

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [X] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-06-07 16:06:36 -03:00
Martin Angers
68ddaafac0
Fix bug preventing gitops role from fleetctl applying macos setup assistant (and bootstrap package) (#12193) 2023-06-07 13:29:36 -04:00
Martin Angers
f27fcddd55
Prevent clearing macos updates settings when applying/modifying a team without those settings (#12160) 2023-06-06 14:31:33 -04:00
Sharon Katz
dc46116d44
Address not installed issue (#12165) 2023-06-06 13:37:43 -04:00
Marcos Oviedo
c6338af0a3
Adding cast to 18.9.108.4.2 (#12131)
This relates to #11668 

This change fixes a CAST issue on 18.9.108.4.2. More details
[here](https://fleetdm.slack.com/archives/C019WG4GH0A/p1685565728281039).
2023-06-06 10:37:21 -03:00
Martin Angers
9f064acd2e
Match pre-assigned profiles to a team (or create one) and assign host to team (#12127) 2023-06-05 15:08:21 -04:00
Roberto Dip
c7488663f2
add a puppet module to manage MDM features (#12032)
Related to #11185 this adds a Puppet module that provides:

1. A custom type named `fleetdm::profile` that can be used to define
profiles to a device
2. A function named `fleetdm::release_device` that can be used to
release a device from await device configuration.

Instructions/usage can be found in the `README.md` file.

---------

Co-authored-by: Martin Angers <martin.n.angers@gmail.com>
2023-05-31 17:26:12 -03:00
Martin Angers
4322a28f5a
Implement preassign endpoint as first step to match profiles and hosts to teams (#12046) 2023-05-31 09:24:22 -04:00
Juan Fernandez
43ab81ee11
Feature 11829: Tailor host table response to ChromeOS (#12002)
Updated ingestion logic and fixed ChromeOS virtual tables to accommodate the requested UI changes.
2023-05-30 22:13:42 -04:00
Lucas Manuel Rodriguez
33d61044b5
Change role of existing users only if SSO attributes are present in the SAMLResponse (#11966)
#10784

The removal of the now deprecated `sso_settings.enable_jit_role_sync`
config will be tackled in: #10688.

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [X] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-05-30 17:49:59 -03:00
Martin Angers
4a077793f5
Return 400 instead of 500 on Apple BM auth error (#11899) 2023-05-29 11:52:42 -04:00
Mo Zhu
e1a0021e7a
remove address column from network_interfaces chromeos table (#11787)
Co-authored-by: Zach Wasserman <zach@fleetdm.com>
2023-05-26 16:47:19 -05:00
Juan Fernandez
de7377e54f
ChromeOS support for Fleet dashboard (#11953)
- Added built-in label for ChromeOS
- Ingest os_version info from ChromeOS hosts.
2023-05-26 14:32:01 -04:00
gillespi314
259d4fa1ac
Track host DEP assignments in new table (#11875) 2023-05-23 13:01:04 -05:00
Roberto Dip
dcc22f436b
allow to set await_device_configured in DEP profile (#11789)
#10744
2023-05-19 07:08:35 -03:00
Roberto Dip
8829b84a63
add migration support to FD and orbit (#11741)
https://github.com/fleetdm/fleet/issues/11534
2023-05-18 14:21:54 -03:00
Roberto Dip
8e532a5e76
pre-populate username/fullname during account creation (#11557)
Related to #10744, this pre-populates and disables the username/fullname
fields.

https://user-images.githubusercontent.com/4419992/236854781-ac67ee28-c19c-4130-a5e6-2872220501b5.mov


# Checklist for submitter

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

- [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] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)
- [x] Added/updated tests
- [x] Manual QA for all new/changed functionality
2023-05-18 12:50:00 -03:00
Juan Fernandez
009a87d33e
Feature 10196: Add filepath to end-points and third party integrations (#11285)
Adds the software installed path property to the proper end-points and third party integrations (webhook, Zendesk and Jira).
2023-05-17 16:53:15 -04:00
Martin Angers
3f9eccc7f8
Refetch host mdm enrollment status until unenrolled (#11740) 2023-05-17 15:52:45 -04:00
Lucas Manuel Rodriguez
47de991ea6
Use hostIDs in team deletion when setting status to pending (#11734)
Found this while working on #11531.

Team deletion for an empty team is taking ~30 seconds with 2632 hosts
that belong to no team.
This change attempts to fix that issue.

- ~[ ] 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.~
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [x] Added/updated tests
- [ ] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-05-17 16:49:02 -03:00
gillespi314
a7f02355fd
Add device-authenticated endpoint to trigger MDM migration webhook request (#11724) 2023-05-17 09:16:26 -05:00
Martin Angers
e3a4e5fa0c
Add support for profile UUIDs per team/no-team for the default profile (#11717) 2023-05-17 09:06:14 -04:00
Roberto Dip
4dd127d577
base logic to show/hide the new Migrate to Fleet FD menu (#11679)
Related to #11670
2023-05-15 17:00:52 -03:00
Martin Angers
7b1b392627
Implement worker jobs that update/re-assign setup assistants on changes (#11630) 2023-05-15 14:06:09 -04:00
RachelElysia
9e8698c779
CIS - WIN10 - Fix 3 policies with false positive bugs (#11668) 2023-05-12 10:57:09 -04:00
Marcos Oviedo
e46d748bd2
Adding CIS non completed items that requires cis_audit table (#11380)
This relates to #11245
2023-05-12 11:55:46 -03:00
Marcos Oviedo
424baf431b
Pusing pending CIS items (#11511)
This relates to #11312 

This completes the last 20 pending CIS policies [here
](https://docs.google.com/spreadsheets/d/1HZn7e4zpd5nfxY0MhSdX8MkGpdpxyLdSZjk0Auo1WaQ/edit#gid=1819959040)
2023-05-12 11:38:17 -03:00
RachelElysia
2523ae39aa
CIS - Windows - Fix CIS_bullet_18.9.85.1.1 (#11650) 2023-05-12 09:41:40 -04:00
gillespi314
a9584dc32f
Allow end user authentication during automatic MDM enrollment to be enabled on a per-team basis (#11566) 2023-05-10 15:22:08 -05:00
Martin Angers
70f18dda4a
Apply custom setup assistants (if present) when ingesting new devices (#11563) 2023-05-09 13:00:18 -04:00
Roberto Dip
33d788caed
add support for displaying EULA during ADE/DEP (#11532)
Related to #11350 and the sub-tasks for stuff that happens in setup
assistant: #11477 and #11479

This adds back-end and UI logic to show an EULA during DEP enrollment if
one was uploaded via the UI, if an EULA wasn't uploaded, we just proceed
to enroll the device right after authentication.


https://user-images.githubusercontent.com/4419992/236316655-282ee74a-5f79-4095-a950-82b77b80a5c0.mov
2023-05-05 14:36:13 -03:00
Sharon Katz
c3d960a036
start (#11503) 2023-05-05 12:19:20 -04:00
RachelElysia
bb3b788ce0
CIS - WIN10 - 18.9.81 to 18.9.83 (#11523) 2023-05-04 11:52:32 -04:00
Sharon Katz
a819a16fc4
17.8.1 (#11347)
Tested for Positive and Negative cases on my Win 10 Pro.
2023-05-04 10:44:26 -04:00
Martin Angers
b3993ebda4
Allow "not_before" timestamp for worker jobs, schedule more quickly (#11512) 2023-05-03 16:25:36 -04:00
RachelElysia
8389531e3b
CIS - WIN10 - 18.9.72 to 18.9.75 (#11510) 2023-05-03 14:45:20 -04:00
Roberto Dip
11356b2f15
add CRUD for EULA (#11274)
https://github.com/fleetdm/fleet/issues/10741
2023-05-02 10:09:33 -03:00
Roberto Dip
a23d208b1d
gate DEP enrollment behind SSO when configured (#11309)
#10739

Co-authored-by: Gabriel Hernandez <ghernandez345@gmail.com>
Co-authored-by: gillespi314 <73313222+gillespi314@users.noreply.github.com>
2023-04-27 09:43:20 -03:00
gillespi314
003e208e4d
Update CLI flow to manage adding and deleting MDM bootstrap packages by applying config and team specs (#11349) 2023-04-26 16:09:21 -05:00
gillespi314
8df5f26bea
Add user activity logs for MDM bootstrap package endpoints (#11302) 2023-04-26 13:40:14 -05:00
Martin Angers
77855a5e1d
Add activities for macOS setup assistant. (#11310) 2023-04-26 10:37:03 -04:00
Artemis Tosini
eb8de78a62
Add Windows 10 CIS 18.9.66-67 (#11143)
This is all 6 queries referenced in #10361. I've tested all queries on
Windows 10 Pro.

- [x] Manual QA for all new/changed functionality
2023-04-25 13:04:38 -04:00
Martin Angers
582e85c876
Add support for the mdm.macos_setup.macos_setup_assistant key in fleetctl, API (#11296) 2023-04-25 09:36:01 -04:00
RachelElysia
1fb9eeec64
CIS - WIN10 18.9.11.3.x (#11289) 2023-04-25 08:53:22 -04:00
Roberto Dip
5c487890ca
add an endpoint to get an aggregate summary of bootstrap packages (#11156)
Co-authored-by: gillespi314 <73313222+gillespi314@users.noreply.github.com>
Co-authored-by: Martin Angers <martin.n.angers@gmail.com>
2023-04-22 10:23:38 -05:00
Zach Wasserman
cda88779c1
Add note about ee license in ee directory (#11252) 2023-04-21 14:55:38 -07:00
Roberto Dip
ddb5894709
remove unused logic specific to DEP+Okta+ROP (#11261)
In #10338 we introduced logic to gate DEP profiles behind Okta auth
using the ROP flow.

We're not going to use that, and instead we're going to gate profiles
behind SSO, which can be used from multiple providers and supports SSO
(the initial motivation behind the ROP flow was to create a local user
account.)

This removes some of the old code, which was never used in
production/documented for the public to use.

At the moment I'm leaving the `mdm_idp_accounts` table and related
methods untouched, as it's unclear yet if we're going to need a similar
auxiliar table, and I would rather deal with the migrations all at once.
2023-04-21 14:57:52 -03:00
RachelElysia
3d78751875
CIS - WIN10 18.9.11.2.x (#11254) 2023-04-20 15:54:53 -04:00
Sharon Katz
ab572553c6
CIS_WIN_19.1-6 (#10988) 2023-04-17 15:24:00 -04:00
RachelElysia
3bd1a77716
CIS - WIN10 - 18.9.47.13 - 18.9.48.x (#11170) 2023-04-17 15:07:33 -04:00
RachelElysia
627ae5bf23
CIS - WIN10 - 17.5.x (Unable to audit/query) (#11166) 2023-04-17 14:52:46 -04:00
Lucas Manuel Rodriguez
1ebfbb14eb
New gitops role (#10850)
#8593

This PR adds a new role `gitops` to Fleet.
MDM capabilities for the role coming on a separate PR. We need this
merged ASAP so that we can unblock the UI work for this.

- [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] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)
- [X] Documented any permissions changes
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [x] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-04-12 16:11:04 -03:00
RachelElysia
3c177aa928
CIS - WIN10 - 18.9.10 to 18.9.11 (#11101) 2023-04-12 12:47:35 -04:00
Artemis Tosini
d1cf7e5a44
Add Windows 10 CIS 18.9.65.3.9-11 (#11067)
I've tested all queries on my system. I'm not quite sure if the cast is
necessary but it was common other queries so I used it. This adds the
queries referenced in #10360

- [x] Manual QA for all new/changed functionality
2023-04-11 16:39:29 -04:00
Zach Wasserman
8118bc77f1
Update fleetd chrome install instructions (#11150) 2023-04-11 12:34:36 -07:00
Artemis Tosini
62b4627f29
Add Windows 10 CIS 18.9.65.3.x (#11007)
This adds all queries referenced in #10359. Some are in the
non-completed since I couldn't test. The referenced UI path didn't exist
on the latest version if Wondows 10 and the ADMX is supposed to be built
in on recent version of Windows.

# Checklist for submitter
- [x] Manual QA for all new/changed functionality
2023-04-11 15:26:27 -04:00
Sharon Katz
e76adbecc8
CIS_WIN_18.5.9.2-BUG-FIX (#10955)
1. FIX for **18.5.9.2** - successfully tested for positive/negative
cases.

2. BUG in **18.5.11.3** and **18.5.11.4** - Registry keys do not appear.
Moved to **`NON-COMPLETED`**
2023-04-11 13:35:32 -04:00
Roberto Dip
a59b8a5096
various profile fixes (#11084)
### Related tickets

https://github.com/fleetdm/fleet/issues/10775
https://github.com/fleetdm/fleet/issues/10678
https://github.com/fleetdm/fleet/issues/11024
https://github.com/fleetdm/fleet/issues/11026

### What's happening

- Implemented the hashing mechanism defined by @mna in #10678, however
this mechanism is mainly relevant for batch profile updates via the CLI,
we can't leverage it when a host switches teams.
- Modified `BulkSetPendingMDMAppleHostProfiles` so when two profiles
with the same identifier are sheduled both for removal and update, the
function will now mark only the `install` as `pending` so it's picked by
the cron, and will `DELETE` the `remove` entry from the database so it's
not picked by the cron and never sent to the user.
- `GetHostMDMProfiles` and consequently the profiles returned in `GET
/api/_version_/fleet/hosts` return `host_mdm_apple_profiles.state =
NULL` as "Enforcing (pending", the distinction between `status =
'pending'` and `status IS NULL` is only useful for the cron, for users
both mean the same thing, and all our profile aggregations already
behave this way.
- Using the solution implemented by @gillespi314 in
https://github.com/fleetdm/fleet/pull/10998 we're now deleting the host
row from `host_disk_encryption_keys` if a host is moved from a team that
enforces disk encryption to a team that doesn't.


# Checklist for submitter

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

- [x] Added/updated tests
- [x] Manual QA for all new/changed functionality
2023-04-08 23:23:36 -03:00
Roberto Dip
77e5c004f4
implement bootstrap packages during DEP enrollment (#11052)
#10213
2023-04-07 17:31:02 -03:00
Marcos Oviedo
a576668cad
Pushing CIS policies from 18.9.103.1 to 18.9.105.2.1 (#10759)
This relates to #10366
2023-04-06 17:53:16 -03:00
Marcos Oviedo
4419820707
Pushing CIS policies for bullets 18.9.108.x.x (#10742)
This relates to #10367
2023-04-06 17:27:20 -03:00
Marcos Oviedo
242716c905
Adding COLLATE NOCASE to address case insesitive registry behavior (#11011)
It relates to bugs found in #9922
2023-04-05 17:22:07 -03:00
Sharon Katz
cea358f53a
CIS WIN 18.2 (#10876)
18.2.1 - successfully Tested for negative and positive cases
18.2.2 - successfully Tested for negative and positive cases
18.2.3 - successfully Tested for negative and positive cases
18.2.4 - successfully Tested for negative and positive cases
18.2.5 - successfully Tested for negative and positive cases
18.2.6 - successfully Tested for negative and positive cases
2023-04-05 10:52:24 -04:00
Artemis Tosini
0b6313bd6b
CIS win10 18.9.46-47 (#10916)
Many of these queries reference registry keys that do not exist so I
moved them to the NON-COMPLETED file. However, all queries name in
#10355 are included in either the main or non completed file.

- [x] Manual QA for all new/changed functionality
2023-04-04 15:41:19 -04:00
Roberto Dip
77d63f12dd
fix TestGroupFromBytesWithWin10CISQueries (#10953)
Go tests are failing in main with:

```
=== RUN   TestGroupFromBytesWithWin10CISQueries
    spec_test.go:69:
        	Error Trace:	/Users/roperzh/fleet/pkg/spec/spec_test.go:69
        	Error:      	Received unexpected error:
        	            	failed to unmarshal spec item error converting YAML to JSON: yaml: line 20: mapping values are not allowed in this context:
        	            	apiVersion: v1
        	            	kind: policy
        	            	spec:
        	            	  name: CIS - Ensure 'Audit Other Object Access Events' is set to 'Success and Failure'
        	            	  platforms: win10
        	            	  platform: windows
        	            	  description: |
        	            	    This policy setting allows you to audit events generated by the management of task scheduler jobs or COM+ objects.
        	            	    For scheduler jobs, the following are audited:
        	            	      -  Job created.
        	            	      -  Job deleted.
        	            	      -  Job enabled.
        	            	      -  Job disabled.
        	            	      -  Job updated.
        	            	    For COM+ objects, the following are audited:
        	            	      -  Catalog object added.
        	            	      -  Catalog object updated.
        	            	      -  Catalog object deleted.
        	            	The recommended state for this setting is: Success and Failure.
        	            	  resolution: |
        	            	    Automatic method:
        	            	    Ask your system administrator to establish the recommended configuration via GP, set the following UI path to Success and Failure:
        	            	    'Computer Configuration\Policies\Windows Settings\Security Settings\Advanced Audit Policy Configuration\Audit Policies\Object Access\Audit Other Object Access Events'
        	            	  query: |
        	            	    SELECT 1 FROM mdm_bridge where mdm_command_input = "<SyncBody><Get><CmdID>1</CmdID><Item><Target><LocURI>./Device/Vendor/MSFT/Policy/Result/Audit/ObjectAccess_AuditOtherObjectAccessEvents</LocURI></Target></Item></Get></SyncBody>"
        	            	    AND mdm_command_output = 3;
        	            	  purpose: Informational
        	            	  tags: compliance, CIS, CIS_Level1, CIS_win10_enterprise_1.12.0, CIS_bullet_17.6.3
        	            	  contributors: sharon-fdm
        	Test:       	TestGroupFromBytesWithWin10CISQueries
--- FAIL: TestGroupFromBytesWithWin10CISQueries (0.31s)
```

This adds a missing indentation to make them pass.
2023-04-04 08:39:35 -03:00
gillespi314
750d64ccca
Add dontAllowFDEDisable to FileVault config profile template (#10941) 2023-04-03 14:22:41 -05:00
Sharon Katz
992a68c435
WIN CIS 17.6.1 (#10912) 2023-04-03 15:09:26 -04:00
Sharon Katz
ba290ffbb7
move-18.9.47.9.4-to-not-completed (#10938)
18.9.47.9.4 needs to be tested then moved back to the main .yml
2023-04-03 15:06:59 -04:00
Sharon Katz
f42ea50cff
18.9.57.1 (#10861) 2023-03-30 13:31:55 -04:00
Sharon Katz
5f42f39019
CIS_WIN_18.9.47.9.x (#10791) 2023-03-29 16:10:15 -04:00
RachelElysia
a21c96330b
CIS - WIN10 - 19.7.28 to 19.7.47 (#10781) 2023-03-29 12:53:55 -04:00
Lucas Manuel Rodriguez
22774243e2
Delete cis-policy-query-verify-iCloud-Keychain-disabled.yml (#10851)
We already have 2.1.1.1 with the `enable`/`disable` approach in the main
yaml.
2023-03-29 13:29:10 -03:00
Artemis Tosini
1e976f0d25
Add Windows 10 CIS 17.1-17.3 queries (#10522)
These 6 queries are extremely similar so I just put them in a single
commit. These issues are tracked in #10139.
2023-03-29 11:01:05 -04:00
Sharon Katz
d54e354022
CIS MAC 1.1 fix (#10619) 2023-03-29 09:24:33 -04:00
Juan Fernandez
aecc2fed75
Feature 9834: Add published date to vulnerability object (#10434)
This only applies to Premium users, we want to show the vulnerabilities' published date anywhere vulnerabilities are shown including API endpoints and third party integrations.
2023-03-28 16:11:31 -04:00
Lucas Manuel Rodriguez
40265d0e6f
Fix SMTP e-mail send when SMTP server has credentials (#10758)
#9609

This PR also fixes #10777.

The issue is: We were using `svc.AppConfig` instead of
`svc.ds.AppConfig` to retrieve the SMTP credentials.
`svc.AppConfig` obfuscates credentials, whereas `svc.ds.AppConfig` does
not.
To help prevent this from happening again I've renamed `svc.AppConfig`
to `svc.AppConfigObfuscated`.
I've also added a new test SMTP server
(https://github.com/axllent/mailpit) that supports Basic Authentication
and tests that make use of it to catch these kind of bugs (the tests are
executed when running `go test` with `MAIL_TEST=1`).

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [X] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-03-28 15:23:15 -03:00
Artemis Tosini
1d2ae58d5f
Add macOS CIS 5.3.2 (#10726)
Add 2 new tables: corestorage_logical_volumes and corestorage_logical_volume_families.
Add a query that uses these tables
2023-03-28 11:57:38 -04:00
Roberto Dip
98845f03a6
remove feature flags to enable MDM (#10746)
https://github.com/fleetdm/fleet/issues/10025
2023-03-27 16:30:29 -03:00
Martin Angers
b6e10eb6da
Update host MDM profile status to pending in response to triggering events (#10443) 2023-03-27 14:43:01 -04:00
Marcos Oviedo
518cbecfbf
cis18.9.100.x to cis18.9.102.x (#10717)
This relates to #10365
2023-03-23 17:54:16 -03:00
RachelElysia
ee116d14ca
CIS - WIN10 - 19.7.4 to 19.7.8 (#10715)
## Issue 
Cerra #10369

## Description
- Lots of trial and error to get the wild card to work (only works with
single \ in the path)
- 6 of 7 tested and working
- Final policy is intended for Windows 11
2023-03-23 17:08:00 -03:00
RachelElysia
1256d1d4b6
CIS - WIN10 - 18.4.1 - 18.4.13 (#10707) 2023-03-23 11:34:48 -04:00
Martin Angers
2fb5aa629d
Normalize the naming of mdm settings, update docs and document missing ones (#10681)
#10408
2023-03-23 07:30:28 -03:00
Josh Brower
c83bc3dd68
CIS WIN10 - 18.5.4.1 - 18.2.11.4 (#10686) 2023-03-22 16:39:10 -04:00
RachelElysia
01e5742d60
CIS - WIN10 - 18.9.89 to 18.9.91 (#10641) 2023-03-21 14:23:00 -04:00
RachelElysia
45bc73be3c
CIS - WIN10 - 18.9.18 to 18.9.27 (#10633) 2023-03-21 11:25:24 -04:00
RachelElysia
c82026e930
CIS - WiN10 - 18.9.31 to 18.9.45 (#10632) 2023-03-21 09:51:26 -04:00
RachelElysia
f6741a43ec
CIS - WIN10 - 18.3.X policies (#10336) 2023-03-20 16:40:04 -04:00
Roberto Dip
61a8a80514
allow to rotate disk encryption key from My Device (#10592)
Related to https://github.com/fleetdm/fleet/issues/8961

Co-authored-by: Martin Angers <martin.n.angers@gmail.com>
2023-03-20 16:14:07 -03:00
Sharon Katz
535ea715a4
Reformat MAC CIS 6.3.5 queries (#10560) 2023-03-20 11:50:35 -04:00
RachelElysia
95fb828a03
CIS - WIN10 - 18.8.17 - 18.8.27 (#10430) 2023-03-20 09:41:11 -04:00
Roberto Dip
f04ff27180
Prevent user action in profiles managed by Fleet (#10559)
related to https://github.com/fleetdm/fleet/issues/10547,
https://github.com/fleetdm/fleet/issues/10549,
https://github.com/fleetdm/fleet/issues/10550 and
https://github.com/fleetdm/fleet/issues/10552 this prevents user
interaction with fleet-managed profiles, including:

- batch actions
- individual POST/UPDATE/DELETE actions
- listing

# Checklist for submitter

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

- [x] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)
- [x] Added/updated tests
2023-03-17 18:52:30 -03:00
RachelElysia
0614a8543f
CIS - WIN10 - 18.9.17.x (#10529) 2023-03-17 14:53:41 -04:00
RachelElysia
5af7aaf12a
CIS - WIN10 - 18.8.38+ (#10449) 2023-03-17 11:41:19 -04:00
Zach Wasserman
42b3e5602e
Fleetd for Chrome (#10281)
# Checklist for submitter

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

- [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
2023-03-16 09:01:10 -03:00
Zach Wasserman
05d8f5dbbd
Fix indentation typo in CIS yaml (#10525)
Caused a failure in
b7ebddcd66/pkg/spec/spec_test.go (L64)
2023-03-15 17:05:31 -07:00
Sharon Katz
58b8d65b6f
MAC CIS 13 2.5.1 (#10168) 2023-03-15 16:40:54 -04:00
RachelElysia
b49c6c82c3
CIS - WIN10 - Move approved policies to correct file (#10509) 2023-03-15 11:33:30 -04:00
RachelElysia
3a170a8df0
CIS - WIN10 - 18.8.28 to 18.8.37 (#10452) 2023-03-15 09:28:54 -04:00
Lucas Manuel Rodriguez
d09252e1ea
Fix YAML and add item to error (#10503) 2023-03-15 08:50:13 -03:00
Martin Angers
276c767ab9
Update aggregated_stats to support "no team" in addition to "all teams" (#10466) 2023-03-14 17:01:16 -04:00
RachelElysia
7fe196304c
CIS - WIN10 - 18.9.12 to 18.9.16 (#10465) 2023-03-14 16:36:34 -04:00
Lucas Manuel Rodriguez
6d918d1366
Add enable_jit_role_sync config (#10478)
#8411

We decided to only update roles for existing accounts if enabled by a
new setting (disabled by default) `sso_settings.enable_jit_role_sync`.

- ~[ ] 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.~
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [X] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-03-14 17:17:08 -03:00
Sharon Katz
c4fa0393af
Audit Location Services Access (#10459)
Tested on my Mac
2023-03-14 12:53:32 -04:00
Marcos Oviedo
a8282864e3
CIS 18.9.4.x to cis 18.9.8.x (#10451)
This relates to #10347
2023-03-13 17:19:21 -03:00
Artemis Tosini
924206982b
Fix indentation issue in macOS 13 CIS (#10448) 2023-03-13 14:19:48 -04:00
Lucas Manuel Rodriguez
3757aace08
Add UUID to Fleet errors and clean up error msgs (#10411)
#8129 

Apart from fixing the issue in #8129, this change also introduces UUIDs
to Fleet errors. To be able to match a returned error from the API to a
error in the Fleet logs. See
https://fleetdm.slack.com/archives/C019WG4GH0A/p1677780622769939 for
more context.

Samples with the changes in this PR:
```
curl -k -H "Authorization: Bearer $TEST_TOKEN" -H 'Content-Type:application/json' "https://localhost:8080/api/v1/fleet/sso" -d ''
{
  "message": "Bad request",
  "errors": [
    {
      "name": "base",
      "reason": "Expected JSON Body"
    }
  ],
  "uuid": "a01f6e10-354c-4ff0-b96e-1f64adb500b0"
}
```
```
curl -k -H "Authorization: Bearer $TEST_TOKEN" -H 'Content-Type:application/json' "https://localhost:8080/api/v1/fleet/sso" -d 'asd'
{
  "message": "Bad request",
  "errors": [
    {
      "name": "base",
      "reason": "json decoder error"
    }
  ],
  "uuid": "5f716a64-7550-464b-a1dd-e6a505a9f89d"
}
```
```
curl -k -X GET -H "Authorization: Bearer badtoken" "https://localhost:8080/api/latest/fleet/teams"
{
  "message": "Authentication required",
  "errors": [
    {
      "name": "base",
      "reason": "Authentication required"
    }
  ],
  "uuid": "efe45bc0-f956-4bf9-ba4f-aa9020a9aaaf"
}
```
```
curl -k -X PATCH -H "Authorization: Bearer $TEST_TOKEN" "https://localhost:8080/api/latest/fleet/users/14" -d '{"name": "Manuel2", "password": "what", "new_password": "p4ssw0rd.12345"}'
{
  "message": "Authorization header required",
  "errors": [
    {
      "name": "base",
      "reason": "Authorization header required"
    }
  ],
  "uuid": "57f78cd0-4559-464f-9df7-36c9ef7c89b3"
}
```
```
curl -k -X PATCH -H "Authorization: Bearer $TEST_TOKEN" "https://localhost:8080/api/latest/fleet/users/14" -d '{"name": "Manuel2", "password": "what", "new_password": "p4ssw0rd.12345"}'
{
  "message": "Permission Denied",
  "uuid": "7f0220ad-6de7-4faf-8b6c-8d7ff9d2ca06"
}
```

- [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] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-03-13 13:44:06 -03:00
Artemis Tosini
ec746374d3
Add macOS CIS 6.3.5 (Safari Hide IP Addresses) (#10316)
This adds two conflicting checks for macOS CIS 6.3.5. Proxying requests
to 3rd party trackers may protect private information but it may also be
against company policy as it routes data throught a 3rd party service.

There's no documentation about now to set this through a policy or
script, and in fact I can find no information about what this bitfield
means, except the incorrect and conflicting documentation in the CIS
pdf.

Co-authored-by: Sharon Katz <sharon@fleetdm.com>
2023-03-13 12:24:00 -04:00
Marcos Oviedo
9cb2ef14ff
CIS 5.23 to CIS 5.45 (#10410)
This relates to #9926
2023-03-13 10:49:33 -03:00
Roberto Dip
a1ca172c95
allow to set up a DEP flow gated by Okta auth (#10338)
#10271
2023-03-13 10:33:32 -03:00
RachelElysia
f97b13d8c0
CIS - WIN10 - 18.8.1. - 18.8.16 (#10407) 2023-03-13 09:25:04 -04:00
Roberto Dip
bf776536ca
add PoC for puppet + fleet MDM (#10424) 2023-03-10 16:06:40 -06:00
RachelElysia
3ee113911c
CIS - WIN10 - 18.6.x and 18.7.x policies (#10344) 2023-03-10 14:29:26 -05:00
Artemis Tosini
af4c3f7061
Add macOS CIS 5.3.1 (#10397)
This adds a new check about whether all APFS volumes are encrypted. I
needed to add a new table, and I took that opportunity to add another so
that osquery has all information from `diskutil apfs list -plist`.

Note that it is somewhat unclear whether to use the `encryption` or
`filevault` field in the query. FileVault is about whether the volume is
encrypted with a password and Encryption is about whether it is
encrypted at all, since all modern macs have hardware-backed disk
encryption.
2023-03-10 12:29:14 -05:00
Sharon Katz
8c04711f60
add minimumMixedCaseCharacters (#10401) 2023-03-09 15:44:28 -05:00
Marcos Oviedo
469ce0f841
Fixing CIS testcases (#10296)
This relates to #9848
2023-03-09 11:33:20 -03:00
Sharon Katz
312ad09e6d
Separate YMLs (#10386) 2023-03-08 13:55:55 -05:00
Sharon Katz
eae7ca23fa
empty non-complited yml (#10389) 2023-03-08 13:46:23 -05:00
Martin Angers
765c8754b6
Add enabled/disabled disk encryption activities and trigger profiles generation (#10319) 2023-03-08 08:31:53 -05:00
Josh Brower
4316fe945f
Initial cut for CIS 9.1.x (#10307) 2023-03-07 17:30:12 -05:00
Martin Angers
50a2739609
Allow updating enable_disk_encryption via the Modify Team endpoint (#10208) 2023-03-06 09:54:51 -05:00
Artemis Tosini
07a045301b
Add macOS CIS 2.6.7 (Administrator password for preferences) (#10259)
This adds a test for if passwords are required are required to access
some system-wide preferences on macOS. It's marked as "Manual" in the
CIS pdf but I wasn't sure how to copy that into here.
2023-03-03 15:41:51 -05:00
Sharon Katz
cf18f1f79f
CIS_MAC13_5.2.5 (#10251) 2023-03-03 15:14:00 -05:00
Sharon Katz
2295575fdb
CIS_MAC13_2.8.1 (#10192) 2023-03-03 15:12:23 -05:00
Marcos Oviedo
a2e8a787c9
Pushing CIS policies check for 2.2.8 to 2.2.39 (#10283)
This relates to #9848
2023-03-03 17:05:07 -03:00
Marcos Oviedo
aafc59bd7e
CIS policies for 2.3.14.x-2.3.15.x (#10211)
This relates to #9923
2023-03-03 16:56:11 -03:00
Marcos Oviedo
83fb9d312c
CIS policies for 2.3.11.x (#10167)
This relates to #9851
2023-03-03 16:42:22 -03:00
Sharon Katz
0867679eeb
CIS_MAC13_6.3.2 (#10258) 2023-03-03 14:15:03 -05:00
Lucas Manuel Rodriguez
e0cbc3aad7
Add automation for win-10 cis policies and fix yaml (#10289) 2023-03-03 16:11:04 -03:00
Sharon Katz
1741c4ddd3
CIS_MAC13_5.2.3_5.2.4 (#10248) 2023-03-03 14:06:15 -05:00
Marcos Oviedo
f7c1cc0c87
Pushing changes for cis2.3.8 to cis2.3.9 compliance checks (#10115)
This relates to #9851
2023-03-03 15:49:53 -03:00
RachelElysia
db9ed90b0c
CIS - WIN10 - 9.3.X policies (#10253) 2023-03-03 13:37:03 -05:00
RachelElysia
82e81a7b06
CIS - WIN10 - 9.2.X policies (#10254) 2023-03-03 13:13:09 -05:00
RachelElysia
0b4ae4f621
CIS - WIN10 - 18.X.X policies (#10286) 2023-03-03 12:52:18 -05:00
Artemis Tosini
1dcced4554
Add Windows 10 CIS 2.3.6.x (#10036)
This adds CIS 2.3.6.x items from Windows 10 Enterprise. I tested all of
these on Windows Server 2019 as my Windows 10 machine hasn't arrived
yet, but they should be identical.

I originally thought this was not possible but I did not realize that
the GPO always seems to change the registry key and does not act as the
single source of truth, unlike profiles on macOS.
2023-03-03 10:47:10 -05:00
Benjamin Edwards
1fb1870ca7
add tier trial that behaves the same as premium (#10157) 2023-03-03 10:46:50 -05:00
RachelElysia
6b2cebd4f1
CIS - WIN10 - 2.3.17.X (#10275) 2023-03-02 17:18:02 -05:00
Sharon Katz
8c9d33f455
MAC CIS 13_2.1.1.2 (#10161) 2023-03-02 10:04:27 -05:00
Sharon Katz
a19d73511e
MAC CIS 13_2.1.1.1 (#10120) 2023-03-02 09:54:37 -05:00
Lucas Manuel Rodriguez
9864048ee9
Allow setting user roles during JIT provisioning (#10193)
#8411

PS: I've opened #10209 to solve the issue with Golang Code Coverage CI
checks.

- [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] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)
- ~[] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [x] Manual QA for all new/changed functionality
  - ~For Orbit and Fleet Desktop changes:~
- ~[ ] Manual QA must be performed in the three main OSs, macOS, Windows
and Linux.~
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-03-01 20:18:40 -03:00
RachelElysia
4c80e1808b
CIS - WIN10 - 2.3.10.X policies (#10178) 2023-03-01 10:28:45 -05:00
Roberto Dip
164bb4bf5c
add logic to configure FileVault + escrow (#10160)
Related to #9495, this adds the underlying methods to send a
configuration profile that enables FileVault and FileVault Escrow, so we
can fetch and decrypt the encryption key later on.

These methods still need to be called somewhere, and they might need to
be moved outside of `Service`, but at least this gives us a start.
2023-03-01 10:43:15 -03:00
Martin Angers
4593c49ec4
Add disk_encryption option to config and team YAML (#10185) 2023-02-28 15:34:46 -05:00
dependabot[bot]
5f95975a05
Bump jsonwebtoken from 8.5.1 to 9.0.0 in /ee/tools/license (#9109)
Bumps [jsonwebtoken](https://github.com/auth0/node-jsonwebtoken) from
8.5.1 to 9.0.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/auth0/node-jsonwebtoken/blob/master/CHANGELOG.md">jsonwebtoken's
changelog</a>.</em></p>
<blockquote>
<h2>9.0.0 - 2022-12-21</h2>
<p><strong>Breaking changes: See <a
href="https://github.com/auth0/node-jsonwebtoken/wiki/Migration-Notes:-v8-to-v9">Migration
from v8 to v9</a></strong></p>
<h3>Breaking changes</h3>
<ul>
<li>Removed support for Node versions 11 and below.</li>
<li>The verify() function no longer accepts unsigned tokens by default.
([834503079514b72264fd13023a3b8d648afd6a16]<a
href="8345030795</a>)</li>
<li>RSA key size must be 2048 bits or greater.
([ecdf6cc6073ea13a7e71df5fad043550f08d0fa6]<a
href="ecdf6cc607</a>)</li>
<li>Key types must be valid for the signing / verification
algorithm</li>
</ul>
<h3>Security fixes</h3>
<ul>
<li>security: fixes <code>Arbitrary File Write via verify
function</code> - CVE-2022-23529</li>
<li>security: fixes <code>Insecure default algorithm in jwt.verify()
could lead to signature validation bypass</code> - CVE-2022-23540</li>
<li>security: fixes <code>Insecure implementation of key retrieval
function could lead to Forgeable Public/Private Tokens from RSA to
HMAC</code> - CVE-2022-23541</li>
<li>security: fixes <code>Unrestricted key type could lead to legacy
keys usage</code> - CVE-2022-23539</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e1fa9dcc12"><code>e1fa9dc</code></a>
Merge pull request from GHSA-8cf7-32gw-wr33</li>
<li><a
href="5eaedbf2b0"><code>5eaedbf</code></a>
chore(ci): remove github test actions job (<a
href="https://github-redirect.dependabot.com/auth0/node-jsonwebtoken/issues/861">#861</a>)</li>
<li><a
href="cd4163eb14"><code>cd4163e</code></a>
chore(ci): configure Github Actions jobs for Tests &amp; Security
Scanning (<a
href="https://github-redirect.dependabot.com/auth0/node-jsonwebtoken/issues/856">#856</a>)</li>
<li><a
href="ecdf6cc607"><code>ecdf6cc</code></a>
fix!: Prevent accidental use of insecure key sizes &amp;
misconfiguration of secr...</li>
<li><a
href="8345030795"><code>8345030</code></a>
fix(sign&amp;verify)!: Remove default <code>none</code> support from
<code>sign</code> and <code>verify</code> met...</li>
<li><a
href="7e6a86b1c2"><code>7e6a86b</code></a>
Upload OpsLevel YAML (<a
href="https://github-redirect.dependabot.com/auth0/node-jsonwebtoken/issues/849">#849</a>)</li>
<li><a
href="74d5719bd0"><code>74d5719</code></a>
docs: update references vercel/ms references (<a
href="https://github-redirect.dependabot.com/auth0/node-jsonwebtoken/issues/770">#770</a>)</li>
<li><a
href="d71e383862"><code>d71e383</code></a>
docs: document &quot;invalid token&quot; error</li>
<li><a
href="37650031fd"><code>3765003</code></a>
docs: fix spelling in README.md: Peak -&gt; Peek (<a
href="https://github-redirect.dependabot.com/auth0/node-jsonwebtoken/issues/754">#754</a>)</li>
<li><a
href="a46097e962"><code>a46097e</code></a>
docs: make decode impossible to discover before verify</li>
<li>Additional commits viewable in <a
href="https://github.com/auth0/node-jsonwebtoken/compare/v8.5.1...v9.0.0">compare
view</a></li>
</ul>
</details>
<details>
<summary>Maintainer changes</summary>
<p>This version was pushed to npm by <a
href="https://www.npmjs.com/~julien.wollscheid">julien.wollscheid</a>, a
new releaser for jsonwebtoken since your current version.</p>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=jsonwebtoken&package-manager=npm_and_yarn&previous-version=8.5.1&new-version=9.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/fleetdm/fleet/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-02-27 18:23:18 -08:00
Sharon Katz
5603190d6a
CIS Win10 1.2.1-1.2.3 + 2.2.1-2.2.7 (Some empty queries) (#9839) 2023-02-24 09:20:27 -05:00
Marcos Oviedo
7e95c52213
Pushing CIS policy checks for 2.3.1.x to 2.3.7.x (#9902)
This relates to #9850
2023-02-23 14:04:23 -03:00
Lucas Manuel Rodriguez
f4df9b58a4
Add docs for cis benchmarks macOS 13 (#9987)
See #9974.

---------

Co-authored-by: Mo Zhu <mo@fleetdm.com>
2023-02-22 18:07:36 -03:00
Roberto Dip
8284274c3b
incomplete implementation of device wipe and lock (#9947) 2023-02-22 17:11:44 -03:00
Martin Angers
4a1f3988f0
Add "edited macos profiles" activity when applying custom settings via fleetctl (#9862)
#9587 and #9639
2023-02-16 13:53:26 -03:00
Martin Angers
33f33163a9
Add macos custom profiles support via fleetctl apply (#9824) 2023-02-15 13:01:44 -05:00
Sharon Katz
4c22fbffd6
rename cis label to win10-stand-alone (#9816) 2023-02-14 14:52:15 -05:00
Sharon Katz
9125263c14
add details to CIS label (#9811) 2023-02-14 10:05:44 -05:00
Sharon Katz
0ddd0d64f7
CIS_fix_desc_errors (#9789) 2023-02-10 12:48:44 -05:00
Artemis Tosini
d36e89a0ef
Add macOS CIS 6.3.3 (Safari Safe Browsing) (#9778) 2023-02-09 13:46:42 -05:00
Lucas Manuel Rodriguez
4a5ce51d49
CIS yaml fixes (#9775) 2023-02-09 15:28:47 -03:00
Sharon Katz
1fc799577d
CIS 6.4.1 (#9773) 2023-02-09 13:22:36 -05:00
Sharon Katz
c7827cf5b1
CIS 6.3.7 (#9767) 2023-02-09 13:15:21 -05:00
Artemis Tosini
6b50914500
Add macOS CIS 2.3.3.10 (Media Sharing) (#9666) 2023-02-09 12:55:22 -05:00
Lucas Manuel Rodriguez
9fa2be0a86
Add check for CIS 5.10 (#9755)
#9260

- ~[ ] 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.~
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- ~[ ] Added/updated tests~
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-09 14:28:22 -03:00
Lucas Manuel Rodriguez
399a6f53e7
Add check for CIS 6.3.4 (#9766)
#9261
2023-02-09 14:28:02 -03:00
Lucas Manuel Rodriguez
4638e8564f
Add check for CIS 5.6 (#9756)
#9260

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-09 14:27:40 -03:00
Lucas Manuel Rodriguez
8af2b56cd5
Add check for macOS CIS 5.9 (#9765)
#9260

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- ~[ ] Added/updated tests~
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-09 14:05:55 -03:00
Artemis Tosini
a92b311030
Add macOS CIS 6.3.1 (Safari Automatic Opening) (#9759) 2023-02-09 11:41:18 -05:00
Artemis Tosini
6d82515b02
Add macOS CIS 2.3.3.8 (Internet Sharing) (#9663) 2023-02-09 11:15:40 -05:00
Lucas Manuel Rodriguez
c6e1447084
Add check for CIS 6.3.6 (#9768)
#9261
2023-02-09 12:36:40 -03:00
Lucas Manuel Rodriguez
7fc3613dc5
Add CIS checks for 5.4 and 5.5 (#9747)
#9260

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-09 12:35:43 -03:00
Sharon Katz
c248968ba3
CIS 2.3.3.9 (#9752) 2023-02-08 15:43:03 -05:00
Artemis Tosini
9fd70ee9e0
Add macOS CIS 2.3.3.7 (Remote Apple Events) (#9751) 2023-02-08 14:13:11 -05:00
Lucas Manuel Rodriguez
2265c84b2a
Add CIS check for 5.8 (#9750)
#9260

- ~[ ] 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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- ~[ ] Added/updated tests~
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-08 13:38:17 -03:00
Lucas Manuel Rodriguez
d4a1b4d218
Add CIS checks for 2.9.X and add pmset table to fleetd (#9470)
#9253

- ~[ ] 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.~
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~

---------

Co-authored-by: Sharon Katz <121527325+sharon-fdm@users.noreply.github.com>
2023-02-08 13:08:17 -03:00
Artemis Tosini
b6968892b0
Add macOS CIS 6.1.1 (Show All Filename Extensions) (#9740)
This adds CIS 6.1.1
---------
Co-authored-by: Sharon Katz <sharon@fleetdm.com>
Approved by: Sharon Katz <sharon@fleetdm.com>
2023-02-08 10:51:42 -05:00
Lucas Manuel Rodriguez
086ec05ca7
Add CIS check for 5.7 (#9748)
#9260

- [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.
- ~[ ] Documented any API changes (docs/Using-Fleet/REST-API.md or
docs/Contributing/API-for-contributors.md)~
- ~[ ] Documented any permissions changes~
- ~[ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)~
- ~[ ] Added support on fleet's osquery simulator `cmd/osquery-perf` for
new osquery data ingestion features.~
- [X] Added/updated tests
- [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.
- ~[ ] Auto-update manual QA, from released version of component to new
version (see [tools/tuf/test](../tools/tuf/test/README.md)).~
2023-02-08 12:30:55 -03:00
Sharon Katz
9672f03d37
CIS 5.1.5/5.1.6/5.1.7 (#9726) 2023-02-08 10:11:20 -05:00
Sharon Katz
84fcee9130
CIS 5.1.3+5.1.4 (#9642) 2023-02-07 13:26:05 -05:00
Artemis Tosini
61da4d3331
Add macOS CIS 2.3.3.4 (Printer Sharing) (#9665)
This makes sure printer sharing is disabled on macOS using the CUPS
configuration file. This script makes a change that both works and is
reflected in the macOS UI, unlike many of the scripts
2023-02-06 17:12:17 -05:00
Artemis Tosini
857e6830d8
Add macOS CIS 2.3.3.11 (Bluetooth Sharing) (#9688)
This adds a test for 2.3.3.11, which verifies that all users have
Bluetooth sharing disabled.

It's not possible to create a profile and it's challenging to write a
script, so testing must be done manually.
As with all sharing tests, the machine will be compliant out of the box.
For QA you should open the sharing preference pane (System Settings >
General > Sharing) and then enable Bluetooth sharing and this test
should fail. Switching bluetooth sharing back off will fix it.
2023-02-06 15:29:47 -05:00