From ec179a826908d9f1b55dd027f68cd7cde6b95008 Mon Sep 17 00:00:00 2001 From: To-om Date: Fri, 28 Jan 2022 09:24:08 +0100 Subject: [PATCH] #1534 Fix filename encoding --- thehive/app/org/thp/thehive/controllers/v0/AttachmentCtrl.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thehive/app/org/thp/thehive/controllers/v0/AttachmentCtrl.scala b/thehive/app/org/thp/thehive/controllers/v0/AttachmentCtrl.scala index e3b7ef0da4..ace88b2086 100644 --- a/thehive/app/org/thp/thehive/controllers/v0/AttachmentCtrl.scala +++ b/thehive/app/org/thp/thehive/controllers/v0/AttachmentCtrl.scala @@ -88,7 +88,7 @@ class AttachmentCtrl @Inject() ( header = ResponseHeader( 200, Map( - "Content-Disposition" -> s"""attachment; filename="$filename.zip"""", + "Content-Disposition" -> s"""attachment; ${HttpHeaderParameterEncoding.encode("filename", filename)}.zip""", "Content-Type" -> "application/zip", "Content-Transfer-Encoding" -> "binary", "Content-Length" -> Files.size(f).toString