Low commit activity in last 3 years
No release in over a year
Ruby binding to bitcoin's secp256k1 implementation.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

= 5.11.3
~> 12.3
= 0.9.20

Runtime

>= 1.9.25
 Project Readme

ruby-bitcoin-secp256k1

Prerequisite

In order to use this gem, libsecp256k1 must be in place.

macOS

brew tap nervosnetwork/tap
brew install libsecp256k1

Ubuntu 18.04 or above

sudo apt install libsecp256k1-dev

Ubuntu 16.04 or below

$ git clone https://github.com/bitcoin-core/secp256k1.git && cd secp256k1
$ ./autogen.sh
$ ./configure
$ make
$ sudo make install

Or if you have cloned the project, you could go to project root and run this install script:

git submodule update --init --recursive
./install_lib.sh

The recovery and ecdh modules are optional. If your local installation of secp256k1 doesn't enable them then the gem would throw LoadModuleError when related functions are invoked.

Install

gem i bitcoin-secp256k1

Then require 'secp256k1' (without bitcoin- prefix) in your source code.

Usage

Check test for examples.

LICENSE

MIT License