Commit Graph
1623 Commits
Author SHA1 Message Date
Cameron Perera 9f49d1a7f8 bump ui commit (#2841) 2023-01-24 13:53:44 -06:00
Irena Rindos 00a73f64d9 bug(sessions): Fix authorizeSession race conditions in handleProxy (#2795)
* initial commit
2023-01-24 09:24:03 -05:00
Todd d66b92abe0 Add directly connected downstream workers to the worker resource api (#2831) 2023-01-23 11:45:09 -08:00
Todd 87b09d5e27 Rename router to receiver for secondary connections (#2816) 2023-01-20 10:43:57 -08:00
Todd b359561e51 Filter WorkerList by feature and go from version string to version.Info (#2807) 2023-01-19 14:39:49 -08:00
Hugo 0bee55aa19 fix(target): Correct accounting of updated rows when deleting address (#2799)
If an update call was made to a target that removed an address, for a
target that already did not have an address, the incorrect number of
rows updated was being reported. During the update the target's version
was correctly being updated, resulting in one row being updated.
However then the delete call would result in zero rows being deleted,
since there was no address associated with the target, and this would
replace the value for the returned rowsUpdated. This resulted in the
target service thinking that no update happened, and it would report an
error.
2023-01-19 16:12:04 -05:00
Jim e64163ad1d fix (controller): prevent panic when controller stops when there's no listener (#2793) 2023-01-18 16:46:45 -05:00
Cameron Perera 4195821d29 bump ui commit to latest on main (#2798) 2023-01-18 13:06:48 -06:00
Todd bc409bc7d4 Graceful shutdown blocks on running proxy handler connections (#2789) 2023-01-17 08:54:01 -08:00
Irena Rindos e238893c21 Unset worker auth when Boundary dev uses a kms worker (#2786) 2023-01-13 12:03:05 -05:00
Timothy Messier e2248c1360 fix(wh): Associate session fact with credential dimensions (#2787)
The wh_upsert_credential_group function was incorrectly attempting to
update the session connection fact table. There are a couple problems
with this:

1. At the time that this runs, there would be no session connection facts
   for this session.
2. This function is meant to update the session fact table, there is a
   separate function that associates the credential group with the
   session connection facts.

This also fixes another bug that was causing expired rows of the
credential dimension to be included in the group membership. And finally
it fixes a typo in the function name.
2023-01-13 11:24:32 -05:00
Todd 38b74ce897 Provide a worker decryption function to proxy handlers (#2784) 2023-01-12 13:16:36 -08:00
Todd 0b87acb896 Always call PostConnectionHook in dialer and fix Dial bug (#2783) 2023-01-12 11:04:16 -08:00
Irena Rindos bb281e494f Fix status NPE if worker has been sitting waiting for registration (#2781) 2023-01-12 12:02:08 -05:00
Irena Rindos 5d5dc7524c update dial function doc to include options (#2776) 2023-01-11 13:26:37 -05:00
Irena Rindos af24972386 warn if controller and worker name are the same (#2773) 2023-01-11 09:07:31 -05:00
Irena Rindos d3d1fa0b55 initial commit (#2768) 2023-01-10 08:10:54 -05:00
Damian Debkowski a8ee18e177 fix(db): target address relabel migration id (#2769) 2023-01-09 14:00:28 -08:00
Irena Rindos beb97ac9f2 SSH Proxy support (#2736)
* initial commit
2023-01-09 13:43:02 -05:00
Hugo 1fb960575f Merge pull request #2613 from hashicorp/llb-target-address
Assign a Network Address to a Target
2023-01-09 18:35:19 +00:00
Irena Rindos a403b3904c initial commit (#2735) 2023-01-09 12:35:13 -05:00
Hugo Vieira f85da3ee2b feat(cmd): Create target using address on boundary dev / database init
Creates a target using an address for boundary dev and when first
init-ing boundary (boundary database init).

It also makes this newly created target the default one
(ttcp_1234567890). The target using host sources is now a secondary
target (ttcp_0987654321).
2023-01-09 15:39:55 +00:00
Damian Debkowski 1d3930a711 feat(handlers): Support address field on a Target 2023-01-09 15:39:55 +00:00
Damian Debkowski bca7c371d8 feat(session): Support connecting to an address associated to a Target 2023-01-09 15:39:55 +00:00
Damian Debkowski 760671f223 feat(target): Support connecting to an address associated to a Target 2023-01-09 15:39:55 +00:00
Damian Debkowski 0dbe18e453 fix(db): remove migration test 59_01
This test uses the target domain repository code to test the ingress
& egress worker filter. With our changes we have updated the target
domain repository logic to fetch the target address. When this migration
test is invoked, the target_address table does not exist and the domain
code will always return an error making this test invalid.
2023-01-09 15:39:55 +00:00
Damian Debkowski 3dd4b1c63d feat(db): Support a direct address association to a Target 2023-01-09 15:39:55 +00:00
Hugo Vieira 803cd278ae fix(cmd): boundary connect SSH depending on a host id for ssh aliasing
Targets are not guaranteed to have Host Ids anymore, so we now use
Target Id when a Host Id is not present.
2023-01-09 15:39:55 +00:00
Hugo Vieira c82d2efb14 feat(cli): Implement address flag for boundary targets create/update
This commit adds CLI support for addresses to be attached directly to a
Target, for all current types of Target (ssh and tcp).

It also clarifies the relevant documentation regarding the autogen of
API option functionality.
2023-01-09 15:39:55 +00:00
Johan Brandhorst-SatzkornandJeff Mitchell 61c90c5623 Add grant parsing fuzz test (#2534)
* testing(perms): Add Parse fuzz test

I ran this for a few minutes and it didn't discover anything catastrophic.

* Add roundtrip tests

* Fix invalid unicode parsing, empty output fields

* Do the unicode conversion once on input

* Remove incorrect fix for empty output fields

* Allow empty output_fields

This is the same behavior as output_fields=,

* Add tests back, make JSON behaviour consistent

* Rework the output fields mechanism to fix some bugs such as properly handling no fields

* Change signature of Fields

Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com>
2023-01-06 18:27:19 -05:00
Irena Rindos b7f0f455db Add options for directly connected worker (#2762) 2023-01-06 17:34:43 -05:00
Jeff Mitchell b286060ea8 Fix string regression in attribute parsing (#2759)
In #2721, the ability for key-only values was added via using a
wrapperspb.StringValue that could be null. This introduced a bug because
originally the default case for `-attr` was to get the string value but
instead it used the incoming value as-is to allow for nulls; the null
check was moved up later but the original behavior was not restored. As
a result, non-explicitly-quoted strings carried through the
wrapperspb.StringValue, resulting in a map for the value in JSON instead
of a string.

This also fixes the ability to set explicitly quoted strings.
2023-01-05 13:25:59 -05:00
Irena Rindos 9135cc7668 In absence of ingress filter, use directly connected worker (#2757)
* directly connected ingress filtering
2023-01-05 12:09:31 -05:00
Irena Rindos 078f5e9328 Fix failing attribute flag test (#2755) 2023-01-04 14:32:12 -05:00
Jeff Mitchell 098248be18 Add the ability for CLI map values to contain keys only, which map to JSON nulls (#2721) 2023-01-04 12:44:11 -05:00
Irena Rindos 24bbf57a19 AuthorizeConnection with filters (#2734)
* AuthorizeConnection with filters
2023-01-04 11:24:09 -05:00
Irena Rindos d5fed10918 fix no path info message (#2751) 2023-01-03 15:00:45 -05:00
Carlos Alcaide Corvo 276afa029f Bump UI version (#2750) 2023-01-03 10:15:54 -08:00
Irena Rindos 7db9fc59ce Expose State() *structpb.Struct interface through the metric connection trackers 2022-12-23 08:14:58 -05:00
Irena Rindos 895aecb58c Do not emit error on auth not found (#2737) 2022-12-22 08:07:02 -05:00
Jim 1c9ca14a8e fix (db): Improve error handling for commit errors. (#2728)
We were not capturing the errors which happen on commit.  We've changed
to a multierror so we should get the commit error and any subsequent
rollback errors in the same txn.
2022-12-20 07:41:31 -05:00
Michael Li 44fd85c751 fix(kms/test): Fix flake (#2723)
There was some flakiness observed in this test, where keyCount was reported to be 21. To prevent any potential conflicts, we are making the sub-tests not run in parallel.
2022-12-16 12:16:17 -05:00
Jeff Mitchell 5353725278 Merge duplicated attr/secret/kv flag handling into one function (#2720) 2022-12-15 13:01:57 -05:00
Irena Rindos 5c73e43912 revert 2712 (#2713) 2022-12-13 14:25:40 -05:00
Irena Rindos a135127524 Move dialingListener setAddresses 2022-12-13 13:29:14 -05:00
Danielle 46037cf85a Add Staticcheck to Build Pipeline (#2421)
Run staticcheck linters on pull requests
2022-12-13 12:07:18 -05:00
Jim 38b12394fd refactor (kms): add GetWrapperer for RewrapFn parameter (#2701)
* refactor (kms): add GetWrapperer for RewrapFn parameter

* tests (kms): add MockWrapper and MockGetWrapperer

Make it a bit easier to write unhappy path tests which depend on
a Wrapper or GetWrapperer
2022-12-13 05:38:14 -05:00
Irena Rindos 173e1587d0 Append initial worker upstreams if current upstreams are unresponsive (#2698)
* Append initial worker upstreams if current upstreams are unresponsive
2022-12-12 13:48:28 -05:00
Todd 7a6983c463 Fix wrapped reverse grpc listener (#2702) 2022-12-12 10:27:31 -08:00
Haotian 340cfb0d88 refactor(metric): adds filter function to collector init method (#2695) 2022-12-12 09:12:33 -08:00