Adjusting Tomcat Security Settings

Posted by cjohnston on 29-Jul-2013 14:09

Hello,

I'm running into a JS alert every time I open the mobile web application or deploy the BlackBerry app to my BB device and open it. I followed BlackBerry's guidelines for converting an HTML5 web app to a BlackBerry app.

When I open the mobile web app in Chrome, the console of the Chrome dev tools tells me 'XMLHttpRequest cannot load http://<my ip address>:<my Tomcat web server port number>/<my mobile service>/static/home.html. Origin null is not allowed by Access-Control-Allow-Origin.'

Based on a few articles on StackOverflow, this is a common issue and can be solved by adjusting the web server's security settings.

I've copied two .jar files into the /lib folder and added the CORS section of code into my web.xml file, yet I'm still having this issue. Has anyone run into this in OpenEdge mobile?

All Replies

Posted by egarcia on 30-Jul-2013 08:24

Hello,

Just a quick reply.

Have you tried the suggestion from the following link:

- http://supportforums.blackberry.com/t5/Web-and-WebWorks-Development/How-to-resolve-Origin-local-is-not-allowed-by-Access-Control/td-p/2275095

I hope this helps.

Posted by cjohnston on 30-Jul-2013 15:54

Thanks Egarcia! Following the instructions from that link solved my problem.

Cheers,

Cameron

This thread is closed