Accessing Files from Remote Servers in Tizen Web Applications

Original Created Sep 26, 2016 | Regeneration Apr 22, 2026

In my Tizen web application, I need to access data files from various public websites that I don't own. I attempted to use Ajax for this purpose, but I'm not receiving any response.

My application privileges are configured as follows:

<tizen:privilege name="http://tizen.org/privilege/internet"/>
<tizen:privilege name="http://tizen.org/privilege/download"/>

What am I missing in this setup? Is it necessary for the target websites to accept cross-domain requests? If cross-origin restrictions are the issue, I would need alternative solutions.

Problem Understanding

The issue involves two main challenges:

  1. Proper configuration of network access permissions in the Tizen application
  2. Potential Cross-Origin Resource Sharing (CORS) restrictions when accessing external domains

Solution Methods

  1. Configure Network Access Permissions:

    • Add domain access permissions in your config.xml file
    • You can specify individual domains or use wildcards (*) for broader access
  2. Handle CORS Restrictions:

    • If the target server doesn't support CORS, consider using a proxy server
    • Alternatively, if you control the server, implement proper CORS headers

Code Examples

  1. Basic domain access configuration:
<access origin="http://example.com" subdomains="true"></access>
<access origin="http://anothersite.com" subdomains="true"></access>
  1. Wildcard access (use with caution):
<access origin="*" subdomains="true"></access>

Additional Tips

  • Always specify the exact domains you need rather than using wildcards when possible for better security
  • For CORS-related issues, refer to the official documentation at Samsung Tizen OS CORS Guide
  • Test your application with different domain configurations to find the most secure setup that meets your requirements

Customize your cookie preferences

You can enable or disable non-essential cookies. Essential cookies are always on to ensure the site works properly and to keep you signed in.

Necessary

These cookies are necessary for the website to function properly and cannot be switched off. They help with things like logging in and setting your privacy preferences.

Always on

Analytics

These cookies help us improve the site by tracking which pages are most popular and how visitors move around the site.

Enable analytics cookies
Public Forum Public Forum
Employees only. Please sign in with your company account.