Commit Graph

70 Commits

Author SHA1 Message Date
Henry de Valence 22c3bdeb61 Prefix workspace crates with zebra- (#70)
* Update license and author metadata in workspace crates.

- ensure that the license field is set to GPL-3 for all GPL-3 licensed crates;
- ensure that the author field is set to "Zcash Foundation", responsible for maintenance;
- preserve the original authorship info in AUTHORS.md for human-readable history.

Updating the author field ensures that all of the machine systems that read
crate metadata list the ZF organization, not any single individual, as the
maintainer of the crate.

* Prefix all internal crate names with zebra-.

This does not move the directories containing these crates to also have zebra-
prefixes (for instance, zebra-chain instead of chain).  I think that this would
be preferable, but because it's a `git mv`, it will be simple to do later and
leaving it out of this change makes it easier to see the renaming of all of the
internal modules.

* Remove git dependency from eth-secp256k1

* Avoid an error seemingly related to Deref coercions.

This code caused an overflow while evaluating type constraints.  As best as I
can determine, the cause of the problem was something like so: the Rust
implementation of the Bitcoin-specific hash function used in the Bloom filter
doesn't operate on byte slices, but only on a `&mut R where R: Read`, so to
hash a byte slice, you need to create a mutable copy of the input slice which
can be consumed as a `Read` implementation by the hash function; the previous
version of this code created a slice copy using a `Deref` coercion instead of
`.clone()`, and when a tokio update added new trait impls, the type inference
for the `Deref` coercion exploded (somehow -- I'm not sure about the last
part?).

This commit avoids the problem by manually cloning the input slice.
2019-07-02 15:07:06 -04:00
Henry de Valence 891226069a Run cargo fmt 2019-06-28 15:26:18 -07:00
Svyatoslav Nikolsky a5dbbb9d7e use empty values as false in comparison ops 2019-04-25 11:46:02 +03:00
Svyatoslav Nikolsky 2bb21e6370 Option<SighashCache> -> SighashCache { Option<> } 2019-04-16 10:20:52 +03:00
Svyatoslav Nikolsky 095e8ec21a removed bitcoin-cash specific opcodes 2019-03-12 13:35:10 +03:00
Dimitris Apostolou cbf4c99d8b
Fix typos 2019-02-03 00:35:00 +02:00
Svyatoslav Nikolsky 9742b113df cache signature portions 2018-12-07 12:33:57 +03:00
Svyatoslav Nikolsky 6eae4aa75d sighash update 2018-12-07 12:10:57 +03:00
NikVolf f111948c97 fix warning and add refs 2018-11-21 13:31:07 +03:00
NikVolf 534d09457b remove test with incorrent opcode 2018-11-20 19:23:15 +03:00
NikVolf da02015342 remove find&delete, split opcode 2018-11-20 19:22:51 +03:00
Svyatoslav Nikolsky c19bf38801 cleaning up 2018-11-14 11:46:02 +03:00
Svyatoslav Nikolsky aa692d8a90 cleaning up 2018-11-14 11:37:28 +03:00
Svyatoslav Nikolsky 3a1e6c9aa6 cleaning up 2018-11-13 14:20:25 +03:00
Svyatoslav Nikolsky c9132eb99d Merge branch 'master' into zcash_init 2018-11-12 12:31:14 +03:00
Svyatoslav Nikolsky 5606bb486b
Merge pull request #529 from paritytech/bch_nov2018_cleanstack
BCH Nov2018 HF: enforce clean-stack restriction for scripts
2018-11-12 09:42:15 +03:00
Svyatoslav Nikolsky cc823839a6 OP_CHECKDATASIG* accepts raw message instead of hash + does a sha256 2018-11-07 13:24:44 +03:00
Svyatoslav Nikolsky d96be02e56 BCH Nov2018 HF: enforce verify_cleanstack 2018-10-17 09:47:34 +03:00
Svyatoslav Nikolsky ad4f51ac07 BCH Nov2018 HF: OP_CHECKDATASIG + OP_CHECKDATASIGVERIFY 2018-10-16 15:45:27 +03:00
Svyatoslav Nikolsky da0c55db7a zcash serialization 2018-05-17 15:09:03 +03:00
Svyatoslav Nikolsky 1ebe3375f4 added tests for reverse ops 2018-04-12 10:47:35 +03:00
Svyatoslav Nikolsky 72832bc675 OP_NUM2BIN implementation 2018-04-11 17:38:59 +03:00
Svyatoslav Nikolsky b52a05e124 renamed back to bin2num where appropriate 2018-04-11 11:18:29 +03:00
Wei Tang dba73290e6 test_bin2num -> test_right 2018-04-09 20:37:18 +08:00
Wei Tang 5760756b3d Keep the original naming of OP_LEFT and OP_RIGHT 2018-04-09 20:35:32 +08:00
Wei Tang 6ad1ef5d9e Fix/typo: mut is not needed 2018-04-09 20:09:43 +08:00
Wei Tang 849e4ca546 OP_BIN2NUM implementation and basic testing
Ref 451aab026d/may-2018-reenabled-opcodes.md
2018-04-03 13:20:57 +08:00
Wei Tang 64caac30c0 Rename OP_LEFT/OP_RIGHT to OP_NUM2BIN/OP_BIN2NUM
The later is used in a future hard fork for Bitcoin Cash. Because the former is disabled in Bitcoin, this change shouldn't do any harm.
2018-04-02 23:46:34 +08:00
Svyatoslav Nikolsky 06a4ef8dbc OP_DIV and OP_MOD implementations 2018-03-02 14:09:31 +03:00
Svyatoslav Nikolsky aca8deeeba bitwise ops (OP_AND, OP_OR, OP_XOR) implementation 2018-03-02 12:48:27 +03:00
Svyatoslav Nikolsky 05f885bfd9 OP_SPLIT implementation 2018-03-02 12:22:38 +03:00
Svyatoslav Nikolsky 7beffdfdc9 fixed typo 2018-03-02 12:07:45 +03:00
Svyatoslav Nikolsky 34239d4fbe OP_CAT implementation 2018-03-02 11:36:32 +03:00
Svyatoslav Nikolsky efbb4d4b57 replace try with ? in script 2018-03-02 10:56:37 +03:00
Svyatoslav Nikolsky c10214c5ed fixed OP_NOP 2017-08-23 17:26:38 +03:00
Svyatoslav Nikolsky 1a7b0e13ea removed comments 2017-08-22 14:47:19 +03:00
Svyatoslav Nikolsky 98db437162 segwit: tx_valid tests 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky a97bdaf0bc segwit: witness tests from tx_invalid.json 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky 6c06081577 segwit: multisig segwit tests 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky c468425daf segwit: script tests 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky 4cd0207c25 basic_witness_script_checks 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky 0a813b2d51 removed excess clone 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky 1e28ec4ed5 segwit: sigops cost stub 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky bda2277b71 segwit: added sync TODOs 2017-08-22 14:40:04 +03:00
Svyatoslav Nikolsky 1b92a9d8d4 segwit: p2sh witness 2017-08-22 14:39:10 +03:00
Svyatoslav Nikolsky b0c1605ee4 swgwit: verify_witness_program 2017-08-22 14:39:10 +03:00
Svyatoslav Nikolsky d4a191aec1 segwit: initial flush 2017-08-22 14:39:10 +03:00
Svyatoslav Nikolsky 65569b2b10 uahf: fixed find_and_delete condition in OP_CHECKMULTISIG 2017-08-17 15:07:45 +03:00
Svyatoslav Nikolsky e83c40a450 fixed test 2017-08-15 12:05:44 +03:00
Svyatoslav Nikolsky 78bd3e5485 FORKID sighash fixes 2017-08-15 11:26:09 +03:00