bitcoinrb 0.9.0 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/bitcoin/constants.rb +22 -16
- data/lib/bitcoin/script/script_interpreter.rb +2 -2
- data/lib/bitcoin/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ffa8f8b7dbf104190628e7ff38dbb950aa14927ab208377c821ad7f5aeaab862
|
4
|
+
data.tar.gz: f24e89dd6de49e066fae37fe5c4118d955f31a9a751af5901d6cde32528aa8fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 306f65243198a07403c785b212d5d86f5a6eb27b189aa9454d27d280f4d93500b967e93fb7f995e8c998ce7f8f9ff4ba40a838c7f4f430b8e2fef0c04cb11206
|
7
|
+
data.tar.gz: 9e4d92cc79249f5027f105a8c7f69320f35b06b3bc3e9b5cc0416f74e7698f47910f4b63afba1821ec49e647671b1b67d4955acb80fe587d79bb34d0507ae98e
|
data/lib/bitcoin/constants.rb
CHANGED
@@ -53,22 +53,28 @@ module Bitcoin
|
|
53
53
|
MANDATORY_SCRIPT_VERIFY_FLAGS = SCRIPT_VERIFY_P2SH
|
54
54
|
|
55
55
|
# Standard script verification flags that standard transactions will comply with.
|
56
|
-
STANDARD_SCRIPT_VERIFY_FLAGS = [
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
56
|
+
STANDARD_SCRIPT_VERIFY_FLAGS = [
|
57
|
+
MANDATORY_SCRIPT_VERIFY_FLAGS,
|
58
|
+
SCRIPT_VERIFY_DERSIG,
|
59
|
+
SCRIPT_VERIFY_STRICTENC,
|
60
|
+
SCRIPT_VERIFY_MINIMALDATA,
|
61
|
+
SCRIPT_VERIFY_NULLDUMMY,
|
62
|
+
SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_NOPS,
|
63
|
+
SCRIPT_VERIFY_CLEANSTACK,
|
64
|
+
SCRIPT_VERIFY_MINIMALIF,
|
65
|
+
SCRIPT_VERIFY_NULLFAIL,
|
66
|
+
SCRIPT_VERIFY_CHECKLOCKTIMEVERIFY,
|
67
|
+
SCRIPT_VERIFY_CHECKSEQUENCEVERIFY,
|
68
|
+
SCRIPT_VERIFY_LOW_S,
|
69
|
+
SCRIPT_VERIFY_WITNESS,
|
70
|
+
SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_WITNESS_PROGRAM,
|
71
|
+
SCRIPT_VERIFY_WITNESS_PUBKEYTYPE,
|
72
|
+
SCRIPT_VERIFY_CONST_SCRIPTCODE,
|
73
|
+
SCRIPT_VERIFY_TAPROOT |
|
74
|
+
SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION |
|
75
|
+
SCRIPT_VERIFY_DISCOURAGE_OP_SUCCESS |
|
76
|
+
SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_PUBKEYTYPE
|
77
|
+
].inject(SCRIPT_VERIFY_NONE){|flags, f| flags |= f}
|
72
78
|
|
73
79
|
# for script
|
74
80
|
|
@@ -163,9 +163,9 @@ module Bitcoin
|
|
163
163
|
end
|
164
164
|
return set_error(SCRIPT_ERR_STACK_SIZE) if stack.size > MAX_STACK_SIZE
|
165
165
|
need_evaluate = true
|
166
|
+
elsif flag?(SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION)
|
167
|
+
return set_error(SCRIPT_ERR_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION)
|
166
168
|
end
|
167
|
-
|
168
|
-
return set_error(SCRIPT_ERR_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION) if flag?(SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_TAPROOT_VERSION)
|
169
169
|
return true unless need_evaluate
|
170
170
|
end
|
171
171
|
elsif flag?(SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_WITNESS_PROGRAM)
|
data/lib/bitcoin/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bitcoinrb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- azuchi
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-11-
|
11
|
+
date: 2021-11-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ecdsa
|