View Issue Details

This bug affects 1 person(s).
 8
IDProjectCategoryView StatusLast Update
18184Bug reportsRemoteControlpublic2023-04-03 10:58
Reporterdjelusive Assigned To 
PrioritynoneSeveritycrash 
Status closedResolutionfixed 
Product Version5.3.x 
Summary18184: cpd_importParticipants with encryption turned on, fails to save the participant encrypted in CPDB, causing 500 error to CPDB
Description

Hi All,
I have setup a laravel site to use cpd_importParticipants to create new entries into the CPDB. This does work unless the CPDB fields are encrypted.
The outcome is a complete block from using CPDB with an Error 500 Internal Server Error.
"Wrong decryption key! Decryption key has changed since this data were last saved, so data can't be decrypted. Please consult our manual at https://manual.limesurvey.org/Data_encryption#Errors. "

After reading through previous bug fixes, one that is still open: 16725 - https://bugs.limesurvey.org/view.php?id=16725#bugnotes
I realised the same thing is actually happening to me, just using the API rather than in the GUI.

I have been able to revice the CPDB by manually removing the newly created participant from the database, which when looking at it is not encrypted.

Steps To Reproduce

Steps to reproduce

  1. Turn on encryption for firstname, lastname and email within the CPDB
  2. Create an appropriate script for using the API. calling cpd_importParticipants
  3. Send a new request using the script.
  4. Check the CPDB in the limesurvey GUI

Expected result

Saves the participant in the database, encrypted according to the settings in the CPDB.
Able to open the CPDB in the GUI as normal

Actual result

Fails to encrypt upon saving the participant to the database
Causes an Error 500 "wrong decryption key!" issue.

TagsNo tags attached.
Attached Files
Bug heat8
Complete LimeSurvey version number (& build)5.3.18+220530
I will donate to the project if issue is resolvedYes
BrowserFirefox
Database type & versionMySQL 5.7.32-35
Server OS (if known)
Webserver software & version (if known)
PHP Version7.4.29

Relationships

duplicate of 18365 closedollehar cpd_importParticipants not encrypting users attributes 
related to 16725 feedbackp_teichmann Cannot add users from CPDB to survey with encryption due to email field issues 

Users monitoring this issue

djelusive

Activities

gabrieljenik

gabrieljenik

2022-06-13 18:56

manager   ~70348

PR: https://github.com/LimeSurvey/LimeSurvey/pull/2464

gabrieljenik

gabrieljenik

2022-07-05 15:19

manager   ~70733

@djelusive Maybe you can help testing the PR?

guest

guest

2023-04-03 10:37

viewer   ~74337

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=34412

LimeBot

LimeBot

2023-04-03 10:58

administrator   ~74343

Fixed in Release 5.6.14+230403

Related Changesets

LimeSurvey: master 68296cc1

2023-04-03 10:37:16

Gabriel Jenik


Committer: GitHub Details Diff
Fixed issue 18184: cpd_importParticipants with encryption turned on, fails to save the participant encrypted in CPDB, causing 500 error to CPDB (#2464)

Co-authored-by: encuestabizdevgit <devgit@encuesta.biz>
Co-authored-by: Lapiu Dev <devgit@lapiu.biz>
Affected Issues
18184
mod - application/helpers/remotecontrol/remotecontrol_handle.php Diff File
mod - tests/unit/helpers/remotecontrol/CPDImportParticpantsTest.php Diff File

Issue History

Date Modified Username Field Change
2022-06-08 04:43 djelusive New Issue
2022-06-08 04:43 djelusive File Added: Screenshot 500 Internal Server Error.png
2022-06-08 04:43 djelusive Issue Monitored: djelusive
2022-06-08 04:43 djelusive Bug heat 0 => 2
2022-06-08 23:40 gabrieljenik Relationship added related to 16725
2022-06-08 23:40 gabrieljenik Assigned To => gabrieljenik
2022-06-08 23:40 gabrieljenik Status new => acknowledged
2022-06-08 23:40 gabrieljenik Assigned To gabrieljenik =>
2022-06-09 18:22 gabrieljenik Assigned To => gabrieljenik
2022-06-09 18:22 gabrieljenik Status acknowledged => assigned
2022-06-13 18:56 gabrieljenik Status assigned => ready for code review
2022-06-13 18:56 gabrieljenik Note Added: 70348
2022-06-13 18:56 gabrieljenik Bug heat 2 => 4
2022-07-05 15:19 gabrieljenik Assigned To gabrieljenik =>
2022-07-05 15:19 gabrieljenik Status ready for code review => ready for testing
2022-07-05 15:19 gabrieljenik Note Added: 70733
2023-02-22 17:40 gabrieljenik Relationship added duplicate of 18365
2023-04-03 10:37 Changeset attached => LimeSurvey master 68296cc1
2023-04-03 10:37 guest Note Added: 74337
2023-04-03 10:37 guest Bug heat 4 => 6
2023-04-03 10:58 LimeBot Note Added: 74343
2023-04-03 10:58 LimeBot Status ready for testing => closed
2023-04-03 10:58 LimeBot Resolution open => fixed
2023-04-03 10:58 LimeBot Bug heat 6 => 8