> For the complete documentation index, see [llms.txt](https://coldbox-security.ortusbooks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://coldbox-security.ortusbooks.com/readme/release-history/whats-new-with-3.9.0.md). Agents can also search and read this documentation through its [MCP server](https://coldbox-security.ortusbooks.com/~gitbook/mcp).

# What's new With 3.9.0

Unreleased

#### Added

* **Route middleware**: secure routes and groups right where they are declared using ColdBox route-scoped middleware (`route().middleware()`), with no firewall rules needed. New WireBox IDs: `Authenticated@cbsecurity`, `Authorized@cbsecurity`, `JwtAuth@cbsecurity` and `BasicAuth@cbsecurity`. Permissions, roles and the permission `mode` (`any`, `all`, `none`) are declared in the route `meta()`. See [Route Middleware](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware.md).
* **More route middleware**, configured in the route `meta()` with defaults in the new `middleware` and `signedUrls` module settings:
  * [`Throttle@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/throttle.md) rate limits with named or inline limiters on any CacheBox cache (default `default`), plus the `RateLimiter@cbsecurity` model for use anywhere.
  * [`ApiKey@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/api-key.md) reads the `x-api-key` header or the `apiKey` request key, both configurable, and can use a validator service.
  * [`AllowedIPs@cbsecurity` and `DenyIPs@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/ip-filtering.md) filter by IPv4, IPv6 and CIDR, with `trustedProxies` support.
  * [`EnsureHttps@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/ensure-https.md), [`VerifyCsrf@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/verify-csrf.md) and [`Honeypot@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/honeypot.md).
* **Signed URLs**: [`Signed@cbsecurity`](https://coldbox-security.ortusbooks.com/secure-your-app/route-middleware/signed-urls.md) middleware, the `UrlSigner@cbsecurity` model and the `signedRoute()`, `signedUrl()` and `hasValidSignature()` helpers for tamper-proof, expiring links.
* Custom middleware by extending `cbsecurity.models.middleware.Guard`.
* `Security` interceptor `validateAccess()` and `processInvalidAccess()` public methods, used by the middleware and available to custom integrations.

#### Changed

* Handler and action annotation security now shares `processInvalidAccess()` with route middleware. The behavior is unchanged.

#### Fixed

* Settings you set on the `cbcsrf` module were overwritten by the cbsecurity `csrf` defaults, even when you never set `cbsecurity.csrf`. Now only the keys you explicitly set in `cbsecurity.csrf` are applied, and they win over the `cbcsrf` settings. See [Which Settings Win](https://coldbox-security.ortusbooks.com/csrf-and-headers/cross-site-request-forgery-cbcsrf.md#which-settings-win).

#### Requirements

* Route middleware requires ColdBox 8.2+.
* Group-level `meta` and route middleware in integration tests (`execute()`, `get()`, etc.) require ColdBox 8.3+.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://coldbox-security.ortusbooks.com/readme/release-history/whats-new-with-3.9.0.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
