blake 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/blake/main.rb +4 -2
- data/lib/blake/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: ecd78e1e399ea0f3553f71000db6f93f399419a9dad9dcf7b621e01678fcc195
|
4
|
+
data.tar.gz: d227eeda89a672d757278ad4d7f0bb8858fe9cb34a8075b56c8afc498d592dd3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 107afa897b1d40618d1860053810e90f924cfa2fb9d63ff29e5859a711905990408f47ac49c326cc5f32c4b0a661e8d717bbd7e2e166643a1fb9f4d6118c651c
|
7
|
+
data.tar.gz: 8c5a17dc70a15a1b2110eab7660a0dc70ee6dc0648d39030258d97e4a7efca0ff2e645f5b8762384240a4d3cc6f481a7d238f07c04c5f1f8c7e6dc8003de0376
|
data/lib/blake/main.rb
CHANGED
@@ -97,8 +97,6 @@ module Blake
|
|
97
97
|
|
98
98
|
MASK64BITS = 0xFFFFFFFFFFFFFFFF
|
99
99
|
|
100
|
-
# private_class_method :new
|
101
|
-
|
102
100
|
def initialize(output_size = 512, salt = nil)
|
103
101
|
self.output_size = output_size
|
104
102
|
self.salt = salt
|
@@ -223,6 +221,10 @@ module Blake
|
|
223
221
|
raise TypeError, "Expected #{Integer}, got #{value.class}"
|
224
222
|
end
|
225
223
|
|
224
|
+
unless [224, 256, 384, 512].include? value
|
225
|
+
raise TypeError, 'unknown output size'
|
226
|
+
end
|
227
|
+
|
226
228
|
@output_size = value
|
227
229
|
end
|
228
230
|
|
data/lib/blake/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blake
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Cavanagh (danielcavanagh)
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-03-
|
11
|
+
date: 2020-03-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|