summaryrefslogtreecommitdiff
path: root/src/acme_challenge.erl
diff options
context:
space:
mode:
authorKonstantinos Kallas <konstantinos.kallas@hotmail.com>2017-08-19 17:47:05 +0300
committerKonstantinos Kallas <konstantinos.kallas@hotmail.com>2017-08-19 17:47:05 +0300
commit9b3e160e1840fa83e0452b351c6d2fbbd1553801 (patch)
tree52e8d624e93bc76640558b847b5033b485fe6266 /src/acme_challenge.erl
parentDelete a development acme module (diff)
Remove some debugging INFO_MSGs
Diffstat (limited to 'src/acme_challenge.erl')
-rw-r--r--src/acme_challenge.erl6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/acme_challenge.erl b/src/acme_challenge.erl
index de0df836..0e9e395e 100644
--- a/src/acme_challenge.erl
+++ b/src/acme_challenge.erl
@@ -21,8 +21,6 @@
%% TODO: Maybe validate request here??
process(LocalPath, Request) ->
Result = ets_get_key_authorization(LocalPath),
- ?INFO_MSG("Trying to serve: ~p at: ~p", [Request, LocalPath]),
- ?INFO_MSG("Http Response: ~p", [Result]),
{200,
[{<<"Content-Type">>, <<"text/plain">>}],
Result}.
@@ -31,7 +29,6 @@ process(LocalPath, Request) ->
-spec key_authorization(bitstring(), jose_jwk:key()) -> bitstring().
key_authorization(Token, Key) ->
Thumbprint = jose_jwk:thumbprint(Key),
- %% ?INFO_MSG("Thumbprint: ~p~n", [Thumbprint]),
KeyAuthorization = erlang:iolist_to_binary([Token, <<".">>, Thumbprint]),
KeyAuthorization.
@@ -84,7 +81,8 @@ solve_challenge1(Chal = #challenge{type = <<"http-01">>, token=Tkn}, Key) ->
ets_put_key_authorization(Tkn, KeyAuthz),
{ok, Chal#challenge.uri, KeyAuthz};
solve_challenge1(Challenge, _Key) ->
- ?INFO_MSG("Challenge: ~p~n", [Challenge]).
+ ?ERROR_MSG("Unkown Challenge Type: ~p", [Challenge]),
+ {error, unknown_challenge}.
%% Old way of solving challenges