Ambassador: Unable to remove `Server` header

Created on 6 Mar 2020  路  4Comments  路  Source: datawire/ambassador

Describe the bug

I cannot remove the Server header from the responses.

To Reproduce
Steps to reproduce the behavior:

  1. Create the host, service and mapping from the getting started examples
  2. Modify the Mapping
apiVersion: getambassador.io/v2
kind: Mapping
metadata:
  name: quote-backend
  namespace: volker
spec:
  remove_response_headers:
  - x-envoy-upstream-service-time
  - server
  add_response_headers:
    server: MyServerHeaderValue
  prefix: /backend/
  service: quote
  1. curl the response with curl -I https://your-server.org/backend/
  2. See Server header is still there
HTTP/1.1 200 OK
content-type: application/json
date: Fri, 06 Mar 2020 12:10:01 GMT
content-length: 163
server: envoy

Expected behavior
Server header value should be MyServerHeaderValue

Versions (please complete the following information):

  • Ambassador: latest
  • Kubernetes environment: bare metal
  • Version latest

Additional context

This is an ongoing issue: https://github.com/datawire/ambassador/issues/307#issuecomment-412501905

[EDIT]
I tried all combinations: Removing the server header. Adding a server header (overwriting). Removing the header and adding a new one. All show the same behaviour.

stale

Most helpful comment

@riker09 It looks like Envoy doesn't support removing server header from response. But you can use ambassador Module to change the server value.

apiVersion: getambassador.io/v2
kind: Module
metadata:
  name: ambassador
spec:
  config:
    server_name: MyServerHeaderValue

All 4 comments

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

This is certainly one way to get rid of open issues. Auto-close them by a bot because they were never acknowledged.

I know this is not a super high priority issue, but total neglectance makes me wonder how serious you are about your open source engagement.

@riker09 It looks like Envoy doesn't support removing server header from response. But you can use ambassador Module to change the server value.

apiVersion: getambassador.io/v2
kind: Module
metadata:
  name: ambassador
spec:
  config:
    server_name: MyServerHeaderValue

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

psychonetic picture psychonetic  路  6Comments

kflynn picture kflynn  路  5Comments

ppeble picture ppeble  路  3Comments

nilanjan-samajdar picture nilanjan-samajdar  路  4Comments

klarose picture klarose  路  5Comments