You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
tech-detect: restore Klaviyo script recall lost by the anchored scriptSrc signature #1457
Follow-up to #1451. Moving the Klaviyo script signature to the anchored scriptSrc helper (needed for the CodeQL finding) narrowed it. The inline loader and theme app block signals cover the common Shopify case, but these script forms are no longer detected:
an unquoted src=https://static.klaviyo.com/onsite/js/klaviyo.js
a src that comes after more than 300 characters of other attributes
a loader built in JavaScript (b.src="//static.klaviyo.com/onsite/js/klaviyo.js")
<link rel="preload" href=...> and data-src lazy loaders
a proxied URL in the script list
And one new false positive: a commented-out <script src=...klaviyo.js>, because the html detector reads comments.
Acceptance Criteria
Each form above is detected as Klaviyo, one fixture per form, with and without script bodies attached
A link, a code sample in a <pre> and a commented-out script tag are not detected
The CodeQL missing-regexp-anchor check stays green
The 23-bundle real-library check shows no new matches
I would like to take this. I will add one fixture for each accepted loader form (with and without attached script bodies), pin the link/pre/comment false positives, keep the regex anchored for CodeQL, and run the focused technology plus real-library checks.
Shipped in v0.0.153 (1831096152d5ef4f8b554b898dbe7cffd99cfb6331ebd074), verified against main: every acceptance criterion is met. One fixture per loader form, with and without script bodies attached (klaviyo-script-recall-1457, 11 tests); a link, a code sample in a <pre> and a commented-out script tag are not detected; the CodeQL check stayed green on the release; and the 23-bundle real-library comparison between main and the fix shows no new matches (0 diffs, and 0 on 19 real pages). Known limits are named in the changelog. Release: https://github.com/squirrelscan/squirrelscan/releases/tag/v0.0.153
Activity
WilliamK112 commentedon Oct 31, 2026
I would like to take this. I will add one fixture for each accepted loader form (with and without attached script bodies), pin the link/pre/comment false positives, keep the regex anchored for CodeQL, and run the focused technology plus real-library checks.
fix(tech-detect): bound Klaviyo loader scan squirrelscan#1457
docs(changelog): keep Klaviyo fix unreleased squirrelscan#1457
fix(tech-detect): restore Klaviyo loader recall #1457
fix(tech-detect): bound Klaviyo loader scan #1457
docs(changelog): keep Klaviyo fix unreleased #1457
fix(tech-detect): klaviyo inline-loader scan stays inside its own scr…
docs(changelog): name the Klaviyo loader recall limits #1457
fix(tech-detect): restore Klaviyo loader recall #1457
fix(tech-detect): bound Klaviyo loader scan #1457
docs(changelog): keep Klaviyo fix unreleased #1457
fix(tech-detect): klaviyo inline-loader scan stays inside its own scr…
docs(changelog): name the Klaviyo loader recall limits #1457
nc9 commentedon Nov 1, 2026
Shipped in v0.0.153 (
1831096152d5ef4f8b554b898dbe7cffd99cfb6331ebd074), verified against main: every acceptance criterion is met. One fixture per loader form, with and without script bodies attached (klaviyo-script-recall-1457, 11 tests); a link, a code sample in a<pre>and a commented-out script tag are not detected; the CodeQL check stayed green on the release; and the 23-bundle real-library comparison between main and the fix shows no new matches (0 diffs, and 0 on 19 real pages). Known limits are named in the changelog. Release: https://github.com/squirrelscan/squirrelscan/releases/tag/v0.0.153nik