Menu

I submitted a side-project extension for review and an AI bot found 4 real security bugs in it
📰

I submitted a side-project extension for review and an AI bot found 4 real security bugs in it

DEV Community: typescript·Kleo Geos·about 6 hours ago
#uoxBa1IU
#devtotypescript#devto#dev#html#markdown
Reading 0:00
15s threshold

I built a small Raycast extension - paste invoice JSON, get a formatted HTML/Markdown preview. Zero dependencies in the render logic, 7 unit tests passing, tsc clean. I was pretty confident in it before opening the PR to the official extensions repo.

Within a few minutes, an automated reviewer (Greptile, which Raycast runs on every incoming PR) left 9 comments. Four were tagged P1/security. None of them were things my tests caught, because I'd only tested the happy path and a couple of "normal" edge cases - not actually hostile input.

1. Unescaped field reaching an HTML template

// before export function computeTotals ( data : InvoiceData ) { const subtotal = data . items . reduce (( acc , i ) => acc + i . qty * i . rate , 0 ); const taxRate = data . tax_rate || 0 ; ... }

Enter fullscreen mode

Exit fullscreen mode

tax_rate is typed as number , but nothing enforces that at runtime - it comes from JSON.parse on whatever the user pastes.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.