Skip to content

Instantly share code, notes, and snippets.

@buggtb
Forked from madis/gist:4650014
Last active January 26, 2016 20:40
Show Gist options
  • Save buggtb/7bdface06dd29a053c97 to your computer and use it in GitHub Desktop.
Save buggtb/7bdface06dd29a053c97 to your computer and use it in GitHub Desktop.
Testing CORS OPTIONS request with curl
curl \
--verbose \
--request OPTIONS \
http://81.174.164.218:8181/cxf/rest/core/user \
--header 'Origin: http://localhost:9292' \
--header 'Access-Control-Request-Headers: Origin, Accept, Content-Type' \
--header 'Access-Control-Request-Method: GET'
# http://nils-blum-oeste.net/cors-api-with-oauth2-authentication-using-rails-and-angularjs/#.UQJeLkp4ZyE
# http://blog.carbonfive.com/2012/02/27/supporting-cross-domain-ajax-in-rails-using-jsonp-and-cors/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment