Commit Graph

12 Commits

Author SHA1 Message Date
Eugene Kabanov 36df1300ce Eth keys API refactor (#14)
* Fix eth_keys to follow nimble rules.
Fix eth_keys to follow NEP-1 rules.
Fix eth_keys to work properly with libsecp256k1 (do not raise uncatchable exceptions).
Added more tests from py_evm, go-ethereum, cpp-ethereum.
Added address utility functions.
Changed public api, to be compatible with more modules.

* Fix newline.

* Added proper appveyor.yml.

* Fix appveyor.yml.

* Removed safeXXX functions.

* Removed Nonce object declaration.
Removed EthKeysContext possibility of inheritation.
Added shutdownLibsecp256k1() and shutdown() procedures.
Some documentation comments got modified.

* Removed RawPublicKey and RawSignature bytes.
getRaw(PublicKey) and getRaw(Signature) are now returning arrays.
Added toRaw(PublicKey, data) and toRaw(Signature, data).

* Added `$` hexadecimal string representation functions.
Added initSignature functions.
Added some previous tests.

* Removed 0x prefixes from `$` functions.
2018-04-10 19:07:40 +02:00
Yuriy Glukhov 07bd05aae4 Use nimcrypto instead of keccak_tiny (#12) 2018-03-26 21:17:35 +02:00
mratsim 85e7f11efe Remove tests of private fields + Hide privat fields for real 2018-03-21 21:03:12 +01:00
mratsim 4454750f95 Hide the (r,s) in signature 2018-03-21 17:59:50 +01:00
mratsim b4f513c847 Rebase on master (new serialization #9 and tests #11) 2018-03-21 16:45:39 +01:00
mratsim 92bdd41643 Remove ttmath and allow compilation to C, change "private" field names. 2018-03-21 15:54:41 +01:00
mratsim c132fac2ce Relicense under dual Apachev2/MIT 2018-03-02 11:57:43 +01:00
mratsim af6f00bd78 require Nim 0.18 2018-03-02 10:11:55 +01:00
Mamy Ratsimbazafy 5e192ebec9
Fix native backend compilation (static types only) (#4)
* Fix types

* Fix compilation of native backends (implementation tests still fails)
2018-03-01 16:33:34 +01:00
Zahary Karadjov 6c300a2c6f Set license to Apache v2 2018-02-27 19:41:16 +02:00
Mamy Ratsimbazafy d3df9f5055
Libsecp256k1 backend (#2)
* Add safe hex, endianness and bytes conversion tools

* comment typo endianess -> endianness

* Add libsecp256k1 - private and public keygen and serialization + tests
2018-02-14 16:24:29 +01:00
Mamy Ratsimbazafy 33b9df4c83
[WIP] add native ECDSA backend implementation (⚠ to be debugged)
* Add jacobian primitives

* Add ECDSA algos

* Implement ECDSA, HMAC crypto (to be cleaned up)

* [WIP] test suite

* Fix arrayOfBytes <-> UInt256 casting issue

* ecdsa_raw_sign: Fix shadowing result which lead to implicit object field construction requires a .partial object

* Fix casting + remove tests covered by ranged type

* Fix toHex conversion and add first test (failing)

* Fix modular inversion for unsigned ints

* Add modulo template

* Public key generation bug still to hunt.
2018-02-13 19:20:27 +01:00