View Issue Details

This bug affects 1 person(s).
 2
IDProjectCategoryView StatusLast Update
17455Bug reportsOtherpublic2021-07-16 19:07
ReporterDenisChenu Assigned ToDenisChenu  
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version3.25.20 
Summary17455: SQL server : CDbException with invalid survey id
Description

With an invalid survey id : not an integer : SQL server throw
«CDbCommand failed to execute the SQL statement: SQLSTATE[22018]: [Microsoft][ODBC Driver 11 for SQL Server][SQL Server]Conversion failed when converting the nvarchar value 'abcd' to data type int.»

Steps To Reproduce
  1. Find a sql server
  2. launch any survey url
  3. Replace the survey id by abcd
Additional Information

I really think Yii+PDO do the job here … but not

It's easy to fix for survey only (public part) needed.

For admin part (qid/gidetc …) we check validity : https://github.com/LimeSurvey/LimeSurvey/blob/f8ee40d663eb346b620091b1253266948b73db69/application/core/Survey_Common_Action.php#L165

If this was wrapped in a clean 500 error : why not, but here : no.

TagsNo tags attached.
Bug heat2
Complete LimeSurvey version number (& build)3.27.7
I will donate to the project if issue is resolvedNo
Browsernot relevant
Database type & versionmssql 12.00.6433
Server OS (if known)IIS
Webserver software & version (if known)windows
PHP Version7.4.20

Users monitoring this issue

There are no users monitoring this issue.

Activities

Issue History

Date Modified Username Field Change
2021-07-16 19:00 DenisChenu New Issue
2021-07-16 19:00 DenisChenu File Added: Capture d’écran du 2021-07-16 18-36-10.png
2021-07-16 19:00 DenisChenu File Deleted: Capture d’écran du 2021-07-16 18-36-10.png
2021-07-16 19:01 DenisChenu Note Added: 65489
2021-07-16 19:01 DenisChenu File Added: Capture d’écran du 2021-07-16 18-36-10.png
2021-07-16 19:07 DenisChenu Assigned To => DenisChenu
2021-07-16 19:07 DenisChenu Status new => closed
2021-07-16 19:07 DenisChenu Resolution open => fixed
2021-07-16 19:07 DenisChenu Note Added: 65491