Skip to content

Commit

Permalink
zs3:head needs to pass amz security headers
Browse files Browse the repository at this point in the history
  • Loading branch information
Nick Levine committed Sep 30, 2016
1 parent 4acf54f commit 64949b1
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions interface.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,16 @@
"Return three values: the HTTP status, an alist of Drakma-style HTTP
headers, and the HTTP phrase, with the results of a HEAD request for
the object specified by the optional BUCKET and KEY arguments."
(let ((response
(submit-request (make-instance 'request
:method :head
:bucket bucket
:key key
:parameters parameters))))
(let* ((security-token (security-token *credentials*))
(response
(submit-request (make-instance 'request
:method :head
:bucket bucket
:key key
:amz-headers
(when security-token
(list (cons "security-token" security-token)))
:parameters parameters))))

(values (http-headers response)
(http-code response)
Expand Down

0 comments on commit 64949b1

Please sign in to comment.