•  
      request #6807 Can't call REST routes from another domain
    Infos
    #6807
    Benjamin Dauton (bdauton_enalean)
    2014-05-07 14:06
    2014-05-05 09:29
    6848
    Details
    Can't call REST routes from another domain
    There is "Access-Control-Allow-Methods" header, but I think "Access-Control-Allow-Origin" is missing.
    API
    development
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Empty
    Stage
    Nicolas Terray (nterray)
    Closed
    2014-05-07
    Attachments
    Empty
    References
    Referencing request #6807

    Artifact Tracker v5

    rel #6686 7.1

    Follow-ups

    User avatar
    The version number used to package the rest api were not upgraded. Done for Tuleap 7.0.99.6.

    Thanks for your input!

    • Status changed from Verified to Closed
    • Close date set to 2014-05-07
    User avatar

    The .htaccess that should send missing headers is not correct on tuleap.net for an unknown reason (/me guess that it is a packaging issue).

    On my working copy:

    <IfModule mod_headers.c>
        Header set Access-Control-Allow-Origin *
        Header set Access-Control-Allow-Credentials true
        Header set Access-Control-Allow-Headers "Accept, Accept-Charset, Authorization, Content-Type, Origin"
    </IfModule>
    <IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteRule ^$ index.php [QSA,L]
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ index.php [QSA,L]
    </IfModule>

    On tuleap.net:

    <IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteRule ^$ index.php [QSA,L]
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ index.php [QSA,L]
    </IfModule>

     


    • Status changed from New to Verified
    • Assigned to changed from None to Nicolas Terray (nterray)