Commit Graph
141 Commits
Author SHA1 Message Date
Kevin Maris 8a8b2fb8e1 Fix nil TLSClientConfig (#901) 2021-02-02 20:50:30 -05:00
Jeff Mitchell 9879841e00 Update SDK in API 2021-01-29 18:28:52 -05:00
Jeff Mitchell 6cd97a4a6e Add support for recursive listing (#885) 2021-01-25 19:37:40 -05:00
Jeff Mitchell 6b58a3317d Add recursive listing to roles (#881)
This also lays the framework for adding recursive listing to the rest of the resources.
2021-01-23 13:39:04 -05:00
Jeff Mitchell 717a3b52ee Add worker tagging (#862)
This allows workers to have tags assigned to them, which can then be filtered to control which targets they are allowed to serve.
2021-01-21 16:27:20 -05:00
Jeff Mitchell dcb15cffbd Add authorized actions output on resources (#870) 2021-01-20 10:53:01 -05:00
Jeff Mitchell 27919ab11b Groundwork for returning authorized actions (#860)
This returns authorized actions on targets to users when they perform an operation on a target, including listing. It also prevents users from seeing values in listing targets on which they have no permissions.
2021-01-13 14:42:37 -05:00
Jeff Mitchell 9de928318d Skip curl output when using automatic versioning and reading (#858)
This makes it so that the actual output is the update/delete.

Fixes #856
2021-01-08 17:30:41 -05:00
Michael GaffneyandJeff Mitchell 94cb79bbdd See how Boundary would look with gofumpt applied (#853)
* See how Boundary would look with https://github.com/mvdan/gofumpt applied

Results of running `gofumpt -w -s .`

* Update tools file and Makefile for gofumpt

Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com>
2021-01-07 10:02:32 -05:00
Jeff Mitchell d4a6efb363 Pass endpoint to the client (#811)
This allows us to automatically set TLS parameters, useful for `boundary
connect http` and some other features to come.
2020-12-09 14:45:53 -05:00
Todd Knight aa4157639c Change Format of API Error (#784)
This is a wire breaking change for json errors since we have removed and renamed a few fields, and changed part of the structure of the returned json error.

* Remove redundant fields in Status, details.error_id, details.TraceId and details.request_id from API errors.

* Added wrapped errors and "ops" field to indicate the internal operation of the errors returned by the API.

* Added error cli error reporting of Op and wrapped errors.
2020-12-07 14:25:16 -07:00
Jeff Mitchell 813d21565f Allow authorize-session to be invoked with target name (#737) 2020-10-22 08:40:00 -04:00
Jeff Mitchell 09b865ab28 Add pass cred storage support (#731)
* Add `pass` cred storage support

Make it the default on non-Windows/macOS

Document the token storage behavior
2020-10-21 09:00:17 -04:00
Jim b8c527c6cd handle v1 as a prefix/suffix, not just a cut set to be trimmed (#723) 2020-10-17 19:01:24 -04:00
Todd Knight abe5e9b950 Add Termination Reason (#573) 2020-10-07 21:37:30 -04:00
Jeff Mitchell 5bc8c8d921 Fix API test 2020-10-07 21:35:43 -04:00
Jeff Mitchell 26e86ef56a Update API deps 2020-10-07 14:16:48 -04:00
Jeff Mitchell fc09e2c21b Remove api mod dep for now 2020-10-07 14:11:06 -04:00
Jeff Mitchell 6993d10118 Update main's api/sdk mods 2020-10-07 14:05:50 -04:00
Jeff Mitchell 5cbfcf8eb6 Shuffle things around out of new modules 2020-10-07 14:03:42 -04:00
Jeff Mitchell 23f7306b62 Add api module 2020-10-07 13:55:55 -04:00
Todd Knight 6c6fb7a4d0 Format errors better for CLI (#552)
* Start making errors easier to read for Table based CLI UI.

* Add TODO about reporting "update_mask" related errors.
2020-10-06 14:08:49 -07:00
Jeff Mitchell 9237d6f787 Rename authorize to authorize-session (#531)
As pointed out by Rob, this makes it clearer what the action actually
is. We were sort of torn on it before, but I've definitely come around
to it.
2020-10-05 11:02:23 -04:00
Jeff Mitchell 6ddfe407a3 Update allowed formats of ACL strings (#508) 2020-10-01 01:49:20 -04:00
Jeff Mitchell cefea936c3 Update ACLs to allow type=*. (#504) 2020-09-29 22:55:22 -04:00
Jeff Mitchell a38f40606e Create default roles in scopes to allow authentication and listing scopes/auth methods (#502) 2020-09-29 20:38:16 -04:00
Jeff Mitchell b1fc9fd547 Sanitize protos (#471) 2020-09-26 08:30:27 -04:00
Todd Knight 0e5a849402 Adding Add|Set|Remove Accounts on the user resource (#461) 2020-09-25 20:44:55 -07:00
Jeff Mitchell ba216f894b Update docs and default address 2020-09-25 19:38:53 -04:00
Jeff Mitchell 220ca253be Add boundary config get-token (#455) 2020-09-25 17:06:53 -04:00
Todd Knight fd0da998e8 SDK error revamp (#432)
SDK methods now return 1 error.  To differentiate between Client errors and Server errors I've also implemented the AsServerError function which returns an *api.Error if it is an error originating from the remote server or nil otherwise.
2020-09-24 14:34:58 -07:00
Kent 'picat' Gruber 9e06d7eec2 Fix unused error in *api/client.Client.Do during redirect (#430)
Previously the error declared during the *retryablehttp.Client.Do was being "overshadowed" by the error declared when a redirect was missing the result location.

By declaring the loc outside the call assignment, we can properly "reuse" the error and resulting check after a redirect.
2020-09-24 14:13:25 -04:00
Jeff Mitchell e86c11db62 Add session lifecycle info to controller's INFO log. (#431)
This required some plumbing, but nothing major.
2020-09-24 14:12:34 -04:00
Todd Knight 2f8d7f0a32 API Errors: Hide and log internal errors (#411) 2020-09-23 08:10:27 -07:00
Todd Knight 21f5cc274f Don't return nil, nil for API service methods. Add tests for updating w/ wrong version. (#396) 2020-09-21 15:09:30 -04:00
Jeff Mitchell d3606e14b6 Set wrapper on client, not token, so it doesn't fail KMS recovery on update calls 2020-09-21 12:20:44 -04:00
Jeff Mitchell 9b2646eaf9 Fix retry behavior with KMS recovery and misleading error message (#391) 2020-09-21 11:05:44 -04:00
Jeff Mitchell 5370111336 Omit private key from session output 2020-09-20 21:23:38 -04:00
Todd Knight e937b0ea27 Sessions Read/List/Cancel API and SDK (#369) 2020-09-20 20:22:57 -04:00
Jeff Mitchell edffc7863d Change connection limit to -1 for unlimited so it works with TF (#383)
* Migrate connection limit unlimited value to -1

* Fix authorization check
2020-09-20 15:53:49 -04:00
Jeff Mitchell 5bf555cca2 Remove connection idle timeout seconds for now (#379) 2020-09-19 14:01:49 -04:00
Jeff Mitchell 0a3f9b8357 Rename connection idle timeout duration -> seconds and sessions max duration -> seconds (#376) 2020-09-19 11:32:38 -04:00
Jeff MitchellandJim Lambert 62baef1b7e Add multi connection parameters through targets and into session creation (#375)
* Update protos and gen

* Add new values to targets CLI command

* Lots more plumbing of new parameters through everything

* allow fields to be set to zero value.

* Disallow set but empty name/description strings in create/update verifiers

Co-authored-by: Jim Lambert <jlambert@hashicorp.com>
2020-09-19 10:31:49 -04:00
Jeff Mitchell 07a7e9750a Tie together the database-driven session handling with the worker and add relevant CLI comands (#370) 2020-09-19 00:18:17 -04:00
Jeff Mitchell a660e56ee7 Fix whitespace typo in generated API 2020-09-16 10:49:38 -04:00
Todd Knight f96fa25157 Add Auth Account id to Auth Token response (#363) 2020-09-15 14:33:38 -07:00
Jeff Mitchell f4ad22b247 Move default port to a TCP target attribute (#361) 2020-09-15 15:20:49 -04:00
Jeff Mitchell 77bcee1861 Use json.Number when unmarshaling into the response map 2020-09-15 02:20:24 -04:00
Jeff Mitchell a00ee7a948 Add Result types to Go SDK and properly populate body/map fields (#358) 2020-09-15 01:08:21 -04:00
Jeff Mitchell c1171e0cc6 Update API templates using list params (#352) 2020-09-11 16:49:31 -04:00