A plugin that turn hashicorp vault into blockchain wallet.

dq-vault - Hashicorp vault BTC/ETH plugin

GitHub PkgGoDev Go Report Card GitHub last commit GitHub go.mod Go version

This vault plugin stores a user's mnemonic inside vault in an encrypted manner. The plugin uses this stored mnemonic to derive a private key based on an HD wallet path provided by the user and signs a raw transaction given as input using that private key. All this process happens inside the vault and the user never knows the mnemonic (unless he has provided it manually) or the private key derived. All he needs to do is give a raw transaction as input and the vault returns a signed transaction. A particular user is identified in the vault using a UUID generated when the user is initially registered in the vault.

There will be two roles communicating with vault:

  1. Admin: The one who sets up the vault.
  2. Application Server: The one who uses vault to read and update data.

The application server can communicate with a vault server using API requests/calls. Both CLI commands and API call methods have been included in this guide.

Visit this link for full documentation of dq-vault

Installation

This part of setting up vault can be done using two methods. You may follow any one of your choices.

  • Method 1:-

    Using Docker to get your vault server up and running. You can find it in this link. We have provided the required docker files in the setup folder.
  • Method 2:-

    Setting up Vault manually. The steps are given below in this README, starting from vault installation to creating your own vault server by using the CLI.

If you are already done with setting up the vault server using method 1, you may go directly to part 2 which elaborates the usage of the vault as an application server.

Vault installation

The first thing you need to do is to install vault to set-up a vault server.

  • To install Vault, find the appropriate package for your system and download it. Vault is packaged as a zip archive.

  • After downloading Vault, unzip the package. Vault runs as a single binary named vault.

  • Copy the vault binary to your PATH. In Ubuntu, PATH should be the usr/bin directory.

  • To verify the installation, type vault in your terminal. You should see help output similar to the following:

      $ vault
      Usage: vault <command> [args]
    
      Common commands:
          read        Read data and retrieves secrets
          write       Write data, configuration, and secrets
          delete      Delete secrets and configuration
          list        List data or secrets
          login       Authenticate locally
          server      Start a Vault server
          status      Print seal and HA status
          unwrap      Unwrap a wrapped secret
    
      Other commands:
          audit          Interact with audit devices
          auth           Interact with auth methods
          lease          Interact with leases
          operator       Perform operator-specific tasks
          path-help      Retrieve API help for paths
          policy         Interact with policies
          secrets        Interact with secrets engines
          ssh            Initiate an SSH session
          token          Interact with tokens
    
  • You can find the official installation guide here

Get go files and Build plugin

Assuming that you have golang installed and your GOPATH configured, get the plugin repository and run the build command in that folder:

  $ go build

This will you give you a binary executable file with the name Vault.

Now move this binary file to a directory which the vault will use as its plugin directory. The plugin directory is where the vault looks up for available plugins.

  $ mv Vault /etc/vault/plugins/vault_plugin

The above path is just an example, you can change the etc path to your own desired path.

License

Copyright 2021, DeqodeLabs (https://deqode.com/)

Licensed under the MIT License(the "License");

Owner
Deqode
Harnessing the power of blockchain, for your business.
Deqode
Similar Resources

An easy to setup local crypto wallet based on Geth

CryptoWallet An easy to setup local crypto wallet based on Geth To run. go run CrytoWallet This will expose a set a api's. To Create new Wallet curl

Oct 15, 2021

A work-in-progress Bitcoin wallet based on Output Descriptors

go-wallet A work-in-progress Bitcoin wallet Descriptors go-wallet is designed around Bitcoin Descriptors. It implements a Output Script Descriptors la

May 4, 2022

API wrapper over high-load TON wallet

highload-wallet-api API wrapper over high-load TON wallet smart contract. Can be

Nov 4, 2022

Minilotus - A simple wallet manager of lotus

A simple wallet manager of lotus. Refer to https://github.com/filecoin-project/l

Jan 5, 2022

A simple ticket-wallet API. It is fully dockerized

Ticket Wallet This is a simple ticket-wallet API. It is fully dockerized. Table of contents 1 Response Data format 2 API  2.1 Get layout  2.2 Start se

Jan 23, 2022

Blockcain - Trust Wallet token repository - A comprehensive, up-to-date collection of information about several thousands (!) of crypto tokens

Blockcain - Trust Wallet token repository - A comprehensive, up-to-date collection of information about several thousands (!) of crypto tokens

Trust Wallet Assets Info Overview Trust Wallet token repository is a comprehensi

Feb 14, 2022

sops is an editor of encrypted files that supports YAML, JSON, ENV, INI and BINARY formats and encrypts with AWS KMS, GCP KMS, Azure Key Vault, age, and PGP

sops is an editor of encrypted files that supports YAML, JSON, ENV, INI and BINARY formats and encrypts with AWS KMS, GCP KMS, Azure Key Vault, age, and PGP

sops is an editor of encrypted files that supports YAML, JSON, ENV, INI and BINARY formats and encrypts with AWS KMS, GCP KMS, Azure Key Vault, age, and PGP. (demo)

Jan 9, 2023

A system written in Golang to help ops team to automate the process of mapping Vault groups to LDAP Groups.

A system written in Golang to help ops team to automate the process of mapping Vault groups to LDAP Groups. This utility automatically adds LDAP Groups' members to the corresponding Vault Groups.

Nov 12, 2021

Create @tailscale authentication tokens using vault

Vault Secrets Plugin - Tailscale Vault secrets plugins to simplying creation, ma

Nov 21, 2022
Comments
  • Running with docker gives error.

    Running with docker gives error.

    When running docker-compose , "glide" gives an error , so instead of that, we shall use go-modules. The necessary change for that is in Docker file , line number 4, Replace that with "RUN go get -u github.com/Masterminds/glide"

Jan 7, 2023
Sidecar container for injecting secrets into configuration files from Hashicorp Vault

talebearer noun A person who spreads scandal or tells secrets; gossip Note This code is not being actively developed, and has not seen substantial cha

Nov 1, 2021
Ethereum-vanity-wallet - A fork of https://github.com/meehow/ethereum-vanity-wallet but the key can be exported to a JSON keystore file

ethereum-vanity-wallet See https://github.com/meehow/ethereum-vanity-wallet This version: doesn't display the private key let's you interactively expo

Jan 2, 2022
The Bhojpur Wallet is a platform-as-a-service product used as a Wallet Engine based on the Bhojpur.NET Platform for application delivery.

Bhojpur Wallet - Data Processing Engine The Bhojpur Wallet is a platform-as-a-service used as a Service Engine based on the Bhojpur.NET Platform. It l

Sep 26, 2022
Scp-wallet-api - Backend for SCP Wallet app

SCP Wallet API Backend for SCP Wallet app. It exposes a simplified REST API whic

Jan 31, 2022
A simple, secure self-destructing message service, using HashiCorp Vault product as a backend
A simple, secure self-destructing message service, using HashiCorp Vault product as a backend

sup3rS3cretMes5age! A simple, secure self-destructing message service, using Has

Mar 5, 2022
Simple and useful principle of wallet in blockchain
Simple and useful principle of wallet in blockchain

Blockchain wallet utiles Development export GOPROXY=https://goproxy.io,direct go run *.go Build go build -o ./bin/app *.go About wallet in blockchain

Aug 11, 2022
docker plugin use vault as secret provider.

docker plugin vault docker secret plugin for vault provider how to build docker plugin rm -fr plugin/rootfs/.dockerenv plugin/rootfs/* docker build -

Aug 12, 2022
Blockchain-go - A repository that houses a blockchain implemented in Go

blockchain-go This is a repository that houses a blockchain implemented in Go. F

May 1, 2022
SwissWallet is a deterministic cryptocurrency wallet generator heavily based on MindWallet and MemWallet

SwissWallet SwissWallet is a deterministic cryptocurrency wallet generator heavily based on MindWallet and MemWallet but using argon2 and scrypt by de

Jul 28, 2022