Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-32647

Allow CORS on the fonts in /library

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 11.4
    • Fix Version/s: 12.0
    • Component/s: Library
    • Labels:
      None
    • Environment:
      Chrome.
    • 11 status:
      Please Merge
    • Test Plan:
      Hide
      • Add Lessons and Resources to a site.
      • Create a HTML page in resources and in the source view paste in: <span class="fa fa-external-link" aria-hidden="true"/>
      • In the lessons tool add an external resource and select the file that has just been uploaded.

      Check that the file display with a little font awesome icon and not a blank box. You can also check the console in the browser to see that it isn't complaining about refusing to load the fonts (checked in Chrome).

      Show
      Add Lessons and Resources to a site. Create a HTML page in resources and in the source view paste in: <span class="fa fa-external-link" aria-hidden="true"/> In the lessons tool add an external resource and select the file that has just been uploaded. Check that the file display with a little font awesome icon and not a blank box. You can also check the console in the browser to see that it isn't complaining about refusing to load the fonts (checked in Chrome).

      Description

      Currently if you have a page served by lessons that attempts to use web fonts from inside Sakai it will fail with an error of:

      Access to Font at 'https://staging.weblearn.ox.ac.uk/library/skin/morpheus-default/fonts/font-awesome/fontawesome-webfont.ttf?v=4.5.0' from origin 'null' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access.

      This doesn't apply when a page is served from resources as it doesn't have a Content-Security-Policy applied to it.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                buckett Matthew Buckett
                Reporter:
                buckett Matthew Buckett
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Git Source Code