-
Notifications
You must be signed in to change notification settings - Fork 3.5k
[SECUR-105] fix: csv injection vulnerability sanitization #8611
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: preview
Are you sure you want to change the base?
Conversation
📝 WalkthroughWalkthroughIntroduces CSV formula injection prevention by adding a new sanitization utility module that prefixes values starting with formula triggers ( Changes
Estimated Code Review Effort🎯 2 (Simple) | ⏱️ ~15 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Linked to Plane Work Item(s) This comment was auto-generated by Plane |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@apps/api/plane/utils/csv_utils.py`:
- Around line 1-4: This file is missing the standard repository license header;
add the project's canonical license comment block at the very top of the module
(above the existing module docstring/comment and before _CSV_FORMULA_TRIGGERS)
so the addlicense check passes; copy the exact header used in other files and
ensure it precedes the existing content (refer to this module's top-level symbol
_CSV_FORMULA_TRIGGERS to locate the file and verify header placement).
| # CSV utility functions for safe export | ||
|
|
||
| # Characters that trigger formula evaluation in spreadsheet applications | ||
| _CSV_FORMULA_TRIGGERS = frozenset(("=", "+", "-", "@", "\t", "\r", "\n")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add the standard license header to satisfy the addlicense check.
The pipeline is failing the copyright check; this file is missing the standard header used across the repo.
🧾 Proposed fix
+# Copyright (c) 2023-present Plane Software, Inc. and contributors
+# SPDX-License-Identifier: AGPL-3.0-only
+# See the LICENSE file for details.
+
# CSV utility functions for safe export🧰 Tools
🪛 GitHub Actions: Copy Right Check
[error] 1-1: Copyright check failed. The command 'addlicense -check -f COPYRIGHT.txt -ignore "/migrations/" $(git ls-files '*.py')' exited with code 1.
🤖 Prompt for AI Agents
In `@apps/api/plane/utils/csv_utils.py` around lines 1 - 4, This file is missing
the standard repository license header; add the project's canonical license
comment block at the very top of the module (above the existing module
docstring/comment and before _CSV_FORMULA_TRIGGERS) so the addlicense check
passes; copy the exact header used in other files and ensure it precedes the
existing content (refer to this module's top-level symbol _CSV_FORMULA_TRIGGERS
to locate the file and verify header placement).
Description
Summary by CodeRabbit
Release Notes