Turned out this is a known bug in Android’s class implementation. Calling Connection.setRequestProperty( "Accept-Encoding", "" );
before connecting can be used as workaround.
More Related Contents:
- How to use java.net.URLConnection to fire and handle HTTP requests
- Can I override the Host header where using java’s HttpUrlConnection class?
- How do you write to a folder on an SD card in Android?
- org.apache.http.entity.FileEntity is deprecated in Android 6 (Marshmallow)
- How do I do a HTTP GET in Java? [duplicate]
- Android download binary file problems
- How do I make an http request using cookies on Android?
- Resume http file download in java
- Can you explain the HttpURLConnection connection process?
- Android project using httpclient –> http.client (apache), post/get method
- How to allow users to check for the latest app version from inside the app?
- What exactly does URLConnection.setDoOutput() affect?
- Android HttpPost: how to get the result
- How to enable wire logging for a java HttpURLConnection traffic?
- java.io.IOException : No authentication challenges found
- how to resume an interrupted download – part 2
- How to get response body using HttpURLConnection, when code other than 2xx is returned?
- How to get string response from Retrofit2?
- Sending HTTP Post Request with Android
- URLConnection getContentLength() is returning a negative value
- How to Reuse HttpUrlConnection? [duplicate]
- Read error response body in Java
- How to modify the header of a HttpUrlConnection
- IOException: “Received authentication challenge is null” (Apache Harmony/Android)
- How do I persist cookies when using HTTPUrlConnection?
- how to resume an interrupted download
- Reading binary file from URLConnection
- Send HTTP GET request with header
- How to send a String array as basic name value pair as HTTPPOST?
- Digest authentication in Android using HttpURLConnection