I'm experiencing an odd problem with HttpClient 4.1.1. I perform a GET on a document and then use the following code to get the bytes of the response entity (assuming a 200 status code):
byte[] responseEntity = EntityUtils.toByteArray(response.getEntity()); The problem I'm having is that this returns 16 fewer bytes than are actually in the document. So far I've checked: - that downloading the file via wget gives me the expected byte account - that the downloaded content is not compressed The document itself has a digital signature over it and this is failing to validate with the content as downloaded by HttpClient, but not with the document downloaded by wget so there is some material difference in the canonical form of the document (i.e., it's not just a lack of a new line at the start/end of the document). Any thoughts? Is EntityUtils.toByteArray not the right method to use to get the complete byte[] of the response entity? Thanks. -- Chad La Joie http://itumi.biz trusted identities, delivered --------------------------------------------------------------------- To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org