Commit Graph
243 Commits
Author SHA1 Message Date
Jim f8ea8c9744 fix (ldap): support only updating the bind-dn and/or bind-password (#3511)
* fix (ldap): support only updating the bind-dn and/or bind-password

* chore: changelog entry for PR #3511
2023-07-27 15:41:37 -04:00
Irena Rindos 39953fe329 fix(targets): return LookupTargets error in AuthorizeSession (#3484)
* fix(targets): return LookupTargets error in AuthorizeSession
2023-07-20 11:01:20 -04:00
Jim 474afe4671 fix: allow ldap managed grps to be set and removed as principals… (#3363) 2023-06-27 12:13:13 -04:00
Jim 84cc3a5988 fix(ldap managed grp): allow ldap managed grps to be added as principals (#3361) 2023-06-26 17:05:54 -04:00
Jeff Mitchell 8322916fb4 Remove all deprecated Err/Wrap/E calls (#3286) 2023-06-14 21:55:24 -04:00
Jeff Mitchell feb3aea38f Support multiple IDs in grants (#3263)
This allows specifying multiple IDs in grants via an `ids` field, which
will eventually become the normal way to specify IDs. Internally, each
grant with multiple IDs turns into multiple ACL grants each with a
single ID; to make this distinction clearer and allow for better
separation of concerns an AclGrant type has been introduced, so really
multiple IDs in a Grant turn into multiple AclGrants.

The nice thing about doing it this way is that it becomes purely a
parsing concern; no actual validation logic has changed.

For backwards compatibility with grants already stored in roles, we do
not error out if `id` is specified. However, eventually we will simply
not support grants with `id` coming via the API; they will fail API
validation, such that new grants will require the use of the updated
`ids` field.

A follow-on PR will plumb this through the service handlers/API/CLI, but
I decided to do it in separate chunks to make reviewing easier, given
that they are easily separable into the internal and external aspects of
the change.

* Add CLI/API checks around using ID in grants (#3264)

* Plumb through some contexts to remove a lot of deprecated errors (#3268)
2023-06-14 21:55:24 -04:00
Jeff Mitchell 74e8491f85 Disallow updates on all types of KMS workers (#3295)
This also slightly changes delete logic and ensures authorized actions
match what is allowable.
2023-06-08 12:17:45 -04:00
Michael Milton fbf56793c6 Add snapshot job (#3282)
* snapshot job

* update census to include context, controller to include snapshot registry

* no need to export runFn in snapshot
2023-06-06 14:26:01 -04:00
Jim 2b3e50ebdd fix (listing): return all resources from listing requests (#3278) 2023-06-05 12:53:59 -04:00
Jim 5029be9999 fix: allow responses larger than the default 4194304 recv msg size (#3276) 2023-06-05 12:13:05 -04:00
Louis Ruch 281f217dcc feat(plugins): Refactor host plugins to boundary plugins (#3262) 2023-06-02 08:04:50 -07:00
Jim d4e537c88d chore: updgrade pgx direct deps to v5 (#3258) 2023-06-01 08:59:38 -04:00
Jeff Mitchell 3d5bed9ce8 Don't allow managed workers to be deleted (#3254)
This also adds checks to ensure the tag cannot be added to workers via
the API.
2023-05-31 14:23:57 -04:00
Timothy Messier f64f03ed46 fix(targets): Support authorize session request with target name (#3252)
For requests to the target authorize session endpoint we support passing
a target name instead of an id. This means that `req.GetId()` might not
be the target's public id. Since the first thing authorize session does
includes retrieving the target as part of the authorization checks, this
subtype check can leverage the public id of the target instead of using
the request.

Fixes: 6178dd516e
2023-05-31 11:25:03 -04:00
Todd 6178dd516e Let a target subtype validate the authorize session's session state 2023-05-31 12:18:23 +00:00
Jim d49fde2299 feat(cli/session-recordings): add download cmd 2023-05-31 12:18:22 +00:00
Jim 9207ec08f2 feat: add request ctx stream interceptor 2023-05-31 12:18:22 +00:00
Jim 0c465706cc chore: increment base version to 0.13.0 2023-05-31 12:18:22 +00:00
Jeff Mitchell 18e59998e9 Add storage bucket worker filter handling 2023-05-31 12:18:18 +00:00
Todd 25d50d1077 Add tests for recording collection actions on scopes 2023-05-31 12:18:17 +00:00
Todd cfe0dc08d9 Add session recording service stuff 2023-05-31 12:18:17 +00:00
Johan Brandhorst-Satzkorn 328b039138 scopes: fix test expectation 2023-05-31 12:18:15 +00:00
Louis Ruch 1662445e8e feat(storage): Wire up storage buckets in session recording 2023-05-31 12:18:14 +00:00
Louis Ruch 8ea61054cd feat(storage): Add support for Storage Bucket API 2023-05-31 12:18:14 +00:00
Danielle Miu a4a14fc7fc merged commit for plugin rework, storage bucket sql and proto, storage bucket secret rewrapping, storage bucket repository 2023-05-31 12:18:13 +00:00
Johan Brandhorst-Satzkorn ad62df6b36 cluster: pass controller ext to authorize conn
Make the controller extension availalbe to the protocol
context constructor.
2023-05-31 12:18:13 +00:00
Johan Brandhorst-Satzkorn 5837d6f387 target: add PostSessionAuthorization callback
The callback is called for any steps that need to be performed
after a successful authorization but before returning to the user.
2023-05-31 12:18:13 +00:00
Johan Brandhorst-Satzkorn 13e1196797 target: add error handling to authorize session
Attempt to undo operations if there are failures during
session authorization.
2023-05-31 12:18:13 +00:00
Johan Brandhorst-Satzkorn 517fc91ebf target: return selected worker when authorizing 2023-05-31 12:18:13 +00:00
Johan Brandhorst-Satzkorn 6d219bd5d1 target: add controller extension to service handler
The controller extension can be used to access types unavailable
in OSS.
2023-05-31 12:18:13 +00:00
Todd bc48f2d0e0 Add monitor session job proto and controller changes
This adds a new Job type that is for generic session state monitoring.  Monitoring sessions does not include any information about specific connections.
2023-05-31 12:18:12 +00:00
Jim 4d60f42210 feat(bsr): add bsr kms support in config, dev and tests 2023-05-31 12:18:12 +00:00
Louis Ruch 798a1f952a feat(storage): Add support for storage plugins 2023-05-31 12:18:12 +00:00
Damian Debkowski 9ef94892f4 test(plugin): Support storage service in loopback plugin 2023-05-31 12:18:12 +00:00
Louis Ruch 351444f1bd refact(plugin): Move host loopback plugin into internal/plugin/loopback 2023-05-31 12:18:12 +00:00
Jim c4b31313a6 feat (controller): define a ControllerExtension 2023-05-31 12:18:11 +00:00
Johan Brandhorst-Satzkorn 7632143861 add session recording API definitions 2023-05-31 12:18:10 +00:00
Jim f9b45ca5b7 refact: extend registerControllerUpstreamMessageService to reg hdrs
Extend registerControllerUpstreamMessageService to register upstream
message handlers
2023-05-31 12:18:10 +00:00
Jim 410bec1e00 feature(worker/controller): register UpstreamMessageServiceServer 2023-05-31 12:18:10 +00:00
Jim 20cf521cc0 feat(bsr): add bsr kms support in config, dev and tests 2023-05-31 12:18:10 +00:00
Michael Milton 9ae2bdfae6 feat: license util config (#3248)
* feat: license util config

* address comments

* introduce census job

* add job

* fix import groups

* remove pointers
2023-05-30 18:20:49 -04:00
Jeff Mitchell 769a7c9e1c Remove cleanup calls for test controller/worker (#3245)
A previous commit added a call to t.Cleanup in the
NewTestController/NewTestWorker commands; as a result these statements
are no longer needed.
2023-05-26 14:57:32 -04:00
Hugo dba7d88523 fix(handlers/scopes): Whitespace on Name and Description fields (#3235)
This commit fixes the behaviour of scopes where whitespace was allowed
(and thus persisted) in the Name and Description fields.

It also adds some more tests for scope Create and Updateto cover more
error cases.

For scope update, `handlers.ValidateUpdateRequest` exists, however this
was not used as it does not work properly for requests where the
`global` scope is updated.

In `ValidateUpdateRequest`, an ID check is performed and it assumes
there's always a resource prefix (eg: "p", "o") and an identifier
(random numbers and letters) after the prefix. This fails for `global`.
See `handlers.ValidId`.
2023-05-25 15:43:52 +01:00
Jeff Mitchell e8559d142a Fix worker auth rotation test (#3243)
Most of the changes here are changes or enhancements that are useful for
tests. The crux of the issue was that I had pulled up one var to the
package level so it could be read from tests, but that var was not being
reset between tests. It's not even used in tests anymore, so I put it
back to function-local.
2023-05-24 23:33:51 -04:00
Jeff Mitchell e0787f4de0 Simplify worker auth rotation timing logic (#3237)
* Simplify worker auth rotation timing logic

* Add some jitter
2023-05-20 21:05:19 -04:00
Jeff Mitchell 77fd51fb12 Add more logging to worker auth rotation and test flags
This makes it much easier to figure out when and why rotation is
happening and control it for tests/debugging.

Remove cert skew

Cherry-picked from release/0.12.x
2023-05-19 17:14:33 -04:00
Jeff Mitchell 037dc0cf18 Add missing nil check in test 2023-05-05 11:56:28 -04:00
Jeff Mitchell f9f7ee2cc4 Fix build 2023-05-05 11:52:41 -04:00
Jeff Mitchell bbe9719e19 Add tracking of worker used for injection (#3204) 2023-05-05 09:22:54 -04:00
Elim Tsiagbey a2f8d87bfb Add support for setting, adding & deleting LDAP account assoicated to a user (#3198) 2023-05-03 09:45:29 -04:00