From a54603039d5c38fcc2c9468f3beb29e1c1c2aca0 Mon Sep 17 00:00:00 2001 From: Jim Kalafut Date: Tue, 8 Jan 2019 16:48:57 -0800 Subject: [PATCH] Run goimports across the repository (#6010) The result will still pass gofmtcheck and won't trigger additional changes if someone isn't using goimports, but it will avoid the piecemeal imports changes we've been seeing. --- api/client.go | 6 +++--- api/ssh_agent.go | 6 +++--- builtin/audit/syslog/backend.go | 2 +- builtin/credential/app-id/cmd/app-id/main.go | 4 ++-- builtin/credential/approle/cmd/approle/main.go | 2 +- builtin/credential/approle/path_role.go | 2 +- builtin/credential/approle/validation.go | 2 +- builtin/credential/aws/backend.go | 2 +- builtin/credential/aws/client.go | 2 +- builtin/credential/aws/cmd/aws/main.go | 4 ++-- builtin/credential/aws/path_login.go | 4 ++-- builtin/credential/aws/path_role.go | 2 +- builtin/credential/aws/path_role_tag.go | 2 +- builtin/credential/cert/backend_test.go | 2 +- builtin/credential/cert/cmd/cert/main.go | 2 +- builtin/credential/cert/path_certs.go | 2 +- builtin/credential/cert/path_login.go | 2 +- builtin/credential/github/backend.go | 2 +- builtin/credential/github/cmd/github/main.go | 2 +- builtin/credential/ldap/cmd/ldap/main.go | 2 +- builtin/credential/okta/cmd/okta/main.go | 2 +- builtin/credential/okta/path_config.go | 2 +- builtin/credential/radius/cmd/radius/main.go | 2 +- builtin/credential/userpass/cmd/userpass/main.go | 2 +- builtin/credential/userpass/path_users.go | 2 +- builtin/logical/aws/backend_test.go | 2 +- builtin/logical/aws/client.go | 2 +- builtin/logical/aws/cmd/aws/main.go | 2 +- builtin/logical/cassandra/cmd/cassandra/main.go | 2 +- builtin/logical/cassandra/path_creds_create.go | 2 +- builtin/logical/consul/cmd/consul/main.go | 2 +- builtin/logical/database/dbplugin/client.go | 2 +- builtin/logical/database/dbplugin/database.pb.go | 3 ++- builtin/logical/database/dbplugin/plugin.go | 2 +- builtin/logical/database/dbplugin/server.go | 2 +- builtin/logical/mongodb/backend.go | 2 +- builtin/logical/mongodb/cmd/mongodb/main.go | 2 +- builtin/logical/mongodb/path_config_connection.go | 2 +- builtin/logical/mongodb/path_creds_create.go | 2 +- builtin/logical/mongodb/secret_creds.go | 2 +- builtin/logical/mongodb/util.go | 2 +- builtin/logical/mssql/cmd/mssql/main.go | 2 +- builtin/logical/mssql/path_creds_create.go | 2 +- builtin/logical/mysql/cmd/mysql/main.go | 2 +- builtin/logical/mysql/path_role_create.go | 2 +- builtin/logical/nomad/cmd/nomad/main.go | 2 +- builtin/logical/pki/cert_util.go | 2 +- builtin/logical/pki/cmd/pki/main.go | 2 +- builtin/logical/postgresql/cmd/postgresql/main.go | 2 +- builtin/logical/postgresql/path_role_create.go | 2 +- builtin/logical/rabbitmq/backend.go | 4 ++-- builtin/logical/rabbitmq/backend_test.go | 2 +- builtin/logical/rabbitmq/cmd/rabbitmq/main.go | 2 +- builtin/logical/rabbitmq/path_config_connection.go | 2 +- builtin/logical/rabbitmq/path_role_create.go | 4 ++-- builtin/logical/ssh/cmd/ssh/main.go | 2 +- builtin/logical/ssh/path_creds_create.go | 2 +- builtin/logical/totp/cmd/totp/main.go | 2 +- builtin/logical/transit/cmd/transit/main.go | 2 +- command/agent.go | 2 +- command/agent/alicloud_end_to_end_test.go | 4 ++-- command/agent/auth/alicloud/alicloud.go | 2 +- command/agent/auth/approle/approle.go | 2 +- command/agent/auth/auth.go | 2 +- command/agent/auth/aws/aws.go | 8 ++++---- command/agent/auth/azure/azure.go | 2 +- command/agent/auth/gcp/gcp.go | 2 +- command/agent/auth/jwt/jwt.go | 2 +- command/agent/auth/kubernetes/kubernetes.go | 2 +- command/agent/aws_end_to_end_test.go | 4 ++-- command/agent/sink/file/file_sink_test.go | 2 +- command/agent/sink/sink.go | 2 +- command/command_test.go | 2 +- command/config/config.go | 2 +- command/server.go | 10 +++++----- command/server/config.go | 2 +- command/token/helper_internal.go | 2 +- helper/cidrutil/cidr.go | 2 +- helper/cidrutil/cidr_test.go | 2 +- helper/forwarding/types.pb.go | 3 ++- helper/identity/mfa/types.pb.go | 3 ++- helper/identity/types.pb.go | 3 ++- helper/ldaputil/client.go | 4 ++-- helper/mfa/duo/path_duo_access.go | 2 +- helper/pgpkeys/keybase.go | 2 +- helper/salt/salt.go | 2 +- helper/salt/salt_test.go | 2 +- helper/storagepacker/types.pb.go | 3 ++- http/handler.go | 2 +- http/handler_test.go | 2 +- http/http_test.go | 2 +- http/logical.go | 2 +- logical/auth.go | 2 +- logical/framework/backend.go | 2 +- logical/framework/wal.go | 2 +- logical/identity.pb.go | 3 ++- logical/plugin.pb.go | 3 ++- logical/plugin/backend.go | 2 +- logical/plugin/backend_client.go | 2 +- logical/plugin/backend_server.go | 5 ++--- logical/plugin/grpc_backend_client.go | 2 +- logical/plugin/logger_test.go | 3 +-- logical/plugin/pb/backend.pb.go | 3 ++- logical/plugin/plugin.go | 2 +- logical/plugin/serve.go | 2 +- logical/testing.go | 3 ++- physical/alicloudoss/alicloudoss.go | 2 +- physical/azure/azure.go | 2 +- physical/cache.go | 2 +- physical/cassandra/cassandra.go | 2 +- physical/cockroachdb/cockroachdb.go | 2 +- physical/consul/consul.go | 2 +- physical/couchdb/couchdb.go | 2 +- physical/foundationdb/foundationdb.go | 4 ++-- physical/foundationdb/foundationdb_test.go | 2 +- physical/gcs/gcs.go | 2 +- physical/inmem/inmem.go | 2 +- physical/manta/manta.go | 4 ++-- physical/manta/manta_test.go | 2 +- physical/mssql/mssql.go | 2 +- physical/mysql/mysql.go | 2 +- physical/postgresql/postgresql.go | 4 ++-- physical/s3/s3.go | 2 +- physical/swift/swift.go | 4 ++-- physical/swift/swift_test.go | 2 +- physical/types.pb.go | 3 ++- plugins/database/mongodb/connection_producer.go | 2 +- plugins/database/mongodb/mongodb.go | 2 +- vault/audit.go | 2 +- vault/audit_test.go | 2 +- vault/auth.go | 2 +- vault/barrier_aes_gcm.go | 2 +- vault/cluster.go | 2 +- vault/core.go | 8 ++++---- vault/core_test.go | 2 +- vault/expiration_test.go | 2 +- vault/generate_root.go | 2 +- vault/logical_cubbyhole_test.go | 2 +- vault/logical_system.go | 4 ++-- vault/mount.go | 2 +- vault/policy.go | 2 +- vault/policy_store.go | 4 ++-- vault/rekey.go | 2 +- vault/request_forwarding_service.pb.go | 3 ++- vault/request_handling.go | 4 ++-- vault/request_handling_test.go | 2 +- vault/rollback.go | 2 +- vault/rollback_test.go | 2 +- vault/router.go | 4 ++-- vault/router_test.go | 2 +- vault/seal_testing.go | 2 +- vault/seal_testing_util.go | 2 +- vault/testing.go | 4 ++-- vault/testing_util.go | 2 +- vault/token_store_test.go | 2 +- 155 files changed, 198 insertions(+), 189 deletions(-) diff --git a/api/client.go b/api/client.go index d3acaea9da..136b730a5d 100644 --- a/api/client.go +++ b/api/client.go @@ -16,9 +16,9 @@ import ( "unicode" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" - "github.com/hashicorp/go-retryablehttp" - "github.com/hashicorp/go-rootcerts" + cleanhttp "github.com/hashicorp/go-cleanhttp" + retryablehttp "github.com/hashicorp/go-retryablehttp" + rootcerts "github.com/hashicorp/go-rootcerts" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/parseutil" "golang.org/x/net/http2" diff --git a/api/ssh_agent.go b/api/ssh_agent.go index 1dd681a5d4..b8e82224ca 100644 --- a/api/ssh_agent.go +++ b/api/ssh_agent.go @@ -9,9 +9,9 @@ import ( "os" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" - "github.com/hashicorp/go-multierror" - "github.com/hashicorp/go-rootcerts" + cleanhttp "github.com/hashicorp/go-cleanhttp" + multierror "github.com/hashicorp/go-multierror" + rootcerts "github.com/hashicorp/go-rootcerts" "github.com/hashicorp/hcl" "github.com/hashicorp/hcl/hcl/ast" "github.com/hashicorp/vault/helper/hclutil" diff --git a/builtin/audit/syslog/backend.go b/builtin/audit/syslog/backend.go index ed707217a1..6f388bdcf4 100644 --- a/builtin/audit/syslog/backend.go +++ b/builtin/audit/syslog/backend.go @@ -7,7 +7,7 @@ import ( "strconv" "sync" - "github.com/hashicorp/go-syslog" + gsyslog "github.com/hashicorp/go-syslog" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/salt" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/app-id/cmd/app-id/main.go b/builtin/credential/app-id/cmd/app-id/main.go index 42af2d44f9..f7b95a82a9 100644 --- a/builtin/credential/app-id/cmd/app-id/main.go +++ b/builtin/credential/app-id/cmd/app-id/main.go @@ -3,8 +3,8 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/vault/builtin/credential/app-id" + hclog "github.com/hashicorp/go-hclog" + appId "github.com/hashicorp/vault/builtin/credential/app-id" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" ) diff --git a/builtin/credential/approle/cmd/approle/main.go b/builtin/credential/approle/cmd/approle/main.go index 480f06cd6c..b6d9db09c8 100644 --- a/builtin/credential/approle/cmd/approle/main.go +++ b/builtin/credential/approle/cmd/approle/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/approle" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/approle/path_role.go b/builtin/credential/approle/path_role.go index d07cd61829..058e41e2d9 100644 --- a/builtin/credential/approle/path_role.go +++ b/builtin/credential/approle/path_role.go @@ -8,7 +8,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/cidrutil" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/locksutil" diff --git a/builtin/credential/approle/validation.go b/builtin/credential/approle/validation.go index 99e9bddc39..fd3a079f73 100644 --- a/builtin/credential/approle/validation.go +++ b/builtin/credential/approle/validation.go @@ -9,7 +9,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/cidrutil" "github.com/hashicorp/vault/helper/locksutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/aws/backend.go b/builtin/credential/aws/backend.go index 35cd49a72c..d54fe9df96 100644 --- a/builtin/credential/aws/backend.go +++ b/builtin/credential/aws/backend.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "github.com/patrickmn/go-cache" + cache "github.com/patrickmn/go-cache" ) func Factory(ctx context.Context, conf *logical.BackendConfig) (logical.Backend, error) { diff --git a/builtin/credential/aws/client.go b/builtin/credential/aws/client.go index 2d09bab30c..b8e0727d05 100644 --- a/builtin/credential/aws/client.go +++ b/builtin/credential/aws/client.go @@ -11,7 +11,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/aws/aws-sdk-go/service/sts" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/awsutil" "github.com/hashicorp/vault/logical" ) diff --git a/builtin/credential/aws/cmd/aws/main.go b/builtin/credential/aws/cmd/aws/main.go index 7ce33a7596..a9438ac4ee 100644 --- a/builtin/credential/aws/cmd/aws/main.go +++ b/builtin/credential/aws/cmd/aws/main.go @@ -3,8 +3,8 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/vault/builtin/credential/aws" + hclog "github.com/hashicorp/go-hclog" + awsauth "github.com/hashicorp/vault/builtin/credential/aws" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" ) diff --git a/builtin/credential/aws/path_login.go b/builtin/credential/aws/path_login.go index 0819a7b273..32f0993f2f 100644 --- a/builtin/credential/aws/path_login.go +++ b/builtin/credential/aws/path_login.go @@ -20,8 +20,8 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/fullsailor/pkcs7" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" - "github.com/hashicorp/go-uuid" + cleanhttp "github.com/hashicorp/go-cleanhttp" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/awsutil" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/strutil" diff --git a/builtin/credential/aws/path_role.go b/builtin/credential/aws/path_role.go index fe7d76c2e2..a79154e5a6 100644 --- a/builtin/credential/aws/path_role.go +++ b/builtin/credential/aws/path_role.go @@ -7,7 +7,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/policyutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/aws/path_role_tag.go b/builtin/credential/aws/path_role_tag.go index 48f44caf6c..a155bebb97 100644 --- a/builtin/credential/aws/path_role_tag.go +++ b/builtin/credential/aws/path_role_tag.go @@ -11,7 +11,7 @@ import ( "strings" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/policyutil" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/cert/backend_test.go b/builtin/credential/cert/backend_test.go index eb95b6c045..a6f3693be6 100644 --- a/builtin/credential/cert/backend_test.go +++ b/builtin/credential/cert/backend_test.go @@ -26,7 +26,7 @@ import ( "github.com/hashicorp/vault/api" vaulthttp "github.com/hashicorp/vault/http" - "github.com/hashicorp/go-rootcerts" + rootcerts "github.com/hashicorp/go-rootcerts" "github.com/hashicorp/vault/builtin/logical/pki" "github.com/hashicorp/vault/helper/certutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/cert/cmd/cert/main.go b/builtin/credential/cert/cmd/cert/main.go index 6668e0b0c6..1c7dad47d2 100644 --- a/builtin/credential/cert/cmd/cert/main.go +++ b/builtin/credential/cert/cmd/cert/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/cert" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/cert/path_certs.go b/builtin/credential/cert/path_certs.go index 1bf3c1ca2d..292b3cedb6 100644 --- a/builtin/credential/cert/path_certs.go +++ b/builtin/credential/cert/path_certs.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/hashicorp/go-sockaddr" + sockaddr "github.com/hashicorp/go-sockaddr" "github.com/hashicorp/vault/helper/parseutil" "github.com/hashicorp/vault/helper/policyutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/credential/cert/path_login.go b/builtin/credential/cert/path_login.go index c85502e50d..4ef6cefe1c 100644 --- a/builtin/credential/cert/path_login.go +++ b/builtin/credential/cert/path_login.go @@ -18,7 +18,7 @@ import ( "github.com/hashicorp/vault/logical/framework" "github.com/hashicorp/vault/helper/cidrutil" - "github.com/ryanuber/go-glob" + glob "github.com/ryanuber/go-glob" ) // ParsedCert is a certificate that has been configured as trusted diff --git a/builtin/credential/github/backend.go b/builtin/credential/github/backend.go index 5f2c131715..b0ad6bb404 100644 --- a/builtin/credential/github/backend.go +++ b/builtin/credential/github/backend.go @@ -4,7 +4,7 @@ import ( "context" "github.com/google/go-github/github" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/mfa" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" diff --git a/builtin/credential/github/cmd/github/main.go b/builtin/credential/github/cmd/github/main.go index 1056ccfea4..76998a175c 100644 --- a/builtin/credential/github/cmd/github/main.go +++ b/builtin/credential/github/cmd/github/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/github" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/ldap/cmd/ldap/main.go b/builtin/credential/ldap/cmd/ldap/main.go index 19769e6b6e..1f46a7b37c 100644 --- a/builtin/credential/ldap/cmd/ldap/main.go +++ b/builtin/credential/ldap/cmd/ldap/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/ldap" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/okta/cmd/okta/main.go b/builtin/credential/okta/cmd/okta/main.go index e21debe5c1..19d7f60748 100644 --- a/builtin/credential/okta/cmd/okta/main.go +++ b/builtin/credential/okta/cmd/okta/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/okta" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/okta/path_config.go b/builtin/credential/okta/path_config.go index e110837f22..284a8dcc55 100644 --- a/builtin/credential/okta/path_config.go +++ b/builtin/credential/okta/path_config.go @@ -8,7 +8,7 @@ import ( "time" "github.com/chrismalek/oktasdk-go/okta" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" ) diff --git a/builtin/credential/radius/cmd/radius/main.go b/builtin/credential/radius/cmd/radius/main.go index 316da3760a..b79910766d 100644 --- a/builtin/credential/radius/cmd/radius/main.go +++ b/builtin/credential/radius/cmd/radius/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/radius" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/userpass/cmd/userpass/main.go b/builtin/credential/userpass/cmd/userpass/main.go index 6fddd3163a..e5fd68293f 100644 --- a/builtin/credential/userpass/cmd/userpass/main.go +++ b/builtin/credential/userpass/cmd/userpass/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/credential/userpass" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/credential/userpass/path_users.go b/builtin/credential/userpass/path_users.go index 0e8eee886f..b9603ee7a6 100644 --- a/builtin/credential/userpass/path_users.go +++ b/builtin/credential/userpass/path_users.go @@ -6,7 +6,7 @@ import ( "strings" "time" - "github.com/hashicorp/go-sockaddr" + sockaddr "github.com/hashicorp/go-sockaddr" "github.com/hashicorp/vault/helper/parseutil" "github.com/hashicorp/vault/helper/policyutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/logical/aws/backend_test.go b/builtin/logical/aws/backend_test.go index 1002cc4d43..59a3e756b4 100644 --- a/builtin/logical/aws/backend_test.go +++ b/builtin/logical/aws/backend_test.go @@ -20,7 +20,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/aws/aws-sdk-go/service/iam/iamiface" "github.com/aws/aws-sdk-go/service/sts" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/testhelpers" "github.com/hashicorp/vault/logical" logicaltest "github.com/hashicorp/vault/logical/testing" diff --git a/builtin/logical/aws/client.go b/builtin/logical/aws/client.go index 8c56b8d1b2..711063de98 100644 --- a/builtin/logical/aws/client.go +++ b/builtin/logical/aws/client.go @@ -10,7 +10,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/aws/aws-sdk-go/service/sts" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/awsutil" "github.com/hashicorp/vault/logical" ) diff --git a/builtin/logical/aws/cmd/aws/main.go b/builtin/logical/aws/cmd/aws/main.go index a2deb3c90d..fc3487ee20 100644 --- a/builtin/logical/aws/cmd/aws/main.go +++ b/builtin/logical/aws/cmd/aws/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/aws" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/cassandra/cmd/cassandra/main.go b/builtin/logical/cassandra/cmd/cassandra/main.go index bcc51f34b6..92e7b0267e 100644 --- a/builtin/logical/cassandra/cmd/cassandra/main.go +++ b/builtin/logical/cassandra/cmd/cassandra/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/cassandra" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/cassandra/path_creds_create.go b/builtin/logical/cassandra/path_creds_create.go index 896176fb76..2ac8a10de6 100644 --- a/builtin/logical/cassandra/path_creds_create.go +++ b/builtin/logical/cassandra/path_creds_create.go @@ -7,7 +7,7 @@ import ( "time" "github.com/gocql/gocql" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" diff --git a/builtin/logical/consul/cmd/consul/main.go b/builtin/logical/consul/cmd/consul/main.go index 11518b2fca..ea47f673a3 100644 --- a/builtin/logical/consul/cmd/consul/main.go +++ b/builtin/logical/consul/cmd/consul/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/consul" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/database/dbplugin/client.go b/builtin/logical/database/dbplugin/client.go index ea71a6f7d1..cbd3560fb2 100644 --- a/builtin/logical/database/dbplugin/client.go +++ b/builtin/logical/database/dbplugin/client.go @@ -6,7 +6,7 @@ import ( "sync" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/pluginutil" ) diff --git a/builtin/logical/database/dbplugin/database.pb.go b/builtin/logical/database/dbplugin/database.pb.go index 3da4421753..8e452430fb 100644 --- a/builtin/logical/database/dbplugin/database.pb.go +++ b/builtin/logical/database/dbplugin/database.pb.go @@ -5,9 +5,10 @@ package dbplugin import ( fmt "fmt" + math "math" + proto "github.com/golang/protobuf/proto" timestamp "github.com/golang/protobuf/ptypes/timestamp" - math "math" ) import ( diff --git a/builtin/logical/database/dbplugin/plugin.go b/builtin/logical/database/dbplugin/plugin.go index 918b98b388..9eabcf8583 100644 --- a/builtin/logical/database/dbplugin/plugin.go +++ b/builtin/logical/database/dbplugin/plugin.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/pluginutil" ) diff --git a/builtin/logical/database/dbplugin/server.go b/builtin/logical/database/dbplugin/server.go index 9f17049354..7a60400584 100644 --- a/builtin/logical/database/dbplugin/server.go +++ b/builtin/logical/database/dbplugin/server.go @@ -3,7 +3,7 @@ package dbplugin import ( "crypto/tls" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/pluginutil" ) diff --git a/builtin/logical/mongodb/backend.go b/builtin/logical/mongodb/backend.go index db74052829..74f44b813c 100644 --- a/builtin/logical/mongodb/backend.go +++ b/builtin/logical/mongodb/backend.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) func Factory(ctx context.Context, conf *logical.BackendConfig) (logical.Backend, error) { diff --git a/builtin/logical/mongodb/cmd/mongodb/main.go b/builtin/logical/mongodb/cmd/mongodb/main.go index bda1424286..c1e41abfbd 100644 --- a/builtin/logical/mongodb/cmd/mongodb/main.go +++ b/builtin/logical/mongodb/cmd/mongodb/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/mongodb" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/mongodb/path_config_connection.go b/builtin/logical/mongodb/path_config_connection.go index ea33c432c3..19ec2032ea 100644 --- a/builtin/logical/mongodb/path_config_connection.go +++ b/builtin/logical/mongodb/path_config_connection.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) func pathConfigConnection(b *backend) *framework.Path { diff --git a/builtin/logical/mongodb/path_creds_create.go b/builtin/logical/mongodb/path_creds_create.go index ea24f45056..35a5e84b60 100644 --- a/builtin/logical/mongodb/path_creds_create.go +++ b/builtin/logical/mongodb/path_creds_create.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" ) diff --git a/builtin/logical/mongodb/secret_creds.go b/builtin/logical/mongodb/secret_creds.go index bde31c6819..e0fd590f19 100644 --- a/builtin/logical/mongodb/secret_creds.go +++ b/builtin/logical/mongodb/secret_creds.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) const SecretCredsType = "creds" diff --git a/builtin/logical/mongodb/util.go b/builtin/logical/mongodb/util.go index 209feb0f75..1880bbd40b 100644 --- a/builtin/logical/mongodb/util.go +++ b/builtin/logical/mongodb/util.go @@ -9,7 +9,7 @@ import ( "strings" "time" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) // Unfortunately, mgo doesn't support the ssl parameter in its MongoDB URI parsing logic, so we have to handle that diff --git a/builtin/logical/mssql/cmd/mssql/main.go b/builtin/logical/mssql/cmd/mssql/main.go index 65980155f8..3915e1fbc6 100644 --- a/builtin/logical/mssql/cmd/mssql/main.go +++ b/builtin/logical/mssql/cmd/mssql/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/mssql" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/mssql/path_creds_create.go b/builtin/logical/mssql/path_creds_create.go index 1a954c87b4..f6c7a7e444 100644 --- a/builtin/logical/mssql/path_creds_create.go +++ b/builtin/logical/mssql/path_creds_create.go @@ -5,7 +5,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/dbtxn" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/logical/mysql/cmd/mysql/main.go b/builtin/logical/mysql/cmd/mysql/main.go index 127f861781..88385c3447 100644 --- a/builtin/logical/mysql/cmd/mysql/main.go +++ b/builtin/logical/mysql/cmd/mysql/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/mysql" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/mysql/path_role_create.go b/builtin/logical/mysql/path_role_create.go index 135587575d..8623685d0f 100644 --- a/builtin/logical/mysql/path_role_create.go +++ b/builtin/logical/mysql/path_role_create.go @@ -5,7 +5,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/dbtxn" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/logical/nomad/cmd/nomad/main.go b/builtin/logical/nomad/cmd/nomad/main.go index f28b71ecd6..2e7000de3f 100644 --- a/builtin/logical/nomad/cmd/nomad/main.go +++ b/builtin/logical/nomad/cmd/nomad/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/nomad" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/pki/cert_util.go b/builtin/logical/pki/cert_util.go index f45c766fb2..9dd422283e 100644 --- a/builtin/logical/pki/cert_util.go +++ b/builtin/logical/pki/cert_util.go @@ -27,7 +27,7 @@ import ( "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "github.com/ryanuber/go-glob" + glob "github.com/ryanuber/go-glob" "golang.org/x/crypto/cryptobyte" cbbasn1 "golang.org/x/crypto/cryptobyte/asn1" "golang.org/x/net/idna" diff --git a/builtin/logical/pki/cmd/pki/main.go b/builtin/logical/pki/cmd/pki/main.go index 7dd5af5983..db530f7299 100644 --- a/builtin/logical/pki/cmd/pki/main.go +++ b/builtin/logical/pki/cmd/pki/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/pki" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/postgresql/cmd/postgresql/main.go b/builtin/logical/postgresql/cmd/postgresql/main.go index e7f7d78c0f..19f89f6895 100644 --- a/builtin/logical/postgresql/cmd/postgresql/main.go +++ b/builtin/logical/postgresql/cmd/postgresql/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/postgresql" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/postgresql/path_role_create.go b/builtin/logical/postgresql/path_role_create.go index 113e3ab896..542bc3fa66 100644 --- a/builtin/logical/postgresql/path_role_create.go +++ b/builtin/logical/postgresql/path_role_create.go @@ -6,7 +6,7 @@ import ( "strings" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/dbtxn" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/logical" diff --git a/builtin/logical/rabbitmq/backend.go b/builtin/logical/rabbitmq/backend.go index 8543297768..1cb911e9d3 100644 --- a/builtin/logical/rabbitmq/backend.go +++ b/builtin/logical/rabbitmq/backend.go @@ -6,10 +6,10 @@ import ( "strings" "sync" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "github.com/michaelklishin/rabbit-hole" + rabbithole "github.com/michaelklishin/rabbit-hole" ) // Factory creates and configures the backend diff --git a/builtin/logical/rabbitmq/backend_test.go b/builtin/logical/rabbitmq/backend_test.go index e374249878..27b3a6c940 100644 --- a/builtin/logical/rabbitmq/backend_test.go +++ b/builtin/logical/rabbitmq/backend_test.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/logical" logicaltest "github.com/hashicorp/vault/logical/testing" - "github.com/michaelklishin/rabbit-hole" + rabbithole "github.com/michaelklishin/rabbit-hole" "github.com/mitchellh/mapstructure" "github.com/ory/dockertest" ) diff --git a/builtin/logical/rabbitmq/cmd/rabbitmq/main.go b/builtin/logical/rabbitmq/cmd/rabbitmq/main.go index 259c4aecac..950a573f32 100644 --- a/builtin/logical/rabbitmq/cmd/rabbitmq/main.go +++ b/builtin/logical/rabbitmq/cmd/rabbitmq/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/rabbitmq" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/rabbitmq/path_config_connection.go b/builtin/logical/rabbitmq/path_config_connection.go index db2fb3c782..55b6ac3ca9 100644 --- a/builtin/logical/rabbitmq/path_config_connection.go +++ b/builtin/logical/rabbitmq/path_config_connection.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "github.com/michaelklishin/rabbit-hole" + rabbithole "github.com/michaelklishin/rabbit-hole" ) func pathConfigConnection(b *backend) *framework.Path { diff --git a/builtin/logical/rabbitmq/path_role_create.go b/builtin/logical/rabbitmq/path_role_create.go index 6cbced5ac5..78764472a2 100644 --- a/builtin/logical/rabbitmq/path_role_create.go +++ b/builtin/logical/rabbitmq/path_role_create.go @@ -6,10 +6,10 @@ import ( "github.com/hashicorp/errwrap" multierror "github.com/hashicorp/go-multierror" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" - "github.com/michaelklishin/rabbit-hole" + rabbithole "github.com/michaelklishin/rabbit-hole" ) func pathCreds(b *backend) *framework.Path { diff --git a/builtin/logical/ssh/cmd/ssh/main.go b/builtin/logical/ssh/cmd/ssh/main.go index 0886a86234..621430b717 100644 --- a/builtin/logical/ssh/cmd/ssh/main.go +++ b/builtin/logical/ssh/cmd/ssh/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/ssh" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/ssh/path_creds_create.go b/builtin/logical/ssh/path_creds_create.go index 004fbe4e6d..899a7eb3c9 100644 --- a/builtin/logical/ssh/path_creds_create.go +++ b/builtin/logical/ssh/path_creds_create.go @@ -7,7 +7,7 @@ import ( "strings" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" ) diff --git a/builtin/logical/totp/cmd/totp/main.go b/builtin/logical/totp/cmd/totp/main.go index 1a561e07c8..a795245b19 100644 --- a/builtin/logical/totp/cmd/totp/main.go +++ b/builtin/logical/totp/cmd/totp/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/totp" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/builtin/logical/transit/cmd/transit/main.go b/builtin/logical/transit/cmd/transit/main.go index 20235f3172..9c9dc69534 100644 --- a/builtin/logical/transit/cmd/transit/main.go +++ b/builtin/logical/transit/cmd/transit/main.go @@ -3,7 +3,7 @@ package main import ( "os" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/builtin/logical/transit" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical/plugin" diff --git a/command/agent.go b/command/agent.go index c8f254e57f..92c93c70c2 100644 --- a/command/agent.go +++ b/command/agent.go @@ -26,7 +26,7 @@ import ( "github.com/hashicorp/vault/command/agent/config" "github.com/hashicorp/vault/command/agent/sink" "github.com/hashicorp/vault/command/agent/sink/file" - "github.com/hashicorp/vault/helper/gated-writer" + gatedwriter "github.com/hashicorp/vault/helper/gated-writer" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/version" ) diff --git a/command/agent/alicloud_end_to_end_test.go b/command/agent/alicloud_end_to_end_test.go index f3b9ebb1f8..3a35699116 100644 --- a/command/agent/alicloud_end_to_end_test.go +++ b/command/agent/alicloud_end_to_end_test.go @@ -12,8 +12,8 @@ import ( "github.com/aliyun/alibaba-cloud-sdk-go/sdk/auth/credentials" "github.com/aliyun/alibaba-cloud-sdk-go/sdk/auth/credentials/providers" "github.com/aliyun/alibaba-cloud-sdk-go/services/sts" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + hclog "github.com/hashicorp/go-hclog" + uuid "github.com/hashicorp/go-uuid" vaultalicloud "github.com/hashicorp/vault-plugin-auth-alicloud" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" diff --git a/command/agent/auth/alicloud/alicloud.go b/command/agent/auth/alicloud/alicloud.go index 7c38a40c2b..680a1ddbab 100644 --- a/command/agent/auth/alicloud/alicloud.go +++ b/command/agent/auth/alicloud/alicloud.go @@ -10,7 +10,7 @@ import ( aliCloudAuth "github.com/aliyun/alibaba-cloud-sdk-go/sdk/auth" "github.com/aliyun/alibaba-cloud-sdk-go/sdk/auth/credentials/providers" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault-plugin-auth-alicloud/tools" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" diff --git a/command/agent/auth/approle/approle.go b/command/agent/auth/approle/approle.go index a4aa85e330..6609a39903 100644 --- a/command/agent/auth/approle/approle.go +++ b/command/agent/auth/approle/approle.go @@ -9,7 +9,7 @@ import ( "strings" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" "github.com/hashicorp/vault/helper/parseutil" diff --git a/command/agent/auth/auth.go b/command/agent/auth/auth.go index a706468e57..73ccf6ea8e 100644 --- a/command/agent/auth/auth.go +++ b/command/agent/auth/auth.go @@ -5,7 +5,7 @@ import ( "math/rand" "time" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/helper/jsonutil" ) diff --git a/command/agent/auth/aws/aws.go b/command/agent/auth/aws/aws.go index c18cd852d3..c92f744183 100644 --- a/command/agent/auth/aws/aws.go +++ b/command/agent/auth/aws/aws.go @@ -13,11 +13,11 @@ import ( "github.com/aws/aws-sdk-go/aws/credentials" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + cleanhttp "github.com/hashicorp/go-cleanhttp" + hclog "github.com/hashicorp/go-hclog" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/api" - "github.com/hashicorp/vault/builtin/credential/aws" + awsauth "github.com/hashicorp/vault/builtin/credential/aws" "github.com/hashicorp/vault/command/agent/auth" ) diff --git a/command/agent/auth/azure/azure.go b/command/agent/auth/azure/azure.go index 7d468d56df..8e74c613c3 100644 --- a/command/agent/auth/azure/azure.go +++ b/command/agent/auth/azure/azure.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/errwrap" cleanhttp "github.com/hashicorp/go-cleanhttp" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" "github.com/hashicorp/vault/helper/jsonutil" diff --git a/command/agent/auth/gcp/gcp.go b/command/agent/auth/gcp/gcp.go index 75956633c5..48e251be62 100644 --- a/command/agent/auth/gcp/gcp.go +++ b/command/agent/auth/gcp/gcp.go @@ -12,7 +12,7 @@ import ( "github.com/hashicorp/errwrap" cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/go-gcp-common/gcputil" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" "github.com/hashicorp/vault/helper/parseutil" diff --git a/command/agent/auth/jwt/jwt.go b/command/agent/auth/jwt/jwt.go index 06e640ebd2..e77265536a 100644 --- a/command/agent/auth/jwt/jwt.go +++ b/command/agent/auth/jwt/jwt.go @@ -10,7 +10,7 @@ import ( "sync/atomic" "time" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" ) diff --git a/command/agent/auth/kubernetes/kubernetes.go b/command/agent/auth/kubernetes/kubernetes.go index 2551dc316f..21542bfc66 100644 --- a/command/agent/auth/kubernetes/kubernetes.go +++ b/command/agent/auth/kubernetes/kubernetes.go @@ -10,7 +10,7 @@ import ( "strings" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/command/agent/auth" ) diff --git a/command/agent/aws_end_to_end_test.go b/command/agent/aws_end_to_end_test.go index 6f02fff5f5..5b9cbb9167 100644 --- a/command/agent/aws_end_to_end_test.go +++ b/command/agent/aws_end_to_end_test.go @@ -12,8 +12,8 @@ import ( "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/session" "github.com/aws/aws-sdk-go/service/sts" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + hclog "github.com/hashicorp/go-hclog" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/api" vaultaws "github.com/hashicorp/vault/builtin/credential/aws" "github.com/hashicorp/vault/command/agent/auth" diff --git a/command/agent/sink/file/file_sink_test.go b/command/agent/sink/file/file_sink_test.go index 6cc4c54f69..fc6649f23e 100644 --- a/command/agent/sink/file/file_sink_test.go +++ b/command/agent/sink/file/file_sink_test.go @@ -8,7 +8,7 @@ import ( "testing" hclog "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/command/agent/sink" "github.com/hashicorp/vault/helper/logging" ) diff --git a/command/agent/sink/sink.go b/command/agent/sink/sink.go index 25d1977dd1..09e42c0af4 100644 --- a/command/agent/sink/sink.go +++ b/command/agent/sink/sink.go @@ -10,7 +10,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-hclog" + hclog "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/helper/dhutil" "github.com/hashicorp/vault/helper/jsonutil" diff --git a/command/command_test.go b/command/command_test.go index a2ae19ec9c..861598e5b1 100644 --- a/command/command_test.go +++ b/command/command_test.go @@ -10,7 +10,7 @@ import ( "time" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/vault-plugin-secrets-kv" + kv "github.com/hashicorp/vault-plugin-secrets-kv" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/builtin/logical/pki" diff --git a/command/config/config.go b/command/config/config.go index d9ed7b6922..188924236d 100644 --- a/command/config/config.go +++ b/command/config/config.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/hcl" "github.com/hashicorp/hcl/hcl/ast" "github.com/hashicorp/vault/helper/hclutil" - "github.com/mitchellh/go-homedir" + homedir "github.com/mitchellh/go-homedir" ) const ( diff --git a/command/server.go b/command/server.go index f2a7c12aaf..f07b6d129e 100644 --- a/command/server.go +++ b/command/server.go @@ -20,18 +20,18 @@ import ( "sync" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/armon/go-metrics/circonus" "github.com/armon/go-metrics/datadog" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-multierror" - "github.com/hashicorp/go-sockaddr" + multierror "github.com/hashicorp/go-multierror" + sockaddr "github.com/hashicorp/go-sockaddr" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/command/server" serverseal "github.com/hashicorp/vault/command/server/seal" "github.com/hashicorp/vault/helper/builtinplugins" - "github.com/hashicorp/vault/helper/gated-writer" + gatedwriter "github.com/hashicorp/vault/helper/gated-writer" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/helper/mlock" @@ -1018,7 +1018,7 @@ CLUSTER_SYNTHESIS_COMPLETE: c.UI.Warn("You may need to set the following environment variable:") c.UI.Warn("") - endpointURL := "http://"+config.Listeners[0].Config["address"].(string) + endpointURL := "http://" + config.Listeners[0].Config["address"].(string) if runtime.GOOS == "windows" { c.UI.Warn("PowerShell:") c.UI.Warn(fmt.Sprintf(" $env:VAULT_ADDR=\"%s\"", endpointURL)) diff --git a/command/server/config.go b/command/server/config.go index 69c89489cc..1b0b7fb3a1 100644 --- a/command/server/config.go +++ b/command/server/config.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-multierror" + multierror "github.com/hashicorp/go-multierror" "github.com/hashicorp/hcl" "github.com/hashicorp/hcl/hcl/ast" "github.com/hashicorp/vault/helper/parseutil" diff --git a/command/token/helper_internal.go b/command/token/helper_internal.go index f3f527be08..01cec1c629 100644 --- a/command/token/helper_internal.go +++ b/command/token/helper_internal.go @@ -7,7 +7,7 @@ import ( "os" "strings" - "github.com/mitchellh/go-homedir" + homedir "github.com/mitchellh/go-homedir" ) var _ TokenHelper = (*InternalTokenHelper)(nil) diff --git a/helper/cidrutil/cidr.go b/helper/cidrutil/cidr.go index 6ecdba71ad..23c458fc37 100644 --- a/helper/cidrutil/cidr.go +++ b/helper/cidrutil/cidr.go @@ -6,7 +6,7 @@ import ( "strings" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-sockaddr" + sockaddr "github.com/hashicorp/go-sockaddr" "github.com/hashicorp/vault/helper/strutil" ) diff --git a/helper/cidrutil/cidr_test.go b/helper/cidrutil/cidr_test.go index c961ff069f..6a8662cdf1 100644 --- a/helper/cidrutil/cidr_test.go +++ b/helper/cidrutil/cidr_test.go @@ -3,7 +3,7 @@ package cidrutil import ( "testing" - "github.com/hashicorp/go-sockaddr" + sockaddr "github.com/hashicorp/go-sockaddr" ) func TestCIDRUtil_IPBelongsToCIDR(t *testing.T) { diff --git a/helper/forwarding/types.pb.go b/helper/forwarding/types.pb.go index e7b104c6a7..44342b2095 100644 --- a/helper/forwarding/types.pb.go +++ b/helper/forwarding/types.pb.go @@ -5,8 +5,9 @@ package forwarding import ( fmt "fmt" - proto "github.com/golang/protobuf/proto" math "math" + + proto "github.com/golang/protobuf/proto" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/helper/identity/mfa/types.pb.go b/helper/identity/mfa/types.pb.go index 5c1855e7fb..9fcc7ab7f7 100644 --- a/helper/identity/mfa/types.pb.go +++ b/helper/identity/mfa/types.pb.go @@ -6,8 +6,9 @@ package mfa import ( fmt "fmt" - proto "github.com/golang/protobuf/proto" math "math" + + proto "github.com/golang/protobuf/proto" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/helper/identity/types.pb.go b/helper/identity/types.pb.go index 28263c8964..8b417e8d46 100644 --- a/helper/identity/types.pb.go +++ b/helper/identity/types.pb.go @@ -5,10 +5,11 @@ package identity import ( fmt "fmt" + math "math" + proto "github.com/golang/protobuf/proto" timestamp "github.com/golang/protobuf/ptypes/timestamp" mfa "github.com/hashicorp/vault/helper/identity/mfa" - math "math" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/helper/ldaputil/client.go b/helper/ldaputil/client.go index 130b17e92d..9556fe2f58 100644 --- a/helper/ldaputil/client.go +++ b/helper/ldaputil/client.go @@ -14,8 +14,8 @@ import ( "github.com/go-ldap/ldap" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-multierror" + hclog "github.com/hashicorp/go-hclog" + multierror "github.com/hashicorp/go-multierror" "github.com/hashicorp/vault/helper/tlsutil" ) diff --git a/helper/mfa/duo/path_duo_access.go b/helper/mfa/duo/path_duo_access.go index 04ed79a25b..5a50c69722 100644 --- a/helper/mfa/duo/path_duo_access.go +++ b/helper/mfa/duo/path_duo_access.go @@ -5,7 +5,7 @@ import ( "fmt" "net/url" - "github.com/duosecurity/duo_api_golang" + duoapi "github.com/duosecurity/duo_api_golang" "github.com/duosecurity/duo_api_golang/authapi" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/framework" diff --git a/helper/pgpkeys/keybase.go b/helper/pgpkeys/keybase.go index eba0677623..cba9a713b6 100644 --- a/helper/pgpkeys/keybase.go +++ b/helper/pgpkeys/keybase.go @@ -7,7 +7,7 @@ import ( "strings" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/jsonutil" "github.com/keybase/go-crypto/openpgp" ) diff --git a/helper/salt/salt.go b/helper/salt/salt.go index 4fd5620583..7d7729a8a2 100644 --- a/helper/salt/salt.go +++ b/helper/salt/salt.go @@ -10,7 +10,7 @@ import ( "hash" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" ) diff --git a/helper/salt/salt_test.go b/helper/salt/salt_test.go index 25359c08d1..f2798cecff 100644 --- a/helper/salt/salt_test.go +++ b/helper/salt/salt_test.go @@ -6,7 +6,7 @@ import ( "crypto/sha256" "testing" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" ) diff --git a/helper/storagepacker/types.pb.go b/helper/storagepacker/types.pb.go index 6319feef6c..9887c72b84 100644 --- a/helper/storagepacker/types.pb.go +++ b/helper/storagepacker/types.pb.go @@ -5,9 +5,10 @@ package storagepacker import ( fmt "fmt" + math "math" + proto "github.com/golang/protobuf/proto" any "github.com/golang/protobuf/ptypes/any" - math "math" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/http/handler.go b/http/handler.go index d236457a0d..c4ccc40c0d 100644 --- a/http/handler.go +++ b/http/handler.go @@ -15,7 +15,7 @@ import ( "time" "github.com/NYTimes/gziphandler" - "github.com/elazarl/go-bindata-assetfs" + assetfs "github.com/elazarl/go-bindata-assetfs" "github.com/hashicorp/errwrap" cleanhttp "github.com/hashicorp/go-cleanhttp" sockaddr "github.com/hashicorp/go-sockaddr" diff --git a/http/handler_test.go b/http/handler_test.go index 6ffa9aff27..2679141c46 100644 --- a/http/handler_test.go +++ b/http/handler_test.go @@ -11,7 +11,7 @@ import ( "strings" "testing" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" diff --git a/http/http_test.go b/http/http_test.go index ca6c420ab3..d7f4d8fcbd 100644 --- a/http/http_test.go +++ b/http/http_test.go @@ -11,7 +11,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/jsonutil" ) diff --git a/http/logical.go b/http/logical.go index a211d6482a..61e993bc57 100644 --- a/http/logical.go +++ b/http/logical.go @@ -12,7 +12,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/vault" diff --git a/logical/auth.go b/logical/auth.go index 7b12e39986..e458ed8686 100644 --- a/logical/auth.go +++ b/logical/auth.go @@ -4,7 +4,7 @@ import ( "fmt" "time" - "github.com/hashicorp/go-sockaddr" + sockaddr "github.com/hashicorp/go-sockaddr" ) // Auth is the resulting authentication information that is part of diff --git a/logical/framework/backend.go b/logical/framework/backend.go index 52b490b56e..a856f0c992 100644 --- a/logical/framework/backend.go +++ b/logical/framework/backend.go @@ -14,7 +14,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-multierror" + multierror "github.com/hashicorp/go-multierror" "github.com/hashicorp/vault/helper/errutil" "github.com/hashicorp/vault/helper/license" "github.com/hashicorp/vault/helper/logging" diff --git a/logical/framework/wal.go b/logical/framework/wal.go index c8fa3b8714..0347f4003f 100644 --- a/logical/framework/wal.go +++ b/logical/framework/wal.go @@ -6,7 +6,7 @@ import ( "strings" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/logical" ) diff --git a/logical/identity.pb.go b/logical/identity.pb.go index cd19652215..5b3342d488 100644 --- a/logical/identity.pb.go +++ b/logical/identity.pb.go @@ -5,8 +5,9 @@ package logical import ( fmt "fmt" - proto "github.com/golang/protobuf/proto" math "math" + + proto "github.com/golang/protobuf/proto" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/logical/plugin.pb.go b/logical/plugin.pb.go index b66bea544b..e8a4f096eb 100644 --- a/logical/plugin.pb.go +++ b/logical/plugin.pb.go @@ -5,8 +5,9 @@ package logical import ( fmt "fmt" - proto "github.com/golang/protobuf/proto" math "math" + + proto "github.com/golang/protobuf/proto" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/logical/plugin/backend.go b/logical/plugin/backend.go index ac367c165e..bf4f84c075 100644 --- a/logical/plugin/backend.go +++ b/logical/plugin/backend.go @@ -8,7 +8,7 @@ import ( "google.golang.org/grpc" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/plugin/pb" ) diff --git a/logical/plugin/backend_client.go b/logical/plugin/backend_client.go index 43a442f4ba..21de944464 100644 --- a/logical/plugin/backend_client.go +++ b/logical/plugin/backend_client.go @@ -6,7 +6,7 @@ import ( "net/rpc" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/logical" ) diff --git a/logical/plugin/backend_server.go b/logical/plugin/backend_server.go index a03e089fb7..291a9e4ab2 100644 --- a/logical/plugin/backend_server.go +++ b/logical/plugin/backend_server.go @@ -5,9 +5,8 @@ import ( "errors" "net/rpc" - "github.com/hashicorp/go-hclog" - - "github.com/hashicorp/go-plugin" + hclog "github.com/hashicorp/go-hclog" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical" ) diff --git a/logical/plugin/grpc_backend_client.go b/logical/plugin/grpc_backend_client.go index 60ef182803..87b740ee0a 100644 --- a/logical/plugin/grpc_backend_client.go +++ b/logical/plugin/grpc_backend_client.go @@ -9,7 +9,7 @@ import ( "google.golang.org/grpc" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical" "github.com/hashicorp/vault/logical/plugin/pb" diff --git a/logical/plugin/logger_test.go b/logical/plugin/logger_test.go index 9acc292413..7a7e080453 100644 --- a/logical/plugin/logger_test.go +++ b/logical/plugin/logger_test.go @@ -8,8 +8,7 @@ import ( "strings" "testing" - "github.com/hashicorp/go-hclog" - + hclog "github.com/hashicorp/go-hclog" plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/logging" ) diff --git a/logical/plugin/pb/backend.pb.go b/logical/plugin/pb/backend.pb.go index 911bb4978d..55f304024a 100644 --- a/logical/plugin/pb/backend.pb.go +++ b/logical/plugin/pb/backend.pb.go @@ -5,10 +5,11 @@ package pb import ( fmt "fmt" + math "math" + proto "github.com/golang/protobuf/proto" timestamp "github.com/golang/protobuf/ptypes/timestamp" logical "github.com/hashicorp/vault/logical" - math "math" ) import ( diff --git a/logical/plugin/plugin.go b/logical/plugin/plugin.go index 250097c22a..2c63d612f6 100644 --- a/logical/plugin/plugin.go +++ b/logical/plugin/plugin.go @@ -12,7 +12,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical" diff --git a/logical/plugin/serve.go b/logical/plugin/serve.go index 97b9f28bd6..c61e59ecf6 100644 --- a/logical/plugin/serve.go +++ b/logical/plugin/serve.go @@ -8,7 +8,7 @@ import ( "google.golang.org/grpc" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-plugin" + plugin "github.com/hashicorp/go-plugin" "github.com/hashicorp/vault/helper/pluginutil" "github.com/hashicorp/vault/logical" ) diff --git a/logical/testing.go b/logical/testing.go index 7c7738996a..472dd68d90 100644 --- a/logical/testing.go +++ b/logical/testing.go @@ -5,9 +5,10 @@ import ( "reflect" "time" + testing "github.com/mitchellh/go-testing-interface" + log "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/helper/logging" - "github.com/mitchellh/go-testing-interface" ) // TestRequest is a helper to create a purely in-memory Request struct. diff --git a/physical/alicloudoss/alicloudoss.go b/physical/alicloudoss/alicloudoss.go index c4edf0c8af..bc9d774a60 100644 --- a/physical/alicloudoss/alicloudoss.go +++ b/physical/alicloudoss/alicloudoss.go @@ -11,7 +11,7 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/physical" diff --git a/physical/azure/azure.go b/physical/azure/azure.go index 17e7eee9e7..6241f9ee26 100644 --- a/physical/azure/azure.go +++ b/physical/azure/azure.go @@ -13,7 +13,7 @@ import ( storage "github.com/Azure/azure-sdk-for-go/storage" "github.com/Azure/go-autorest/autorest/azure" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" cleanhttp "github.com/hashicorp/go-cleanhttp" log "github.com/hashicorp/go-hclog" diff --git a/physical/cache.go b/physical/cache.go index af6a39b83e..0485c54276 100644 --- a/physical/cache.go +++ b/physical/cache.go @@ -5,7 +5,7 @@ import ( "sync/atomic" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/golang-lru" + lru "github.com/hashicorp/golang-lru" "github.com/hashicorp/vault/helper/locksutil" "github.com/hashicorp/vault/helper/pathmanager" ) diff --git a/physical/cassandra/cassandra.go b/physical/cassandra/cassandra.go index 17b09ffce8..528e26ece8 100644 --- a/physical/cassandra/cassandra.go +++ b/physical/cassandra/cassandra.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/gocql/gocql" "github.com/hashicorp/vault/helper/certutil" "github.com/hashicorp/vault/physical" diff --git a/physical/cockroachdb/cockroachdb.go b/physical/cockroachdb/cockroachdb.go index 646eb0822e..377b27429e 100644 --- a/physical/cockroachdb/cockroachdb.go +++ b/physical/cockroachdb/cockroachdb.go @@ -9,7 +9,7 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/cockroachdb/cockroach-go/crdb" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" diff --git a/physical/consul/consul.go b/physical/consul/consul.go index beeb52bfdf..0ad84dad89 100644 --- a/physical/consul/consul.go +++ b/physical/consul/consul.go @@ -22,7 +22,7 @@ import ( "crypto/tls" "crypto/x509" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/consul/api" "github.com/hashicorp/consul/lib" "github.com/hashicorp/errwrap" diff --git a/physical/couchdb/couchdb.go b/physical/couchdb/couchdb.go index a239d88941..d2323f9c30 100644 --- a/physical/couchdb/couchdb.go +++ b/physical/couchdb/couchdb.go @@ -13,7 +13,7 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" cleanhttp "github.com/hashicorp/go-cleanhttp" log "github.com/hashicorp/go-hclog" diff --git a/physical/foundationdb/foundationdb.go b/physical/foundationdb/foundationdb.go index 376f0309cd..96b2c65934 100644 --- a/physical/foundationdb/foundationdb.go +++ b/physical/foundationdb/foundationdb.go @@ -14,14 +14,14 @@ import ( "encoding/binary" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/apple/foundationdb/bindings/go/src/fdb" "github.com/apple/foundationdb/bindings/go/src/fdb/directory" "github.com/apple/foundationdb/bindings/go/src/fdb/subspace" "github.com/apple/foundationdb/bindings/go/src/fdb/tuple" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" "github.com/hashicorp/vault/physical" ) diff --git a/physical/foundationdb/foundationdb_test.go b/physical/foundationdb/foundationdb_test.go index 97aa5e76b9..031d962791 100644 --- a/physical/foundationdb/foundationdb_test.go +++ b/physical/foundationdb/foundationdb_test.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/apple/foundationdb/bindings/go/src/fdb" "github.com/apple/foundationdb/bindings/go/src/fdb/directory" diff --git a/physical/gcs/gcs.go b/physical/gcs/gcs.go index 5513ed63a4..e125a55c0c 100644 --- a/physical/gcs/gcs.go +++ b/physical/gcs/gcs.go @@ -12,6 +12,7 @@ import ( "strings" "time" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" multierror "github.com/hashicorp/go-multierror" @@ -19,7 +20,6 @@ import ( "github.com/hashicorp/vault/physical" "cloud.google.com/go/storage" - "github.com/armon/go-metrics" "google.golang.org/api/iterator" "google.golang.org/api/option" ) diff --git a/physical/inmem/inmem.go b/physical/inmem/inmem.go index d1433d8aed..97433a7d60 100644 --- a/physical/inmem/inmem.go +++ b/physical/inmem/inmem.go @@ -11,7 +11,7 @@ import ( log "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/physical" - "github.com/armon/go-radix" + radix "github.com/armon/go-radix" ) // Verify interfaces are satisfied diff --git a/physical/manta/manta.go b/physical/manta/manta.go index bb17e7499c..cd3ec76fd0 100644 --- a/physical/manta/manta.go +++ b/physical/manta/manta.go @@ -12,11 +12,11 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/physical" - "github.com/joyent/triton-go" + triton "github.com/joyent/triton-go" "github.com/joyent/triton-go/authentication" "github.com/joyent/triton-go/errors" "github.com/joyent/triton-go/storage" diff --git a/physical/manta/manta_test.go b/physical/manta/manta_test.go index ba81bef2c9..ffeb562bde 100644 --- a/physical/manta/manta_test.go +++ b/physical/manta/manta_test.go @@ -12,7 +12,7 @@ import ( log "github.com/hashicorp/go-hclog" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/physical" - "github.com/joyent/triton-go" + triton "github.com/joyent/triton-go" "github.com/joyent/triton-go/authentication" tt "github.com/joyent/triton-go/errors" "github.com/joyent/triton-go/storage" diff --git a/physical/mssql/mssql.go b/physical/mssql/mssql.go index a3d73c1639..7de3423f10 100644 --- a/physical/mssql/mssql.go +++ b/physical/mssql/mssql.go @@ -9,7 +9,7 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" _ "github.com/denisenkom/go-mssqldb" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" diff --git a/physical/mysql/mysql.go b/physical/mysql/mysql.go index de63d1307b..00f8019dd7 100644 --- a/physical/mysql/mysql.go +++ b/physical/mysql/mysql.go @@ -18,7 +18,7 @@ import ( log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" mysql "github.com/go-sql-driver/mysql" "github.com/hashicorp/errwrap" "github.com/hashicorp/vault/helper/strutil" diff --git a/physical/postgresql/postgresql.go b/physical/postgresql/postgresql.go index a4332be887..fa44950bf8 100644 --- a/physical/postgresql/postgresql.go +++ b/physical/postgresql/postgresql.go @@ -10,10 +10,10 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/vault/physical" - //log "github.com/hashicorp/go-hclog" + log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/lib/pq" ) diff --git a/physical/s3/s3.go b/physical/s3/s3.go index c30a203874..5ccd0ad02a 100644 --- a/physical/s3/s3.go +++ b/physical/s3/s3.go @@ -14,7 +14,7 @@ import ( log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/aws/aws-sdk-go/aws/session" diff --git a/physical/swift/swift.go b/physical/swift/swift.go index 37f5b4f4e8..a7de719b60 100644 --- a/physical/swift/swift.go +++ b/physical/swift/swift.go @@ -11,9 +11,9 @@ import ( log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/strutil" "github.com/hashicorp/vault/physical" "github.com/ncw/swift" diff --git a/physical/swift/swift_test.go b/physical/swift/swift_test.go index db0a075d86..dca1bd0399 100644 --- a/physical/swift/swift_test.go +++ b/physical/swift/swift_test.go @@ -8,7 +8,7 @@ import ( log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/physical" "github.com/ncw/swift" diff --git a/physical/types.pb.go b/physical/types.pb.go index 91fbb0e812..e02137c0cf 100644 --- a/physical/types.pb.go +++ b/physical/types.pb.go @@ -5,8 +5,9 @@ package physical import ( fmt "fmt" - proto "github.com/golang/protobuf/proto" math "math" + + proto "github.com/golang/protobuf/proto" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/plugins/database/mongodb/connection_producer.go b/plugins/database/mongodb/connection_producer.go index a4d394f9e7..5debbc6a5e 100644 --- a/plugins/database/mongodb/connection_producer.go +++ b/plugins/database/mongodb/connection_producer.go @@ -19,7 +19,7 @@ import ( "github.com/hashicorp/vault/plugins/helper/database/dbutil" "github.com/mitchellh/mapstructure" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) // mongoDBConnectionProducer implements ConnectionProducer and provides an diff --git a/plugins/database/mongodb/mongodb.go b/plugins/database/mongodb/mongodb.go index 9f338a152a..94c80f199e 100644 --- a/plugins/database/mongodb/mongodb.go +++ b/plugins/database/mongodb/mongodb.go @@ -17,7 +17,7 @@ import ( "github.com/hashicorp/vault/plugins" "github.com/hashicorp/vault/plugins/helper/database/credsutil" "github.com/hashicorp/vault/plugins/helper/database/dbutil" - "gopkg.in/mgo.v2" + mgo "gopkg.in/mgo.v2" ) const mongoDBTypeName = "mongodb" diff --git a/vault/audit.go b/vault/audit.go index cc4c8d8dfa..d23e8a9da8 100644 --- a/vault/audit.go +++ b/vault/audit.go @@ -7,7 +7,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/namespace" diff --git a/vault/audit_test.go b/vault/audit_test.go index 1e262a0f87..1ac632f7c9 100644 --- a/vault/audit_test.go +++ b/vault/audit_test.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/logging" diff --git a/vault/auth.go b/vault/auth.go index 3a3f8014cd..38a77f8286 100644 --- a/vault/auth.go +++ b/vault/auth.go @@ -6,7 +6,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/builtin/plugin" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/jsonutil" diff --git a/vault/barrier_aes_gcm.go b/vault/barrier_aes_gcm.go index 8ddae28983..39b1e05cd3 100644 --- a/vault/barrier_aes_gcm.go +++ b/vault/barrier_aes_gcm.go @@ -13,7 +13,7 @@ import ( "sync" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/strutil" diff --git a/vault/cluster.go b/vault/cluster.go index 356722a0e4..93b2dc731b 100644 --- a/vault/cluster.go +++ b/vault/cluster.go @@ -18,7 +18,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/jsonutil" ) diff --git a/vault/core.go b/vault/core.go index 47d569b7df..5c8a4db0e9 100644 --- a/vault/core.go +++ b/vault/core.go @@ -15,15 +15,15 @@ import ( "sync/atomic" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" log "github.com/hashicorp/go-hclog" - "github.com/patrickmn/go-cache" + multierror "github.com/hashicorp/go-multierror" + uuid "github.com/hashicorp/go-uuid" + cache "github.com/patrickmn/go-cache" "google.golang.org/grpc" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-multierror" - "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/jsonutil" diff --git a/vault/core_test.go b/vault/core_test.go index 3a4174e174..934641ef3b 100644 --- a/vault/core_test.go +++ b/vault/core_test.go @@ -9,7 +9,7 @@ import ( "github.com/go-test/deep" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/logging" diff --git a/vault/expiration_test.go b/vault/expiration_test.go index f6256de339..daa2fffce9 100644 --- a/vault/expiration_test.go +++ b/vault/expiration_test.go @@ -14,7 +14,7 @@ import ( "time" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" diff --git a/vault/generate_root.go b/vault/generate_root.go index 4344342449..a93cc61403 100644 --- a/vault/generate_root.go +++ b/vault/generate_root.go @@ -7,7 +7,7 @@ import ( "fmt" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/pgpkeys" "github.com/hashicorp/vault/helper/xor" diff --git a/vault/logical_cubbyhole_test.go b/vault/logical_cubbyhole_test.go index d426bb40a3..358f2c9ead 100644 --- a/vault/logical_cubbyhole_test.go +++ b/vault/logical_cubbyhole_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/logical" ) diff --git a/vault/logical_system.go b/vault/logical_system.go index 05438f401e..76be568473 100644 --- a/vault/logical_system.go +++ b/vault/logical_system.go @@ -20,8 +20,8 @@ import ( "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-memdb" - "github.com/hashicorp/go-uuid" + memdb "github.com/hashicorp/go-memdb" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/compressutil" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/identity" diff --git a/vault/mount.go b/vault/mount.go index fd9905e32d..355b150543 100644 --- a/vault/mount.go +++ b/vault/mount.go @@ -10,7 +10,7 @@ import ( "sync" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/builtin/plugin" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/jsonutil" diff --git a/vault/policy.go b/vault/policy.go index 7bf448a352..ebc4cfd66a 100644 --- a/vault/policy.go +++ b/vault/policy.go @@ -7,7 +7,7 @@ import ( "time" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-multierror" + multierror "github.com/hashicorp/go-multierror" "github.com/hashicorp/hcl" "github.com/hashicorp/hcl/hcl/ast" "github.com/hashicorp/vault/helper/hclutil" diff --git a/vault/policy_store.go b/vault/policy_store.go index 2c7e12967b..2e143d4e34 100644 --- a/vault/policy_store.go +++ b/vault/policy_store.go @@ -8,10 +8,10 @@ import ( "sync" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/golang-lru" + lru "github.com/hashicorp/golang-lru" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/identity" "github.com/hashicorp/vault/helper/namespace" diff --git a/vault/rekey.go b/vault/rekey.go index ad7d914f87..5152160e91 100644 --- a/vault/rekey.go +++ b/vault/rekey.go @@ -10,7 +10,7 @@ import ( "net/http" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/jsonutil" "github.com/hashicorp/vault/helper/pgpkeys" diff --git a/vault/request_forwarding_service.pb.go b/vault/request_forwarding_service.pb.go index 6f1ce084d9..cfc53b0c41 100644 --- a/vault/request_forwarding_service.pb.go +++ b/vault/request_forwarding_service.pb.go @@ -5,9 +5,10 @@ package vault import ( fmt "fmt" + math "math" + proto "github.com/golang/protobuf/proto" forwarding "github.com/hashicorp/vault/helper/forwarding" - math "math" ) import ( diff --git a/vault/request_handling.go b/vault/request_handling.go index 7b40a1d9b4..d01fcadd7c 100644 --- a/vault/request_handling.go +++ b/vault/request_handling.go @@ -7,9 +7,9 @@ import ( "strings" "time" - "github.com/armon/go-metrics" + metrics "github.com/armon/go-metrics" "github.com/hashicorp/errwrap" - "github.com/hashicorp/go-multierror" + multierror "github.com/hashicorp/go-multierror" sockaddr "github.com/hashicorp/go-sockaddr" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/consts" diff --git a/vault/request_handling_test.go b/vault/request_handling_test.go index c76bf5e83f..b4d4e24a68 100644 --- a/vault/request_handling_test.go +++ b/vault/request_handling_test.go @@ -4,7 +4,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" credUserpass "github.com/hashicorp/vault/builtin/credential/userpass" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" diff --git a/vault/rollback.go b/vault/rollback.go index f9b4953990..9148335289 100644 --- a/vault/rollback.go +++ b/vault/rollback.go @@ -7,9 +7,9 @@ import ( "sync" "time" + metrics "github.com/armon/go-metrics" log "github.com/hashicorp/go-hclog" - "github.com/armon/go-metrics" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" ) diff --git a/vault/rollback_test.go b/vault/rollback_test.go index e6769672eb..4c74f25e84 100644 --- a/vault/rollback_test.go +++ b/vault/rollback_test.go @@ -7,8 +7,8 @@ import ( "time" log "github.com/hashicorp/go-hclog" + uuid "github.com/hashicorp/go-uuid" - "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/logging" "github.com/hashicorp/vault/helper/namespace" ) diff --git a/vault/router.go b/vault/router.go index 66c1ef2372..b17661caba 100644 --- a/vault/router.go +++ b/vault/router.go @@ -8,8 +8,8 @@ import ( "sync/atomic" "time" - "github.com/armon/go-metrics" - "github.com/armon/go-radix" + metrics "github.com/armon/go-metrics" + radix "github.com/armon/go-radix" "github.com/hashicorp/vault/helper/consts" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/helper/salt" diff --git a/vault/router_test.go b/vault/router_test.go index 287fca27ca..41fe4a722f 100644 --- a/vault/router_test.go +++ b/vault/router_test.go @@ -10,7 +10,7 @@ import ( "time" log "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical" ) diff --git a/vault/seal_testing.go b/vault/seal_testing.go index d97281b36f..0aad332e3b 100644 --- a/vault/seal_testing.go +++ b/vault/seal_testing.go @@ -3,7 +3,7 @@ package vault import ( "context" - "github.com/mitchellh/go-testing-interface" + testing "github.com/mitchellh/go-testing-interface" ) var ( diff --git a/vault/seal_testing_util.go b/vault/seal_testing_util.go index 76568fad4d..1ff664c9f7 100644 --- a/vault/seal_testing_util.go +++ b/vault/seal_testing_util.go @@ -2,7 +2,7 @@ package vault -import "github.com/mitchellh/go-testing-interface" +import testing "github.com/mitchellh/go-testing-interface" func NewTestSeal(testing.T, *TestSealOpts) Seal { return NewDefaultSeal() diff --git a/vault/testing.go b/vault/testing.go index fd19d47a1e..44c6d9b72f 100644 --- a/vault/testing.go +++ b/vault/testing.go @@ -33,7 +33,7 @@ import ( "golang.org/x/crypto/ssh" "golang.org/x/net/http2" - "github.com/hashicorp/go-cleanhttp" + cleanhttp "github.com/hashicorp/go-cleanhttp" "github.com/hashicorp/vault/api" "github.com/hashicorp/vault/audit" "github.com/hashicorp/vault/helper/consts" @@ -45,7 +45,7 @@ import ( "github.com/hashicorp/vault/physical" dbMysql "github.com/hashicorp/vault/plugins/database/mysql" dbPostgres "github.com/hashicorp/vault/plugins/database/postgresql" - "github.com/mitchellh/go-testing-interface" + testing "github.com/mitchellh/go-testing-interface" physInmem "github.com/hashicorp/vault/physical/inmem" ) diff --git a/vault/testing_util.go b/vault/testing_util.go index 3aff71e150..689ce11fd6 100644 --- a/vault/testing_util.go +++ b/vault/testing_util.go @@ -2,7 +2,7 @@ package vault -import "github.com/mitchellh/go-testing-interface" +import testing "github.com/mitchellh/go-testing-interface" func testGenerateCoreKeys() (interface{}, interface{}, error) { return nil, nil, nil } func testGetLicensingConfig(interface{}) *LicensingConfig { return &LicensingConfig{} } diff --git a/vault/token_store_test.go b/vault/token_store_test.go index 5d285ed11c..e6a3f4bc43 100644 --- a/vault/token_store_test.go +++ b/vault/token_store_test.go @@ -16,7 +16,7 @@ import ( "github.com/go-test/deep" "github.com/hashicorp/errwrap" hclog "github.com/hashicorp/go-hclog" - "github.com/hashicorp/go-uuid" + uuid "github.com/hashicorp/go-uuid" "github.com/hashicorp/vault/helper/locksutil" "github.com/hashicorp/vault/helper/namespace" "github.com/hashicorp/vault/logical"