Security Advisories (1)
CVE-2026-75870 (2026-08-22)

Punk versions before 0.18 for Perl allow session cookie forgery via an empty default HMAC key when a session is declared without a secret. The session keyword freezes its options onto the application as given: it does not require a secret, warn, or refuse to start when one is absent. The cookie read and the write-back both default that key to the empty string, so a declaration with no secret option, or with an undefined or empty one, signs and verifies with a zero-length HMAC-SHA256 key. An attacker who knows the cookie format can then mint one offline carrying any contents the session holds, such as a user identifier or a role. Nothing marks the misconfiguration at runtime: cookies are well formed and sessions round-trip as expected.

Changes for version 0.13 - 2026-08-16

  • $c->send_file($path_or_scalarref, %opts): a finished download response
  • Static files inherit the send_file core
  • The punk command line rebuilt around a registry: commands are specs (abstract, options with docs and defaults, nested verbs, code), and help is generated from them
  • Plugin subcommands: Punk::Command->register($name => \%spec) with owner-collision croaks; an unknown command gets one require of Punk::Command::<Ucfirst>, whose load registers it
  • In-process testing seam: $Punk::Command::OUT/$ERR replace the streams and main() returns the exit code.
  • routes: --method, --path GLOB, --kind, and --json.
  • dev: --workers, --watch (repeatable), --env; one watch loop.
  • console: a history file, --eval 'CODE', and q/exit.
  • New commands: `generate controller|model` into an existing application

Documentation

the Punk command line

Modules

a MVC web framework
the per-application registry and boot compiler
the authentication battery
password hashing
cross-origin resource sharing
single-use CSRF tokens
the punk command line: registry, dispatcher and commands
YAML configuration with secrets kept out of the file
the per-request object
base class for Punk controllers
the development error page
an async result that runs on the loop, or blocks
scaffold a new Punk application
security response headers
a level-based logger
the storage-agnostic model tier
the default DBI backend for Punk models
a non-blocking backend for Punk models
a directory of markdown as a documentation site
the api mount: spec-first operations
base class for Punk plugins
rate limiting and IP blocking over Hyperman's shared arena
a lazy wrapper over the PSGI environment
a response builder
the compiled-at-boot route tables (XS)
the handle an under returns
a Server-Sent Events stream
the bounded body of a ranged send_file response
signed cookie sessions
serving files from a directory
an in-process test client for Punk applications
a pure-Perl RFC 6455 codec for testing WebSocket servers
the client side of one WebSocket connection
the outbound HTTP agent on the context
an uploaded file from a multipart form
collecting request validation
the Template::Stencil view engine
the pluggable view engine registry (XS)
a WebSocket connection
pub/sub groups of WebSocket connections

Provides

in bench/apps/cat-lib/BenchCat.pm
in bench/apps/cat-lib/BenchCat/Controller/Root.pm