diff --git a/.circleci/.gitattributes b/.circleci/.gitattributes
new file mode 100644
index 0000000000..2dd06ee5f7
--- /dev/null
+++ b/.circleci/.gitattributes
@@ -0,0 +1 @@
+config.yml linguist-generated
diff --git a/.circleci/.gitignore b/.circleci/.gitignore
new file mode 100644
index 0000000000..3018b3a681
--- /dev/null
+++ b/.circleci/.gitignore
@@ -0,0 +1 @@
+.tmp/
diff --git a/.circleci/Makefile b/.circleci/Makefile
new file mode 100644
index 0000000000..db2b3d7581
--- /dev/null
+++ b/.circleci/Makefile
@@ -0,0 +1,47 @@
+.PHONY: default
+default: ci-config
+
+.PHONY: check-circleci-installed
+check-circleci-installed:
+ @command -v circleci > /dev/null 2>&1 || { \
+ echo "Please install circleci-cli, see https://circleci.com/docs/2.0/local-cli/#installation"; \
+ exit 1; }
+
+.PHONY: ci-config
+# ci-config is just an alias for config.yml for now
+ci-config: config.yml
+
+CONFIG_SOURCE_DIR := config/
+CONFIG_SOURCE := $(shell find config/) Makefile
+OUT := config.yml
+TMP := .tmp/config.yml.tmp
+CONFIG_21 := .tmp/config.2.1.tmp
+
+# Ensure the .tmp dir exists.
+$(shell [ -d .tmp ] || mkdir .tmp)
+
+define GEN_CONFIG
+ @circleci config pack $(CONFIG_SOURCE_DIR) > $(CONFIG_21)
+ @echo "### Generated by 'make ci-config' do not manually edit this file." > $@
+ @circleci config process $(CONFIG_21) >> $@
+endef
+
+$(OUT): $(CONFIG_SOURCE) check-circleci-installed
+ $(GEN_CONFIG)
+ @echo "$@ updated"
+
+$(TMP): $(CONFIG_SOURCE) check-circleci-installed
+ $(GEN_CONFIG)
+
+.PHONY: config-up-to-date
+config-up-to-date: $(TMP) # Note this must not depend on $(OUT)!
+ @if diff config.yml $<; then \
+ echo "Generated $(OUT) is up to date!"; \
+ else \
+ echo "Generated $(OUT) is out of date, run make ci-config to update."; \
+ exit 1; \
+ fi
+
+.PHONY: ci-verify
+ci-verify: config-up-to-date
+ @circleci config validate config.yml
diff --git a/.circleci/README.md b/.circleci/README.md
new file mode 100644
index 0000000000..ea7ed54a2b
--- /dev/null
+++ b/.circleci/README.md
@@ -0,0 +1,117 @@
+# CircleCI config
+
+This directory contains both the source code (under `./config/`)
+and the generated single-file `config.yml`
+which defines the CircleCI workflows for this project.
+
+The Makefile in this directory generates the `./config.yml`
+in CircleCI 2.0 syntax,
+from the tree rooted at `./config/`,
+which contains files in CircleCI 2.1 syntax.
+CircleCI supports [generating a single config file from many],
+using the `$ circleci config pack` command.
+It also supports [expanding 2.1 syntax to 2.0 syntax]
+using the `$ circleci config process` command.
+
+[generating a single config file from many]: https://circleci.com/docs/2.0/local-cli/#packing-a-config
+[expanding 2.1 syntax to 2.0 syntax]: https://circleci.com/docs/2.0/local-cli/#processing-a-config
+
+## Prerequisites
+
+You will need the [CircleCI CLI tool] installed and working,
+at least version `0.1.5607`.
+
+```
+$ circleci version
+0.1.5607+f705856
+```
+
+NOTE: It is recommended to [download this tool directly from GitHub Releases].
+Do not install it using Homebrew, as this version cannot be easily updated.
+It is also not recommended to pipe curl to bash (which CircleCI recommend) for security reasons!
+
+[CircleCI CLI tool]: https://circleci.com/docs/2.0/local-cli/
+[download this tool directly from GitHub Releases]: https://github.com/CircleCI-Public/circleci-cli/releases
+
+## How to make changes
+
+Before making changes, be sure to understand the layout
+of the `./config/` file tree, as well as circleci 2.1 syntax.
+See the [Syntax and layout] section below.
+
+To update the config, you should edit, add or remove files
+in the `./config/` directory,
+and then run `make ci-config`.
+If that's successful,
+you should then commit every `*.yml` file in the tree rooted in this directory.
+That is: you should commit both the source under `./config/`
+and the generated file `./config.yml` at the same time, in the same commit.
+Do not edit the `./config.yml` file directly, as you will lose your changes
+next time `make ci-config` is run.
+
+[Syntax and layout]: #syntax-and-layout
+
+### Verifying `./config.yml`
+
+To check whether or not the current `./config.yml` is up to date with the source,
+and whether it is valid, run `$ make ci-verify`.
+Note that `$ make ci-verify` should be run in CI,
+as well as by a local git commit hook,
+to ensure we never commit files that are invalid or out of date.
+
+#### Example shell session
+
+```sh
+$ make ci-config
+config.yml updated
+$ git add -A . # The -A makes sure to include deletions/renames etc.
+$ git commit -m "ci: blah blah blah"
+Changes detected in .circleci/, running 'make -C .circleci ci-verify'
+--> Generated config.yml is up to date!
+--> Config file at config.yml is valid.
+```
+
+### Syntax and layout
+
+It is important to understand the layout of the config directory.
+Read the documentation on [packing a config] for a full understanding
+of how multiple YAML files are merged by the circleci CLI tool.
+
+[packing a config]: https://circleci.com/docs/2.0/local-cli/#packing-a-config
+
+Here is an example file tree (with comments added afterwards):
+
+```sh
+$ tree .
+.
+├── Makefile
+├── README.md # This file.
+├── config # The source code for config.yml is rooted here.
+│ ├── @config.yml # Files beginning with @ are treated specially by `circleci config pack`
+│ ├── commands # Subdirectories of config become top-level keys.
+│ │ └── go_test.yml # Filenames (minus .yml) become top-level keys under their parent (in this case "commands").
+│ │ # The contents of go_test.yml therefore are placed at: .commands.go_test:
+│ └── jobs # jobs also becomes a top-level key under config...
+│ ├── build-go-dev.yml # ...and likewise filenames become keys under their parent.
+│ ├── go-mod-download.yml
+│ ├── install-ui-dependencies.yml
+│ ├── test-go-race.yml
+│ ├── test-go.yml
+│ └── test-ui.yml
+└── config.yml # The generated file in 2.0 syntax.
+```
+
+About those `@` files... Preceding a filename with `@`
+indicates to `$ circleci config pack` that the contents of this YAML file
+should be at the top-level, rather than underneath a key named after their filename.
+This naming convention is unfortunate as it breaks autocompletion in bash,
+but there we go.
+
+### Why not just use YAML references?
+
+YAML references only work within a single file,
+this is because `circleci config pack` is not a text-level packer,
+but rather stitches together the structures defined in each YAML
+file according to certain rules.
+Therefore it must parse each file separately,
+and YAML references are handled by the parser.
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 790a973d90..6cceda575f 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -1,228 +1,511 @@
+### Generated by 'make ci-config' do not manually edit this file.
version: 2
-
-references:
- images:
- go: &GOLANG_IMAGE golang:1.12.4-stretch # Pin Go to patch version (ex: 1.2.3)
- node: &NODE_IMAGE node:10-stretch # Pin Node.js to major version (ex: 10)
-
- environment: &ENVIRONMENT
- CIRCLECI_CLI_VERSION: 0.1.5546 # Pin CircleCI CLI to patch version (ex: 1.2.3)
- GO_VERSION: 1.12.4 # Pin Go to patch version (ex: 1.2.3)
- GOTESTSUM_VERSION: 0.3.3 # Pin gotestsum to patch version (ex: 1.2.3)
-
- cache:
- go-sum: &GO_SUM_CACHE_KEY go-sum-v1-{{ checksum "go.sum" }}
- yarn-lock: &YARN_LOCK_CACHE_KEY yarn-lock-v1-{{ checksum "ui/yarn.lock" }}
-
jobs:
install-ui-dependencies:
docker:
- - image: *NODE_IMAGE
+ - image: node:10-stretch
working_directory: /src
steps:
- - checkout
- - restore_cache:
- key: *YARN_LOCK_CACHE_KEY
- - run:
- name: Install UI dependencies
- command: |
- set -eux -o pipefail
-
- cd ui
- yarn install --ignore-optional
- npm rebuild node-sass
- - save_cache:
- key: *YARN_LOCK_CACHE_KEY
- paths:
- - ui/node_modules
+ - checkout
+ - restore_cache:
+ key: yarn-lock-v1-{{ checksum "ui/yarn.lock" }}
+ - run:
+ command: |
+ set -eux -o pipefail
+ cd ui
+ yarn install --ignore-optional
+ npm rebuild node-sass
+ name: Install UI dependencies
+ - save_cache:
+ key: yarn-lock-v1-{{ checksum "ui/yarn.lock" }}
+ paths:
+ - ui/node_modules
go-mod-download:
docker:
- - image: *GOLANG_IMAGE
+ - image: golang:1.12.4-stretch
working_directory: /src
steps:
- - checkout
- - restore_cache:
- key: *GO_SUM_CACHE_KEY
- - run:
- name: Download Go modules
- command: go mod download
- - run:
- name: Verify checksums of Go modules
- command: go mod verify
- - save_cache:
- key: *GO_SUM_CACHE_KEY
- paths:
- - /go/pkg/mod
-
+ - add_ssh_keys:
+ fingerprints:
+ - c6:96:98:82:dc:04:6c:39:dd:ac:83:05:e3:15:1c:98
+ - checkout
+ - restore_cache:
+ key: go-sum-v1-{{ checksum "go.sum" }}
+ - run:
+ command: go mod download
+ name: Download Go modules
+ - run:
+ command: go mod verify
+ name: Verify checksums of Go modules
+ - save_cache:
+ key: go-sum-v1-{{ checksum "go.sum" }}
+ paths:
+ - /go/pkg/mod
build-go-dev:
docker:
- - image: *GOLANG_IMAGE
+ - image: golang:1.12.4-stretch
working_directory: /src
steps:
- - checkout
- - restore_cache:
- key: *GO_SUM_CACHE_KEY
- - run:
- name: Build dev binary
- command: |
- set -eux -o pipefail
+ - checkout
+ - restore_cache:
+ key: go-sum-v1-{{ checksum "go.sum" }}
+ - attach_workspace:
+ at: .
+ - run:
+ command: |
+ set -eux -o pipefail
- # Move dev UI assets to expected location
- rm -rf ./pkg
- mkdir ./pkg
-
- # Build dev binary
- make bootstrap dev
- - persist_to_workspace:
- root: .
- paths:
- - bin
+ # Move dev UI assets to expected location
+ rm -rf ./pkg
+ mkdir ./pkg
+ # Build dev binary
+ make bootstrap dev
+ name: Build dev binary
+ - persist_to_workspace:
+ paths:
+ - bin
+ root: .
test-ui:
docker:
- - image: *NODE_IMAGE
+ - image: node:10-stretch
working_directory: /src
resource_class: medium+
steps:
- - checkout
- - restore_cache:
- key: *YARN_LOCK_CACHE_KEY
- - attach_workspace:
- at: .
- - run:
- name: Test UI
- command: |
- set -eux -o pipefail
+ - checkout
+ - restore_cache:
+ key: yarn-lock-v1-{{ checksum "ui/yarn.lock" }}
+ - attach_workspace:
+ at: .
+ - run:
+ command: |
+ set -eux -o pipefail
- # Install Chrome
- wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub \
- | apt-key add -
- echo "deb http://dl.google.com/linux/chrome/deb/ stable main" \
- | tee /etc/apt/sources.list.d/google-chrome.list
- apt-get update
- apt-get -y install google-chrome-stable
- rm /etc/apt/sources.list.d/google-chrome.list
- rm -rf /var/lib/apt/lists/* /var/cache/apt/*
+ # Install Chrome
+ wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub \
+ | apt-key add -
+ echo "deb http://dl.google.com/linux/chrome/deb/ stable main" \
+ | tee /etc/apt/sources.list.d/google-chrome.list
+ apt-get update
+ apt-get -y install google-chrome-stable
+ rm /etc/apt/sources.list.d/google-chrome.list
+ rm -rf /var/lib/apt/lists/* /var/cache/apt/*
- # Add ./bin to the PATH so vault binary can be run by Ember tests
- export PATH="${PWD}"/bin:${PATH}
-
- # Run Ember tests
- cd ui
- mkdir -p test-results/qunit
- yarn run test-oss
- - store_artifacts:
- path: ui/test-results
- - store_test_results:
- path: ui/test-results
-
- test-ui-browserstack:
- docker:
- - image: *NODE_IMAGE
- steps:
- - checkout
- - restore_cache:
- key: *YARN_LOCK_CACHE_KEY
- - attach_workspace:
- at: .
- - run:
- name: Run BrowserStack tests
- command: |
- set -eux -o pipefail
-
- # Add ./bin to the PATH so vault binary can be run by Ember tests
- export PATH="${PWD}"/bin:${PATH}
-
- make test-ui-browserstack
+ # Add ./bin to the PATH so vault binary can be run by Ember tests
+ export PATH="${PWD}/bin:${PATH}"
+ # Run Ember tests
+ cd ui
+ mkdir -p test-results/qunit
+ yarn run test-oss
+ name: Test UI
+ - store_artifacts:
+ path: ui/test-results
+ - store_test_results:
+ path: ui/test-results
test-go:
machine: true
- environment:
- <<: *ENVIRONMENT
- GO_TAGS:
+ working_directory: ~/src
parallelism: 2
+ steps:
+ - checkout
+ - run:
+ command: |
+ set -eux -o pipefail
+
+ sudo mkdir /go
+ sudo chown -R circleci:circleci /go
+ name: Allow circleci user to restore Go modules cache
+ - restore_cache:
+ key: go-sum-v1-{{ checksum "go.sum" }}
+ - run:
+ command: |
+ set -eux -o pipefail
+
+ # Install Go
+ curl -sSLO "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz"
+ sudo rm -rf /usr/local/go
+ sudo tar -C /usr/local -xzf "go${GO_VERSION}.linux-amd64.tar.gz"
+ rm -f "go${GO_VERSION}.linux-amd64.tar.gz"
+ export GOPATH=/go
+ export PATH="${PATH}:${GOPATH}/bin:/usr/local/go/bin"
+
+ # Install CircleCI CLI
+ curl -sSL \
+ "https://github.com/CircleCI-Public/circleci-cli/releases/download/v${CIRCLECI_CLI_VERSION}/circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz \
+ -C /usr/local/bin \
+ "circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64/circleci"
+
+ # Split Go tests by prior test times
+ package_names=$(go list \
+ -tags "${GO_TAGS}" \
+ ./... \
+ | grep -v /integ \
+ | grep -v /vendor/ \
+ | sort \
+ | circleci tests split --split-by=timings --timings-type=classname)
+
+ # Install gotestsum
+ curl -sSL "https://github.com/gotestyourself/gotestsum/releases/download/v${GOTESTSUM_VERSION}/gotestsum_${GOTESTSUM_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz -C /usr/local/bin gotestsum
+
+ # Run tests
+ make prep
+ mkdir -p test-results/go-test
+ CGO_ENABLED= \
+ VAULT_ADDR= \
+ VAULT_TOKEN= \
+ VAULT_DEV_ROOT_TOKEN_ID= \
+ VAULT_ACC= \
+ gotestsum --format=short-verbose --junitfile test-results/go-test/results.xml -- \
+ -tags "${GO_TAGS}" \
+ -timeout=40m \
+ -parallel=20 \
+ \
+ ${package_names}
+ name: Run Go tests
+ no_output_timeout: 20m
+ - store_artifacts:
+ path: test-results
+ - store_test_results:
+ path: test-results
+ environment:
+ - CIRCLECI_CLI_VERSION: 0.1.5546
+ - GO_TAGS: null
+ - GO_VERSION: 1.12.4
+ - GOTESTSUM_VERSION: 0.3.3
+ test-go-race:
+ machine: true
working_directory: ~/src
steps:
- - checkout
- - run:
- name: Allow circleci user to restore Go modules cache
- command: |
- set -eux -o pipefail
+ - checkout
+ - run:
+ command: |
+ set -eux -o pipefail
- sudo mkdir /go
- sudo chown -R circleci:circleci /go
- - restore_cache:
- key: *GO_SUM_CACHE_KEY
- - run:
- name: Run Go tests
- no_output_timeout: 20m
- command: |
- set -eux -o pipefail
+ sudo mkdir /go
+ sudo chown -R circleci:circleci /go
+ name: Allow circleci user to restore Go modules cache
+ - restore_cache:
+ key: go-sum-v1-{{ checksum "go.sum" }}
+ - run:
+ command: |
+ set -eux -o pipefail
- # Install Go
- curl -sSLO "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz"
- sudo rm -rf /usr/local/go
- sudo tar -C /usr/local -xzf "go${GO_VERSION}.linux-amd64.tar.gz"
- rm -f "go${GO_VERSION}.linux-amd64.tar.gz"
- export GOPATH=/go
- export PATH="${PATH}:${GOPATH}/bin:/usr/local/go/bin"
+ # Install Go
+ curl -sSLO "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz"
+ sudo rm -rf /usr/local/go
+ sudo tar -C /usr/local -xzf "go${GO_VERSION}.linux-amd64.tar.gz"
+ rm -f "go${GO_VERSION}.linux-amd64.tar.gz"
+ export GOPATH=/go
+ export PATH="${PATH}:${GOPATH}/bin:/usr/local/go/bin"
- # Install CircleCI CLI
- curl -sSL \
- "https://github.com/CircleCI-Public/circleci-cli/releases/download/v${CIRCLECI_CLI_VERSION}/circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64.tar.gz" \
- | sudo tar --overwrite -xz \
- -C /usr/local/bin \
- "circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64/circleci"
+ # Install CircleCI CLI
+ curl -sSL \
+ "https://github.com/CircleCI-Public/circleci-cli/releases/download/v${CIRCLECI_CLI_VERSION}/circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz \
+ -C /usr/local/bin \
+ "circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64/circleci"
- # Split Go tests by prior test times
- package_names=$(go list \
- -tags "${GO_TAGS}" \
- ./... \
- | grep -v /vendor/ \
- | sort \
- | circleci tests split --split-by=timings --timings-type=classname)
+ # Split Go tests by prior test times
+ package_names=$(go list \
+ -tags "${GO_TAGS}" \
+ ./... \
+ | grep -v /integ \
+ | grep -v /vendor/ \
+ | sort \
+ | circleci tests split --split-by=timings --timings-type=classname)
- # Install gotestsum
- curl -sSL "https://github.com/gotestyourself/gotestsum/releases/download/v${GOTESTSUM_VERSION}/gotestsum_${GOTESTSUM_VERSION}_linux_amd64.tar.gz" \
- | sudo tar --overwrite -xz -C /usr/local/bin gotestsum
-
- # Run tests
- make prep
- mkdir -p test-results/go-test
- CGO_ENABLED= \
- VAULT_ADDR= \
- VAULT_TOKEN= \
- VAULT_DEV_ROOT_TOKEN_ID= \
- VAULT_ACC= \
- gotestsum --format=short-verbose --junitfile test-results/go-test/results.xml -- \
- -tags "${GO_TAGS}" \
- -timeout=40m \
- -parallel=20 \
- ${package_names}
- - store_artifacts:
- path: test-results
- - store_test_results:
- path: test-results
+ # Install gotestsum
+ curl -sSL "https://github.com/gotestyourself/gotestsum/releases/download/v${GOTESTSUM_VERSION}/gotestsum_${GOTESTSUM_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz -C /usr/local/bin gotestsum
+ # Run tests
+ make prep
+ mkdir -p test-results/go-test
+ CGO_ENABLED= \
+ VAULT_ADDR= \
+ VAULT_TOKEN= \
+ VAULT_DEV_ROOT_TOKEN_ID= \
+ VAULT_ACC= \
+ gotestsum --format=short-verbose --junitfile test-results/go-test/results.xml -- \
+ -tags "${GO_TAGS}" \
+ -timeout=40m \
+ -parallel=20 \
+ -race \
+ ${package_names}
+ name: Run Go tests
+ no_output_timeout: 20m
+ - store_artifacts:
+ path: test-results
+ - store_test_results:
+ path: test-results
+ environment:
+ - CIRCLECI_CLI_VERSION: 0.1.5546
+ - GO_TAGS: null
+ - GO_VERSION: 1.12.4
+ - GOTESTSUM_VERSION: 0.3.3
workflows:
- version: 2
-
ci:
jobs:
- - install-ui-dependencies
- - go-mod-download
- - build-go-dev:
- requires:
- - go-mod-download
- - test-ui:
- requires:
- - install-ui-dependencies
- - build-go-dev
- - test-go:
- requires:
- - build-go-dev
- - test-ui-browserstack:
- requires:
- - install-ui-dependencies
- - build-go-dev
+ - install-ui-dependencies
+ - go-mod-download
+ - build-go-dev:
+ requires:
+ - go-mod-download
+ - test-ui:
+ requires:
+ - install-ui-dependencies
+ - build-go-dev
+ - test-go:
+ requires:
+ - build-go-dev
+ - test-go-race:
+ requires:
+ - build-go-dev
+ version: 2
+
+# Original config.yml file:
+# commands:
+# go_test:
+# description: run go tests
+# parameters:
+# extra_flags:
+# default: \"\"
+# type: string
+# steps:
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# # Install Go
+# curl -sSLO \"https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz\"
+# sudo rm -rf /usr/local/go
+# sudo tar -C /usr/local -xzf \"go${GO_VERSION}.linux-amd64.tar.gz\"
+# rm -f \"go${GO_VERSION}.linux-amd64.tar.gz\"
+# export GOPATH=/go
+# export PATH=\"${PATH}:${GOPATH}/bin:/usr/local/go/bin\"
+#
+# # Install CircleCI CLI
+# curl -sSL \\
+# \"https://github.com/CircleCI-Public/circleci-cli/releases/download/v${CIRCLECI_CLI_VERSION}/circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64.tar.gz\" \\
+# | sudo tar --overwrite -xz \\
+# -C /usr/local/bin \\
+# \"circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64/circleci\"
+#
+# # Split Go tests by prior test times
+# package_names=$(go list \\
+# -tags \"${GO_TAGS}\" \\
+# ./... \\
+# | grep -v /integ \\
+# | grep -v /vendor/ \\
+# | sort \\
+# | circleci tests split --split-by=timings --timings-type=classname)
+#
+# # Install gotestsum
+# curl -sSL \"https://github.com/gotestyourself/gotestsum/releases/download/v${GOTESTSUM_VERSION}/gotestsum_${GOTESTSUM_VERSION}_linux_amd64.tar.gz\" \\
+# | sudo tar --overwrite -xz -C /usr/local/bin gotestsum
+#
+# # Run tests
+# make prep
+# mkdir -p test-results/go-test
+# CGO_ENABLED= \\
+# VAULT_ADDR= \\
+# VAULT_TOKEN= \\
+# VAULT_DEV_ROOT_TOKEN_ID= \\
+# VAULT_ACC= \\
+# gotestsum --format=short-verbose --junitfile test-results/go-test/results.xml -- \\
+# -tags \"${GO_TAGS}\" \\
+# -timeout=40m \\
+# -parallel=20 \\
+# << parameters.extra_flags >> \\
+# ${package_names}
+# name: Run Go tests
+# no_output_timeout: 20m
+# restore_go_cache:
+# steps:
+# - restore_cache:
+# key: go-sum-v1-{{ checksum \"go.sum\" }}
+# restore_yarn_cache:
+# steps:
+# - restore_cache:
+# key: yarn-lock-v1-{{ checksum \"ui/yarn.lock\" }}
+# save_go_cache:
+# steps:
+# - save_cache:
+# key: go-sum-v1-{{ checksum \"go.sum\" }}
+# paths:
+# - /go/pkg/mod
+# save_yarn_cache:
+# steps:
+# - save_cache:
+# key: yarn-lock-v1-{{ checksum \"ui/yarn.lock\" }}
+# paths:
+# - ui/node_modules
+# executors:
+# go:
+# docker:
+# - image: golang:1.12.4-stretch
+# working_directory: /src
+# go-machine:
+# environment:
+# CIRCLECI_CLI_VERSION: 0.1.5546
+# GO_TAGS: null
+# GO_VERSION: 1.12.4
+# GOTESTSUM_VERSION: 0.3.3
+# machine: true
+# working_directory: ~/src
+# node:
+# docker:
+# - image: node:10-stretch
+# working_directory: /src
+# jobs:
+# build-go-dev:
+# executor: go
+# steps:
+# - checkout
+# - restore_go_cache
+# - attach_workspace:
+# at: .
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# # Move dev UI assets to expected location
+# rm -rf ./pkg
+# mkdir ./pkg
+#
+# # Build dev binary
+# make bootstrap dev
+# name: Build dev binary
+# - persist_to_workspace:
+# paths:
+# - bin
+# root: .
+# go-mod-download:
+# executor: go
+# steps:
+# - add_ssh_keys:
+# fingerprints:
+# - c6:96:98:82:dc:04:6c:39:dd:ac:83:05:e3:15:1c:98
+# - checkout
+# - restore_go_cache
+# - run:
+# command: go mod download
+# name: Download Go modules
+# - run:
+# command: go mod verify
+# name: Verify checksums of Go modules
+# - save_go_cache
+# install-ui-dependencies:
+# executor: node
+# steps:
+# - checkout
+# - restore_yarn_cache
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# cd ui
+# yarn install --ignore-optional
+# npm rebuild node-sass
+# name: Install UI dependencies
+# - save_yarn_cache
+# test-go:
+# executor: go-machine
+# parallelism: 2
+# steps:
+# - checkout
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# sudo mkdir /go
+# sudo chown -R circleci:circleci /go
+# name: Allow circleci user to restore Go modules cache
+# - restore_go_cache
+# - go_test
+# - store_artifacts:
+# path: test-results
+# - store_test_results:
+# path: test-results
+# test-go-race:
+# executor: go-machine
+# steps:
+# - checkout
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# sudo mkdir /go
+# sudo chown -R circleci:circleci /go
+# name: Allow circleci user to restore Go modules cache
+# - restore_go_cache
+# - go_test:
+# extra_flags: -race
+# - store_artifacts:
+# path: test-results
+# - store_test_results:
+# path: test-results
+# test-ui:
+# executor: node
+# resource_class: medium+
+# steps:
+# - checkout
+# - restore_yarn_cache
+# - attach_workspace:
+# at: .
+# - run:
+# command: |
+# set -eux -o pipefail
+#
+# # Install Chrome
+# wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub \\
+# | apt-key add -
+# echo \"deb http://dl.google.com/linux/chrome/deb/ stable main\" \\
+# | tee /etc/apt/sources.list.d/google-chrome.list
+# apt-get update
+# apt-get -y install google-chrome-stable
+# rm /etc/apt/sources.list.d/google-chrome.list
+# rm -rf /var/lib/apt/lists/* /var/cache/apt/*
+#
+# # Add ./bin to the PATH so vault binary can be run by Ember tests
+# export PATH=\"${PWD}/bin:${PATH}\"
+#
+# # Run Ember tests
+# cd ui
+# mkdir -p test-results/qunit
+# yarn run test-oss
+# name: Test UI
+# - store_artifacts:
+# path: ui/test-results
+# - store_test_results:
+# path: ui/test-results
+# references:
+# cache:
+# go-sum: go-sum-v1-{{ checksum \"go.sum\" }}
+# yarn-lock: yarn-lock-v1-{{ checksum \"ui/yarn.lock\" }}
+# images:
+# go: golang:1.12.4-stretch
+# node: node:10-stretch
+# version: 2.1
+# workflows:
+# ci:
+# jobs:
+# - install-ui-dependencies
+# - go-mod-download
+# - build-go-dev:
+# requires:
+# - go-mod-download
+# - test-ui:
+# requires:
+# - install-ui-dependencies
+# - build-go-dev
+# - test-go:
+# requires:
+# - build-go-dev
+# - test-go-race:
+# requires:
+# - build-go-dev
\ No newline at end of file
diff --git a/.circleci/config/@config.yml b/.circleci/config/@config.yml
new file mode 100644
index 0000000000..c4ef96b68b
--- /dev/null
+++ b/.circleci/config/@config.yml
@@ -0,0 +1,53 @@
+---
+version: 2.1
+
+references:
+ images:
+ go: &GOLANG_IMAGE golang:1.12.4-stretch # Pin Go to patch version (ex: 1.2.3)
+ node: &NODE_IMAGE node:10-stretch # Pin Node.js to major version (ex: 10)
+
+ cache:
+ go-sum: &GO_SUM_CACHE_KEY go-sum-v1-{{ checksum "go.sum" }}
+ yarn-lock: &YARN_LOCK_CACHE_KEY yarn-lock-v1-{{ checksum "ui/yarn.lock" }}
+
+# more commands defined in commands/
+commands:
+ restore_yarn_cache:
+ steps:
+ - restore_cache:
+ key: *YARN_LOCK_CACHE_KEY
+ save_yarn_cache:
+ steps:
+ - save_cache:
+ key: *YARN_LOCK_CACHE_KEY
+ paths:
+ - ui/node_modules
+ restore_go_cache:
+ steps:
+ - restore_cache:
+ key: *GO_SUM_CACHE_KEY
+ save_go_cache:
+ steps:
+ - save_cache:
+ key: *GO_SUM_CACHE_KEY
+ paths:
+ - /go/pkg/mod
+
+executors:
+ go:
+ docker:
+ - image: *GOLANG_IMAGE
+ working_directory: /src
+ go-machine:
+ machine: true
+ environment:
+ CIRCLECI_CLI_VERSION: 0.1.5546 # Pin CircleCI CLI to patch version (ex: 1.2.3)
+ GO_VERSION: 1.12.4 # Pin Go to patch version (ex: 1.2.3)
+ GOTESTSUM_VERSION: 0.3.3 # Pin gotestsum to patch version (ex: 1.2.3)
+ GO_TAGS:
+ working_directory: ~/src
+ node:
+ docker:
+ - image: *NODE_IMAGE
+ working_directory: /src
+
diff --git a/.circleci/config/commands/go_test.yml b/.circleci/config/commands/go_test.yml
new file mode 100644
index 0000000000..bfae0c3d69
--- /dev/null
+++ b/.circleci/config/commands/go_test.yml
@@ -0,0 +1,55 @@
+description: run go tests
+parameters:
+ extra_flags:
+ type: string
+ default: ""
+steps:
+ - run:
+ name: Run Go tests
+ no_output_timeout: 20m
+ command: |
+ set -eux -o pipefail
+
+ # Install Go
+ curl -sSLO "https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz"
+ sudo rm -rf /usr/local/go
+ sudo tar -C /usr/local -xzf "go${GO_VERSION}.linux-amd64.tar.gz"
+ rm -f "go${GO_VERSION}.linux-amd64.tar.gz"
+ export GOPATH=/go
+ export PATH="${PATH}:${GOPATH}/bin:/usr/local/go/bin"
+
+ # Install CircleCI CLI
+ curl -sSL \
+ "https://github.com/CircleCI-Public/circleci-cli/releases/download/v${CIRCLECI_CLI_VERSION}/circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz \
+ -C /usr/local/bin \
+ "circleci-cli_${CIRCLECI_CLI_VERSION}_linux_amd64/circleci"
+
+ # Split Go tests by prior test times
+ package_names=$(go list \
+ -tags "${GO_TAGS}" \
+ ./... \
+ | grep -v /integ \
+ | grep -v /vendor/ \
+ | sort \
+ | circleci tests split --split-by=timings --timings-type=classname)
+
+ # Install gotestsum
+ curl -sSL "https://github.com/gotestyourself/gotestsum/releases/download/v${GOTESTSUM_VERSION}/gotestsum_${GOTESTSUM_VERSION}_linux_amd64.tar.gz" \
+ | sudo tar --overwrite -xz -C /usr/local/bin gotestsum
+
+ # Run tests
+ make prep
+ mkdir -p test-results/go-test
+ CGO_ENABLED= \
+ VAULT_ADDR= \
+ VAULT_TOKEN= \
+ VAULT_DEV_ROOT_TOKEN_ID= \
+ VAULT_ACC= \
+ gotestsum --format=short-verbose --junitfile test-results/go-test/results.xml -- \
+ -tags "${GO_TAGS}" \
+ -timeout=40m \
+ -parallel=20 \
+ << parameters.extra_flags >> \
+ ${package_names}
+
diff --git a/.circleci/config/jobs/build-go-dev.yml b/.circleci/config/jobs/build-go-dev.yml
new file mode 100644
index 0000000000..59729bc698
--- /dev/null
+++ b/.circleci/config/jobs/build-go-dev.yml
@@ -0,0 +1,21 @@
+executor: go
+steps:
+ - checkout
+ - restore_go_cache
+ - attach_workspace:
+ at: .
+ - run:
+ name: Build dev binary
+ command: |
+ set -eux -o pipefail
+
+ # Move dev UI assets to expected location
+ rm -rf ./pkg
+ mkdir ./pkg
+
+ # Build dev binary
+ make bootstrap dev
+ - persist_to_workspace:
+ root: .
+ paths:
+ - bin
diff --git a/.circleci/config/jobs/go-mod-download.yml b/.circleci/config/jobs/go-mod-download.yml
new file mode 100644
index 0000000000..adfaf0ad80
--- /dev/null
+++ b/.circleci/config/jobs/go-mod-download.yml
@@ -0,0 +1,15 @@
+executor: go
+steps:
+ - add_ssh_keys:
+ fingerprints:
+ # "CircleCI SSH Checkout" SSH key associated with hashicorp-ci GitHub user
+ - "c6:96:98:82:dc:04:6c:39:dd:ac:83:05:e3:15:1c:98"
+ - checkout
+ - restore_go_cache
+ - run:
+ name: Download Go modules
+ command: go mod download
+ - run:
+ name: Verify checksums of Go modules
+ command: go mod verify
+ - save_go_cache
diff --git a/.circleci/config/jobs/install-ui-dependencies.yml b/.circleci/config/jobs/install-ui-dependencies.yml
new file mode 100644
index 0000000000..2b04e176bb
--- /dev/null
+++ b/.circleci/config/jobs/install-ui-dependencies.yml
@@ -0,0 +1,13 @@
+executor: node
+steps:
+ - checkout
+ - restore_yarn_cache
+ - run:
+ name: Install UI dependencies
+ command: |
+ set -eux -o pipefail
+
+ cd ui
+ yarn install --ignore-optional
+ npm rebuild node-sass
+ - save_yarn_cache
diff --git a/.circleci/config/jobs/test-go-race.yml b/.circleci/config/jobs/test-go-race.yml
new file mode 100644
index 0000000000..df16fc6164
--- /dev/null
+++ b/.circleci/config/jobs/test-go-race.yml
@@ -0,0 +1,17 @@
+executor: go-machine
+steps:
+ - checkout
+ - run:
+ name: Allow circleci user to restore Go modules cache
+ command: |
+ set -eux -o pipefail
+
+ sudo mkdir /go
+ sudo chown -R circleci:circleci /go
+ - restore_go_cache
+ - go_test:
+ extra_flags: "-race"
+ - store_artifacts:
+ path: test-results
+ - store_test_results:
+ path: test-results
diff --git a/.circleci/config/jobs/test-go.yml b/.circleci/config/jobs/test-go.yml
new file mode 100644
index 0000000000..031f7bc249
--- /dev/null
+++ b/.circleci/config/jobs/test-go.yml
@@ -0,0 +1,17 @@
+executor: go-machine
+parallelism: 2
+steps:
+ - checkout
+ - run:
+ name: Allow circleci user to restore Go modules cache
+ command: |
+ set -eux -o pipefail
+
+ sudo mkdir /go
+ sudo chown -R circleci:circleci /go
+ - restore_go_cache
+ - go_test
+ - store_artifacts:
+ path: test-results
+ - store_test_results:
+ path: test-results
diff --git a/.circleci/config/jobs/test-ui.yml b/.circleci/config/jobs/test-ui.yml
new file mode 100644
index 0000000000..813f800d20
--- /dev/null
+++ b/.circleci/config/jobs/test-ui.yml
@@ -0,0 +1,33 @@
+executor: node
+resource_class: medium+
+steps:
+ - checkout
+ - restore_yarn_cache
+ - attach_workspace:
+ at: .
+ - run:
+ name: Test UI
+ command: |
+ set -eux -o pipefail
+
+ # Install Chrome
+ wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub \
+ | apt-key add -
+ echo "deb http://dl.google.com/linux/chrome/deb/ stable main" \
+ | tee /etc/apt/sources.list.d/google-chrome.list
+ apt-get update
+ apt-get -y install google-chrome-stable
+ rm /etc/apt/sources.list.d/google-chrome.list
+ rm -rf /var/lib/apt/lists/* /var/cache/apt/*
+
+ # Add ./bin to the PATH so vault binary can be run by Ember tests
+ export PATH="${PWD}/bin:${PATH}"
+
+ # Run Ember tests
+ cd ui
+ mkdir -p test-results/qunit
+ yarn run test-oss
+ - store_artifacts:
+ path: ui/test-results
+ - store_test_results:
+ path: ui/test-results
diff --git a/.circleci/config/workflows/ci.yml b/.circleci/config/workflows/ci.yml
new file mode 100644
index 0000000000..dda98aea45
--- /dev/null
+++ b/.circleci/config/workflows/ci.yml
@@ -0,0 +1,16 @@
+jobs:
+ - install-ui-dependencies
+ - go-mod-download
+ - build-go-dev:
+ requires:
+ - go-mod-download
+ - test-ui:
+ requires:
+ - install-ui-dependencies
+ - build-go-dev
+ - test-go:
+ requires:
+ - build-go-dev
+ - test-go-race:
+ requires:
+ - build-go-dev
diff --git a/.hooks/pre-commit b/.hooks/pre-commit
new file mode 100755
index 0000000000..fd2533885f
--- /dev/null
+++ b/.hooks/pre-commit
@@ -0,0 +1,104 @@
+#!/usr/bin/env bash
+
+# READ THIS BEFORE MAKING CHANGES:
+#
+# If you want to add a new pre-commit check, here are the rules:
+#
+# 1. Create a bash function for your check (see e.g. ui_lint below).
+# NOTE: Each function will be called in a sub-shell so you can freely
+# change directory without worrying about interference.
+# 2. Add the name of the function to the CHECKS variable.
+# 3. If no changes relevant to your new check are staged, then
+# do not output anything at all - this would be annoying noise.
+# In this case, call 'return 0' from your check function to return
+# early without blocking the commit.
+# 4. If any non-trivial check-specific thing has to be invoked,
+# then output '==> [check description]' as the first line of
+# output. Each sub-check should output '--> [subcheck description]'
+# after it has run, indicating success or failure.
+# 5. Call 'block [reason]' to block the commit. This ensures the last
+# line of output calls out that the commit was blocked - which may not
+# be obvious from random error messages generated in 4.
+#
+# At the moment, there are no automated tests for this hook, so please run it
+# locally to check you have not broken anything - breaking this will interfere
+# with other peoples' workflows significantly, so be sure, check everything twice.
+
+set -euo pipefail
+
+# Call block to block the commit with a message.
+block() {
+ echo "$@"
+ echo "Commit blocked - see errors above."
+ exit 1
+}
+
+# Add all check functions to this space separated list.
+# They are executed in this order (see end of file).
+CHECKS="ui_lint circleci_verify"
+
+# Run ui linter if changes in that dir detected.
+ui_lint() {
+ local DIR=ui LINTER=node_modules/.bin/lint-staged
+
+ # Silently succeed if no changes staged for $DIR
+ if git diff --name-only --cached --exit-code -- $DIR/; then
+ return 0
+ fi
+
+ # Silently succeed if the linter has not been installed.
+ # We assume that if you're doing UI dev, you will have installed the linter
+ # by running yarn.
+ if [ ! -x $DIR/$LINTER ]; then
+ return 0
+ fi
+
+ echo "==> Changes detected in $DIR/: Running linter..."
+
+ # Run the linter from the UI dir.
+ cd $DIR
+ $LINTER || block "UI lint failed"
+}
+
+# Check .circleci/config.yml is up to date and valid, and that all changes are
+# included together in this commit.
+circleci_verify() {
+ # Change to the root dir of the repo.
+ cd "$(git rev-parse --show-toplevel)"
+
+ # Fail early if we accidentally used '.yaml' instead of '.yml'
+ if ! git diff --name-only --cached --exit-code -- '.circleci/***.yaml'; then
+ # This is just for consistency, as I keep making this mistake - Sam.
+ block "ERROR: File(s) with .yaml extension detected. Please rename them .yml instead."
+ fi
+
+ # Succeed early if no changes to yml files in .circleci/ are currently staged.
+ # make ci-verify is slow so we really don't want to run it unnecessarily.
+ if git diff --name-only --cached --exit-code -- '.circleci/***.yml'; then
+ return 0
+ fi
+ # Make sure to add no explicit output before this line, as it would just be noise
+ # for those making non-circleci changes.
+ echo "==> Verifying config changes in .circleci/"
+ echo "--> OK: All files are .yml not .yaml"
+
+ # Ensure commit includes _all_ files in .circleci/
+ # So not only are the files up to date, but we are also committing them in one go.
+ if ! git diff --name-only --exit-code -- '.circleci/***.yml'; then
+ echo "ERROR: Some .yml diffs in .circleci/ are staged, others not."
+ block "Please commit the entire .circleci/ directory together, or omit it altogether."
+ fi
+
+ echo "--> OK: All .yml files in .circleci are staged."
+
+ if ! make -C .circleci ci-verify; then
+ block "ERROR: make ci-verify failed"
+ fi
+
+ echo "--> OK: make ci-verify succeeded."
+}
+
+for CHECK in $CHECKS; do
+ # Force each check into a subshell to avoid crosstalk.
+ ( $CHECK ) || exit $?
+done
diff --git a/CHANGELOG.md b/CHANGELOG.md
index db986e1852..4a59827128 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,13 @@
CHANGES:
+ * auth/token: Token store roles use new, common token fields for the values
+ that overlap with other auth backends. `period`, `explicit_max_ttl`, and
+ `bound_cidrs` will continue to work, with priority being given to the
+ `token_` prefixed versions of those parameters. They will also be returned
+ when doing a read on the role if they were used to provide values initially;
+ however, in Vault 1.4 if `period` or `explicit_max_ttl` is zero they will no
+ longer be returned. (`explicit_max_ttl` was already not returned if empty.)
* Due to underlying changes in Go version 1.12 and Go > 1.11.5, Vault is now
stricter about what characters it will accept in path names. Whereas before
it would filter out unprintable characters (and this could be turned off),
@@ -50,6 +57,9 @@ IMPROVEMENTS:
BUG FIXES:
+ * identity: Fix a case where modifying aliases of an entity could end up
+ moving the entity into the wrong namespace
+
## 1.1.3 (June 5th, 2019)
IMPROVEMENTS:
diff --git a/Makefile b/Makefile
index 6869df88c0..c2c413547c 100644
--- a/Makefile
+++ b/Makefile
@@ -102,8 +102,15 @@ vet:
prep: fmtcheck
@sh -c "'$(CURDIR)/scripts/goversioncheck.sh' '$(GO_VERSION_MIN)'"
@go generate $(go list ./... | grep -v /vendor/)
+ @# Remove old (now broken) husky git hooks.
+ @[ ! -d .git/hooks ] || grep -l '^# husky$$' .git/hooks/* | xargs rm -f
@if [ -d .git/hooks ]; then cp .hooks/* .git/hooks/; fi
+ci-config:
+ @$(MAKE) -C .circleci
+ci-verify:
+ @$(MAKE) -C .circleci ci-verify
+
# bootstrap the build by downloading additional tools
bootstrap:
@for tool in $(EXTERNAL_TOOLS) ; do \
diff --git a/api/go.mod b/api/go.mod
index 6f8d42cb2e..0c3d7cf9b0 100644
--- a/api/go.mod
+++ b/api/go.mod
@@ -11,7 +11,7 @@ require (
github.com/hashicorp/go-retryablehttp v0.5.3
github.com/hashicorp/go-rootcerts v1.0.0
github.com/hashicorp/hcl v1.0.0
- github.com/hashicorp/vault/sdk v0.1.8
+ github.com/hashicorp/vault/sdk v0.1.12-0.20190614165924-47d4e5b1f688
github.com/mitchellh/mapstructure v1.1.2
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
diff --git a/api/sys_rekey.go b/api/sys_rekey.go
index 55f1a703d4..153e486c6d 100644
--- a/api/sys_rekey.go
+++ b/api/sys_rekey.go
@@ -234,7 +234,7 @@ func (c *Sys) RekeyRetrieveBackup() (*RekeyRetrieveResponse, error) {
}
func (c *Sys) RekeyRetrieveRecoveryBackup() (*RekeyRetrieveResponse, error) {
- r := c.c.NewRequest("GET", "/v1/sys/rekey/recovery-backup")
+ r := c.c.NewRequest("GET", "/v1/sys/rekey/recovery-key-backup")
ctx, cancelFunc := context.WithCancel(context.Background())
defer cancelFunc()
@@ -275,7 +275,7 @@ func (c *Sys) RekeyDeleteBackup() error {
}
func (c *Sys) RekeyDeleteRecoveryBackup() error {
- r := c.c.NewRequest("DELETE", "/v1/sys/rekey/recovery-backup")
+ r := c.c.NewRequest("DELETE", "/v1/sys/rekey/recovery-key-backup")
ctx, cancelFunc := context.WithCancel(context.Background())
defer cancelFunc()
diff --git a/audit/format.go b/audit/format.go
index c5f57ff0d6..1c0ddb3fb9 100644
--- a/audit/format.go
+++ b/audit/format.go
@@ -153,6 +153,7 @@ func (f *AuditFormatter) FormatRequest(ctx context.Context, w io.Writer, config
TokenPolicies: auth.TokenPolicies,
IdentityPolicies: auth.IdentityPolicies,
ExternalNamespacePolicies: auth.ExternalNamespacePolicies,
+ NoDefaultPolicy: auth.NoDefaultPolicy,
Metadata: auth.Metadata,
EntityID: auth.EntityID,
RemainingUses: req.ClientTokenRemainingUses,
@@ -352,6 +353,7 @@ func (f *AuditFormatter) FormatResponse(ctx context.Context, w io.Writer, config
TokenPolicies: resp.Auth.TokenPolicies,
IdentityPolicies: resp.Auth.IdentityPolicies,
ExternalNamespacePolicies: resp.Auth.ExternalNamespacePolicies,
+ NoDefaultPolicy: resp.Auth.NoDefaultPolicy,
Metadata: resp.Auth.Metadata,
NumUses: resp.Auth.NumUses,
EntityID: resp.Auth.EntityID,
@@ -397,6 +399,7 @@ func (f *AuditFormatter) FormatResponse(ctx context.Context, w io.Writer, config
TokenPolicies: auth.TokenPolicies,
IdentityPolicies: auth.IdentityPolicies,
ExternalNamespacePolicies: auth.ExternalNamespacePolicies,
+ NoDefaultPolicy: auth.NoDefaultPolicy,
Metadata: auth.Metadata,
RemainingUses: req.ClientTokenRemainingUses,
EntityID: auth.EntityID,
@@ -496,6 +499,7 @@ type AuditAuth struct {
TokenPolicies []string `json:"token_policies,omitempty"`
IdentityPolicies []string `json:"identity_policies,omitempty"`
ExternalNamespacePolicies map[string][]string `json:"external_namespace_policies,omitempty"`
+ NoDefaultPolicy bool `json:"no_default_policy,omitempty"`
Metadata map[string]string `json:"metadata,omitempty"`
NumUses int `json:"num_uses,omitempty"`
RemainingUses int `json:"remaining_uses,omitempty"`
diff --git a/audit/format_json_test.go b/audit/format_json_test.go
index a937eb342b..a1e32a1103 100644
--- a/audit/format_json_test.go
+++ b/audit/format_json_test.go
@@ -38,12 +38,13 @@ func TestFormatJSON_formatRequest(t *testing.T) {
}{
"auth, request": {
&logical.Auth{
- ClientToken: "foo",
- Accessor: "bar",
- EntityID: "foobarentity",
- DisplayName: "testtoken",
- Policies: []string{"root"},
- TokenType: logical.TokenTypeService,
+ ClientToken: "foo",
+ Accessor: "bar",
+ DisplayName: "testtoken",
+ EntityID: "foobarentity",
+ NoDefaultPolicy: true,
+ Policies: []string{"root"},
+ TokenType: logical.TokenTypeService,
},
&logical.Request{
Operation: logical.UpdateOperation,
@@ -64,12 +65,13 @@ func TestFormatJSON_formatRequest(t *testing.T) {
},
"auth, request with prefix": {
&logical.Auth{
- ClientToken: "foo",
- Accessor: "bar",
- EntityID: "foobarentity",
- DisplayName: "testtoken",
- Policies: []string{"root"},
- TokenType: logical.TokenTypeService,
+ ClientToken: "foo",
+ Accessor: "bar",
+ EntityID: "foobarentity",
+ DisplayName: "testtoken",
+ NoDefaultPolicy: true,
+ Policies: []string{"root"},
+ TokenType: logical.TokenTypeService,
},
&logical.Request{
Operation: logical.UpdateOperation,
@@ -141,5 +143,5 @@ func TestFormatJSON_formatRequest(t *testing.T) {
}
}
-const testFormatJSONReqBasicStrFmt = `{"time":"2015-08-05T13:45:46Z","type":"request","auth":{"client_token":"%s","accessor":"bar","display_name":"testtoken","policies":["root"],"metadata":null,"entity_id":"foobarentity","token_type":"service"},"request":{"operation":"update","path":"/foo","data":null,"wrap_ttl":60,"remote_address":"127.0.0.1","headers":{"foo":["bar"]}},"error":"this is an error"}
+const testFormatJSONReqBasicStrFmt = `{"time":"2015-08-05T13:45:46Z","type":"request","auth":{"client_token":"%s","accessor":"bar","display_name":"testtoken","policies":["root"],"no_default_policy":true,"metadata":null,"entity_id":"foobarentity","token_type":"service"},"request":{"operation":"update","path":"/foo","data":null,"wrap_ttl":60,"remote_address":"127.0.0.1","headers":{"foo":["bar"]}},"error":"this is an error"}
`
diff --git a/audit/format_jsonx_test.go b/audit/format_jsonx_test.go
index d5239277a6..6c46d3d9db 100644
--- a/audit/format_jsonx_test.go
+++ b/audit/format_jsonx_test.go
@@ -37,12 +37,13 @@ func TestFormatJSONx_formatRequest(t *testing.T) {
}{
"auth, request": {
&logical.Auth{
- ClientToken: "foo",
- Accessor: "bar",
- EntityID: "foobarentity",
- DisplayName: "testtoken",
- Policies: []string{"root"},
- TokenType: logical.TokenTypeService,
+ ClientToken: "foo",
+ Accessor: "bar",
+ DisplayName: "testtoken",
+ EntityID: "foobarentity",
+ NoDefaultPolicy: true,
+ Policies: []string{"root"},
+ TokenType: logical.TokenTypeService,
},
&logical.Request{
ID: "request",
@@ -64,17 +65,18 @@ func TestFormatJSONx_formatRequest(t *testing.T) {
errors.New("this is an error"),
"",
"",
- fmt.Sprintf(`bar%stesttokenfoobarentityrootservicethis is an error%sbarbarrequestrootupdate/footrue127.0.0.160request`,
+ fmt.Sprintf(`bar%stesttokenfoobarentitytruerootservicethis is an error%sbarbarrequestrootupdate/footrue127.0.0.160request`,
fooSalted, fooSalted),
},
"auth, request with prefix": {
&logical.Auth{
- ClientToken: "foo",
- Accessor: "bar",
- EntityID: "foobarentity",
- DisplayName: "testtoken",
- Policies: []string{"root"},
- TokenType: logical.TokenTypeService,
+ ClientToken: "foo",
+ Accessor: "bar",
+ DisplayName: "testtoken",
+ NoDefaultPolicy: true,
+ EntityID: "foobarentity",
+ Policies: []string{"root"},
+ TokenType: logical.TokenTypeService,
},
&logical.Request{
ID: "request",
@@ -96,7 +98,7 @@ func TestFormatJSONx_formatRequest(t *testing.T) {
errors.New("this is an error"),
"",
"@cee: ",
- fmt.Sprintf(`bar%stesttokenfoobarentityrootservicethis is an error%sbarbarrequestrootupdate/footrue127.0.0.160request`,
+ fmt.Sprintf(`bar%stesttokenfoobarentitytruerootservicethis is an error%sbarbarrequestrootupdate/footrue127.0.0.160request`,
fooSalted, fooSalted),
},
}
diff --git a/command/operator_rekey.go b/command/operator_rekey.go
index 724d9ad3ca..d437a92591 100644
--- a/command/operator_rekey.go
+++ b/command/operator_rekey.go
@@ -685,12 +685,22 @@ func (c *OperatorRekeyCommand) printUnsealKeys(client *api.Client, status *api.R
if len(resp.PGPFingerprints) > 0 && resp.Backup {
c.UI.Output("")
- c.UI.Output(wrapAtLength(fmt.Sprintf(
- "The encrypted unseal keys are backed up to \"core/unseal-keys-backup\"" +
- "in the storage backend. Remove these keys at any time using " +
- "\"vault operator rekey -backup-delete\". Vault does not automatically " +
- "remove these keys.",
- )))
+ switch strings.ToLower(strings.TrimSpace(c.flagTarget)) {
+ case "barrier":
+ c.UI.Output(wrapAtLength(fmt.Sprintf(
+ "The encrypted unseal keys are backed up to \"core/unseal-keys-backup\" " +
+ "in the storage backend. Remove these keys at any time using " +
+ "\"vault operator rekey -backup-delete\". Vault does not automatically " +
+ "remove these keys.",
+ )))
+ case "recovery", "hsm":
+ c.UI.Output(wrapAtLength(fmt.Sprintf(
+ "The encrypted unseal keys are backed up to \"core/recovery-keys-backup\" " +
+ "in the storage backend. Remove these keys at any time using " +
+ "\"vault operator rekey -backup-delete -target=recovery\". Vault does not automatically " +
+ "remove these keys.",
+ )))
+ }
}
switch status.VerificationRequired {
diff --git a/go.mod b/go.mod
index bd727fc4f3..2c3b65d167 100644
--- a/go.mod
+++ b/go.mod
@@ -81,8 +81,8 @@ require (
github.com/hashicorp/vault-plugin-secrets-gcp v0.5.2
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.5.1
github.com/hashicorp/vault-plugin-secrets-kv v0.5.2-0.20190416155133-fd495225dea0
- github.com/hashicorp/vault/api v1.0.1
- github.com/hashicorp/vault/sdk v0.1.11
+ github.com/hashicorp/vault/api v1.0.3-0.20190614165924-47d4e5b1f688
+ github.com/hashicorp/vault/sdk v0.1.12-0.20190614165924-47d4e5b1f688
github.com/influxdata/influxdb v0.0.0-20190411212539-d24b7ba8c4c4
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733 // indirect
github.com/jackc/pgx v3.3.0+incompatible // indirect
diff --git a/helper/testhelpers/testhelpers.go b/helper/testhelpers/testhelpers.go
index 3a02fbcd75..9e3afe03ce 100644
--- a/helper/testhelpers/testhelpers.go
+++ b/helper/testhelpers/testhelpers.go
@@ -265,10 +265,6 @@ func ConfClusterAndCore(t testing.T, conf *vault.CoreConfig, opts *vault.TestClu
"approle": credAppRole.Factory,
"userpass": credUserpass.Factory,
}
- coreConfig.LogicalBackends = map[string]logical.Factory{
- "local-kv": PassthroughWithLocalPathsFactory,
- "leased-kv": vault.LeasedPassthroughBackendFactory,
- }
vault.AddNoopAudit(&coreConfig)
cluster := vault.NewTestCluster(t, &coreConfig, opts)
cluster.Start()
@@ -281,13 +277,6 @@ func ConfClusterAndCore(t testing.T, conf *vault.CoreConfig, opts *vault.TestClu
return cluster, core
}
-func GetClusterAndCore(t testing.T, logger log.Logger, handlerFunc func(*vault.HandlerProperties) http.Handler) (*vault.TestCluster, *vault.TestClusterCore) {
- return ConfClusterAndCore(t, &vault.CoreConfig{}, &vault.TestClusterOptions{
- Logger: logger,
- HandlerFunc: handlerFunc,
- })
-}
-
func GetPerfReplicatedClusters(t testing.T, conf *vault.CoreConfig, opts *vault.TestClusterOptions) *ReplicatedTestClusters {
ret := &ReplicatedTestClusters{}
@@ -305,13 +294,18 @@ func GetPerfReplicatedClusters(t testing.T, conf *vault.CoreConfig, opts *vault.
// Set this lower so that state populates quickly to standby nodes
cluster.HeartbeatInterval = 2 * time.Second
- opts1 := *opts
- opts1.Logger = logger.Named("perf-pri")
- ret.PerfPrimaryCluster, _ = ConfClusterAndCore(t, conf, &opts1)
+ numCores := opts.NumCores
+ if numCores == 0 {
+ numCores = vault.DefaultNumCores
+ }
- opts2 := *opts
- opts1.Logger = logger.Named("perf-sec")
- ret.PerfSecondaryCluster, _ = ConfClusterAndCore(t, conf, &opts2)
+ localopts := *opts
+ localopts.Logger = logger.Named("perf-pri")
+ ret.PerfPrimaryCluster, _ = ConfClusterAndCore(t, conf, &localopts)
+
+ localopts.Logger = logger.Named("perf-sec")
+ localopts.FirstCoreNumber += numCores
+ ret.PerfSecondaryCluster, _ = ConfClusterAndCore(t, conf, &localopts)
SetupTwoClusterPerfReplication(t, ret.PerfPrimaryCluster, ret.PerfSecondaryCluster)
@@ -319,6 +313,12 @@ func GetPerfReplicatedClusters(t testing.T, conf *vault.CoreConfig, opts *vault.
}
func GetFourReplicatedClusters(t testing.T, handlerFunc func(*vault.HandlerProperties) http.Handler) *ReplicatedTestClusters {
+ return GetFourReplicatedClustersWithConf(t, &vault.CoreConfig{}, &vault.TestClusterOptions{
+ HandlerFunc: handlerFunc,
+ })
+}
+
+func GetFourReplicatedClustersWithConf(t testing.T, conf *vault.CoreConfig, opts *vault.TestClusterOptions) *ReplicatedTestClusters {
ret := &ReplicatedTestClusters{}
logger := log.New(&log.LoggerOptions{
@@ -328,13 +328,26 @@ func GetFourReplicatedClusters(t testing.T, handlerFunc func(*vault.HandlerPrope
// Set this lower so that state populates quickly to standby nodes
cluster.HeartbeatInterval = 2 * time.Second
- ret.PerfPrimaryCluster, _ = GetClusterAndCore(t, logger.Named("perf-pri"), handlerFunc)
+ numCores := opts.NumCores
+ if numCores == 0 {
+ numCores = vault.DefaultNumCores
+ }
- ret.PerfSecondaryCluster, _ = GetClusterAndCore(t, logger.Named("perf-sec"), handlerFunc)
+ localopts := *opts
+ localopts.Logger = logger.Named("perf-pri")
+ ret.PerfPrimaryCluster, _ = ConfClusterAndCore(t, conf, &localopts)
- ret.PerfPrimaryDRCluster, _ = GetClusterAndCore(t, logger.Named("perf-pri-dr"), handlerFunc)
+ localopts.Logger = logger.Named("perf-sec")
+ localopts.FirstCoreNumber += numCores
+ ret.PerfSecondaryCluster, _ = ConfClusterAndCore(t, conf, &localopts)
- ret.PerfSecondaryDRCluster, _ = GetClusterAndCore(t, logger.Named("perf-sec-dr"), handlerFunc)
+ localopts.Logger = logger.Named("perf-pri-dr")
+ localopts.FirstCoreNumber += numCores
+ ret.PerfPrimaryDRCluster, _ = ConfClusterAndCore(t, conf, &localopts)
+
+ localopts.Logger = logger.Named("perf-sec-dr")
+ localopts.FirstCoreNumber += numCores
+ ret.PerfSecondaryDRCluster, _ = ConfClusterAndCore(t, conf, &localopts)
builder := &ReplicatedTestClustersBuilder{clusters: ret}
builder.setupFourClusterReplication(t)
diff --git a/physical/consul/consul.go b/physical/consul/consul.go
index e050cf08ee..4db2b36287 100644
--- a/physical/consul/consul.go
+++ b/physical/consul/consul.go
@@ -237,9 +237,7 @@ func NewConsulBackend(conf map[string]string, logger log.Logger) (physical.Backe
logger.Debug("config address parsed", "scheme", parts[0])
logger.Debug("config scheme parsed", "address", parts[1])
}
- } else {
- return nil, errors.New("address should be host[:port], not URL")
- }
+ } // allow "unix:" or whatever else consul supports in the future
}
}
if scheme, ok := conf["scheme"]; ok {
diff --git a/physical/consul/consul_test.go b/physical/consul/consul_test.go
index fa45f972f1..b474fb9ae5 100644
--- a/physical/consul/consul_test.go
+++ b/physical/consul/consul_test.go
@@ -231,6 +231,24 @@ func TestConsul_newConsulBackend(t *testing.T) {
max_parallel: 4,
consistencyMode: "strong",
},
+ {
+ name: "Unix socket",
+ consulConfig: map[string]string{
+ "address": "unix:///tmp/.consul.http.sock",
+ },
+ address: "/tmp/.consul.http.sock",
+ scheme: "http", // Default, not overridden?
+
+ // Defaults
+ checkTimeout: 5 * time.Second,
+ redirectAddr: "http://127.0.0.1:8200",
+ path: "vault/",
+ service: "vault",
+ token: "",
+ max_parallel: 4,
+ disableReg: false,
+ consistencyMode: "default",
+ },
{
name: "Scheme in address",
consulConfig: map[string]string{
diff --git a/physical/postgresql/postgresql_test.go b/physical/postgresql/postgresql_test.go
index 54d7d0e60c..af83865fa3 100644
--- a/physical/postgresql/postgresql_test.go
+++ b/physical/postgresql/postgresql_test.go
@@ -107,103 +107,92 @@ func testPostgresSQLLockTTL(t *testing.T, ha physical.HABackend) {
// Set much smaller lock times to speed up the test.
lockTTL := 3
renewInterval := time.Second * 1
- watchInterval := time.Second * 1
+ retryInterval := time.Second * 1
+ longRenewInterval := time.Duration(lockTTL*2) * time.Second
+ lockkey := "postgresttl"
+
+ var leaderCh <-chan struct{}
// Get the lock
- origLock, err := ha.LockWith("dynamodbttl", "bar")
+ origLock, err := ha.LockWith(lockkey, "bar")
if err != nil {
t.Fatalf("err: %v", err)
}
- // set the first lock renew period to double the expected TTL.
- lock := origLock.(*PostgreSQLLock)
- lock.renewInterval = time.Duration(lockTTL*2) * time.Second
- lock.ttlSeconds = lockTTL
- // lock.retryInterval = watchInterval
+ {
+ // set the first lock renew period to double the expected TTL.
+ lock := origLock.(*PostgreSQLLock)
+ lock.renewInterval = longRenewInterval
+ lock.ttlSeconds = lockTTL
- // Attempt to lock
- leaderCh, err := lock.Lock(nil)
- if err != nil {
- t.Fatalf("err: %v", err)
- }
- if leaderCh == nil {
- t.Fatalf("failed to get leader ch")
- }
+ // Attempt to lock
+ leaderCh, err = lock.Lock(nil)
+ if err != nil {
+ t.Fatalf("err: %v", err)
+ }
+ if leaderCh == nil {
+ t.Fatalf("failed to get leader ch")
+ }
- // Check the value
- held, val, err := lock.Value()
- if err != nil {
- t.Fatalf("err: %v", err)
- }
- if !held {
- t.Fatalf("should be held")
- }
- if val != "bar" {
- t.Fatalf("bad value: %v", err)
+ // Check the value
+ held, val, err := lock.Value()
+ if err != nil {
+ t.Fatalf("err: %v", err)
+ }
+ if !held {
+ t.Fatalf("should be held")
+ }
+ if val != "bar" {
+ t.Fatalf("bad value: %v", val)
+ }
}
// Second acquisition should succeed because the first lock should
// not renew within the 3 sec TTL.
- origLock2, err := ha.LockWith("dynamodbttl", "baz")
+ origLock2, err := ha.LockWith(lockkey, "baz")
if err != nil {
t.Fatalf("err: %v", err)
}
+ {
+ lock2 := origLock2.(*PostgreSQLLock)
+ lock2.renewInterval = renewInterval
+ lock2.ttlSeconds = lockTTL
+ lock2.retryInterval = retryInterval
- lock2 := origLock2.(*PostgreSQLLock)
- lock2.renewInterval = renewInterval
- lock2.ttlSeconds = lockTTL
- // lock2.retryInterval = watchInterval
+ // Cancel attempt in 6 sec so as not to block unit tests forever
+ stopCh := make(chan struct{})
+ time.AfterFunc(time.Duration(lockTTL*2)*time.Second, func() {
+ close(stopCh)
+ })
- // Cancel attempt in 6 sec so as not to block unit tests forever
- stopCh := make(chan struct{})
- time.AfterFunc(time.Duration(lockTTL*2)*time.Second, func() {
- close(stopCh)
- })
+ // Attempt to lock should work
+ leaderCh2, err := lock2.Lock(stopCh)
+ if err != nil {
+ t.Fatalf("err: %v", err)
+ }
+ if leaderCh2 == nil {
+ t.Fatalf("should get leader ch")
+ }
+ defer lock2.Unlock()
- // Attempt to lock should work
- leaderCh2, err := lock2.Lock(stopCh)
- if err != nil {
- t.Fatalf("err: %v", err)
- }
- if leaderCh2 == nil {
- t.Fatalf("should get leader ch")
- }
-
- // Check the value
- held, val, err = lock2.Value()
- if err != nil {
- t.Fatalf("err: %v", err)
- }
- if !held {
- t.Fatalf("should be held")
- }
- if val != "baz" {
- t.Fatalf("bad value: %v", err)
+ // Check the value
+ held, val, err := lock2.Value()
+ if err != nil {
+ t.Fatalf("err: %v", err)
+ }
+ if !held {
+ t.Fatalf("should be held")
+ }
+ if val != "baz" {
+ t.Fatalf("bad value: %v", val)
+ }
}
// The first lock should have lost the leader channel
- leaderChClosed := false
- blocking := make(chan struct{})
- // Attempt to read from the leader or the blocking channel, which ever one
- // happens first.
- go func() {
- select {
- case <-time.After(watchInterval * 3):
- return
- case <-leaderCh:
- leaderChClosed = true
- close(blocking)
- case <-blocking:
- return
- }
- }()
-
- <-blocking
- if !leaderChClosed {
+ select {
+ case <-time.After(longRenewInterval * 2):
t.Fatalf("original lock did not have its leader channel closed.")
+ case <-leaderCh:
}
-
- // Cleanup
- lock2.Unlock()
}
// Verify that once Unlock is called, we don't keep trying to renew the original
@@ -237,7 +226,7 @@ func testPostgresSQLLockRenewal(t *testing.T, ha physical.HABackend) {
t.Fatalf("should be held")
}
if val != "bar" {
- t.Fatalf("bad value: %v", err)
+ t.Fatalf("bad value: %v", val)
}
// Release the lock, which will delete the stored item
@@ -280,7 +269,7 @@ func testPostgresSQLLockRenewal(t *testing.T, ha physical.HABackend) {
t.Fatalf("should be held")
}
if val != "baz" {
- t.Fatalf("bad value: %v", err)
+ t.Fatalf("bad value: %v", val)
}
// Cleanup
diff --git a/scripts/cross/Dockerfile b/scripts/cross/Dockerfile
index 2ce7ea669a..d367ab2e39 100644
--- a/scripts/cross/Dockerfile
+++ b/scripts/cross/Dockerfile
@@ -21,7 +21,7 @@ RUN apt-get update -y && apt-get install -y -q nodejs yarn=1.12.1-1
RUN rm -rf /var/lib/apt/lists/*
-ENV GOVERSION 1.12.4
+ENV GOVERSION 1.12.6
RUN mkdir /goroot && mkdir /gopath
RUN curl https://storage.googleapis.com/golang/go${GOVERSION}.linux-amd64.tar.gz \
| tar xvzf - -C /goroot --strip-components=1
diff --git a/sdk/helper/tokenutil/tokenutil.go b/sdk/helper/tokenutil/tokenutil.go
new file mode 100644
index 0000000000..5945fd47e0
--- /dev/null
+++ b/sdk/helper/tokenutil/tokenutil.go
@@ -0,0 +1,233 @@
+package tokenutil
+
+import (
+ "errors"
+ "fmt"
+ "time"
+
+ sockaddr "github.com/hashicorp/go-sockaddr"
+ "github.com/hashicorp/vault/sdk/framework"
+ "github.com/hashicorp/vault/sdk/helper/parseutil"
+ "github.com/hashicorp/vault/sdk/helper/strutil"
+ "github.com/hashicorp/vault/sdk/logical"
+)
+
+// TokenParams contains a set of common parameters that auth plugins can use
+// for setting token behavior
+type TokenParams struct {
+ // The set of CIDRs that tokens generated using this role will be bound to
+ TokenBoundCIDRs []*sockaddr.SockAddrMarshaler `json:"token_bound_cidrs"`
+
+ // If set, the token entry will have an explicit maximum TTL set, rather
+ // than deferring to role/mount values
+ TokenExplicitMaxTTL time.Duration `json:"token_explicit_max_ttl" mapstructure:"token_explicit_max_ttl"`
+
+ // The max TTL to use for the token
+ TokenMaxTTL time.Duration `json:"token_max_ttl" mapstructure:"token_max_ttl"`
+
+ // If set, core will not automatically add default to the policy list
+ TokenNoDefaultPolicy bool `json:"token_no_default_policy" mapstructure:"token_no_default_policy"`
+
+ // The maximum number of times a token issued from this role may be used.
+ TokenNumUses int `json:"token_num_uses" mapstructure:"token_num_uses"`
+
+ // If non-zero, tokens created using this role will be able to be renewed
+ // forever, but will have a fixed renewal period of this value
+ TokenPeriod time.Duration `json:"token_period" mapstructure:"token_period"`
+
+ // The policies to set
+ TokenPolicies []string `json:"token_policies" mapstructure:"token_policies"`
+
+ // The type of token this role should issue
+ TokenType logical.TokenType `json:"token_type" mapstructure:"token_type"`
+
+ // The TTL to user for the token
+ TokenTTL time.Duration `json:"token_ttl" mapstructure:"token_ttl"`
+}
+
+// AddTokenFields adds fields to an existing role. It panics if it would
+// overwrite an existing field.
+func AddTokenFields(m map[string]*framework.FieldSchema) {
+ AddTokenFieldsWithAllowList(m, nil)
+}
+
+// AddTokenFields adds fields to an existing role. It panics if it would
+// overwrite an existing field. Allowed can be use to restrict the set, e.g. if
+// there would be conflicts.
+func AddTokenFieldsWithAllowList(m map[string]*framework.FieldSchema, allowed []string) {
+ r := TokenFields()
+ for k, v := range r {
+ if len(allowed) > 0 && !strutil.StrListContains(allowed, k) {
+ continue
+ }
+ if _, has := m[k]; has {
+ panic(fmt.Sprintf("adding role field %s would overwrite existing field", k))
+ }
+ m[k] = v
+ }
+}
+
+// TokenFields provides a set of field schemas for the parameters
+func TokenFields() map[string]*framework.FieldSchema {
+ return map[string]*framework.FieldSchema{
+ "token_bound_cidrs": &framework.FieldSchema{
+ Type: framework.TypeCommaStringSlice,
+ Description: `Comma separated string or JSON list of CIDR blocks. If set, specifies the blocks of IP addresses which are allowed to use the generated token.`,
+ },
+
+ "token_explicit_max_ttl": &framework.FieldSchema{
+ Type: framework.TypeDurationSecond,
+ Description: tokenExplicitMaxTTLHelp,
+ },
+
+ "token_max_ttl": &framework.FieldSchema{
+ Type: framework.TypeDurationSecond,
+ Description: "The maximum lifetime of the generated token",
+ },
+
+ "token_no_default_policy": &framework.FieldSchema{
+ Type: framework.TypeBool,
+ Description: "If true, the 'default' policy will not automatically be added to generated tokens",
+ },
+
+ "token_period": &framework.FieldSchema{
+ Type: framework.TypeDurationSecond,
+ Description: tokenPeriodHelp,
+ },
+
+ "token_policies": &framework.FieldSchema{
+ Type: framework.TypeCommaStringSlice,
+ Description: "Comma-separated list of policies",
+ },
+
+ "token_type": &framework.FieldSchema{
+ Type: framework.TypeString,
+ Default: "default-service",
+ Description: "The type of token to generate, service or batch",
+ },
+
+ "token_ttl": &framework.FieldSchema{
+ Type: framework.TypeDurationSecond,
+ Description: "The initial ttl of the token to generate",
+ },
+
+ "token_num_uses": &framework.FieldSchema{
+ Type: framework.TypeInt,
+ Description: "The maximum number of times a token may be used, a value of zero means unlimited",
+ },
+ }
+}
+
+// ParseTokenFields provides common field parsing functionality into a TokenFields struct
+func (t *TokenParams) ParseTokenFields(req *logical.Request, d *framework.FieldData) error {
+ if boundCIDRsRaw, ok := d.GetOk("token_bound_cidrs"); ok {
+ boundCIDRs, err := parseutil.ParseAddrs(boundCIDRsRaw.([]string))
+ if err != nil {
+ return err
+ }
+ t.TokenBoundCIDRs = boundCIDRs
+ }
+
+ if explicitMaxTTLRaw, ok := d.GetOk("token_explicit_max_ttl"); ok {
+ t.TokenExplicitMaxTTL = time.Duration(explicitMaxTTLRaw.(int)) * time.Second
+ }
+
+ if maxTTLRaw, ok := d.GetOk("token_max_ttl"); ok {
+ t.TokenMaxTTL = time.Duration(maxTTLRaw.(int)) * time.Second
+ }
+ if t.TokenMaxTTL < 0 {
+ return errors.New("'token_max_ttl' cannot be negative")
+ }
+
+ if noDefaultRaw, ok := d.GetOk("token_no_default_policy"); ok {
+ t.TokenNoDefaultPolicy = noDefaultRaw.(bool)
+ }
+
+ if periodRaw, ok := d.GetOk("token_period"); ok {
+ t.TokenPeriod = time.Duration(periodRaw.(int)) * time.Second
+ }
+ if t.TokenPeriod < 0 {
+ return errors.New("'token_period' cannot be negative")
+ }
+
+ if policiesRaw, ok := d.GetOk("token_policies"); ok {
+ t.TokenPolicies = policiesRaw.([]string)
+ }
+
+ if tokenTypeRaw, ok := d.GetOk("token_type"); ok {
+ var tokenType logical.TokenType
+ tokenTypeStr := tokenTypeRaw.(string)
+ switch tokenTypeStr {
+ case "service":
+ tokenType = logical.TokenTypeService
+ case "batch":
+ tokenType = logical.TokenTypeBatch
+ case "", "default", "default-service":
+ tokenType = logical.TokenTypeDefaultService
+ case "default-batch":
+ tokenType = logical.TokenTypeDefaultBatch
+ default:
+ return fmt.Errorf("invalid 'token_type' value %q", tokenTypeStr)
+ }
+ t.TokenType = tokenType
+ }
+
+ if ttlRaw, ok := d.GetOk("token_ttl"); ok {
+ t.TokenTTL = time.Duration(ttlRaw.(int)) * time.Second
+ }
+ if t.TokenTTL < 0 {
+ return errors.New("'token_ttl' cannot be negative")
+ }
+ if t.TokenTTL > 0 && t.TokenMaxTTL > 0 && t.TokenTTL > t.TokenMaxTTL {
+ return errors.New("'token_ttl' cannot be greater than 'token_max_ttl'")
+ }
+
+ if tokenNumUses, ok := d.GetOk("token_num_uses"); ok {
+ t.TokenNumUses = tokenNumUses.(int)
+ }
+ if t.TokenNumUses < 0 {
+ return errors.New("'token_num_uses' cannot be negative")
+ }
+
+ return nil
+}
+
+// PopulateTokenData adds information from TokenParams into the map
+func (t *TokenParams) PopulateTokenData(m map[string]interface{}) {
+ m["token_bound_cidrs"] = t.TokenBoundCIDRs
+ m["token_explicit_max_ttl"] = t.TokenExplicitMaxTTL.Seconds()
+ m["token_max_ttl"] = t.TokenMaxTTL.Seconds()
+ m["token_no_default_policy"] = t.TokenNoDefaultPolicy
+ m["token_period"] = t.TokenPeriod.Seconds()
+ m["token_policies"] = t.TokenPolicies
+ m["token_type"] = t.TokenType.String()
+ m["token_ttl"] = t.TokenTTL.Seconds()
+ m["token_num_uses"] = t.TokenNumUses
+}
+
+// PopulateTokenAuth populates Auth with parameters
+func (t *TokenParams) PopulateTokenAuth(auth *logical.Auth) {
+ auth.BoundCIDRs = t.TokenBoundCIDRs
+ auth.ExplicitMaxTTL = t.TokenExplicitMaxTTL
+ auth.MaxTTL = t.TokenMaxTTL
+ auth.NoDefaultPolicy = t.TokenNoDefaultPolicy
+ auth.Period = t.TokenPeriod
+ auth.Policies = t.TokenPolicies
+ auth.TokenType = t.TokenType
+ auth.TTL = t.TokenTTL
+ auth.NumUses = t.TokenNumUses
+}
+
+const (
+ tokenPeriodHelp = `If set, tokens created via this role
+will have no max lifetime; instead, their
+renewal period will be fixed to this value.
+This takes an integer number of seconds,
+or a string duration (e.g. "24h").`
+ tokenExplicitMaxTTLHelp = `If set, tokens created via this role
+carry an explicit maximum TTL. During renewal,
+the current maximum TTL values of the role
+and the mount are not checked for changes,
+and any updates to these values will have
+no effect on the token being renewed.`
+)
diff --git a/sdk/logical/auth.go b/sdk/logical/auth.go
index 89aa916590..2bfb6e0015 100644
--- a/sdk/logical/auth.go
+++ b/sdk/logical/auth.go
@@ -38,6 +38,11 @@ type Auth struct {
// different namespaces indexed by respective namespace identifiers
ExternalNamespacePolicies map[string][]string `json:"external_namespace_policies" mapstructure:"external_namespace_policies" structs:"external_namespace_policies"`
+ // Indicates that the default policy should not be added by core when
+ // creating a token. The default policy will still be added if it's
+ // explicitly defined.
+ NoDefaultPolicy bool `json:"no_default_policy" mapstructure:"no_default_policy" structs:"no_default_policy"`
+
// Metadata is used to attach arbitrary string-type metadata to
// an authenticated user. This metadata will be outputted into the
// audit log.
diff --git a/sdk/logical/system_view.go b/sdk/logical/system_view.go
index 550b74a915..52fc2bd6ac 100644
--- a/sdk/logical/system_view.go
+++ b/sdk/logical/system_view.go
@@ -72,6 +72,7 @@ type SystemView interface {
type ExtendedSystemView interface {
Auditor() Auditor
+ ForwardGenericRequest(context.Context, *Request) (*Response, error)
}
type StaticSystemView struct {
@@ -104,6 +105,10 @@ func (d StaticSystemView) Auditor() Auditor {
return noopAuditor{}
}
+func (d StaticSystemView) ForwardGenericRequest(ctx context.Context, req *Request) (*Response, error) {
+ return nil, errors.New("ForwardGenericRequest is not implemented in StaticSystemView")
+}
+
func (d StaticSystemView) DefaultLeaseTTL() time.Duration {
return d.DefaultLeaseTTLVal
}
diff --git a/sdk/plugin/pb/backend.pb.go b/sdk/plugin/pb/backend.pb.go
index 2db00c7e9e..28ff0c455e 100644
--- a/sdk/plugin/pb/backend.pb.go
+++ b/sdk/plugin/pb/backend.pb.go
@@ -526,7 +526,9 @@ type Auth struct {
// TTL is a hard limit and cannot be exceeded, also counts for periodic tokens.
ExplicitMaxTTL int64 `sentinel:"" protobuf:"varint,16,opt,name=explicit_max_ttl,json=explicitMaxTtl,proto3" json:"explicit_max_ttl,omitempty"`
// TokenType is the type of token being requested
- TokenType uint32 `sentinel:"" protobuf:"varint,17,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
+ TokenType uint32 `sentinel:"" protobuf:"varint,17,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
+ // Whether the default policy should be added automatically by core
+ NoDefaultPolicy bool `sentinel:"" protobuf:"varint,18,opt,name=no_default_policy,json=noDefaultPolicy,proto3" json:"no_default_policy,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
@@ -676,6 +678,13 @@ func (m *Auth) GetTokenType() uint32 {
return 0
}
+func (m *Auth) GetNoDefaultPolicy() bool {
+ if m != nil {
+ return m.NoDefaultPolicy
+ }
+ return false
+}
+
type TokenEntry struct {
ID string `sentinel:"" protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Accessor string `sentinel:"" protobuf:"bytes,2,opt,name=accessor,proto3" json:"accessor,omitempty"`
@@ -2713,164 +2722,165 @@ func init() {
func init() { proto.RegisterFile("sdk/plugin/pb/backend.proto", fileDescriptor_4dbf1dfe0c11846b) }
var fileDescriptor_4dbf1dfe0c11846b = []byte{
- // 2499 bytes of a gzipped FileDescriptorProto
+ // 2519 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x59, 0xdb, 0x72, 0x1b, 0xc7,
0xd1, 0x2e, 0x00, 0xc4, 0xa9, 0x71, 0x22, 0x46, 0xb4, 0xfe, 0x15, 0x24, 0xff, 0x82, 0xd7, 0x91,
- 0x0c, 0x2b, 0x36, 0x68, 0x51, 0x71, 0x2c, 0x27, 0x65, 0xa7, 0x68, 0x8a, 0x96, 0x19, 0x93, 0x36,
- 0x6b, 0x09, 0xc5, 0x39, 0x55, 0xc1, 0x83, 0xdd, 0x21, 0xb8, 0xc5, 0xc5, 0xee, 0x66, 0x76, 0x96,
- 0x22, 0xae, 0xf2, 0x16, 0x79, 0x8d, 0xdc, 0xa6, 0x72, 0x93, 0xbb, 0x94, 0x2b, 0xf7, 0x79, 0x8d,
- 0x3c, 0x43, 0x6a, 0x7a, 0x66, 0x4f, 0x00, 0x68, 0xc9, 0x55, 0xce, 0xdd, 0x4c, 0x77, 0xcf, 0xa9,
- 0xe7, 0xeb, 0xaf, 0x7b, 0x76, 0xe1, 0x6e, 0xe4, 0x5c, 0xee, 0x86, 0x5e, 0x3c, 0x77, 0xfd, 0xdd,
- 0x70, 0xb6, 0x3b, 0xa3, 0xf6, 0x25, 0xf3, 0x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00, 0xff, 0xff, 0xbd,
+ 0xc6, 0x6e, 0xfa, 0xf8, 0x1a, 0x00, 0x00,
}
// Reference imports to suppress errors if they are not otherwise used.
diff --git a/sdk/plugin/pb/backend.proto b/sdk/plugin/pb/backend.proto
index 65f4ef80dc..ca86c9c139 100644
--- a/sdk/plugin/pb/backend.proto
+++ b/sdk/plugin/pb/backend.proto
@@ -210,6 +210,9 @@ message Auth {
// TokenType is the type of token being requested
uint32 token_type = 17;
+
+ // Whether the default policy should be added automatically by core
+ bool no_default_policy = 18;
}
message TokenEntry {
diff --git a/sdk/plugin/pb/translation.go b/sdk/plugin/pb/translation.go
index 3ef85a0821..23c7e718cb 100644
--- a/sdk/plugin/pb/translation.go
+++ b/sdk/plugin/pb/translation.go
@@ -507,6 +507,7 @@ func LogicalAuthToProtoAuth(a *logical.Auth) (*Auth, error) {
Policies: a.Policies,
TokenPolicies: a.TokenPolicies,
IdentityPolicies: a.IdentityPolicies,
+ NoDefaultPolicy: a.NoDefaultPolicy,
Metadata: a.Metadata,
ClientToken: a.ClientToken,
Accessor: a.Accessor,
@@ -554,6 +555,7 @@ func ProtoAuthToLogicalAuth(a *Auth) (*logical.Auth, error) {
Policies: a.Policies,
TokenPolicies: a.TokenPolicies,
IdentityPolicies: a.IdentityPolicies,
+ NoDefaultPolicy: a.NoDefaultPolicy,
Metadata: a.Metadata,
ClientToken: a.ClientToken,
Accessor: a.Accessor,
diff --git a/ui/app/components/edition-badge.js b/ui/app/components/edition-badge.js
deleted file mode 100644
index 025f657be6..0000000000
--- a/ui/app/components/edition-badge.js
+++ /dev/null
@@ -1,18 +0,0 @@
-import { computed } from '@ember/object';
-import Component from '@ember/component';
-
-export default Component.extend({
- tagName: 'span',
- classNames: 'tag is-outlined edition-badge',
- attributeBindings: ['edition:aria-label'],
- icon: computed('edition', function() {
- const edition = this.get('edition');
- const entEditions = ['Enterprise', 'Premium', 'Pro'];
-
- if (entEditions.includes(edition)) {
- return 'edition-enterprise';
- } else {
- return 'edition-oss';
- }
- }),
-});
diff --git a/ui/app/styles/components/empty-state.scss b/ui/app/styles/components/empty-state.scss
index 2cb489aae0..b023403cfa 100644
--- a/ui/app/styles/components/empty-state.scss
+++ b/ui/app/styles/components/empty-state.scss
@@ -2,7 +2,7 @@
align-items: center;
color: $grey;
display: flex;
- background: $ui-gray-050;
+ background: $ui-gray-010;
justify-content: center;
padding: $spacing-xxl $spacing-s;
box-shadow: 0 -2px 0 -1px $ui-gray-300;
diff --git a/ui/app/styles/components/upgrade-overlay.scss b/ui/app/styles/components/upgrade-overlay.scss
deleted file mode 100644
index f5770064ac..0000000000
--- a/ui/app/styles/components/upgrade-overlay.scss
+++ /dev/null
@@ -1,63 +0,0 @@
-.upgrade-overlay {
- font-size: 1rem;
- opacity: 0;
- text-align: left;
- transition: opacity $speed-slow;
- will-change: opacity;
- z-index: 300;
-
- &.is-animated {
- opacity: 1;
- }
-
- .modal-background {
- background-image: url('/ui/vault-hex.svg'), linear-gradient(90deg, #191a1c, #1b212d);
- opacity: 0.97;
- }
-
- .modal-content {
- overflow: auto;
- overflow-x: hidden;
- transform: translateY(20%) scale(0.9);
- transition: transform $speed-slow;
- will-change: transform;
- }
-
- &.is-animated {
- .modal-content {
- transform: translateY(0) scale(1);
- }
- }
-
- .upgrade-overlay-title {
- border-bottom: 1px solid $grey;
- padding-bottom: $size-10;
-
- .icon {
- width: 32px;
-
- #edition-enterprise-hexagon {
- fill: $white;
- }
- }
- }
-
- .columns {
- margin-bottom: $size-4;
- margin-top: $size-4;
- }
-
- .column {
- display: flex;
-
- .box {
- border-radius: $radius;
- box-shadow: inset 0 0 0 1px $grey;
- width: 100%;
- }
- }
-
- li {
- list-style: inside disc;
- }
-}
diff --git a/ui/app/styles/core.scss b/ui/app/styles/core.scss
index 0eb83f62b4..654221e12b 100644
--- a/ui/app/styles/core.scss
+++ b/ui/app/styles/core.scss
@@ -81,7 +81,6 @@
@import './components/toolbar';
@import './components/tool-tip';
@import './components/unseal-warning';
-@import './components/upgrade-overlay';
@import './components/ui-wizard';
@import './components/vault-loading';
diff --git a/ui/app/templates/components/edition-badge.hbs b/ui/app/templates/components/edition-badge.hbs
deleted file mode 100644
index 28bf3e6b50..0000000000
--- a/ui/app/templates/components/edition-badge.hbs
+++ /dev/null
@@ -1,4 +0,0 @@
-{{#if icon}}
-
-{{/if}}
-{{edition}}
diff --git a/ui/app/templates/partials/status/cluster.hbs b/ui/app/templates/partials/status/cluster.hbs
index e3bf8b5fe3..abed797612 100644
--- a/ui/app/templates/partials/status/cluster.hbs
+++ b/ui/app/templates/partials/status/cluster.hbs
@@ -1,76 +1,67 @@