Michael Li
3bf925ca32
test(e2e): Decrease rate limit in config ( #4183 )
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
050bcdfec9
handlers/host_sets: implement pagination for host sets
...
Adds protobuf types and handler logic to support pagination of host sets.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
e14c1382b3
internal/host: add static host set pagination
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
4ba521a3e0
internal/host: add plugin host set pagination
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
27393a8227
internal/db: add host set indexes
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
6757510205
internal/session: add helper for listing sessions
...
This is used in an enterprise test
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
f29d559d60
handlers/session_recordings: add pagination support
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
24130c4313
handlers/storage_buckets: add pagination fields
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
516d7b3486
internal/storage: support pagination for storage buckets
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
8c3e309816
internal/storage/plugin: run tests in parallel
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
1a6e2fc5b1
internal/storage: fix options test
...
An assert created in the parent was being used in subtests,
which will attribute test failures incorrectly.
Also run tests in parallel.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
16eab12458
internal/plugin: fix typo
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
5ef1a39727
internal/credential: use simpler query arg
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
61642f8b5f
internal/authtoken: use simpler query arg
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
9b40cf0801
internal/iam: validate token resource type
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
025ef0d9ca
internal/target: validate token resource type
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
3288f78f12
internal/session: validate token resource type
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
12403d49ad
internal/credential: validate token resource type
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
799009fc04
internal/authtoken: validate token resource type
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
597ac645b2
internal/handlers: fix some comments
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
7190042f8e
internal/credential: 🤦
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
bf1e44afd6
internal/pagination: add notes about plugin map
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
a237157b91
internal/listtoken: remove validation depending on application time
...
All times in the list tokens are sourced from the database,
and any comparisons to times in the application can
cause false positive validation errors. We've observed
this from multiple users of the pagination logic, and
the value of this validation is very little compared
to the cost of a single false positive error like this
happening to a real world customer. Therefore, remove
any list token validation using the application time,
except the one monitoring for token expiry, which
should not suffer from the issue to a degree
that matters to our users.
Also refactor validation such that the list token subtype
constructors only perform sanity checks on the values
while punting business logic validation to the validate
method on the new token. This means we avoid
duplicating logic.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
f89e53d5f0
internal/handlers: tidy up test times
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
bcddef87a2
internal/pagination: stop using unknown resource type
2024-01-05 07:43:21 -08:00
Todd
d453a2a48a
Check in client wrapper if cache daemon is already in use ( #4172 )
2024-01-05 07:43:21 -08:00
Michael Li
3e4feac261
test(e2e): Add test for pagination of hosts
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
17b6ad5c5c
handlers/hosts: implement pagination for hosts
...
Adds protobuf types and handler logic to support pagination of hosts.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
cea80413c9
internal/host: add static host pagination
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
473facbc5f
internal/host: add plugin host pagination
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
faf7ebce85
internal/host: add pagination options
...
Add options to support pagination of hosts, host sets and host catalogs.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
21c593ab71
internal/db: add host indexes
2024-01-05 07:43:21 -08:00
Todd
6f488d7c59
Evanulate if cache daemon should be skipped after the flags are parsed ( #4168 )
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
8175086be7
internal/pagination: avoid import cycle
...
The iam package is very foundational, and now depends
on the pagination package. Thus, the pagination package
must not import any packages that may import iam,
such as the plugin package. Move the plugin helpers
to a subdirectory to avoid this import cycle.
2024-01-05 07:43:21 -08:00
Todd
5aa560387c
Add pagination for iam Roles ( #4161 )
...
* Add pagination for iam Roles
2024-01-05 07:43:21 -08:00
Todd
9ebb69f2a4
Add target type and session user_id as searchable ( #4076 )
...
* Add target type and session user_id to search
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
df93313b9a
all: fix test failures after rebase
...
The stability of the authorized_actions have been removed in main,
so we need to add these sorts to all our new tests.
2024-01-05 07:43:21 -08:00
Johan Brandhorst-Satzkorn
77b76ae685
internal/db: reorder pagination schema files
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
6c9bc84790
testing/e2e: add credential store pagination test
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
0259f2f26b
internal/handlers: add credential store pagination
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
a7ebb7a3ef
internal/credential: add store pagination logic
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
3197ab763f
internal/credential/static: add store pagination logic
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
7efb43ac03
internal/credential/vault: add store pagination logic
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
22ce2b4468
internal/db: add cred store pagination schema changes
...
Add create time, update time columns to base table,
add indexes used by list queries.
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
7b27d7d20f
internal/target: fix some test typos
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
576e25bd27
internal/session: fix some test typos
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
dc0b8cfc62
internal/credential: fix some test typos
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
cb109da5b2
internal/pagination: add generic ListPlugins functions
...
These new methods can be used in places where the caller wants
to automatically paginate over a resource that is returned
together with a slice of plugins, such as host catalogs.
2024-01-05 07:43:20 -08:00
Johan Brandhorst-Satzkorn
97ba8b3bad
internal/pagination: add generic ListPlugin functions
...
These new methods can be used in places where the caller wants
to automatically paginate over a resource that is returned
together with a plugin, such as plugin hosts, host sets and storage buckets.
2024-01-05 07:43:20 -08:00
Michael Milton
335ccbfdaf
Session pagination e2e tests ( #4134 )
...
* Tests session pagination over CLI
* session pagination tests
* Add cleanup and fix api test
2024-01-05 07:43:20 -08:00