From 8ec33721f76e58b7dd52d3cecbcda2581bf1e365 Mon Sep 17 00:00:00 2001 From: ScreenTinker Date: Tue, 28 Apr 2026 14:37:31 -0500 Subject: [PATCH] Security: sanitize notes, add CSP headers, tighten CORS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit LOW 1 (notes XSS): device.notes textarea content now goes through esc(). Notes weren't in the sanitizeBody allow-list at write time, so HTML in the field would render unescaped on the device-detail page. LOW 2 (CSP): enabled Helmet contentSecurityPolicy with default-src 'self', script-src 'self', style-src 'self' 'unsafe-inline', plus the data:/blob:/https: image and media sources the player needs. Strict script-src blocks