diff options
author | Alex Dupre <ale@FreeBSD.org> | 2018-01-29 21:23:12 +0800 |
---|---|---|
committer | Alex Dupre <ale@FreeBSD.org> | 2018-01-29 21:23:12 +0800 |
commit | d23b88379ecf81f6bb861d2fe0d16a924ad93d09 (patch) | |
tree | 0fbe0d0854e62925328d55f6cda7e216567ec0b7 /math | |
parent | 78174bb8c584f270b4c340bc1dbeb4a0850610dd (diff) | |
download | freebsd-ports-gnome-d23b88379ecf81f6bb861d2fe0d16a924ad93d09.tar.gz freebsd-ports-gnome-d23b88379ecf81f6bb861d2fe0d16a924ad93d09.tar.zst freebsd-ports-gnome-d23b88379ecf81f6bb861d2fe0d16a924ad93d09.zip |
An optimized C library for EC operations on curve secp256k1.
This library is a work in progress and is being used to research best practices.
Use at your own risk.
Features:
- secp256k1 ECDSA signing/verification and key generation.
- Adding/multiplying private/public keys.
- Serialization/parsing of private keys, public keys, signatures.
- Constant time, constant memory access signing and pubkey generation.
- Derandomized DSA (via RFC6979 or with a caller provided function.)
- Very efficient implementation.
WWW: https://github.com/bitcoin-core/secp256k1
Diffstat (limited to 'math')
-rw-r--r-- | math/Makefile | 1 | ||||
-rw-r--r-- | math/secp256k1/Makefile | 47 | ||||
-rw-r--r-- | math/secp256k1/distinfo | 3 | ||||
-rw-r--r-- | math/secp256k1/pkg-descr | 14 | ||||
-rw-r--r-- | math/secp256k1/pkg-plist | 7 |
5 files changed, 72 insertions, 0 deletions
diff --git a/math/Makefile b/math/Makefile index 177e814ac127..409c832f0e0c 100644 --- a/math/Makefile +++ b/math/Makefile @@ -714,6 +714,7 @@ SUBDIR += scilab-toolbox-swt SUBDIR += sdpa SUBDIR += sdpara + SUBDIR += secp256k1 SUBDIR += sfft SUBDIR += sfst SUBDIR += simd-viterbi diff --git a/math/secp256k1/Makefile b/math/secp256k1/Makefile new file mode 100644 index 000000000000..8e204e36188b --- /dev/null +++ b/math/secp256k1/Makefile @@ -0,0 +1,47 @@ +# Created by: Alex Dupre <ale@FreeBSD.org> +# $FreeBSD$ + +PORTNAME= secp256k1 +PORTVERSION= 0.1.20171222 +CATEGORIES= math security java + +MAINTAINER= ale@FreeBSD.org +COMMENT= Optimized C library for EC operations on curve secp256k1 + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/COPYING + +USES= autoreconf libtool gmake +USE_LDCONFIG= yes +USE_GITHUB= yes +GH_ACCOUNT= bitcoin-core +GH_TAGNAME= c95f6f1 + +OPTIONS_DEFINE= GMP JAVA +OPTIONS_DEFAULT=GMP JAVA + +GMP_DESC= Use GMP bignum implementation +GMP_LIB_DEPENDS=libgmp.so:math/gmp +GMP_CONFIGURE_ON=--with-bignum=gmp +GMP_CONFIGURE_OFF=--with-bignum=no + +JAVA_DESC= Build JNI bindings +JAVA_CONFIGURE_ENABLE=jni + +GNU_CONFIGURE= yes +CONFIGURE_ARGS= --enable-experimental --enable-module-ecdh +INSTALL_TARGET= install-strip + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MGMP} +CPPFLAGS+= -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib +.endif + +.if ${PORT_OPTIONS:MJAVA} +USE_JAVA= yes +CONFIGURE_ENV+= JAVA_HOME="${JAVA_HOME}" +.endif + +.include <bsd.port.mk> diff --git a/math/secp256k1/distinfo b/math/secp256k1/distinfo new file mode 100644 index 000000000000..536e28cc03e4 --- /dev/null +++ b/math/secp256k1/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1517222904 +SHA256 (bitcoin-core-secp256k1-0.1.20171222-c95f6f1_GH0.tar.gz) = 8c171d1064f3e4780bbfb76a21a768df4cece36c2e7b680e6b04d71f9554dfcf +SIZE (bitcoin-core-secp256k1-0.1.20171222-c95f6f1_GH0.tar.gz) = 161854 diff --git a/math/secp256k1/pkg-descr b/math/secp256k1/pkg-descr new file mode 100644 index 000000000000..710aa547f5b1 --- /dev/null +++ b/math/secp256k1/pkg-descr @@ -0,0 +1,14 @@ +An optimized C library for EC operations on curve secp256k1. + +This library is a work in progress and is being used to research best practices. +Use at your own risk. + +Features: + - secp256k1 ECDSA signing/verification and key generation. + - Adding/multiplying private/public keys. + - Serialization/parsing of private keys, public keys, signatures. + - Constant time, constant memory access signing and pubkey generation. + - Derandomized DSA (via RFC6979 or with a caller provided function.) + - Very efficient implementation. + +WWW: https://github.com/bitcoin-core/secp256k1 diff --git a/math/secp256k1/pkg-plist b/math/secp256k1/pkg-plist new file mode 100644 index 000000000000..c2677f3d2bef --- /dev/null +++ b/math/secp256k1/pkg-plist @@ -0,0 +1,7 @@ +include/secp256k1.h +include/secp256k1_ecdh.h +lib/libsecp256k1.a +lib/libsecp256k1.so +lib/libsecp256k1.so.0 +lib/libsecp256k1.so.0.0.0 +libdata/pkgconfig/libsecp256k1.pc |