Brian Kassouf
c705adc79c
Fix some linting errors ( #12860 )
2021-10-18 17:29:47 -07:00
Rémi Lapeyre
308806eee3
Return 404 response when looking for a secret_id_accessor that does not exist ( #12788 )
...
* Return 404 response when looking for an secret_id_accessor that does not exist
Closes https://github.com/hashicorp/vault/issues/12660
2021-10-11 15:07:51 +01:00
Lars Lehtonen
159272db7f
builtin/credential/approle: fix dropped test errors ( #11990 )
2021-07-05 11:00:12 -04:00
Marc Boudreau
3c35a25d36
Fix for Issue 11863 - Panic when creating/updating approle role with token_type ( #11864 )
...
* initializing resp variable with aa *logical.Response before using it to add warning for default-service or default-batch token type. Also adding guard around code that sets resp to a new logical.Response further on in the function.
* adding changelog entry
* renaming changelog file to match PR number
2021-06-24 13:03:41 -04:00
Brian Kassouf
303c2aee7c
Run a more strict formatter over the code ( #11312 )
...
* Update tooling
* Run gofumpt
* go mod vendor
2021-04-08 09:43:39 -07:00
Calvin Leung Huang
b1c4b86d7f
approle: add ttl to the secret ID generation response ( #10826 )
...
* approle: add ttl to the secret ID generation response
* approle: move TTL derivation into helper func
* changelog: add changelog entry
* docs: update approle docs and api-docs pages
2021-02-03 16:32:16 -08:00
Calvin Leung Huang
522fa83568
sdk/logical: handle empty token type string values as TokenTypeDefault ( #7273 )
...
* sdk/logical: handle empty token type string values as TokenTypeDefault
* add test case for missing token_type value
2019-08-14 09:45:40 -04:00
ncabatoff
f7690d1f6a
Handle TokenType serialized as string or as uint8. ( #7233 )
2019-08-05 16:51:14 -04:00
Jeff Mitchell
2bca5f439f
AppRole TokenUtil conversion ( #7020 )
2019-07-01 16:30:08 -04:00
Jeff Mitchell
8d6ce1ffb5
Move policyutil to sdk
2019-04-12 18:08:46 -04:00
Jeff Mitchell
8bcb533a1b
Create sdk/ and api/ submodules ( #6583 )
2019-04-12 17:54:35 -04:00
Jeff Mitchell
a64fc7d7cb
Batch tokens ( #755 )
2018-10-15 12:56:24 -04:00
Becca Petrin
73cbbe2a9f
Add bound cidrs to tokens in AppRole ( #4680 )
2018-06-19 22:57:11 -04:00
Vishal Nayak
11e2fd2fce
approle: Fix role name case sensitivity issue
2018-06-05 18:53:27 -04:00
vishalnayak
9ef3a36007
s/enable_local_secret_ids/local_secret_ids
2018-04-24 17:52:42 -04:00
vishalnayak
7832e06fdc
Add field read test
2018-04-24 15:48:07 -04:00
vishalnayak
c46e021543
Add tests
2018-04-24 11:02:11 -04:00
vishalnayak
aade040e50
Add immutability test
2018-04-24 10:05:17 -04:00
vishalnayak
97c03c5a65
Add enable_local_secret_ids to role read response
2018-04-24 09:53:36 -04:00
vishalnayak
a369a4edb6
Upgrade secret ID prefix and fix tests
2018-04-23 16:31:51 -04:00
Vishal Nayak
527eb418fe
approle: Use TypeCommaStringSlice for BoundCIDRList ( #4078 )
...
* Use TypeCommaStringSlice for Approle bound_cidr_list
* update docs
* Add comments in the test
2018-03-08 17:49:08 -05:00
Brian Kassouf
2f19de0305
Add context to storage backends and wire it through a lot of places ( #3817 )
2018-01-19 01:44:44 -05:00
Brian Kassouf
1c190d4bda
Pass context to backends ( #3750 )
...
* Start work on passing context to backends
* More work on passing context
* Unindent logical system
* Unindent token store
* Unindent passthrough
* Unindent cubbyhole
* Fix tests
* use requestContext in rollback and expiration managers
2018-01-08 10:31:38 -08:00
Vishal Nayak
513d12ab7c
Fix the casing problem in approle ( #3665 )
2017-12-11 16:41:17 -05:00
Vishal Nayak
61d617df81
Avoid race conditions in AppRole ( #3561 )
...
* avoid race conditions in approle
* return a warning from role read if secondary index is missing
* Create a role ID index if a role is missing one
* Fix locking in approle read and add test
* address review feedback
2017-11-10 11:32:04 -05:00
Jeff Mitchell
9077adb377
Sanitize policy behavior across backends ( #3324 )
...
Fixes #3323
Fixes #3318
* Fix tests
* Fix tests
2017-09-13 11:36:52 -04:00
Lars Lehtonen
3f0b15826a
Fix swallowed errors in builtin ( #2977 )
2017-07-07 08:23:12 -04:00
Ben Gadbois
537342f038
Fixing printf (and similar) issues ( #2666 )
2017-05-01 23:34:10 -04:00
Vishal Nayak
491a56fe9f
AppRole: Support restricted use tokens ( #2435 )
...
* approle: added token_num_uses to the role
* approle: added RUD tests for token_num_uses on role
* approle: doc: added token_num_uses
2017-03-03 09:31:20 -05:00
Félix Cantournet
103b7ceab2
all: test: Fix govet warnings
...
Fix calls to t.Fatal() with formatting.
Fixed some calls to Fatalf() with wrong formatting
2016-12-21 19:44:07 +01:00
vishalnayak
1487dce475
Fix regression caused by not creating a role_id secondary index
2016-10-14 12:56:29 -04:00
vishalnayak
d20819949c
Make secret-id reading and deleting, a POST op instead of GET
2016-09-28 20:22:37 -04:00
vishalnayak
aaadd4ad97
Store the CIDR list in the secret ID storage entry.
...
Use the stored information to validate the source address and credential issue time.
Correct the logic used to verify BoundCIDRList on the role.
Reverify the subset requirements between secret ID and role during credential issue time.
2016-09-21 20:19:26 -04:00
vishalnayak
93604e1e2e
Added cidrutil helper
2016-09-21 13:58:32 -04:00
vishalnayak
bef9c2ee61
Ensure at least one constraint on the role
2016-09-13 16:03:15 -04:00
vishalnayak
dfe73733d5
Seperate endpoints for read/delete using secret-id and accessor
2016-08-21 14:42:49 -04:00
vishalnayak
a6907769b0
AppRole authentication backend
2016-07-26 09:32:41 -04:00