Tomas Touceda
53ba8f07ea
Issue 3882 clean team packs ( #4002 )
...
* Cleanup team schedules when deleting teams
* Add changes file
* Improve code readability
* Reuse func instead of formatting twice
2022-02-03 14:55:48 -03:00
Martin Angers
6e2ba62744
Trigger webhooks for recently published vulnerabilities ( #3941 )
2022-02-02 16:34:37 -05:00
Martin Angers
6319812984
Fix column name when detecting order by ( #3978 )
2022-02-02 10:08:51 -05:00
Tomas Touceda
a63c549f07
Make software filter by counts faster ( #3975 )
...
* Make software filter by counts faster
* Sort only when it's for the agg table
2022-02-02 09:51:56 -03:00
Martin Angers
ecf6bd8907
Migrate more user-authenticated endpoints to new pattern ( #3933 )
2022-01-31 16:35:22 -05:00
Tomas Touceda
e956b0ba04
Add filter software by CVE and make osquery-perf also push vulnerable software ( #3902 )
...
* Add filter software by CVE and make osquery-perf also push vulnerable software
* Update based on review comments
2022-01-28 10:05:11 -03:00
Tomas Touceda
ffabf803a3
Aggregate munki and mdm data ( #3886 )
...
* Aggregate munki and mdm data
* Update doc
* Use reader to read
* Reader to read
* Address review comments
2022-01-26 17:55:07 -03:00
Martin Angers
a6f3f02a85
Cleanup unused software after calculating the count of hosts ( #3887 )
2022-01-26 11:32:42 -05:00
Martin Angers
9a0f749641
Add hosts_count
field to "list software" endpoint ( #3873 )
2022-01-26 09:47:56 -05:00
Martin Angers
8b8cebb6fe
Migrate remaining user-authenticated endpoints ( #3796 )
2022-01-25 09:34:00 -05:00
Tomas Touceda
f02bef6f2c
Add platform filter to host_summary ( #3845 )
...
* Add platform filter to host_summary
* Add documentation
* Actually forward the platform param down the chain
* Update mock
* Update mock
2022-01-24 14:49:21 -03:00
Lucas Manuel Rodriguez
81672ee50e
Add dev sql interceptor for logging of queries ( #3815 )
...
* Add dev sql interceptor for logging of queries
* Remove extra spaces and tabs from queries
* Make regex global
2022-01-21 14:28:21 -03:00
Martin Angers
afb3310937
Migrate team-related endpoints to new pattern ( #3740 )
2022-01-19 10:52:14 -05:00
Tomas Touceda
eee539cccc
Issue 3707 clean targets on delete ( #3739 )
...
* wip
* Delete targets when deleting teams, hosts, and labels
* Add changes file
* Fix error message
* Remove unused teamsTable
* Cleanup new pack
* Clean new packs at end of test
2022-01-19 10:28:08 -03:00
Martin Angers
f19e676e62
Refactor async host processing to avoid redis SCAN keys (for policies) ( #3657 )
2022-01-18 09:56:43 -05:00
Lucas Manuel Rodriguez
371c533bfc
Improved Datastore usage of osquery hosts requests ( #3601 )
...
* WIP
* Amend tests
* Do not load aggregated stats for packs
* Add option to host lite
* Fix remaining TODOs
* Fix osquery_utils tests
* Fix SQL
* Fix SQL (bis)
* Restore AuthenticateHost to load once
* Code improvements and re-add deferred host save
* More fixes to the PR
* Wrap users table update on tx
* Add caching to ListPacksForHost and ListScheduledQueriesInPack
* Remove SaveHostSoftware (replaced by UpdateHostSoftware)
* Add unit tests for new functionality
* Add changes file
* Fix scheduled queries test
2022-01-17 22:52:09 -03:00
gillespi314
dc8eacc95c
Add AvailableTeams to loginResponse and getUserResponse ( #3585 )
2022-01-13 13:57:44 -06:00
gillespi314
6952653e1b
Fix usage stats to send missing numLabels field ( #3606 )
2022-01-13 11:11:13 -06:00
Tomas Touceda
4bed4757fb
Remove cleanups and fk for host ids ( #3607 )
...
* Remove cleanups and fk for host ids
* Readd missing things to the schema
* Remove unused
* Add changes file and fix some error messages
* Fix test
* Use tx instead of plain writer
* Other fixes
* More not found test fixes
* Go back to getcontext
2022-01-12 14:07:51 -03:00
Tomas Touceda
312bd840a2
Detect not found errors for queries and policies ( #3595 )
...
* Detect not found errors for queries and policies
* Fix test
2022-01-12 10:04:16 -03:00
Lucas Manuel Rodriguez
49ceee59aa
Add fixes for running tests with mysql:8 and add mysql
to test-go
job matrix ( #3627 )
...
* Add fixes for running tests with mysql:8
* Add getServer function
* Test github matrix
* Add changes file for the user facing fix
* Remove unused mysql8 docker-compose
2022-01-11 22:44:37 -03:00
Tomas Touceda
c662cd2b53
Add policies yaml ( #3464 )
...
* Add policies yaml
* Add documentation and address review comments
* Amend documentation
2022-01-11 11:04:29 -03:00
Zach Wasserman
bda2ef0ca0
Fix regex matching email in host search ( #3539 )
...
Fixes #3528
2021-12-31 09:16:25 -08:00
Lucas Manuel Rodriguez
787944482b
Global policies automation webhooks ( #3378 )
...
* Add webhook to app config
* Add redis failing policies set and webhook
* Add basic webhook test
* Store hostname in redis
* Global policy deletion to remove policy ID from set and config
* Also process new passing policies
* Fix unit test
* Sort hosts
* Add more tests
* Add ListSets to the failing policies interface
* Fix server URL and garbage collect on the triggering side
* Do not use Redis SCAN
* Fix Redis operation order
* Add API changes to doc
* Add comments
* Add more tests
* Fix tests
* Add tests for config update upon deletion of policies
* Run make dump-test-schema
* Ignore policies that failed to run
* Add proper unit tests to trigger logic
* Fix comments
* WIP
* Add tests to service_osquerty_test.go
* Use SSCAN for listing hosts instead of SMEMBERS
* Add failing policies to docs/01-Using-Fleet/configuration-files/README.md
* Remove skip
* Fix PR comments
2021-12-23 18:26:55 -03:00
Zach Wasserman
fb10d50f73
Hide warnings for removed migrations ( #3449 )
...
For #3427
2021-12-23 17:07:17 -03:00
Tomas Touceda
06a64cdd2c
Use id instead of seen time/created_at to sort hosts ( #3482 )
...
* Use id instead of seen time/created_at to sort hosts
* Add test for ordering by id
2021-12-23 15:45:50 -03:00
Martin Angers
1e2059585a
Add support for google chrome profiles ( #3423 )
2021-12-21 15:36:19 -05:00
Lucas Manuel Rodriguez
93f4577c7d
Fix policy membership migration for MariaDB ( #3418 )
...
* Fix policy membership migration for MariaDB
* Use constraintsForTable to get the proper foreign key names
2021-12-21 14:39:46 -03:00
Martin Angers
a74e562893
Migrate labels endpoints to new pattern ( #3354 )
2021-12-21 09:53:15 -05:00
Tomas Touceda
39e71c6d77
Add mdm and munki ( #3406 )
...
* Draft for mdm and munki as direct ingest funcs
* Expose mdm/munki over API
* Add test for service and fix bug
* Update queries test
* Fix lint
* Address review comments
2021-12-21 09:37:58 -03:00
Lucas Manuel Rodriguez
5aeb418945
Exclude old data migration from the migrations check ( #3373 )
2021-12-16 10:52:42 -03:00
Martin Angers
af42a0850e
Migrate global scheduled queries endpoints to new pattern ( #3235 )
2021-12-15 09:06:34 -05:00
Martin Angers
0cc57bd294
Mna 1782 migrate endpoints ( #3226 )
2021-12-14 16:34:11 -05:00
Zach Wasserman
33797ddfc1
Optimize requests on packs page ( #3327 )
...
Improves #3259
2021-12-13 21:50:24 -08:00
Tomas Touceda
66f4fc46c0
Only join big tables when absolutely needed ( #3308 )
...
* Only join big tables when absolutely needed
* Fix test
* Revert unintended change in test
2021-12-09 17:36:12 -03:00
Lucas Manuel Rodriguez
d0765cb9ee
Do not exit on serve
/prepare
if there are unknown migrations ( #3262 )
...
* Do not exit on serve/prepare if there are unknown migrations
* PR review changes
2021-12-08 19:50:00 -03:00
Tomas Touceda
8686c1520b
Add index software ( #3241 )
...
* Add index to software over name/id
* Update schema
* Remove double semi colon
2021-12-07 16:36:13 -03:00
Lucas Manuel Rodriguez
edec1abc86
Remove platform and team from policy editing ( #3233 )
2021-12-07 13:01:00 -03:00
Lucas Manuel Rodriguez
6b8a2cb61a
Fix mysql8 compatibility with zero dates ( #3231 )
...
* Fix mysql8 compatibility with zero dates
* Amend date
2021-12-07 12:51:53 -03:00
Tomas Touceda
dc9686024b
Remove tx from SaveHost ( #3232 )
...
* Remove tx from SaveHost
Also change REPLACE for software for an insert.
* Remove bundle identifier from the get since it's not part of the key
* Revert unneeded change
2021-12-07 12:39:07 -03:00
gillespi314
6ee6dba4a4
Update anonymous usage statistics to record Fleet feature adoption ( #3056 )
...
* Collect additional anonymous usage statistics
* Update fleetdm.com and docs for usage stats
* Fix lint-go errors
* Fix failing test
* update webhook inputs
* Update receive-usage-analytics.js
* fix failing test
* Update statistics_test.go
Co-authored-by: eashaw <eashaw@sailsjs.com>
2021-12-06 14:39:00 -06:00
Lucas Manuel Rodriguez
c5375263b6
Change policy platforms name to platform singular (for consistency) ( #3221 )
...
* Change policy platforms name to platform singular
* Fix fleetctl tests
2021-12-06 13:56:28 -03:00
Martin Angers
b84ef79bf4
Add the fleetctl debug {errors,db-locks} sub-commands ( #3168 )
2021-12-06 09:26:01 -05:00
Lucas Manuel Rodriguez
b9a408704e
Add platforms
field to policies ( #3181 )
...
* Add platforms field to policies
* Fix fleetctl tests
* PR review changes
* Add missing tests
* Add changes for ListPoliciesForHost
2021-12-03 15:33:33 -03:00
Tomas Touceda
142006cbdd
Issue 2099 enable vulnerability processing new installs ( #3104 )
...
* Enable vulnerability processing by default
* Add changes file
* Remove wrong env var
* Fix import
* Fix tests
* Update log line
* Remove unneeded import
2021-12-03 14:44:57 -03:00
Tomas Touceda
17bd4d5110
Remove policy membership history and only store the latest value ( #3178 )
...
* Remove policy membership history and only store the latest value
* Address review comments
* Correct error msg wrap
2021-12-03 13:10:11 -03:00
Tomas Touceda
5cff07f332
Issue 3184 drop event host expiry ( #3185 )
...
* Drop event host_expiry if it exists
* Add changes file
2021-12-03 12:34:58 -03:00
Tomas Touceda
a0404b6736
Add software count API ( #3105 )
...
* Add software count API
* Fix makefile
* Fine no mock generating at this point
* Actually, one last try
* Use go install instead
* Fix go sum/mod
* Improve documentation
* Try setting node to 14
2021-12-03 10:54:17 -03:00
Martin Angers
7464e72ba8
Move carves endpoints to new endpoint pattern ( #3148 )
2021-12-01 15:45:29 -05:00
Tomas Touceda
3a031e946d
Sort hostIDs before inserting seen time ( #3162 )
...
* Sort hostIDs before inserting seen time
* Fix status test
* Add comment
2021-12-01 16:20:54 -03:00