silkimen / cordova-plugin-advanced-http

Cordova / Phonegap plugin for communicating with HTTP servers. Allows for SSL pinning!
MIT License
391 stars 313 forks source link

[Bug] [Android] Accept-Charset header #482

Open gasperinn opened 1 year ago

gasperinn commented 1 year ago

Overview of the Issue

I am having problems with sending requests to Authenticate Server from an Ionic 3 app as the request is being denied (403) because "Accept-Charset" header is being set as "UTF-8". As described here, this header should not be used anymore.

Operating System

Android only

Suggest a Fix

In class CordovaHttpBase, in function prepareRequest the line 136 where the header "Accept-Charset" is set should be deleted :

request.acceptCharset("UTF-8");

silkimen commented 11 months ago

Hi @gasperinn, thanks for the catch! Would you please provide a PR? Just saw, @ciknowles already did!