Commit Graph

18722 Commits

Author SHA1 Message Date
Josh Black
1e34eb5ef8 update vault auth submodules to api/v1.10.0 (#22772) api/auth/userpass/v0.5.0 api/auth/approle/v0.5.0 api/auth/aws/v0.5.0 api/auth/azure/v0.5.0 api/auth/gcp/v0.5.0 api/auth/ldap/v0.5.0 api/auth/kubernetes/v0.5.0 2023-09-05 18:57:10 +00:00
Josh Black
23932dee23 Use new sdk and api versions (#22771) 2023-09-05 18:37:17 +00:00
Divya Pola
dcb7083260 Validate seal generation info only if beta flag is enabled (#22741) 2023-09-05 13:13:43 -05:00
hc-github-team-secure-vault-core
b97ec49125 Update hashicorp/vault-plugin-secrets-gcpkms to v0.15.1 (#22757)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
api/v1.10.0 sdk/v0.10.0
2023-09-05 15:27:46 +00:00
Cinthia Conti
fcd6f01761 UI: [VAULT-18126] adding style to prevent namespace to overflow on sidebar (#22733)
* adding style to prevent namespace to overflow

* adding helper css classes

* adding changelog entry

* removing namespace-name class in favour of helper classes

* style cleanup

* removing identation
2023-09-05 11:04:08 -04:00
hc-github-team-secure-vault-core
dc896a5aa1 Update hashicorp/vault-plugin-auth-cf to v0.15.1 (#22758)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-09-05 14:53:20 +00:00
Alexander Scheel
f150a52593 Fix transit panic with invalid PEM (#22753)
* Fix transit panic with invalid PEM

When an invalid (non-PEM) public key is given to Transit's import, this
fails with a panic in server logs:

    2023-09-05T08:11:11.526-0400 [INFO]  http: panic serving 127.0.0.1:42414: runtime error: invalid memory address or nil pointer dereference
    goroutine 950 [running]:
    net/http.(*conn).serve.func1()
	    /usr/local/go/src/net/http/server.go:1868 +0xb9
    panic({0x8371620?, 0x1050b390?})
	    /usr/local/go/src/runtime/panic.go:920 +0x270
    github.com/hashicorp/vault/sdk/helper/keysutil.(*Policy).ImportPublicOrPrivate(0xc003fff440, {0xaf02918, 0xc004509920}, {0xaf03670, 0xc0032e4180}, {0xc004532ea0, 0x188, 0x1a0}, 0x0, {0xae7f5e0, ...})
	    /home/cipherboy/GitHub/cipherboy/vault/sdk/helper/keysutil/policy.go:1538 +0x687
    github.com/hashicorp/vault/sdk/helper/keysutil.(*LockManager).ImportPolicy(0xc001a29410, {0xaf02918, 0xc004509920}, {{0xaf03670, 0xc0032e4180}, {0xc003eb5ab5, 0xb}, 0x3, 0x0, 0x0, ...}, ...)
	    /home/cipherboy/GitHub/cipherboy/vault/sdk/helper/keysutil/lock_manager.go:517 +0x38a

This is unfortunate and doesn't reveal the cause of the failure: input
was not provided in PEM format, per docs.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Fix additional PEM decode without error check

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Add changelog entry

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

---------

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-09-05 14:32:20 +00:00
Steven Clark
a7c2b15f4e Improve transit import command error handling (#22755)
- Doubtful this will ever happen in real life
 - We would nil panic if the public_key field was not present in the
   wrapping key response
 - Also trap a casting error if the public key was not an RSA public key
2023-09-05 10:04:37 -04:00
miagilepner
de043d6736 Fix flaky rollback test (#22754)
* fix flaky rollback test

* better fix

* switch to defer

* add comment
2023-09-05 13:44:40 +00:00
miagilepner
4e3b91d91f [VAULT-17827] Rollback manager worker pool (#22567)
* workerpool implementation

* rollback tests

* website documentation

* add changelog

* fix failing test
2023-09-04 15:48:09 +02:00
hc-github-team-secure-vault-core
c25e1a5fd4 Update hashicorp/vault-plugin-secrets-mongodbatlas to v0.10.1 (#22748)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-09-01 15:08:39 -07:00
hc-github-team-secure-vault-core
f3c0bfeb5d Update hashicorp/vault-plugin-secrets-gcp to v0.17.0 (#22746)
Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-09-01 20:40:44 +00:00
Tom Proctor
d5b223424d Revert "Pin security scan's semgrep version to 1.37.0 (#22731)" (#22745)
This reverts commit 9808578086.

Previous issue fixed in returntocorp/semgrep#8604, released in 1.38.1
2023-09-01 20:32:48 +00:00
Josh Black
dbf094940f Add more docs for update-primary (#22677)
* add more docs for update-primary

* Update website/content/api-docs/system/replication/replication-dr.mdx

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

* Update website/content/api-docs/system/replication/replication-dr.mdx

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

* Update website/content/api-docs/system/replication/replication-dr.mdx

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

* Update website/content/api-docs/system/replication/replication-performance.mdx

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

* Update website/content/api-docs/system/replication/replication-performance.mdx

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

* PR feedback

* Apply suggestions from code review

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>

---------

Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>
2023-09-01 12:42:46 -07:00
Victor Rodriguez
5dc85c58c1 Protect SealWrapper health fields (#22740)
* Create accessors for SealWrapper fields protecteb by the lock.

* Use NewSealWrapper constructor to create all seal wrappers.
2023-09-01 14:38:11 -04:00
Tom Proctor
07e76196ba Support running plugins in isolated containers (#22712)
Implements running plugins in containers to give them some degree
of isolation from the main Vault process and other plugins. It only
supports running on Linux initially, where it is easiest to manage unix
socket communication across the container boundary.

Additionally

* Adds -env arg to vault plugin register.
* Don't return env from 'vault plugin info'

Historically it's been omitted, and it could conceivably have secret information in
it, so if we want to return it in the response, it should probably only be via explicit
opt-in. Skipping for now though as it's not the main purpose of the commit.
2023-09-01 17:55:17 +00:00
Thy Ton
c26aa9cb9e add copyright header (#22739) 2023-09-01 17:42:02 +00:00
Peter Wilson
3eba73892b Eventbus related refactoring (#22732)
* refactored test to try and see if we can solve flakey test errors

* refactored code for readability

* don't defer in a for loop
2023-09-01 17:00:37 +00:00
Sarah Chavis
133e9ac793 Add WAF links and remove tip notation from guide (#22710) 2023-09-01 12:51:32 -04:00
Raymond Ho
715f02ff0d fix: upgrade vault-plugin-auth-kubernetes to v0.17.0 (#22709) 2023-09-01 09:35:44 -07:00
hc-github-team-secure-vault-core
ece4b60346 Update hashicorp/vault-plugin-secrets-openldap to v0.11.2 (#22734)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-09-01 11:28:55 -05:00
hc-github-team-secure-vault-core
ccda5e2a34 Update hashicorp/vault-plugin-secrets-kv to v0.16.1 (#22716) 2023-09-01 10:52:59 -05:00
Angel Garbarino
18d694fd06 KV - no list permissions error catch (#22670)
* initial fix. need to clear out local storage to see it work.

* first draft

* clean up

* test fix

* add test coverage

* pairing to do clean up

* update tests
2023-09-01 09:27:36 -06:00
Tom Proctor
9808578086 Pin security scan's semgrep version to 1.37.0 (#22731)
hashicorp/security-scanner#504 tracks the breakage that requires us to pin pre-1.38.0 for now
2023-09-01 15:39:35 +01:00
Divya Pola
5481fd2cef Set partiallyWrappedPaths to false in operator_diagnose test (#22724)
* Fix failure in operator_diagnose test

* Fix a typo

* make fmt fix

---------

Co-authored-by: Peter Wilson <peter.wilson@hashicorp.com>
2023-09-01 07:57:28 -05:00
miagilepner
258dc91f09 Fix activity log test for enterprise (#22727) 2023-09-01 12:06:14 +00:00
Ellie
bd36e66ea6 Add config value that gives users options to skip calculating role for each lease (#22651)
* Add config value that gives users options to skip calculating role for each lease

* add changelog

* change name

* add config for testing

* Update changelog/22651.txt

Co-authored-by: Violet Hynes <violet.hynes@hashicorp.com>

* update tests, docs and reorder logic in conditional

* fix comment

* update comment

* fix comment again

* Update comments and change if order

* change comment again

* add other comment

* fix tests

* add documentation

* edit docs

* Update http/util.go

Co-authored-by: Mike Palmiotto <mike.palmiotto@hashicorp.com>

* Update vault/core.go

* Update vault/core.go

* update var name

* udpate docs

* Update vault/request_handling.go

Co-authored-by: Mike Palmiotto <mike.palmiotto@hashicorp.com>

* 1 more docs change

---------

Co-authored-by: Violet Hynes <violet.hynes@hashicorp.com>
Co-authored-by: Mike Palmiotto <mike.palmiotto@hashicorp.com>
2023-09-01 07:01:41 -05:00
Peter Wilson
897cbbc0c3 make fmt fix (#22725) 2023-09-01 09:37:22 +00:00
miagilepner
6fd8cb6409 [VAULT-15398] Client count tests (#22635)
* fix bugs in client count data generation

* add new tests for client counts

* fix package name
2023-09-01 11:32:40 +02:00
Victor Rodriguez
00e355c491 Refactor the seal wrapper health check (#22701)
* Stop embedding Wrapper in SealInfo, make it an explicit field.

* Move SealWrapper to its own file.

Remove unused method SealWrapper.keyId().

* Extract method SealWrapper.CheckHealth out of StartHealthCheck.

Restore the metrics around overall seal health, so that we have metrics for
individual seal wrappers as well as the backend itself.
2023-08-31 22:49:04 +00:00
Tom Proctor
87649219ff Add -dev-tls-san flag (#22657)
* Add -dev-tls-san flag

This is helpful when wanting to set up a dev server with TLS in Kubernetes
and any other situations where the dev server may not be the same machine
as the Vault client (e.g. in combination with some /etc/hosts entries)

* Automatically add (best-effort only) -dev-listen-address host to extraSANs
2023-08-31 23:31:42 +01:00
Chelsea Shaw
8da06f9b54 UI: Update kv list filter to not search on type (#22648) 2023-08-31 21:30:00 +00:00
John-Michael Faircloth
16f805419f fix rotation_window bug in error path (#22699) 2023-08-31 15:45:01 -05:00
Thy Ton
08574508c8 add plugin runtime API (#22469)
---------

Co-authored-by: Tom Proctor <tomhjp@users.noreply.github.com>
2023-08-31 13:37:04 -07:00
Angel Garbarino
50bad8c035 add missing adapter test and handle the kv/metadata currentSecret getter (#22700) 2023-08-31 13:57:23 -06:00
Jason O'Donnell
4e963c4c5b Add worker pool for LDAP group lookup (#22659)
* Add worker pool for LDAP group lookup

* changelog

* Add lock

* derefAliases disappeared
2023-08-31 19:34:23 +00:00
Divya Pola
cdf6bf0669 Add checks to see if current seal generation is in middle of rewrapping (#22692)
* Add checks to see if current seal generation is in middle of rewrapping

* Check for rewrap flag only if thr previous configuration is not shamir
2023-08-31 14:32:22 -05:00
Violet Hynes
3e0baa9864 New-line and emojify test output (#22663)
* Attempt to new-line/emojify test output

* Update emoji

* Make it always run, for testing

* Put the emojis first

* Add a space

* OSS -> CE

* Update enterprise tests also

* Test failure

* Test failures but better

* Print it even if not main :)

* Fix the comparison

* Finalize changes
2023-08-31 15:29:59 -04:00
Kianna
1dfd57e26d UI: [VAULT-19560] Add empty states and tests (#22690) 2023-08-31 12:12:20 -07:00
hc-github-team-secure-vault-core
bbffe93bbb Update hashicorp/vault-plugin-auth-jwt to v0.17.0 (#22678)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-08-31 11:59:34 -07:00
hc-github-team-secure-vault-core
d9ec27eb4c Update hashicorp/vault-plugin-database-elasticsearch to v0.13.3 (#22696)
* Automated dependency upgrades

* Add changelog

---------

Co-authored-by: hc-github-team-secure-vault-ecosystem <hc-github-team-secure-vault-ecosystem@users.noreply.github.com>
2023-08-31 11:31:38 -07:00
claire bontempo
173b007b02 ui: Refreshes parent route to fix secret state discrepancies within a namespace for kv v2 (#22681)
* move json toggle action to template

* add test for version dropdown problem

* refactor write secret to allow for namespaces

* consolidate transition functions

* refresh model for certain routes

* add destroy assertion

* rename variables

* remove dataset clearing from details component
2023-08-31 18:05:52 +00:00
claire bontempo
1d273d6b3e ui: unskip mount engine transition tests (#22693)
* unskip mount backend transition tests

* address comment

* add enterprise tests
2023-08-31 11:01:17 -07:00
Peter Wilson
d2d3d8a27d Fix potential panic in audit during header formatting (#22694) 2023-08-31 17:44:35 +00:00
Rachel Culpepper
56ce89544e Change to prioritize config over env for transit (#22615)
* change to prioritize config over env for transit

* add special cases for transit config

* fix formatting

* fix typo

* change contains function

* add comments
2023-08-31 15:28:51 +00:00
Victor Rodriguez
caec65a7a5 Rename SealInfo to SealWrapper. (#22689) 2023-08-31 11:27:36 -04:00
Tom Proctor
3e55447036 Refactor plugin catalog set functions (#22666)
Use a struct arg instead of a long list of args. Plugins running in containers
will require even more args and it's getting difficult to maintain.
2023-08-31 10:32:24 +01:00
Austin Gebauer
1acd0c6d24 Adds adjustment factor for assertions in auth enable tests (#22679)
* Adds adjustment factor for assertions in auth enable tests

* format comment
2023-08-30 15:51:49 -07:00
brian shore
c31817abd0 Add GitHub workflow concurrency controls (#22610) 2023-08-30 14:39:50 -07:00
Kianna
fc9e308f02 UI: Cleanup dashboard (#22574) 2023-08-30 14:17:06 -07:00