summaryrefslogtreecommitdiff
path: root/vendor/acme-client/lib/acme/client/resources/challenges/http01.rb
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2016-10-05 14:35:56 -0700
committerelijah <elijah@riseup.net>2016-10-05 14:35:56 -0700
commit7abfbd6abae14fa6a72350f7b75268ff561354ee (patch)
treeaf5c969c905a8d2a95f2b2aa7c4dd6f4b8763126 /vendor/acme-client/lib/acme/client/resources/challenges/http01.rb
parentcc57bc6c0ff99d88f3bfeff1b04297e9b91e6988 (diff)
parentf95e08ef7d8defbde4a19e138b1ac4ebc9677669 (diff)
Merge branch 'develop'
# Conflicts: # lib/leap_cli/version.rb
Diffstat (limited to 'vendor/acme-client/lib/acme/client/resources/challenges/http01.rb')
-rw-r--r--vendor/acme-client/lib/acme/client/resources/challenges/http01.rb18
1 files changed, 18 insertions, 0 deletions
diff --git a/vendor/acme-client/lib/acme/client/resources/challenges/http01.rb b/vendor/acme-client/lib/acme/client/resources/challenges/http01.rb
new file mode 100644
index 0000000..4966091
--- /dev/null
+++ b/vendor/acme-client/lib/acme/client/resources/challenges/http01.rb
@@ -0,0 +1,18 @@
+# frozen_string_literal: true
+
+class Acme::Client::Resources::Challenges::HTTP01 < Acme::Client::Resources::Challenges::Base
+ CHALLENGE_TYPE = 'http-01'.freeze
+ CONTENT_TYPE = 'text/plain'.freeze
+
+ def content_type
+ CONTENT_TYPE
+ end
+
+ def file_content
+ authorization_key
+ end
+
+ def filename
+ ".well-known/acme-challenge/#{token}"
+ end
+end