Formula-injection guards
Values that start with =, +, -, @, tab or carriage return are neutralized on copy and export, so they cannot run as formulas when opened in a spreadsheet app. On paste, incoming formulas are kept as plain text and are never evaluated. Neutralization is on by default and is configurable per column.
Planned. This page shows the specification from issue #191. The live example, source for every framework and the API reference replace it when the feature ships.
Live example
A grid whose rows contain malicious-looking values, alongside legitimate negative numbers.
Expected behavior
Text values starting with trigger characters get a leading apostrophe. Numeric -5 in a number column is not altered. The guardApplied event lists the affected cells.
Planned API surface
clipboard.formulaGuardclipboard.formulaGuard.modecolumn.allowFormulaPrefixclipboard:guardAppliedAcceptance criteria
- The guard is on by default (pending)
- Typed numeric negatives are never altered (pending)
- Text that looks like a negative number, such as "-5" in a text column, is guarded (pending)
- Turning the guard off logs a development-mode warning (pending)
- Paste never evaluates a formula: "=1+1" is stored as text (pending)