Skip to content

Commit

Permalink
Remove storage and crypto backend vault (#1282)
Browse files Browse the repository at this point in the history
This commit removes support for the unmaintained backend for Hashicorp
Vault.

Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
  • Loading branch information
dominikschulz committed Apr 25, 2020
1 parent 0f437fb commit aef3b82
Show file tree
Hide file tree
Showing 9 changed files with 1 addition and 873 deletions.
13 changes: 1 addition & 12 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,37 +8,28 @@ require (
github.com/blang/semver v0.0.0-20190414182527-1a9109f8c4a1
github.com/cenkalti/backoff v2.2.1+incompatible
github.com/cpuguy83/go-md2man/v2 v2.0.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/dominikschulz/github-releases v0.0.0-20171016132906-7635b43b2447
github.com/doronbehar/gocui v0.4.2
github.com/fatih/color v1.9.0
github.com/frankban/quicktest v1.4.1 // indirect
github.com/gdamore/tcell v1.3.0
github.com/go-test/deep v1.0.2 // indirect
github.com/godbus/dbus v0.0.0-20190623212516-8a1682060722
github.com/gokyle/twofactor v1.0.1
github.com/golang/protobuf v1.4.0
github.com/hashicorp/go-hclog v0.12.2 // indirect
github.com/hashicorp/go-multierror v1.1.0
github.com/hashicorp/go-retryablehttp v0.6.6 // indirect
github.com/hashicorp/go-rootcerts v1.0.2 // indirect
github.com/hashicorp/golang-lru v0.5.4
github.com/hashicorp/vault/api v1.0.5-0.20191216174727-9d51b36f3ae4
github.com/hashicorp/vault/sdk v0.1.14-0.20191218020134-06959d23b502 // indirect
github.com/jsimonetti/pwscheme v0.0.0-20160922125227-76804708ecad
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51
github.com/kr/pretty v0.2.0 // indirect
github.com/kr/text v0.2.0 // indirect
github.com/lucasb-eyer/go-colorful v1.0.3 // indirect
github.com/martinhoefling/goxkcdpwgen v0.0.0-20190331205820-7dc3d102eca3
github.com/mattn/go-colorable v0.1.6
github.com/mattn/go-runewidth v0.0.9
github.com/mitchellh/go-homedir v1.1.0
github.com/mitchellh/go-ps v1.0.0
github.com/mitchellh/mapstructure v1.2.2 // indirect
github.com/muesli/crunchy v0.4.0
github.com/muesli/goprogressbar v0.0.0-20190807022807-e540249d2ac1
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect
github.com/pierrec/lz4 v2.5.2+incompatible // indirect
github.com/pkg/errors v0.9.1
github.com/schollz/closestmatch v0.0.0-20190308193919-1fbe626be92e
github.com/skip2/go-qrcode v0.0.0-20191027152451-9434209cb086
Expand All @@ -48,10 +39,8 @@ require (
golang.org/x/net v0.0.0-20200421231249-e086a090c8fd
golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f
golang.org/x/text v0.3.2 // indirect
golang.org/x/time v0.0.0-20200416051211-89c76fbcd5d1 // indirect
google.golang.org/protobuf v1.21.0
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect
gopkg.in/square/go-jose.v2 v2.5.0 // indirect
gopkg.in/yaml.v2 v2.2.8
rsc.io/qr v0.2.0 // indirect
)
160 changes: 0 additions & 160 deletions go.sum

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions pkg/backend/crypto.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ const (
XC
// OpenPGP is a GPG1.x compatible pure-Go crypto backend
OpenPGP
// Vault is Hashicorp Vault backend
Vault
)

func (c CryptoBackend) String() string {
Expand Down
6 changes: 0 additions & 6 deletions pkg/backend/url_xc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,6 @@ func TestParseSchemeXC(t *testing.T) {
Storage: FS,
Path: filepath.Join(hd, ".local", "share", "password-store"),
},
//{
// URL: "plain+vault-http://localhost:9600/foo/bar",
// Crypto: Plain,
// RCS: Noop,
// Storage: Vault,
//},
} {
u, err := ParseURL(tc.URL)
require.NoError(t, err, tc.Name)
Expand Down
11 changes: 0 additions & 11 deletions pkg/store/root/mount.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import (
"github.com/gopasspw/gopass/pkg/out"
"github.com/gopasspw/gopass/pkg/store"
"github.com/gopasspw/gopass/pkg/store/sub"
"github.com/gopasspw/gopass/pkg/store/vault"

"github.com/fatih/color"
"github.com/pkg/errors"
Expand Down Expand Up @@ -88,17 +87,7 @@ func (r *Store) addMount(ctx context.Context, alias, path string, sc *config.Sto
return nil
}

func (r *Store) initSubVault(ctx context.Context, alias string, path *backend.URL) (store.Store, error) {
return vault.New(ctx, alias, path, r.cfg.Directory(), r.agent)
}

func (r *Store) initSub(ctx context.Context, sc *config.StoreConfig, alias string, path *backend.URL, keys []string) (store.Store, error) {
// init vault sub store
if backend.GetCryptoBackend(ctx) == backend.Vault || path.Crypto == backend.Vault {
out.Debug(ctx, "Initializing Vault Store at %s -> %s", alias, path.String())
return r.initSubVault(ctx, alias, path)
}

// init regular sub store
s, err := sub.New(ctx, r.cfg, alias, path, r.cfg.Directory(), r.agent)
if err != nil {
Expand Down
54 changes: 0 additions & 54 deletions pkg/store/vault/seccfg.go

This file was deleted.

143 changes: 0 additions & 143 deletions pkg/store/vault/secret.go

This file was deleted.

Loading

0 comments on commit aef3b82

Please sign in to comment.