SecureJuniorSecurityAuto-graded
Stop a CSV export from injecting spreadsheet formulas
User-supplied cells in a report export run as formulas when the file is opened in a spreadsheet. Escape them without losing any data.export_csv(rows) builds the CSV behind a Download report button, and the cells hold user input: display names, notes, ticket subjects. A customer opened a report in a spreadsheet and some cells ran as formulas instead of showing as text. Make the export safe to open. Ordinary values must come through unchanged, the output must stay valid CSV, and the original text of any cell you neutralise must still be recoverable.20 min
python
You're done when
- No cell built to run as a spreadsheet formula evaluates when the report is opened.
- Every cell you neutralise still holds its original text, so nothing is lost.
- The fix also holds on a second, different dataset, not just the sample rows.
What it measures
Spotting the riskSeeing that a file export can carry an attack into a program you don't control.
Full coverageHandling every way a cell can turn into a formula, and checking the fix on data you haven't seen.
No collateral damageKeeping ordinary values exactly as they were while making the dangerous ones safe.
Your environment
Terminal + editorA full shell in the browser
Coding agentAlready signed in, no API key to set up
Isolated workspaceOnly yours, wiped when you finish
Start this lab
20 min
Start labYou'll need to sign in to Anthropos first. The lab opens in a private cloud workspace with your coding agent ready to use.AI Labs is part of Anthropos Workforce. Not on your plan yet? Book a demo