long email subject with backticks breaks pop3 forever
Posted: Wed Mar 11, 2020 10:30 am
Hesk 2.8.2
Mods 2018.2.0
This is more of a bug report where sending a certain subject line breaks the helpdesk
I found the helpdesk no longer got new emails, creating on website still worked and generated tickets, but emailing directly to support@ didn't end up in helpdesk
To replicate:
Send an email with subject:
FW: along.emailemails.safaaacmm.do.do backtick break `key` email
Sending a short subject with backticks got through, but a long subject with backticks fails
When i turn on debug i get this in
/inc/mail/hesk_pop3.php
Error:
Can't execute SQL: INSERT INTO `hesk_tickets` ( `trackid`, `name`, `email`, `category`, `priority`, `subject`, `message`, `dt`, `lastchange`, `articles`, `ip`, `language`, `openedby`, `owner`, `attachments`, `merged`, `status`, `latitude`, `longitude`, `html`, `user_agent`, `screen_resolution_height`, `screen_resolution_width`, `due_date`, `history` , `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`, `custom9`, `custom10`, `custom11`, `custom12`, `custom13`, `custom14`, `custom15`, `custom16`, `custom17`, `custom18`, `custom19`, `custom20`, `custom21`, `custom22`, `custom23`, `custom24`, `custom25`, `custom26`, `custom27`, `custom28`, `custom29`, `custom30`, `custom31`, `custom32`, `custom33`, `custom34`, `custom35`, `custom36`, `custom37`, `custom38`, `custom39`, `custom40`, `custom41`, `custom42`, `custom43`, `custom44`, `custom45`, `custom46`, `custom47`, `custom48`, `custom49`, `custom50` ) VALUES ( 'G1A-EQW-S4MU', 'Test Jones', 'test@testtest.com', '1', '3', 'FW: along.emailemails.safaaacmm.do.do backtick break `key` email', '[No message]', NOW(), NOW(), NULL, '97.57.10.6', 'English', '-2', '0', '', '', '0', '', '', '0', '', NULL, NULL, NULL, '' , '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '' )
MySQL said:
Data too long for column 'subject' at row 1
WARNING
Debug mode is enabled. Make sure you disable debug mode in settings once HESK is installed and working properly.
The way to fix is to delete the email with long subject and backticks
then turn on debug mode, and visit /inc/mail/hesk_pop3.php to check for any other errors
Mods 2018.2.0
This is more of a bug report where sending a certain subject line breaks the helpdesk
I found the helpdesk no longer got new emails, creating on website still worked and generated tickets, but emailing directly to support@ didn't end up in helpdesk
To replicate:
Send an email with subject:
FW: along.emailemails.safaaacmm.do.do backtick break `key` email
Sending a short subject with backticks got through, but a long subject with backticks fails
When i turn on debug i get this in
/inc/mail/hesk_pop3.php
Error:
Can't execute SQL: INSERT INTO `hesk_tickets` ( `trackid`, `name`, `email`, `category`, `priority`, `subject`, `message`, `dt`, `lastchange`, `articles`, `ip`, `language`, `openedby`, `owner`, `attachments`, `merged`, `status`, `latitude`, `longitude`, `html`, `user_agent`, `screen_resolution_height`, `screen_resolution_width`, `due_date`, `history` , `custom1`, `custom2`, `custom3`, `custom4`, `custom5`, `custom6`, `custom7`, `custom8`, `custom9`, `custom10`, `custom11`, `custom12`, `custom13`, `custom14`, `custom15`, `custom16`, `custom17`, `custom18`, `custom19`, `custom20`, `custom21`, `custom22`, `custom23`, `custom24`, `custom25`, `custom26`, `custom27`, `custom28`, `custom29`, `custom30`, `custom31`, `custom32`, `custom33`, `custom34`, `custom35`, `custom36`, `custom37`, `custom38`, `custom39`, `custom40`, `custom41`, `custom42`, `custom43`, `custom44`, `custom45`, `custom46`, `custom47`, `custom48`, `custom49`, `custom50` ) VALUES ( 'G1A-EQW-S4MU', 'Test Jones', 'test@testtest.com', '1', '3', 'FW: along.emailemails.safaaacmm.do.do backtick break `key` email', '[No message]', NOW(), NOW(), NULL, '97.57.10.6', 'English', '-2', '0', '', '', '0', '', '', '0', '', NULL, NULL, NULL, '' , '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '' )
MySQL said:
Data too long for column 'subject' at row 1
WARNING
Debug mode is enabled. Make sure you disable debug mode in settings once HESK is installed and working properly.
The way to fix is to delete the email with long subject and backticks
then turn on debug mode, and visit /inc/mail/hesk_pop3.php to check for any other errors