|
A patch file demonstrating not to use file.php for SCORM content transfer, to speed up SCORM page loading.
While loading a course, a series of scripts are executed on the server. We zoomed in on these scripts that load the SCOs and removed redundant code for a system running courses locally from the server on a php 5 and apache 2. We replaced the original file file.php with a Fastfileparser.php and redid the tests. Maybe you can also test SCORM loading with a SCORM page containing a lot of small image files. Hi Gerd, can you plese provide the fastfileparser file as well? - thanks.
also - it looks like you're using an old version of LoadSCO.php - we no longer use get_file_url() as slashargs don't work with SCORM so there's no point in checking for it. - see
In the diagram you can see the concept of our solution. Please have a look at it. We would appreciate your feedback.
Ok Dan,
We usualy do all our test on Moodle version 1.9.2+, since that's the environment that we are preparing for production. We've also tested with the head version of CVS, with simular results. Please check out the diagram for a possible solution. Hi Gerd,
I'm still not sold on this. - You haven't provided an example of your fastfileparser.php. Also one of the critical functions of file.php is the security checks - to check if the user is allowed access to the file they have requested. How will your fastfileparser.php file address this? Also - you still have not addressed my query regarding your claims on load time. 1 sec per file does not seem correct.
hello,
the I did not read your patch yet, going to do that later today thanks for the report anyway Dan,
Following your questions you can find:
We are aware that this does not cover all security issues yet, but we think that we can look at this part of the code for performance improvement and then again at the whole (security issues included). Hi Gerd,
as it stands, your patch introduces more issues than it solves. Security is very important for most Scorm designers. - using your patch anyone could obtain a scorm package.... in fact... using your patch, anyone could obtain any data they wanted from moodledata - including submitted assignments, and a range of data that should not be available without authenticating. The script you have written introduces this massive security hole into Moodle. Also - your script requires manual configuration of the moodledata path. the moodledata path is already stored in config.php - any other script should obtain that information from config.php and should not require manual configuration. thanks, Dear Dan,
You were quite right to point out the security issue in regard to the fastfileparser.
Steps of the current system: Steps of the solution proposed: See attachments '20080926_fastFileParser.php' and ''20080926_loadSCO.php'. From our test results we think it is worth while to investigate this solution, although we still have the path to the data- folder and mimetypes hardcoded at this time. It would be nice to find a structual solution for this also. One last remark: we have noticed that in the new version from CVS uploading SCORM packages is limited to 1MB. At VDAB only 5 of a total of 160 SCORM packages are smaller than 1MB. Is there a special reason for this limit? Regards, Gerd Hi Gerd,
haven't had a chance to look at this further - I have a range of other things that need my focus. Also - Hard coding vars isn't a viable option. might look at this again in a couple of months. thanks, Dan Hi Dan,
I understand that you're very bussy at the moment. We keep on working on our version of the SCORM player because the performance issue is really critical, and even a show stopper, for going in production with Moodle. We will try to follow as closely as possible the guidelines for development for Moodle, this in order to provide in the end an alternative module for the SCORM player. The current version of our SCORM player includes:
The next problem that we will tackle is the SCORM communication API object. Remark: in the bottom left corner the activities block should be visible (= a customisation for VDAB) Kind regards, |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
as mentioned in response to your discussion posting here:
http://moodle.org/mod/forum/discuss.php?d=102356
I haven't seen a package behave in the manner you mention - 1sec per file. - this doesn't seem right - in fact this sounds like a badly configured browser or server - all files should be available to download concurrently instead of 1 at a time.
The File API for Moodle 2.0 is changing a lot, and the use of file.php will also be quite different - see here for more details:
http://docs.moodle.org/en/Development:File_API
We won't be looking at putting in a new file handler just for the SCORM objects at this stage. However this may be something we look into with the new File API in Moodle 2.0
thanks,
Dan