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
* docs(hosting): document default rate limiter values
The rate limiter page listed only some of the default limiters by name
and never stated their actual values, which led to questions about
whether the limiters work without adding shopware.api.rate_limiter to
shopware.yml.
Add a complete Default rate limiters table with policy, reset window and
limits for every limiter the core ships, and clarify that the defaults
are always active and shopware.yml only overrides them.
* docs(hosting): add Since column to rate limiter defaults table
Replace the separate version info block with a per-row Since column so
the introduction version lives next to each limiter. This removes the
redundant note at the bottom and makes it clear that a version should be
recorded whenever a new default limiter is added.
* docs(hosting): address review feedback on rate limiter defaults
- Reference the core config as a repo path instead of a PHP-style
namespace with backslashes
- Drop trailing periods from the Protects table cells per the docs
table guidelines
- Use shopware.yml consistently in the override example
* add/code-groups-table-format
* add/readable-table
---------
Co-authored-by: Micha <m.hobert@shopware.com>
Copy file name to clipboardExpand all lines: guides/hosting/infrastructure/rate-limiter.md
+36-12Lines changed: 36 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,6 +15,31 @@ This functionality is available starting with Shopware 6.4.6.0.
15
15
16
16
Shopware 6 provides certain rate limits by default that reduces the risk of brute-force attacks for pages like login or password reset.
17
17
18
+
These rate limiters are always active. You do not need to add the `shopware.api.rate_limiter` map to your `shopware.yml` for them to work. The core already ships with the defaults documented below, and the `shopware.yml` is only used to override them (for example, to raise a limit or disable a limiter).
19
+
20
+
## Default rate limiters
21
+
22
+
The following limiters are enabled by default. The values listed here reflect the current Shopware core configuration and may change between versions. When in doubt, the source of truth is `src/Core/Framework/Resources/config/packages/shopware.yaml` in the version you are running.
|`cart_add_line_item`| Adding line items to the cart | 6.4.18.0 |`system_config`| 1 hour | Limit read from `core.cart.lineItemAddLimit`, interval 60s |
|`mcp_admin_api`| MCP server Admin API access (keyed per OAuth token) | 6.8.0.0 |`time_backoff`| 1 hour | 300 / 60s, 1000 / 10min |
39
+
|`mcp_store_api`| MCP server Store API access (keyed per sales-channel context token) | 6.8.0.0 |`time_backoff`| 1 hour | 120 / 60s, 600 / 10min |
40
+
41
+
In the table above, `Limits` uses the `limit / interval` notation, and `s` / `min` are seconds / minutes. When you add a new default limiter to the core, add a row here with its introduction version so this table stays complete.
42
+
18
43
## Configuration
19
44
20
45
The configuration for the rate limiter of Shopware 6 resides in the general bundle configuration:
@@ -26,19 +51,13 @@ The configuration for the rate limiter of Shopware 6 resides in the general bund
26
51
└── shopware.yml
27
52
```
28
53
29
-
To configure the default rate limiters for your shop, you need to add the `shopware.api.rate_limiter` map to the `shopware.yml`. Under this key, you can separately define the rate limiters.
54
+
To override the [default rate limiters](#default-rate-limiters) for your shop, you need to add the `shopware.api.rate_limiter` map to the `shopware.yml`. Under this key, you can separately define each rate limiter. Any key you set is merged into the defaults, so you only need to configure the values you want to change.
30
55
31
-
In the following, you can find a list of the default limiters:
56
+
The following example disables the `login` limiter and overrides the `oauth` limiter:
0 commit comments