acme-client 0.3.3 → 0.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/acme/client.rb +8 -1
- data/lib/acme/client/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 67915cb47841b3a55198b9630e1fd75199475941
|
4
|
+
data.tar.gz: 977b3f6200b5838ba8efd62f1c18416467c4f029
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 40a523d0fa5466f150468ac8bb0095fc4bba60d12dd5b0504d2dee6d03410bbe3521df8b120a93196192248c29520764813e2d5b1de9319fe215b59cb230dc44
|
7
|
+
data.tar.gz: e5f037113d4f1976108027a95310d8c01d4422becc9f535596f2a37893d95d342bcdefd4abb924c3b81cf9339885297329ed74bdcf7ace7d1003580bde5ba37e
|
data/lib/acme/client.rb
CHANGED
@@ -66,7 +66,12 @@ class Acme::Client
|
|
66
66
|
end
|
67
67
|
end
|
68
68
|
|
69
|
-
def challenge_from_hash(
|
69
|
+
def challenge_from_hash(arguments)
|
70
|
+
attributes = arguments.to_h
|
71
|
+
%w(type uri token).each do |key|
|
72
|
+
raise ArgumentError, "missing key: #{key}" unless attributes.key?(key)
|
73
|
+
end
|
74
|
+
|
70
75
|
case attributes.fetch('type')
|
71
76
|
when 'http-01'
|
72
77
|
Acme::Client::Resources::Challenges::HTTP01.new(self, attributes)
|
@@ -74,6 +79,8 @@ class Acme::Client
|
|
74
79
|
Acme::Client::Resources::Challenges::DNS01.new(self, attributes)
|
75
80
|
when 'tls-sni-01'
|
76
81
|
Acme::Client::Resources::Challenges::TLSSNI01.new(self, attributes)
|
82
|
+
else
|
83
|
+
raise 'Unsupported resource type'
|
77
84
|
end
|
78
85
|
end
|
79
86
|
|
data/lib/acme/client/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: acme-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Charles Barbier
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-06-
|
11
|
+
date: 2016-06-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|