Commit Graph

18722 Commits

Author SHA1 Message Date
Ryan Cragun
8d22142a3e [QT-572][VAULT-17391] enos: use ec2 fleets for consul storage scenarios (#21400)
Begin the process of migrating away from the "strongly encouraged not to
use"[0] Ec2 spot fleet API to the more modern `ec2:CreateFleet`.
Unfortuantely the `instant` type fleet does not guarantee fulfillment
with either on-demand or spot types. We'll need to add a feature similar
to `wait_for_fulfillment` on the `spot_fleet_request` resource[1] to
`ec2_fleet` before we can rely on it.

We also update the existing target fleets to support provisioning generic
targets. This has allowed us to remove our usage of `terraform-enos-aws-consul`
and replace it with a smaller `backend_consul` module in-repo.

We also remove `terraform-enos-aws-infra` and replace it with two smaller
in-repo modules `ec2_info` and `create_vpc`. This has allowed us to simplify
the vpc resources we use for each scneario, which in turn allows us to
not rely on flaky resources.

As part of this refactor we've also made it possible to provision
targets using different distro versions.

[0] https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-best-practices.html#which-spot-request-method-to-use
[1] https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/spot_fleet_request#wait_for_fulfillment

* enos/consul: add `backend_consul` module that accepts target hosts.
* enos/target_ec2_spot_fleet: add support for consul networking.
* enos/target_ec2_spot_fleet: add support for customizing cluster tag
  key.
* enos/scenarios: create `target_ec2_fleet` which uses a more modern
  `ec2_fleet` API.
* enos/create_vpc: replace `terraform-enos-aws-infra` with smaller and
  simplified version. Flatten the networking to a single route on the
  default route table and a single subnet.
* enos/ec2_info: add a new module to give us useful ec2 information
  including AMI id's for various arch/distro/version combinations.
* enos/ci: update service user role to allow for managing ec2 fleets.

Signed-off-by: Ryan Cragun <me@ryan.ec>
2023-06-22 12:42:21 -06:00
Rowan Smith
c7db2d61b0 [Docs] ldap auth add VAULT_LDAP_PASSWORD environment variable (#21407)
Add VAULT_LDAP_PASSWORD environment variable
2023-06-22 11:31:26 -07:00
Rowan Smith
21bd774c67 Fix incorrect ordering in api-docs-nav-data.json (#21404)
https://github.com/hashicorp/vault/pull/20595/files#diff-9c9c146a6465b0deafac528d60a94bee5f609ac37c203005bd3b5cda6c190882 was a contrib which added a new endpoint, however the ref to the page in api-docs-nav-data.json was incorrectly added and thus appears out of order in the left sidebar, i.e. https://developer.hashicorp.com/vault/api-docs/system/decode-token
2023-06-22 11:05:26 -07:00
Violet Hynes
8e40823fe1 Some small KV API docs improvements (#21395) 2023-06-22 13:39:47 -04:00
Meggie
416dff8765 Update upgrade-to-1.14.x.mdx (#21389)
Add information about Docker retirement.
2023-06-22 17:25:06 +00:00
Christopher Swenson
cf48236a3c Move database connections map out to separate package (#21207)
The upcoming event main plugin will use a very similar pattern
as the database plugin map, so it makes sense to refactor this and move
this map out. It also cleans up the database plugin backend so that
it does not have to keep track of the lock.

Co-authored-by: Tom Proctor <tomhjp@users.noreply.github.com>
2023-06-22 10:20:13 -07:00
Yoko Hyakuna
58b6cb1c42 [Docs] Add cross-links to related tutorials (#21405)
* Add cross-links to related tutorials

* Add additional tutorial links
2023-06-22 08:27:00 -07:00
Angel Garbarino
4fd4a0693d Remove readOnly attrs from Clients Count Config Serializer (#21391)
* octanify and add serialize false to readonly attrs

* alphabetize

* stuff

* adds back payload.data check in normalizeResponse method of clients config serializer

* test things

* fix

* clean up

* Update ui/app/serializers/clients/config.js

Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>

---------

Co-authored-by: Jordan Reimer <zofskeez@gmail.com>
Co-authored-by: claire bontempo <68122737+hellobontempo@users.noreply.github.com>
2023-06-22 01:28:59 +00:00
Raymond Ho
5b41148bfc normalize LDAP auth HTTP responses (#21282) 2023-06-21 15:32:00 -07:00
claire bontempo
8df34b0871 add changelog (#21399) 2023-06-21 14:47:53 -07:00
Rachel Culpepper
254d8f8356 Vault-11623: OSS changes for seal config and env vars (#21116)
* add config changes for name and priority fields in seal stanza

* change env vars and fix tests

* add header and fix func call

* tweak limits on seals

* fix missing import

* add docstrings
2023-06-21 16:30:59 -05:00
Alexander Scheel
15aee2e0ba Fix re-migration of existing CA bundles (#21316)
* Fix re-migration of existing version 1 storage bundles

Related: VAULT-17307

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

* Add test for v1->v2 migration post-issuer deletion

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

* Add changelog entry

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

* Add known-issue about PKI double migration

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

* Update website/content/partials/pki-double-migration-bug.mdx

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

* Update website/content/partials/pki-double-migration-bug.mdx

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

* Update website/content/partials/pki-double-migration-bug.mdx

* Additional clarity around known issue

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

---------

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
Co-authored-by: Sarah Chavis <62406755+schavis@users.noreply.github.com>
2023-06-21 20:34:51 +00:00
Steven Clark
eb634e9326 Remove bump_version from transit import docs (#21393)
- The argument was removed along the development path, but the
   documentation was not updated.
2023-06-21 15:36:52 -04:00
claire bontempo
76e742ba32 ui: HDS adoption replace <AlertBanner> component (#21375)
* UI: HDS adoption replace AlertBanner part 1 (#21163)

* rename test selector

* replace db banner

* add class

* replace db role edit

* db creds

* generate creds

* simpler class

* license banner component

* oidc callback plash

* raft

* aws

* secret create or update

* change to compact alert for form field

* change back to inline

* combine alert banners

* wrap in conditional

* remove references to message class

* UI: HDS adoption replace AlertBanner part 2 (#21243)

* token expire warning

* delete css

* edit form

* item details distribute mfa step 2 transit verify

* back to secondary

* distribute

* oidc lease error

* sign

* kv obj and repl dash

* more repl

* update test selector

* show, creds

* shamir

* pki csr

* pki banners

* add hds library to ember engines

* woops comma

* fix k8 test

* update message error component for last!

* hold off MessageError changes until next pr

* revert test selectors

* update pki tests

* UI: part 3 remove alert banner (#21334)

* final component swap

* and actual final of MessageError

* update MessageError selectors

* delete alert-banner and remove references

* update next step alerts to highlight color

* finishing touches, auth form test and client dashboard inline link

* fix more selectors

* fix shamir flow test

* ui: part 4 final cleanup (#21365)

* replace AlertPopup

* add test tag

* move tag

* one more message error tag

* delete alert popup

* final css cleanup

* move preformatted flash into <p> tag

* ui: address comments for sidebranch  (#21388)

* add periods, move link to trailing

* more periods and typo fix
2023-06-21 11:37:11 -07:00
claire bontempo
772ca6e1bb ui: remove old references to pki and old adapter (#21376)
* remove old references to pki and old adapter

* remove after model hook from list

* remove references to isEngine

* add test

* update test

* delete test

* fix test
2023-06-21 11:36:38 -07:00
Cinthia Conti
f7b96b4443 Update CHANGELOG.md for 1.14.0, 1.13.4, 1.12.8 and 1.11.12 (#21380)
* Update CHANGELOG.md for 1.14.0, 1.13.4, 1.12.8 and 1.11.12

Update CHANGELOG.md for 1.14.0, 1.13.4, 1.12.8 and 1.11.12

* Update CHANGELOG.md 1.14 generated with changelog-build

-last-release c9b7ca7f369f8a8ab0b71ff45fffbd15126abf01
-this-release 81c88fc5890eb19dffed6cac53e09e23a3ee537e

* Update CHANGELOG.md **OCI Auto-Auth**
2023-06-21 12:01:04 -04:00
miagilepner
d8b811d8da Add additional reporting versions to the documentation (#21304)
* add additional versions to the documentation

* pr fixes

* pr fixes
2023-06-21 17:42:23 +02:00
Sarah Chavis
3ad87e4b9a Updates for GA (#21374) 2023-06-21 07:44:50 -07:00
Paul Banks
fbcd92dd88 Remove drift from Ent repo (#21379) 2023-06-21 13:22:07 +00:00
Violet Hynes
99cf3836b6 Update logging completed requests docs (#21368) 2023-06-21 09:18:04 -04:00
Peter Wilson
cf8cf84db9 fix to prevent extra CI running when docs label is added (#21378) 2023-06-21 11:20:55 +00:00
Adrian Todorov
c1e6fa36e1 Update faq.mdx to remove dead link (#21377) 2023-06-21 11:12:06 +00:00
Josh Black
17d63abdb1 bump lib/pq to 1.10.9 (#20594)
* bump lib/pq to 1.10.9

* bump jackc/pgx/v4 also
2023-06-20 13:50:24 -07:00
Violet Hynes
3a46ecc389 Replace all remaining time.ParseDurations with parseutil.ParseDurationSeconds (#21357)
* Replace all time.ParseDurations with testutil.ParseDurationSeconds

* Changelog

* Import formatting

* Import formatting

* Import formatting

* Import formatting

* Semgrep rule that runs as part of CI
2023-06-20 14:37:46 -04:00
Alexander Scheel
4eed18cf49 Add ACME consideration about entity templating (#21356)
These don't do anything but reject requests:

> The server will not issue certificates for the identifier:
> role (something) will not issue certificate for name
> xps15.local.cipherboy.com

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-06-20 14:53:47 +00:00
Nick Cabatoff
67927a1e9f Make sure that main upgrading page contains the guidelines for replicated cluster upgrades (#21351) 2023-06-20 08:37:43 -04:00
Anton Averchenkov
e31ead37ba [docs] Add Agent & Proxy to related tools (#21352) 2023-06-19 14:15:03 -04:00
Andy Assareh
6ebb61cc35 correct spelling error - Compatability to Compatibility (#21333) 2023-06-19 12:38:07 -04:00
Nick Cabatoff
f12c128559 Don't exit just because we think there was a possible deadlock (#21342) 2023-06-19 15:08:34 +00:00
Sarah Chavis
8af6780325 [DOCS] 1.14.0 draft release notes (#21296)
Push initial draft of layout and text
Co-authored-by: Yoko Hyakuna <yoko@hashicorp.com>
2023-06-16 17:08:51 -07:00
Anton Averchenkov
3908ec9dc4 agent: Fix agent generate-config to accept namespace (#21297) 2023-06-16 16:04:15 -04:00
cui fliter
8b30657ddc fix function name in comment (#21214)
Signed-off-by: cui fliter <imcusg@gmail.com>
2023-06-16 16:03:07 -04:00
Violet Hynes
d76424cb53 Miscellaneous docs cleanups (#21327) 2023-06-16 15:38:58 -04:00
Alexander Scheel
3347e5d56b Fix naming of enable_templating parameter (#21319)
Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-06-16 17:04:37 +00:00
miagilepner
30aac443d0 Fix verify test packages GOPRIVATE (#21318) 2023-06-16 16:54:58 +00:00
claire bontempo
9290d5f188 add waitUntil (#21299) 2023-06-16 08:29:18 -07:00
Nick Cabatoff
a1fdf105b3 Setup Go before calling the test package test script (#21308) 2023-06-16 13:57:33 +00:00
Violet Hynes
41f392c43f Fix some broken links/clarify some things in the Vault Proxy docs (#21262)
* Fix some broken links/clarify some things

* More docs fixes

* More docs fixes
2023-06-16 08:47:29 -04:00
Steven Clark
042dd57811 Supporting PR for Enterprise ACME PR cluster tests (#21275)
* Supporting PR for Enterprise ACME PR cluster tests

 - Some changes within the OSS test helpers to help in the ACME Enterprise test cases.

* Don't rename existing helper method to make oss/ent merge easier
2023-06-15 21:12:49 +00:00
Sarah Chavis
774d75e63e 1.14.0 Known Issues text update (#21118)
TW editorial review on language and restructuring for scanability
2023-06-15 13:55:19 -07:00
Matt Schultz
8cc7be234a Adds automated ACME tests using Caddy. (#21277)
* Adds automated ACME tests using Caddy.

* Do not use CheckSignatureFrom method to validate TLS-ALPN-01 challenges

* Uncomment TLS-ALPN test.

* Fix validation of tls-alpn-01 keyAuthz

Surprisingly, this failure was not caught by our earlier, but unmerged
acme.sh tests:

> 2023-06-07T19:35:27.6963070Z [32mPASS[0m builtin/logical/pkiext/pkiext_binary.Test_ACME/group/acme.sh_tls-alpn (33.06s)

from https://github.com/hashicorp/vault/pull/20987.

Notably, we had two failures:

 1. The extension's raw value is not used, but is instead an OCTET
    STRING encoded version:

    > The extension has the following ASN.1 [X.680] format :
    >
    > Authorization ::= OCTET STRING (SIZE (32))
    >
    > The extnValue of the id-pe-acmeIdentifier extension is the ASN.1
    > DER encoding [X.690] of the Authorization structure, which
    > contains the SHA-256 digest of the key authorization for the
    > challenge.
 2. Unlike DNS, the SHA-256 is directly embedded in the authorization,
    as evidenced by the `SIZE (32)` annotation in the quote above: we
    were instead expecting this to be url base-64 encoded, which would
    have a different size.

This failure was caught by Matt, testing with Caddy. :-)

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

* Quick gofmt run.

* Fix challenge encoding in TLS-ALPN-01 challenge tests

* Rename a PKI test helper that retrieves the Vault cluster listener's cert to distinguish it from the method that retrieves the PKI mount's CA cert. Combine a couple of Docker file copy commands into one.

---------

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
Co-authored-by: Steve Clark <steven.clark@hashicorp.com>
Co-authored-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-06-15 20:44:09 +00:00
Hamid Ghaf
f5b2f8744f Bump Go to 1.20.5 (#21283)
* Bump Go to 1.20.5

* updating 1.14 go bump changelog file
2023-06-15 12:52:13 -07:00
Nick Cabatoff
d3ae2085ae Rework the test package tester to avoid grep pitfalls. (#21281) 2023-06-15 19:08:37 +00:00
Alexander Scheel
e6f3003adc ACME Considerations Guide (#21225)
* Add notes on PKI performance and key types

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

* Add ACME Public Internet section

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

* Add note on importance of tidy

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

* Add note on cluster scalability

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

* Add note about server log location

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

* Fix ToC, finish public ACME discussion

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

* Add note on role restrictions and ACLs

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

* Add note on security considerations of ACME

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

* Add consideration note about cluster URLs

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

* Add note on 90 day certificates

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

* Add note about client counts and ACME

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

---------

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-06-15 14:29:52 -04:00
Nick Cabatoff
c5549cdac6 Call runFilteredPathsEvaluation from within mountInternal/enableCredentialInternal (#21260)
The main point of this work is to move runFilteredPathsEvaluation inside mountInternal/enableCredentialInternal, while we hold the lock.  This requires that we grab both the mountsLock and authLock, for reasons that only make sense when looking at the ent code.

While fixing this I noticed that ListAuths grabs the wrong lock, so I also fixed that.

And I modified ClusterSetup: as a convenience, it now populates the factories for all the builtin engines in the config it returns.
2023-06-15 16:55:59 +00:00
Nick Cabatoff
7b56b69959 Allow mounted paths to be tracked via path hook for use in merkle tree management (#21261) 2023-06-15 12:32:38 -04:00
Jordan Reimer
d001a0482e Bump HDS to 2.7.0 (#21259)
* bumps hds and flight icon deps to latest

* renames page-header style sheet to fix collision with HDS
2023-06-15 10:20:35 -06:00
miagilepner
b993384983 VAULT-16905: Add upgrade description about non entity tokens (#21245)
* add to utilization reporting

* add known issue

* fixes
2023-06-15 17:38:28 +02:00
Nick Cabatoff
6b87a087af Fix a panic I observed in a sealed node running CollectMetrics (#21249) 2023-06-15 15:02:20 +00:00
Jordan Reimer
fd1f95439d Rename PKI check-config Decorator (#21241)
* renames pki check-config decorator to check-issuers

* reverts check-issuers decorator function name change
2023-06-14 16:22:33 -06:00