Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -132,9 +132,11 @@
"For input string: \"1%\"")]
(cert-from-request "%1%2"))))
(testing "fails as expected when URL encoded properly but base64 content malformed"
(is (thrown+? [:kind :bad-request
:msg (str "Unable to parse x-client-cert into "
"certificate: -----END CERTIFICATE not found")]
(is (thrown+? #(and
(= (:kind %) :bad-request)
(re-matches
#"Unable to parse x-client-cert into certificate: -----END CERTIFICATE(-----)? not found"
(:msg %)))
(cert-from-request
"-----BEGIN%20CERTIFICATE-----%0AM"))))
(testing "fails when cert not in the payload"
Expand Down