From 951eb7e741f829328defe505d4b6859f7a736db4 Mon Sep 17 00:00:00 2001 From: Kingston Chan Date: Tue, 15 Mar 2022 23:56:09 +0900 Subject: [PATCH] Add header passthrough for osd-version and osd-xsrf --- aws-es-proxy.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/aws-es-proxy.go b/aws-es-proxy.go index f1f588ef..f88f1037 100644 --- a/aws-es-proxy.go +++ b/aws-es-proxy.go @@ -421,6 +421,14 @@ func addHeaders(src, dest http.Header) { dest.Add("Kbn-Version", val[0]) } + if val, ok := src["Osd-Version"]; ok { + dest.Add("Osd-Version", val[0]) + } + + if val, ok := src["Osd-Xsrf"]; ok { + dest.Add("Osd-Xsrf", val[0]) + } + if val, ok := src["Content-Type"]; ok { dest.Add("Content-Type", val[0]) }