Re: [Resteasy-users] @OPTIONS / allowing cross-site scripting

2014-04-03 Thread Rajshekhar AndalaPisharam
Its good to hear it worked for you :). Thanks A.P. Rajshekhar - Original Message - From: "andrew simpson" To: "Rajshekhar AndalaPisharam" Cc: resteasy-users@lists.sourceforge.net Sent: Friday, April 4, 2014 10:04:29 AM Subject: Re: [Resteasy-users] @OPTIONS /

Re: [Resteasy-users] @OPTIONS / allowing cross-site scripting

2014-04-03 Thread andrew simpson
Rajshekhar, thanks for this suggestion, that worked for me. Here's a pointer to an implementation. https://gist.github.com/ams10961/9968111 Andrew On Wed, Apr 2, 2014 at 9:03 AM, Rajshekhar AndalaPisharam < randa...@redhat.com> wrote: > Andrew > > The best option is to make an exception mappe

Re: [Resteasy-users] @OPTIONS / allowing cross-site scripting

2014-04-02 Thread Bill Burke
In 3.0.7 I implemented a CORS filter: https://github.com/resteasy/Resteasy/blob/master/jaxrs/resteasy-jaxrs/src/main/java/org/jboss/resteasy/plugins/interceptors/CorsFilter.java On 4/2/2014 3:03 AM, Rajshekhar AndalaPisharam wrote: > Andrew > > The best option is to make an exception mapper for

Re: [Resteasy-users] @OPTIONS / allowing cross-site scripting

2014-04-02 Thread Rajshekhar AndalaPisharam
Andrew The best option is to make an exception mapper for DefaultOptionsMethodException and add the CORS headers within the toResponse method of the mapper. For example: @Provider public class OptionsMethodExceptionMapper implements ExceptionMapper{ @Override public Response toResponse(D