Commit Graph

32 Commits

Author SHA1 Message Date
Matt Corallo d9d398ccc9 Re-support WASM via simple stub headers
libsecp256k1 really only barely uses libc at all, and in practice,
things like memcpy/memcmp get optimized into something other than a
libc call. Thus, if we provide simple stub headers, things seem to
work with wasm-pack just fine.
2020-04-29 15:32:54 -04:00
Elichai Turkel 9bbd4a3df1
Disable emscripten tests until they work again
https://github.com/rust-lang/rust/issues/66916
https://github.com/rustwasm/team/issues/291
2020-03-11 12:22:32 +02:00
Elichai Turkel 89271c9c3c
Fix fuzztarget symbols 2020-01-09 16:56:10 +02:00
Andrew Poelstra 5de62f80f3
Merge pull request #174 from elichai/2019-10-examples
Adding usage examples
2019-11-05 18:36:49 +00:00
Andrew Poelstra c883a983bd
Merge pull request #173 from elichai/2019-10-no-std-tests
Add tests for no-std
2019-11-05 18:35:00 +00:00
Elichai Turkel 2b50e02d7a
Add a rand-std feature 2019-10-29 11:13:05 +02:00
Elichai Turkel 7e5916b61f
Aded an example for recoverable signatures and recovering the pubkey 2019-10-28 22:23:56 +02:00
Elichai Turkel e28f756788
Added an example for signing and verification 2019-10-28 22:09:59 +02:00
Elichai Turkel 5ee0afbde4
Added an example for generating keys using OsRng 2019-10-28 22:09:18 +02:00
Elichai Turkel c117114549
Added no_std_tests to travis 2019-10-24 21:09:47 +03:00
Elichai Turkel 6e58c8b623 Trying to optimize travis speeds
Cache cargo-web only
2019-08-13 10:41:29 -04:00
Wladimir J. van der Laan 62b9f06104 build.rs: Add feature 'lowmemory' to reduce memory usage
Currently, this only set `ECMULT_WINDOW_SIZE` to 4 instead of 15.

Fixes #139.

fixup
2019-08-12 19:21:22 +02:00
Jonas Nick 179f35e0ba Move libsecp USE_ENDOMORPHISM option behind non-default feature flag 2019-06-13 06:38:18 +00:00
Jonas Nick 0e6ff34009 Fix imports when using recovery with fuzztarget feature 2019-05-29 00:02:11 +00:00
Jonas Nick c7eecd159e Feature gate recovery module 2019-05-21 07:02:11 +00:00
Elichai Turkel 6871567a1c
Updated travis.yml to test no-std too 2019-04-14 12:09:42 +03:00
François Garillot a8a3afe8db
Fix clippy errors
Changes include cargo-fix generated, Default impls
2019-02-25 20:12:25 -08:00
François Garillot e69eabb36f
Bumping minimum Rust version 1.14.0 -> 1.22.0, as per https://git.io/fhDLO 2019-02-25 20:09:44 -08:00
Matt Corallo e9588d9c85 Test builds using cargo-web on Travis to ensure they dont break 2019-01-30 21:03:12 -05:00
Tim Ruffing 9a4961c823 Disable travis build on rust 1.14 on windows 2018-12-07 22:37:21 +01:00
Tim Ruffing bbbc63713e Add window target to travis 2018-12-07 22:18:00 +01:00
Andrew Poelstra 2478930ec1 add feature-gated serde 1.0 support for Signature, SecretKey, PublicKey 2018-07-25 14:44:51 +00:00
Matt Corallo ad72da771c Use travis' native rust support (and build fuzztarget on travis) 2018-03-21 18:05:04 -04:00
Andrew Poelstra fe811b37b2 Add some `--` to travis-cargo to separate cargo opts from travis-cargo ones 2016-05-30 15:59:44 +00:00
Andrew Poelstra 9a91b69fad Remove side-effect from assertion; add release build to travis 2015-11-18 18:22:16 -06:00
Andrew Poelstra e5c1b42e3c Upgrades for Travis 2015-10-26 16:26:45 -05:00
Andrew Poelstra e7ca836c2b Switch to static linking of secp256k1
Pieter moved some stuff I need into the contrib/ directory which does
not expose anything through the shared lib, so I need to statically
link.

I might also use this to do evil things to expose the SHA256 code
in libsecp, but not for now ;).
2015-10-26 10:28:01 -05:00
Andrew Poelstra 016d781f2e Fix for upstream API changes; add ECDH support
I didn't mean for both of these to go into the same commit, but given how
small the ECDH code was, and the fact that no commit prior to this one will
compile (as both libsecp256k1 and rustc have changed so much), I'm letting
it slide.
2015-09-18 15:40:42 -05:00
Andrew Poelstra 8d6f384dac Update Travis to use travis-cargo 2015-07-28 13:21:12 -05:00
Andrew Poelstra 1591bba3f9 Update bindings to current secp256k1 library
rust-secp256k1 was based off of https://github.com/sipa/secp256k1,
which has been inactive nearly as long as this repository (prior to
a couple days ago anyway). The correct repository is

   https://github.com/bitcoin/secp256k1

This is a major breaking change to the library for one reason: there
are no longer any Nonce types in the safe interface. The signing functions
do not take a nonce; this is generated internally.

This also means that I was able to drop all my RFC6979 code, since
libsecp256k1 has its own implementation.

If you need to generate your own nonces, you need to create an unsafe
function of type `ffi::NonceFn`, then pass it to the appropriate
functions in the `ffi` module. There is no safe interface for doing
this, deliberately: there is basically no need to directly fiddle
with nonces ever.
2015-04-06 00:13:38 -05:00
Andrew Poelstra a0f11d0f92 Travis speaks rust now :D 2014-08-27 10:58:24 -07:00
Andrew Poelstra 79815e225b Add .travis.yml, update tests and Cargo.toml for upstream changes 2014-08-17 18:58:20 -07:00