aboutsummaryrefslogtreecommitdiff
path: root/src/mod_http_upload.erl
diff options
context:
space:
mode:
authorChristoph Scholz <christoph.scholz@gmail.com>2018-07-07 17:01:39 +0200
committerChristoph Scholz <christoph.scholz@gmail.com>2018-07-07 17:01:39 +0200
commitfbdcc44fd973209a04283633b48ac96ce340e9a1 (patch)
treec40a5e36edd1f176534455edb9f5f2ebeaaf5705 /src/mod_http_upload.erl
parentRemove cyrsasl elixir tests, we no longer have it (diff)
fix HMAC for external_secret
Diffstat (limited to 'src/mod_http_upload.erl')
-rw-r--r--src/mod_http_upload.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mod_http_upload.erl b/src/mod_http_upload.erl
index 377e625cd..846071a2a 100644
--- a/src/mod_http_upload.erl
+++ b/src/mod_http_upload.erl
@@ -688,7 +688,7 @@ make_query_string(Slot, Size, #state{external_secret = Key}) when Key /= <<>> ->
UrlPath = str:join(Slot, <<$/>>),
SizeStr = integer_to_binary(Size),
Data = <<UrlPath/binary, " ", SizeStr/binary>>,
- HMAC = str:to_hexlist(crypto:hmac(sha256, Data, Key)),
+ HMAC = str:to_hexlist(crypto:hmac(sha256, Key, Data)),
<<"?v=", HMAC/binary>>;
make_query_string(_Slot, _Size, _State) ->
<<>>.