New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[policy] [xml-json] Remove charset in content-type header #391

Closed
AnselmeDewavrin opened this Issue Dec 27, 2016 · 1 comment

Comments

Projects
None yet
3 participants
@AnselmeDewavrin

AnselmeDewavrin commented Dec 27, 2016

Expected Behavior

xml2json only replaces application/xml part by application/json in the content-type header, but leaves charset part untouched.

Current Behavior

xml2json removes charset part of the content-type header

Possible Solution

Steps to Reproduce (for bugs)

  1. have an xml backend not specifying the content-type charset
  2. add a transform-header policy on the response scope, adding a content-type with charset=utf-8
  3. add a xml2json policy

Context

Your Environment

  • Version used: 1.1.0
  • Browser Name and version: postman
  • Operating System and version: win10

@brasseld brasseld added the type: bug label Dec 27, 2016

@brasseld brasseld added this to the 1.2.0 milestone Dec 27, 2016

@brasseld

This comment has been minimized.

Member

brasseld commented Jan 3, 2017

According to the RFC7158 Section 8.1, the charset will be set to UTF-8 by default for both request and response content-type.

brasseld added a commit to gravitee-io/gravitee-policy-xml-json that referenced this issue Jan 3, 2017

@brasseld brasseld self-assigned this Jan 3, 2017

@brasseld brasseld changed the title from xml2json remove charset in content-type header to [policy] [xml-json] Remove charset in content-type header Jan 3, 2017

NicolasGeraud added a commit to gravitee-io/gravitee-policy-xml-json that referenced this issue Jan 3, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment