Skip to content

canship 0.3.2

Choose a tag to compare

@Tasomei Tasomei released this 25 Sep 09:56
· 143 commits to main since this release

Highlights

  • API authentication checks now cover server routes beyond Next.js: SvelteKit (+server endpoints), Nuxt (server/api and server/routes), Remix and React Router (modules in app/routes exporting loader or action), and Astro (endpoints in src/pages). Admin clients are followed through $lib, ~/, and Nuxt server/utils auto-imports.
  • An authentication check in SvelteKit hooks.server or Nuxt server/middleware lowers confidence instead of hiding the finding, because the routes it covers are decided in code.

Fixes

  • Common guards are now recognised: optional-chained session checks (if (!session?.user)), Clerk userId redirects, SvelteKit error(401), Nuxt createError({ statusCode: 401 }), requireUserId, and requireUserSession. Previously the first two were reported as P0 admin access without authentication on Next.js routes.
  • A scanned file could make a scan take minutes: long whitespace after createClient, or after a CORS origin: function callback. Both are now linear.

Release

Published from GitHub Actions through npm trusted publishing with staged approval. The package carries SLSA provenance linking it to this tag; verify with npm audit signatures.

Usage

npx canship@0.3.2 .

For the GitHub Action, set version: '0.3.2' explicitly.

Requires Node.js 18 or later. No runtime dependencies. Scanning does not execute project code or use the network; package installation may access npm.

Package on npm · Documentation · 简体中文

Source commit: 2ac2a7b1b5870d97cddc0951b5b70ce85c9f9102. This release identifies the source corresponding to the published npm package; subsequent Action-default changes are not included.