From 32c092523228f370edb5a8246a09881e0245e1a6 Mon Sep 17 00:00:00 2001 From: Andreas Fitzek Date: Wed, 4 Mar 2015 15:22:23 +0100 Subject: enabled CORS header --- pdf-as-web/build.gradle | 2 ++ pdf-as-web/src/main/webapp/WEB-INF/web.xml | 14 +++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/pdf-as-web/build.gradle b/pdf-as-web/build.gradle index 31c34ac6..765502f2 100644 --- a/pdf-as-web/build.gradle +++ b/pdf-as-web/build.gradle @@ -35,6 +35,8 @@ dependencies { compile 'org.apache.commons:commons-lang3:3.3.2' compile 'org.apache.cxf:cxf-rt-transports-http:3.0.1' compile 'org.apache.cxf:cxf-rt-frontend-jaxws:3.0.1' + compile 'com.thetransactioncompany:cors-filter:2.3' + providedCompile 'javax.servlet:javax.servlet-api:3.0.1' testCompile group: 'junit', name: 'junit', version: '4.+' } diff --git a/pdf-as-web/src/main/webapp/WEB-INF/web.xml b/pdf-as-web/src/main/webapp/WEB-INF/web.xml index b6cfb46d..5ed5d5a9 100644 --- a/pdf-as-web/src/main/webapp/WEB-INF/web.xml +++ b/pdf-as-web/src/main/webapp/WEB-INF/web.xml @@ -25,12 +25,21 @@ sitemesh com.opensymphony.sitemesh.webapp.SiteMeshFilter + + CORS + com.thetransactioncompany.cors.CORSFilter + + cors.allowOrigin + * + + + ExceptionCatchFilter /* @@ -39,7 +48,10 @@ UserAgentFilter /* - + + CORS + /* + -- cgit v1.2.3