View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
19741Bug reportsQuestion editorpublic2024-09-11 12:17
Reporterrami.shenouda Assigned Top_teichmann  
PrioritynoneSeveritycrash 
Status assignedResolutionopen 
Product Version6.6.x 
Summary19741: Out of memory because of adding inline images in questoins/questionGroups description.
Description

The customer was unable to open their survey and encountered a 500 error. I exported the survey, and its size was 47 MB, even though it only had around 100-140 questions.

When I tried to import it, I encountered "out of memory" errors. Upon investigation, I noticed that the user had included base64 images in the questions/questionGroups descriptions, with some of these descriptions being as large as 15 MB.

I was debugging this issue with Patrick, and we came to the following conclusions:

  1. Base64 images should not be allowed. And because they bypass the file storage limit detection.
  2. The query should be optimized to load the data stored in the tables. If we can save it, we should also be able to load it.
Steps To Reproduce

Steps to reproduce

  1. Create a question
  2. Drag and drop images to the question CKEditor
  3. do step (2) multiple times or in many questions
  4. if you look at the source code in the CkEditor you will see that the images were added as base64 and the size is huge.

Expected result

  1. The application should show an error that we can't upload base64 images. the user should be only able to add images/files using the file manager. or something similar.

Actual result

  1. The image is added to the question and also saved in the database of course.
  2. The user can't open the survey anymore due to memory limit issues in both SQL and PHP.
TagsNo tags attached.
Attached Files
1.png (93,040 bytes)   
1.png (93,040 bytes)   
2.png (6,324 bytes)   
2.png (6,324 bytes)   
3.png (15,507 bytes)   
3.png (15,507 bytes)   
4.png (197,894 bytes)
Bug heat4
Complete LimeSurvey version number (& build)6.x
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMYSQL
Server OS (if known)
Webserver software & version (if known)
PHP Version8.x

Relationships

related to 18275 confirmed Long free text question cannot handle excessively long input 

Users monitoring this issue

There are no users monitoring this issue.

Activities

tibor.pacalat

tibor.pacalat

2024-09-10 15:30

administrator   ~80947

This issue should be resolved after we updated to Ckeditor5.
@p_teichmann is currently working on this.
It might be automatically fixed, because CK5 has a special plugin for that (base64 https://ckeditor.com/docs/ckeditor5/24.0.0/features/image-upload/base64-upload-adapter.html).

DenisChenu

DenisChenu

2024-09-10 15:54

developer   ~80948

related to 18275: Long free text question cannot handle excessively long input

We use mediumtext https://mariadb.com/kb/en/mediumtext/ for question and help text (on mariadb)

Issue History

Date Modified Username Field Change
2024-09-10 15:22 rami.shenouda New Issue
2024-09-10 15:22 rami.shenouda File Added: 1.png
2024-09-10 15:22 rami.shenouda File Added: 2.png
2024-09-10 15:22 rami.shenouda File Added: 3.png
2024-09-10 15:22 rami.shenouda File Added: 4.png
2024-09-10 15:23 tibor.pacalat Assigned To => gabrieljenik
2024-09-10 15:23 tibor.pacalat Status new => assigned
2024-09-10 15:30 tibor.pacalat Note Added: 80947
2024-09-10 15:30 tibor.pacalat Bug heat 0 => 2
2024-09-10 15:52 DenisChenu Relationship added related to 18275
2024-09-10 15:54 DenisChenu Note Added: 80948
2024-09-10 15:54 DenisChenu Bug heat 2 => 4
2024-09-11 12:17 c_schmitz Assigned To gabrieljenik => p_teichmann