Commit Graph

375 Commits

Author SHA1 Message Date
Calvin Leung Huang a08ccbffa7
[Review Only] Autoseal OSS port (#757)
* Port awskms autoseal

* Rename files

* WIP autoseal

* Fix protobuf conflict

* Expose some structs to properly allow encrypting stored keys

* Update awskms with the latest changes

* Add KeyGuard implementation to abstract encryption/decryption of keys

* Fully decouple seal.Access implementations from sealwrap structs

* Add extra line to proto files, comment update

* Update seal_access_entry.go

* govendor sync

* Add endpoint info to configureAWSKMSSeal

* Update comment

* Refactor structs

* Update make proto

* Remove remove KeyGuard, move encrypt/decrypt to autoSeal

* Add rest of seals, update VerifyRecoveryKeys, add deps

* Fix some merge conflicts via govendor updates

* Rename SealWrapEntry to EncryptedBlobInfo

* Remove barrier type upgrade check in oss

* Add key to EncryptedBlobInfo proto

* Update barrierTypeUpgradeCheck signature
2018-10-19 14:43:57 -07:00
Brian Kassouf 48ee3650a3
Update deps (#5521) 2018-10-15 15:25:08 -07:00
Brian Kassouf d987a3c230
Update deps (#5520) 2018-10-15 14:36:55 -07:00
Becca Petrin 072d56be95 vendor the desired version of go.uuid (#5458) 2018-10-03 15:30:05 -07:00
Brian Kassouf 2995c06a53
Fix build (#5457) 2018-10-03 14:53:08 -07:00
Brian Kassouf 9307ba4b0b
Update Deps (#5454) 2018-10-03 09:55:26 -07:00
Brian Kassouf bc36d78df1 Update plugins 2018-10-02 11:14:15 -07:00
Becca Petrin 3da8d38e7d point at a fork of aliyun-oss-go-sdk (#5358) 2018-10-01 10:05:08 -07:00
Jeff Mitchell 56aaaac944
Add lz4 to compressutil (#5403) 2018-09-26 09:20:33 -05:00
Becca Petrin 74d4d0ccc0
add alicloud secrets engine (#5352) 2018-09-19 08:42:28 -07:00
Clint 5882156f53
Translate AWS Rate limiting errors to 502 errors (#5270)
* Initial implemntation of returning 529 for rate limits

- bump aws iam and sts packages to v1.14.31 to get mocking interface
- promote the iam and sts clients to the aws backend struct, for mocking in tests
- this also promotes some functions to methods on the Backend struct, so
  that we can use the injected client

Generating creds requires reading config/root for credentials to contact
IAM. Here we make pathConfigRoot a method on aws/backend so we can clear
the clients on successful update of config/root path. Adds a mutex to
safely clear the clients

* refactor locking and unlocking into methods on *backend

* refactor/simply the locking

* check client after grabbing lock
2018-09-18 15:26:06 -05:00
Jeff Mitchell cdd08cba58 Bump for release 2018-09-05 13:17:37 -04:00
Becca Petrin 7e0e49656a Add AliCloud auth to the Vault Agent (#5179) 2018-09-05 11:56:30 -04:00
Jeff Mitchell a001021d51 Sync plugin updates 2018-08-28 02:39:13 -04:00
Brian Kassouf 20a58d68df
Update kv plugin (#5187) 2018-08-25 14:56:40 -07:00
Jeff Mitchell 64660afee2 Get reflect2 into vendoring 2018-08-22 16:11:51 -04:00
Jeff Mitchell f42201ac64 Add ali deps to vendor 2018-08-22 15:39:18 -04:00
Jim Kalafut d8dc68495d
Update Azure Secrets plugin (#5154) 2018-08-21 21:05:05 -07:00
Jeff Mitchell fcc2cd7356 Pull in go-ldap update that fixes comparison with AD 2018-08-20 18:16:47 -04:00
Jeff Mitchell bb9b4bcf08 Sync plugins 2018-08-16 16:21:38 -04:00
Jim Kalafut a8e81ce393 Initial import of Azure Secrets (#5120)
* Initial import of Azure Secrets

* Update vendor folder
2018-08-16 12:18:06 -07:00
Becca Petrin 8e8095163e Add alicloud auth (#5123)
* add alicloud auth commands

* add dependencies
2018-08-16 12:17:49 -07:00
Nándor István Krácser b9fab6375b Alibaba Object Storage support (#4783) 2018-08-13 17:03:24 -04:00
Brian Kassouf 735287bd6a
Update k8s auth (#5059) 2018-08-07 10:45:40 -07:00
Joel Thompson eb322bbbc5 Vendor AWS ARN parser (#5048)
This adds the AWS ARN parser into the vendor as suggested by
https://github.com/hashicorp/vault/pull/4360#discussion_r186744987
2018-08-06 09:51:06 -07:00
Jim Kalafut 2a8f368ef8 Update GCP auth plugin (#5043)
Fixes #5037
2018-08-03 14:56:02 -07:00
Brian Kassouf 215d4404e0
Update ad plugin (#5008) 2018-07-27 14:52:38 -06:00
Jeff Mitchell 09ac94a59f Update plugins 2018-07-24 22:19:38 -04:00
Chris Hoffman 1cd2509065
updating azure plugin (#4989) 2018-07-24 22:13:23 -04:00
Jeff Mitchell e72890e83f
VSI (#4985) 2018-07-24 22:02:27 -04:00
Jim Kalafut ca8dd26374
Update Azure auth plugin (#4978) 2018-07-23 15:00:46 -07:00
Chris Hoffman b37c05cf64
updating azure auth plugin and docs (#4975) 2018-07-23 10:00:44 -04:00
Jeff Mitchell bb057dd1df Update go-retryablehttp and affected deps 2018-07-19 08:50:18 -04:00
Jeff Mitchell 4b354e1110
Re-add dockertest and fix up imports and update script (#4909) 2018-07-11 17:49:13 -04:00
Jeff Mitchell a371bd7e7b Minor dep sync 2018-07-11 16:04:02 -04:00
Jeff Mitchell f05e132c91 Sync jwt auth plugin 2018-07-10 11:14:36 -04:00
Jeff Mitchell 1011f61bf2 Add JWT plugin 2018-07-09 16:21:47 -04:00
Jeff Mitchell 2821ccd6a3 Bump hclog 2018-07-09 12:54:13 -04:00
Jeff Mitchell 94486a6650 Bump deps 2018-07-09 12:41:21 -04:00
Chris Hoffman a1c8c8459b
Bump Deps (#4868)
* bump deps

* revert script changes

* adding govendor miss
2018-07-06 12:09:34 -04:00
Jeff Mitchell 00673fe197 Update kubernetes auth plugin 2018-06-19 23:03:22 -04:00
Jeff Mitchell 961d24d89a Update ad plugin 2018-06-19 12:16:20 -04:00
Jeff Mitchell bef7db5711 Bump Kube auth dep 2018-06-18 12:24:41 -04:00
Jeff Mitchell fccf7204b8 Bump plugins and changelog 2018-06-18 11:54:23 -04:00
Becca Petrin e285915915
update go-ldap (#4776) 2018-06-15 10:13:57 -07:00
Jim Kalafut 88102708a2
Update aws-sdk-go/service/dynamodb/dynamodbattribute (#4744)
Fixes #4721, Fixes #4742
2018-06-12 06:07:15 -07:00
Jeff Mitchell 2ac5c2cdac Pull in kv fix for 4726 2018-06-08 13:48:25 -04:00
Jeff Mitchell 9fce6c0c0c Update plugins 2018-06-05 22:57:35 -04:00
Becca Petrin 2e8a3e6d59 update ad dependency (#4692) 2018-06-04 15:09:41 -04:00
Jeff Mitchell b9ea7ae7cd Bump retryablehttp dep 2018-05-31 17:14:04 -04:00
Jim Kalafut 2528a261bf
Add gzip compression to UI static content responses (#4664) 2018-05-31 09:42:08 -07:00
Jeff Mitchell 53c6ffcb75 Update kv plugin 2018-05-30 09:07:19 -04:00
Jeff Mitchell 0e396cf4fe Bump plugin deps 2018-05-29 21:16:48 -04:00
emily 192c228931 Add GCP auth helper (#4654)
* update auth plugin vendoring

* add GCP auth helper and docs
2018-05-29 20:36:24 -04:00
Becca Petrin 13a0eebb67
Update ad plugin (#4652) 2018-05-29 16:16:43 -07:00
Brian Kassouf 893d874291 Update proto files (#4651) 2018-05-29 18:23:51 -04:00
Jeff Mitchell bd0ac25eb9
Merge branch 'master' into rekey-verification 2018-05-29 10:19:57 -04:00
Becca Petrin 94ae5d2567
Add Active Directory secrets plugin (#4635) 2018-05-25 11:37:41 -07:00
Jeff Mitchell 9255cc84da Add updated go-retryablehttp 2018-05-21 13:39:45 -04:00
Jeff Mitchell 484b32d3da Update go-retryablehttp de 2018-05-18 15:11:44 -04:00
emily 1eb2765318 update gcputil deps (#4537) 2018-05-10 08:24:53 -04:00
Jeff Mitchell f4b98ace65 Fix retryable dep 2018-05-09 20:52:44 -04:00
Jeff Mitchell 2cc9b7fc72 Update retryable dep 2018-05-09 20:49:32 -04:00
Jeff Mitchell bbaf923a27 Update retryable vendor 2018-05-09 18:34:05 -04:00
Jeff Mitchell 2dc9276e4c Update go-retryablehttp and use PassthroughErrorHandler 2018-05-09 18:11:08 -04:00
Jeff Mitchell a59661a87a Remove unneeeded dep 2018-05-09 17:50:49 -04:00
Jeff Mitchell 7f886b5675 Update go-retryablehttp vendor 2018-05-09 17:44:53 -04:00
Becca Petrin d51acbde68
New proto version (#4501) 2018-05-03 10:19:39 -07:00
Brian Kassouf c7f9d185b0
Kv preflight (#4430)
* Update kv command to use a preflight check

* Make the existing ui endpoint return the allowed mounts

* Add kv subcommand tests

* Enable `-field` in `vault kv get/put` (#4426)

* Enable `-field` in `vault kv get/put`

Fixes #4424

* Unify nil value handling

* Use preflight helper

* Update vkv plugin

* Add all the mount info when authenticated

* Add fix the error message on put

* add metadata test

* No need to sort the capabilities

* Remove the kv client header

* kv patch command (#4432)

* Fix test

* Fix tests

* Use permission denied instead of entity disabled
2018-04-23 15:00:02 -07:00
Jeff Mitchell 8d338f9903 Bump secrets-gcp for panic fix (#6) 2018-04-23 10:11:14 -04:00
Jeff Mitchell 640b30ff7b
Resultant acl (#4386) 2018-04-20 14:19:04 -04:00
Jeff Mitchell 4e444ae2f9 Update gcp plugin 2018-04-17 13:50:28 -04:00
Jeff Mitchell 35c852b97f Bump gcp secrets plugin 2018-04-17 11:59:43 -04:00
Andrew Hamilton 2eb334d156 Updates pester so that retries work (#4322) 2018-04-10 00:34:16 -04:00
Jeff Mitchell 6f1bd385c7 Bump KV plugin 2018-04-09 17:28:32 -04:00
Jeff Mitchell 2d5120fe2a Bump KV plugin and allow `-version` to work 2018-04-09 16:33:01 -04:00
Brian Kassouf 1f7f21f24f
Update kv plugin (#4320) 2018-04-09 12:47:34 -07:00
Jeff Mitchell 9f435a75eb Update azure plugin 2018-04-09 14:51:14 -04:00
Brian Kassouf 2bb3ecea33
Update kv plugin (#4317) 2018-04-09 10:20:47 -07:00
Brian Kassouf eee819e37e
Update kv plugin (#4315) 2018-04-09 09:52:13 -07:00
Jeff Mitchell 36c507b273 Update vault-plugin-auth-gcp to get client invalidation fix 2018-04-07 21:07:43 -04:00
Chris Hoffman e1edbbde4f
update azure plugin (#4306) 2018-04-07 11:20:22 -04:00
Jeff Mitchell 510a57e7de Update CLI coloring 2018-04-06 14:38:56 -04:00
Jeff Mitchell 7d520e53a5 Update auth-gcp plugin 2018-04-05 17:34:27 -04:00
Jeff Mitchell 27db47828b Bump kv plugin 2018-04-05 14:09:19 -04:00
Chris Hoffman 384b0c0b74
update azure plugin (#4266) 2018-04-04 08:02:37 -04:00
Jeff Mitchell 4a45851681 Update plugins 2018-04-03 22:40:35 -04:00
Jeff Mitchell 8d33a0e089 Bump vkv plugin 2018-04-03 17:09:33 -04:00
Jeff Mitchell 4b687eca3f Update vkv plugin 2018-04-03 15:55:57 -04:00
Jeff Mitchell c10ae3a755 Bump vkv plugin 2018-04-03 15:04:33 -04:00
Jeff Mitchell 9d16593f48 Interim vkv plugin push 2018-04-03 14:34:36 -04:00
Chris Hoffman e293fe84c3 OSS: Adding UI handlers and configurable headers (#390)
* adding UI handlers and UI header configuration

* forcing specific static headers

* properly getting UI config value from config/environment

* fixing formatting in stub UI text

* use http.Header

* case-insensitive X-Vault header check

* fixing var name

* wrap both stubbed and real UI in header handler

* adding test for >1 keys
2018-04-03 09:34:01 -05:00
Becca Petrin 03cf302e9a Move to "github.com/hashicorp/go-hclog" (#4227)
* logbridge with hclog and identical output

* Initial search & replace

This compiles, but there is a fair amount of TODO
and commented out code, especially around the
plugin logclient/logserver code.

* strip logbridge

* fix majority of tests

* update logxi aliases

* WIP fixing tests

* more test fixes

* Update test to hclog

* Fix format

* Rename hclog -> log

* WIP making hclog and logxi love each other

* update logger_test.go

* clean up merged comments

* Replace RawLogger interface with a Logger

* Add some logger names

* Replace Trace with Debug

* update builtin logical logging patterns

* Fix build errors

* More log updates

* update log approach in command and builtin

* More log updates

* update helper, http, and logical directories

* Update loggers

* Log updates

* Update logging

* Update logging

* Update logging

* Update logging

* update logging in physical

* prefixing and lowercase

* Update logging

* Move phyisical logging name to server command

* Fix som tests

* address jims feedback so far

* incorporate brians feedback so far

* strip comments

* move vault.go to logging package

* update Debug to Trace

* Update go-plugin deps

* Update logging based on review comments

* Updates from review

* Unvendor logxi

* Remove null_logger.go
2018-04-02 17:46:59 -07:00
Jeff Mitchell 5590cb63c1 Merge in go-hclog 2018-04-02 16:14:46 -04:00
Jeff Mitchell 95d9e83bc3 Merge in go-hclog 2018-04-02 15:58:31 -04:00
Jeff Mitchell 85584e75f4 Update go-hclog and go-plugin 2018-04-02 14:22:52 -04:00
Jeff Mitchell 7a6f582168
1.10 Updates (#4218) 2018-03-29 15:32:16 -04:00
Chris Hoffman 84ec79a93f
updating azure plugin and deps (#4191) 2018-03-23 16:48:05 -04:00
Jeff Mitchell a62376c429 Remove unneeded dep file 2018-03-21 23:10:34 -04:00
Brian Kassouf ad383e911f Update kv backend and add some docs (#4182)
* Add kv backend

* Move kv in apha order

* Update kv backend and add some docs
2018-03-21 23:10:05 -04:00
Jeff Mitchell 2bb4e7535a Add gcp secrets 2018-03-21 23:07:16 -04:00
Jeff Mitchell 22f3a337f3 Update kv with existence check 2018-03-21 22:58:11 -04:00
Brian Kassouf 3324d6dd12 Add kv backend (#4181) 2018-03-21 22:56:52 -04:00
Chris Hoffman 695eae6ede
adding azure auth plugin (#4180) 2018-03-21 17:35:31 -04:00
Jeff Mitchell 4b491229ba Update hcl 2018-03-20 16:36:37 -04:00
Jeff Mitchell 396ccd8699 Push up changes to prep for release 2018-03-20 14:10:53 -04:00
Jeff Mitchell 7b58d3b2fa Use public forked big package for encrypted_key_storage file until Go 1.10 2018-03-16 10:30:05 -04:00
Jeff Mitchell 8455e25604 Bump complete. Fixes #4094 2018-03-09 10:43:20 -05:00
Brian Kassouf f226fbbbb9
helper/keysutil: Add a storage implementation that uses policies to encrypt paths (#3989)
* helper/keysutil: Add a policy encrypted path storage

* Add vendored deps

* Fix spelling and paths that start with a /

* Add a key version template to change configure the ciphertext prefix

* Use big.Int for base58 instead of external lib

* Update go requirment to 1.10

* Add a version prefix cache

* Move logic to helper function

* Cache the template parts

* Add a storage prefix to policy

* Add an error if the policy passed in is nil

* Pull in the go1.10 version of the math/big package until we can update
2018-03-08 17:58:50 -08:00
Jeff Mitchell ba40b1bd07 Sync plugins 2018-02-26 12:24:04 -05:00
Jeff Mitchell 177ecc946b Bump pkcs7 library version to fix #4024 2018-02-22 20:11:49 -05:00
Jeff Mitchell 15c3bffcc9 Revert "Switch to a forked copy of pkcs7 to fix aws pkcs7 verification error (#4024)"
This reverts commit f75c7dd15784831aef0bd9fda8a230b0a08556f3.
2018-02-22 20:09:19 -05:00
Jeff Mitchell 67e614bac4
Switch to a forked copy of pkcs7 to fix aws pkcs7 verification error (#4024)
Fixes #4014
2018-02-22 08:49:11 -05:00
Jeff Mitchell fb33782593 Update plugins 2018-02-20 14:15:43 -05:00
Seth Vargo cd930b1173 Add support for Google Cloud Spanner (#3977) 2018-02-14 20:31:20 -05:00
Jeff Mitchell 936eb82604 Update Okta dep.
Fixes #3963
2018-02-14 09:38:46 -05:00
Jeff Mitchell 6f69a40ada Update triton version 2018-02-12 18:27:18 -05:00
Paul Stack 3c683dba92 Adding Manta Storage Backend (#3720)
This PR adds a new Storage Backend for Triton's Object Storage - Manta

```
make testacc TEST=./physical/manta
==> Checking that code complies with gofmt requirements...
==> Checking that build is using go version >= 1.9.1...
go generate
VAULT_ACC=1 go test -tags='vault' ./physical/manta -v  -timeout 45m
=== RUN   TestMantaBackend
--- PASS: TestMantaBackend (61.18s)
PASS
ok  	github.com/hashicorp/vault/physical/manta	61.210s
```

Manta behaves differently to how S3 works - it has no such concepts of Buckets - it is merely a filesystem style object store

Therefore, we have chosen the approach of when writing a secret `foo` it will actually map (on disk) as foo/.vault_value

The reason for this is because if we write the secret `foo/bar` and then try and Delete a key using the name `foo` then Manta
will complain that the folder is not empty because `foo/bar` exists. Therefore, `foo/bar` is written as `foo/bar/.vault_value`

The value of the key is *always* written to a directory tree of the name and put in a `.vault_value` file.
2018-02-12 18:22:41 -05:00
Jeff Mitchell 958afd4019 Bump deps 2018-02-10 19:29:52 -05:00
Jeff Mitchell 3297d3dc92 Update go-plugin 2018-02-06 13:31:13 -05:00
Jeff Mitchell fe6c19d623 Update zookeeper dep
Fixes #3896
2018-02-05 11:22:21 -05:00
Jeff Mitchell 98b479ab58 Bump deps 2018-01-26 18:51:00 -05:00
Jeff Mitchell 063f5a982b Sync plugins 2018-01-26 09:04:48 -05:00
Jeff Mitchell c6f35c3890 Update plugins 2018-01-24 23:24:16 -05:00
Jeff Mitchell 3cea1a4f37 Update go-plugin dep 2018-01-23 18:18:04 -05:00
Calvin Leung Huang 385140ee6b
Version protocol switch (#3833)
* Use version to determine plugin protocol to use

* Remove field from ServeOpts

* Fix missing assignment, handle errors

* contraint -> constraint

* Inject the version string from the vault side

* Fix the version check

* Add grpc support check to database plugins

* Default to use grpc unless missing env var or fail on contraint check

* Add GRPCSupport test

* Add greater than test case

* Add go-version dep
2018-01-23 17:29:26 -05:00
Jeff Mitchell e5e4307713 Add centrify plugin as builtin 2018-01-19 06:03:33 -05:00
Jeff Mitchell ffe3ae9118 Add gcp and kubernetes back now that they're updated 2018-01-19 05:56:34 -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
Jeff Mitchell 85ceb198b8 bump go-plugin 2018-01-18 16:58:03 -05:00
Brian Kassouf 7050c1ca41
gRPC Backend Plugins (#3808)
* Add grpc plugins

* Add grpc plugins

* Translate wrap info to/from proto

* Add nil checks

* Fix nil marshaling errors

* Provide logging through the go-plugin logger

* handle errors in the messages

* Update the TLS config so bidirectional connections work

* Add connectivity checks

* Restart plugin and add timeouts where context is not availible

* Add the response wrap data into the grpc system implementation

* Add leaseoptions to pb.Auth

* Add an error translator

* Add tests for translating the proto objects

* Fix rename of function

* Add tracing to plugins for easier debugging

* Handle plugin crashes with the go-plugin context

* Add test for grpcStorage

* Add tests for backend and system

* Bump go-plugin for GRPCBroker

* Remove RegisterLicense

* Add casing translations for new proto messages

* Use doneCtx in grpcClient

* Use doneCtx in grpcClient

* s/shutdown/shut down/
2018-01-18 13:49:20 -08:00
Jeff Mitchell 3dc9967460 Sync in latest go-plugin 2018-01-17 11:57:24 -05:00
Paweł Słomka b994e83c65 Cleanup of deprecated commands in tests, docs (#3788) 2018-01-15 15:19:28 -05:00
Jeff Mitchell d8009bced1 Merge branch 'master-oss' into sethvargo/cli-magic 2018-01-10 11:15:49 -05:00
Brian Kassouf 64da50c27c
Update plugin deps to include context changes (#3765)
* Update plugin deps to include context changes

* Fix tests
2018-01-08 12:26:13 -08:00
Jeff Mitchell d1803098ae Merge branch 'master-oss' into sethvargo/cli-magic 2018-01-03 14:02:31 -05:00
Jeff Mitchell a14ed7f48d Sync in plugin updates 2017-12-21 08:31:20 -05:00
Jeff Mitchell 77a7c52392
Merge branch 'master' into f-nomad 2017-12-18 12:23:39 -05:00
Jeff Mitchell edab61c204 Pull in new go-cleanhttp to fix data race 2017-12-18 09:40:22 -05:00
Calvin Leung Huang 685b4a27e4 Use cleanhttp.PrintablePathCheckHandler to handle non-printable chara… (#3697) 2017-12-15 20:19:37 -05:00
Jeff Mitchell b478ba8bac
Merge branch 'master' into f-nomad 2017-12-14 16:44:28 -05:00
Jeff Mitchell d70db5df9b
Update go-ldap with our patch for control packets. (#3670)
Fixes #3656
Fixes #3625
Fixes #3402
2017-12-09 10:45:03 -05:00
Nicolas Corrarello a6d3119e3e
Pull master into f-nomad
Signed-off-by: Nicolas Corrarello <nicolas@corrarello.com>
2017-11-29 15:56:37 +00:00
Jeff Mitchell 07dfc1da27 Bump deps 2017-11-07 11:57:05 -05:00
Jeff Mitchell 85ea7363d4 Update gocql dep 2017-11-03 17:30:34 -04:00
Jeff Mitchell dc9d24c69c Update kube stuff 2017-10-27 16:12:14 -04:00
Jeff Mitchell 343d1714c1 Bump deps 2017-10-27 15:06:04 -04:00
Seth Vargo f940fd6a3b
Update vendor 2017-10-24 09:39:34 -04:00
Seth Vargo c77072e093
Update vendor libraries for autocomplete and cli 2017-10-24 09:26:43 -04:00
Vishal Nayak f7ed6732a5 Porting identity store (#3419)
* porting identity to OSS

* changes that glue things together

* add testing bits

* wrapped entity id

* fix mount error

* some more changes to core

* fix storagepacker tests

* fix some more tests

* fix mount tests

* fix http mount tests

* audit changes for identity

* remove upgrade structs on the oss side

* added go-memdb to vendor
2017-10-11 10:21:20 -07:00