Todd Knight
28dbcd84bd
Authenticate Handler API and SDK, and much more ( #183 )
2020-07-14 17:32:47 -04:00
Jeff Mitchell
acce195dcb
Organizations -> orgs consistency ( #189 )
...
* Organizations -> orgs consistency
* Fix up some tests and some mistaken substitutions
2020-07-11 12:00:49 -04:00
Jim
e1afed75ff
fix dbMask and role tests... ( #188 )
...
* fix up tests.
* case sensitive dbMask
2020-07-10 20:44:00 -04:00
Todd Knight and Jeff Mitchell
847ca1cc78
Grant management added to Roles API and SDK ( #185 )
...
* Adding grants related methods to Roles.
* Adding grants back after the merge of Principals.
* Adding tests for Grant related custom methods.
* Improving api handler methods.
* Fixing tests and sdk field.
* Adding todos for adding principals and grants to List and Update Role responses.
* Fix up Set* tests and fix SetPrincipals bug.
* Making AddPrincipals and RemovePrincipals similar to the tests for AddGrants and RemoveGrants.
* Add JSON grants to output (#187 )
I also changed canonical_grants to grants_canonical and used
grants_json. I believe that when members are simply different formats of
other members this is the preferred way to have it in the API. Let me
know if you disagree and we can dig in more.
* Regenerate the API role resource.
Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com >
2020-07-10 17:42:47 -07:00
Jim and Jeff Mitchell
260703febe
add group member capabilities ( #178 )
...
* add group member capabilities
Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com >
2020-07-10 19:01:23 -04:00
Jeff Mitchell and Jim Lambert
c657e4b9fc
Fix test broken through various merges ( #186 )
...
Co-authored-by: Jim Lambert <jlambert@hashicorp.com >
2020-07-10 18:59:39 -04:00
Jeff Mitchell
f30d4d08ef
Pass grant scope ID through API handlers ( #184 )
2020-07-10 17:56:33 -04:00
bcdcaffa6f
Port over 162 and 165 to master ( #176 )
...
Co-authored-by: Jim Lambert <jlambert@hashicorp.com >
Co-authored-by: Michael Gaffney <mgaffney@users.noreply.github.com >
2020-07-10 15:46:26 -04:00
Todd Knight and Jeff Mitchell
1ddc59f81e
Adding principal custom methods to roles handler. ( #180 )
...
* Adding Add/Set/Remove principals API calls.
* Add SDK custom methods.
Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com >
2020-07-10 11:21:11 -07:00
Jim
136e923583
make iam_role scope_id immutable ( #179 )
2020-07-10 10:22:38 -04:00
Jeff Mitchell
732c07126d
Introduce global scope ( #168 )
...
Introduce the global scope, which holds some resources that don't necessarily belong at either the org or project level.
2020-07-08 17:20:20 -04:00
Jim
6c1b45f7f5
add principal roles (users and groups) to iam ( #163 )
2020-07-08 17:02:01 -04:00
Todd Knight
beea32b8c8
Fixing test that was missed with PR #171 . ( #175 )
2020-07-08 16:55:37 -04:00
Todd Knight
2ce9affeea
Don't use repo to check impossible token requests and repo doesn't return error on token value mismatch. ( #171 )
...
* Remove error when tokens mismatch from public id but log returned errors from repo.
2020-07-08 09:09:09 -07:00
Jeff Mitchell
4decf9502a
Fix handler test by moving it to a new file with a build tag
2020-07-07 20:42:17 -05:00
Jeff Mitchell
8987d8d435
Separate out ui handler under build tag ( #170 )
2020-07-07 16:57:54 -07:00
Todd Knight
c44a4c4795
Tools for auth token interception and authentication ( #152 )
2020-07-07 12:14:26 -07:00
Todd Knight
f69d6b9952
Creating Auth Token Repo ( #125 )
2020-07-07 07:44:49 -07:00
Todd Knight
bb4a185412
Pushing test db cleanup up to where the database objects are created using t.Cleanup. ( #166 )
2020-07-06 10:15:01 -07:00
Jeff Mitchell
316b250a24
Use dockertest v3 consistently ( #167 )
2020-07-06 12:41:09 -04:00
Todd Knight
2727917b2a
Adding List to go SDK ( #164 )
2020-07-02 10:26:31 -07:00
Todd Knight
c017da7087
Add ListUsers handler implementation. ( #160 )
2020-07-02 08:17:52 -07:00
Jim
d0a846823a
support for NewOplogMsgs() option when calling CreateItems and DeleteItems ( #158 )
2020-07-01 05:40:02 -04:00
Jeff Mitchell
c965cf1bc5
Attempt to fix content-length header in index ( #159 )
2020-06-30 17:37:24 -04:00
Todd Knight
9a1539867e
Adding SDK ability to do CRUD operations on groups and roles under the project scope. ( #157 )
2020-06-30 10:25:58 -07:00
Jeff Mitchell and Randall Morey
8da4effd5e
Add mechanism for bundling UI assets. ( #153 )
...
* Add mechanism for bundling UI assets.
The scripts/uigen.sh script will check out the UI repo, build assets,
create a static assets file, and clean up.
The dev Makefile target has been modified to run this script if no
assets file is found. There is also a build-ui target that will
unilaterally update (the dev target only builds if the file isn't found,
but doesn't update).
The handler has been updated to add the default org ID as a header if
the request path is "/".
Co-authored-by: Randall Morey <randall@randallmorey.com >
2020-06-30 11:26:22 -04:00
Jim
8d8bb42418
add CreateItems and DeleteItems to writer interface ( #156 )
2020-06-29 19:28:15 -04:00
Todd Knight
8399764442
Roles and Groups Handlers Support Project Scope ( #154 )
...
* Adding project level scopes for groups and roles.
* Adding tests to verify the routes are working as expected.
2020-06-29 11:12:40 -07:00
Jim
3e3144117e
iam and auth integration ( #144 )
2020-06-29 08:18:57 -04:00
Jim
3d85c7ebb0
add CreateItems() and DeleteItems() ( #146 )
2020-06-29 06:36:00 -04:00
Jim
9a87df38c7
add CreateItems() and DeleteItems() ( #146 )
2020-06-29 06:31:23 -04:00
Michael Gaffney
d69588131c
Fix for panic in db.setFieldsToNil ( #155 )
2020-06-28 16:55:57 -04:00
Todd Knight
08e9a027fa
API for authenticate/deauthenticate ( #151 )
...
* Creating the authentication API.
2020-06-26 15:41:08 -07:00
Jeff Mitchell
d8f11af4d7
Move actions, resource (types), and scopes to packages. ( #149 )
2020-06-26 11:00:14 -04:00
Jeff Mitchell
9d1d0ba08e
Simplify UI passthrough logic ( #148 )
...
I realized we can handle the special case of `/index.html` by ensuring
that `/` does the right thing because that's _also_ standard behavior to
fetch `/index.html`. As a result this allows a lot of simplification.
2020-06-25 15:03:03 -04:00
Jeff Mitchell
94f66c9ee6
Fix test function breakage after merging encrypted config
2020-06-25 12:16:59 -05:00
Jeff Mitchell
16b56a37ed
Rename base.New -> base.NewCommand for clarity
2020-06-24 15:10:12 -05:00
Jeff Malnick
8afcbd4c8e
Add config CLI command and encrypt/decrypt sub-commands ( #77 )
2020-06-24 16:08:13 -04:00
Jeff Mitchell
8de5371499
Enable UI handling logic with dev passthrough directories. ( #145 )
...
* Enable UI handling logic with dev passthrough directories.
* Add tests and fix a couple of things
2020-06-24 16:06:19 -04:00
Jim
6641244734
add support for WithVersion option to updates ( #126 )
2020-06-24 12:33:49 -04:00
Michael Gaffney
c110c86ee5
Add function to check if db error is a check constraint violation ( #142 )
2020-06-23 18:00:50 -04:00
Jeff Malnick
6c2a17c845
feat: use root path for passthrough ( #141 )
2020-06-23 10:34:07 -07:00
Jeff Mitchell
993a6f1680
Remove "projects" from grant strings ( #143 )
...
This removes the ability for a grant string to switch projects, in
accordance with our updated design. It mostly removes code, with a few
test fixes, and also adds one additional check (and test) to ensure a
grant errors rather than do-nothing succeeds if both id and type are
empty.
2020-06-23 11:28:44 -04:00
Todd Knight
a02222c1f0
Adding List functionality for projects. ( #140 )
2020-06-23 07:04:44 -07:00
Todd Knight
0c8385b423
Updating TxHandler to accept a reader as well in order to support reads inside the same transactions as writes. ( #139 )
2020-06-22 13:27:26 -07:00
Michael Gaffney
6908f7a7a2
Use standard column names ( #138 )
2020-06-22 13:54:55 -04:00
Todd Knight
766c174fe9
Implement List Groups ( #133 )
...
* Implement List Groups
* Updating ListGroup's comments and tweaking variable name.
2020-06-22 10:46:45 -07:00
Todd Knight
5b1e4a680d
Create Role CUDLR API and SDK ( #135 )
...
* Implement the Role CRUD API.
* Implement the Role List API.
* Adding Roles SDK.
2020-06-22 06:56:27 -07:00
Michael Gaffney
1023c90729
Enforce auth_account to iam_user plus iam_scope constraints ( #137 )
2020-06-21 13:16:03 -04:00
Todd Knight
0a0d37668d
Org List and Get API Methods ( #132 )
...
* Create the organization Get handler.
* Added org listing.
* Make sure the cmp.Diff always sorts the returned organizations before comparing.
* Connect organization service to the Controller handler.
2020-06-19 10:55:50 -07:00