Hi Mikkel, As you said, the problem lies in a JDK bug (details at: http://www.restlet.org/faq#18). One workaround is to use JDK 6 beta 2 if possible.
Otherwise, I don't know how to workaround the bug. Setting the content type to "" may solve the issue? Could you try? Otherwise, we always have the possibility to consider the content type to be "application/x-www-form-urlencoded" when signing for AWS... Best regards, Jerome > -----Message d'origine----- > De : news [mailto:[EMAIL PROTECTED] De la part de Mikkel Jensen > Envoyé : vendredi 27 octobre 2006 19:44 > À : [email protected] > Objet : Re: Adding standard headers > > Hi Jerome, > > Just tried implementing the AWS challenge scheme as you > suggested and it works > great! > > The only problem I seem to have is with 'empty' requests: > When there is no entity representation in the request the > Content-type is set > to a default value of 'application/x-www-form-urlencoded' for > all request > methods except 'PUT' - in which case the header is left out!!! > > I'm aware that the problem lies with the HttpURLConnection > class. But, if you > have any suggestions for a way to remove (or explicitly set) > the content-type > I would very much like to hear it! > > So far the rule stated above seems to hold up so I am able to > construct the AWS > credential correctly. It just seems like bad programming > style to have to > depend on some fairly undocumented default value. > > - Mikkel > > >

