@radicaltools/mcp 0.1.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +52 -26
- package/dist/chunk-Z7THA3L5.js +3200 -0
- package/dist/elkLayout-TAUBPPVN.js +8 -0
- package/dist/hub-catalogue/concern/concern-api-evolution.radical +935 -0
- package/dist/hub-catalogue/concern/concern-architecture-style.radical +1112 -0
- package/dist/hub-catalogue/concern/concern-authentication.radical +685 -0
- package/dist/hub-catalogue/concern/concern-authorization.radical +1464 -0
- package/dist/hub-catalogue/concern/concern-availability.radical +804 -0
- package/dist/hub-catalogue/concern/concern-backend-stack.radical +1118 -0
- package/dist/hub-catalogue/concern/concern-backup-recovery.radical +1304 -0
- package/dist/hub-catalogue/concern/concern-capacity.radical +802 -0
- package/dist/hub-catalogue/concern/concern-communication-style.radical +1202 -0
- package/dist/hub-catalogue/concern/concern-data-consistency.radical +1081 -0
- package/dist/hub-catalogue/concern/concern-data-store.radical +960 -0
- package/dist/hub-catalogue/concern/concern-decomposition.radical +1143 -0
- package/dist/hub-catalogue/concern/concern-deployment.radical +952 -0
- package/dist/hub-catalogue/concern/concern-encryption.radical +1055 -0
- package/dist/hub-catalogue/concern/concern-frontend-stack.radical +1340 -0
- package/dist/hub-catalogue/concern/concern-infrastructure.radical +1151 -0
- package/dist/hub-catalogue/concern/concern-integration-resilience.radical +1079 -0
- package/dist/hub-catalogue/concern/concern-messaging.radical +940 -0
- package/dist/hub-catalogue/concern/concern-module-boundaries.radical +864 -0
- package/dist/hub-catalogue/concern/concern-observability.radical +1048 -0
- package/dist/hub-catalogue/concern/concern-personal-data.radical +1434 -0
- package/dist/hub-catalogue/concern/concern-rate-limiting.radical +1153 -0
- package/dist/hub-catalogue/concern/concern-secrets.radical +1026 -0
- package/dist/hub-catalogue/concern/concern-supply-chain.radical +1312 -0
- package/dist/hub-catalogue/concern/concern-tenant-isolation.radical +1306 -0
- package/dist/hub-catalogue/concern/concern-test-strategy.radical +1193 -0
- package/dist/index.js +22690 -6064
- package/package.json +1 -1
- package/dist/chunk-KI4NVSTU.js +0 -1763
- package/dist/elkLayout-WC6AXWOG.js +0 -185
- package/dist/hub-catalogue/adr/adr-api-versioning.radical +0 -53
- package/dist/hub-catalogue/adr/adr-auth-strategy.radical +0 -53
- package/dist/hub-catalogue/adr/adr-caching-strategy.radical +0 -59
- package/dist/hub-catalogue/adr/adr-data-consistency-model.radical +0 -40
- package/dist/hub-catalogue/adr/adr-data-store.radical +0 -47
- package/dist/hub-catalogue/adr/adr-deployment-strategy.radical +0 -53
- package/dist/hub-catalogue/adr/adr-event-schema-evolution.radical +0 -53
- package/dist/hub-catalogue/adr/adr-integration-style.radical +0 -50
- package/dist/hub-catalogue/adr/adr-ledger-reconciliation-strategy.radical +0 -38
- package/dist/hub-catalogue/adr/adr-llm-provider-strategy.radical +0 -40
- package/dist/hub-catalogue/adr/adr-marketplace-payments-model.radical +0 -39
- package/dist/hub-catalogue/adr/adr-multi-region.radical +0 -60
- package/dist/hub-catalogue/adr/adr-multi-tenancy-strategy.radical +0 -41
- package/dist/hub-catalogue/adr/adr-observability.radical +0 -59
- package/dist/hub-catalogue/adr/adr-realtime-transport.radical +0 -38
- package/dist/hub-catalogue/adr/adr-tech-stack.radical +0 -45
- package/dist/hub-catalogue/adr/adr-zero-trust-network.radical +0 -40
- package/dist/hub-catalogue/blueprint/bp-ai-assistant-platform.radical +0 -1641
- package/dist/hub-catalogue/blueprint/bp-analytical-data-platform.radical +0 -1428
- package/dist/hub-catalogue/blueprint/bp-ecommerce-platform.radical +0 -1989
- package/dist/hub-catalogue/blueprint/bp-fintech-ledger-platform.radical +0 -1701
- package/dist/hub-catalogue/blueprint/bp-marketplace-platform.radical +0 -1792
- package/dist/hub-catalogue/blueprint/bp-realtime-collaboration.radical +0 -1421
- package/dist/hub-catalogue/blueprint/bp-saas-b2b-platform.radical +0 -1713
- package/dist/hub-catalogue/fitness-function/ff-accessibility-scan.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-ai-eval-gate.radical +0 -52
- package/dist/hub-catalogue/fitness-function/ff-api-contract.radical +0 -36
- package/dist/hub-catalogue/fitness-function/ff-capacity-load-test.radical +0 -67
- package/dist/hub-catalogue/fitness-function/ff-carbon-footprint-guard.radical +0 -62
- package/dist/hub-catalogue/fitness-function/ff-change-failure-rate.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-chaos-resilience-test.radical +0 -53
- package/dist/hub-catalogue/fitness-function/ff-cost-efficiency-guard.radical +0 -64
- package/dist/hub-catalogue/fitness-function/ff-coupling-guard.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-data-integrity-check.radical +0 -51
- package/dist/hub-catalogue/fitness-function/ff-data-residency.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-dependency-rules.radical +0 -37
- package/dist/hub-catalogue/fitness-function/ff-deploy-frequency.radical +0 -46
- package/dist/hub-catalogue/fitness-function/ff-dr-drill-success.radical +0 -52
- package/dist/hub-catalogue/fitness-function/ff-duplication-guard.radical +0 -53
- package/dist/hub-catalogue/fitness-function/ff-error-budget.radical +0 -59
- package/dist/hub-catalogue/fitness-function/ff-fail-safe-verification.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-infra-drift.radical +0 -34
- package/dist/hub-catalogue/fitness-function/ff-latency-slo.radical +0 -59
- package/dist/hub-catalogue/fitness-function/ff-lead-time.radical +0 -44
- package/dist/hub-catalogue/fitness-function/ff-ledger-balance-integrity.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-license-compliance.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-mttr.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-noisy-neighbor-guard.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-sast-scan.radical +0 -35
- package/dist/hub-catalogue/fitness-function/ff-scale-out-verification.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-security-scan.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-startup-shutdown-check.radical +0 -66
- package/dist/hub-catalogue/fitness-function/ff-sync-convergence-test.radical +0 -45
- package/dist/hub-catalogue/fitness-function/ff-test-coverage.radical +0 -43
- package/dist/hub-catalogue/fitness-function/ff-web-vitals.radical +0 -57
- package/dist/hub-catalogue/pattern/pattern-anti-corruption-layer.radical +0 -88
- package/dist/hub-catalogue/pattern/pattern-api-gateway.radical +0 -168
- package/dist/hub-catalogue/pattern/pattern-bff.radical +0 -179
- package/dist/hub-catalogue/pattern/pattern-bulkhead.radical +0 -114
- package/dist/hub-catalogue/pattern/pattern-circuit-breaker.radical +0 -219
- package/dist/hub-catalogue/pattern/pattern-cqrs.radical +0 -195
- package/dist/hub-catalogue/pattern/pattern-crdt-sync.radical +0 -200
- package/dist/hub-catalogue/pattern/pattern-event-driven.radical +0 -210
- package/dist/hub-catalogue/pattern/pattern-event-sourced-ledger.radical +0 -211
- package/dist/hub-catalogue/pattern/pattern-hexagonal.radical +0 -196
- package/dist/hub-catalogue/pattern/pattern-microservices.radical +0 -262
- package/dist/hub-catalogue/pattern/pattern-rag-pipeline.radical +0 -213
- package/dist/hub-catalogue/pattern/pattern-rate-limiter.radical +0 -114
- package/dist/hub-catalogue/pattern/pattern-saga.radical +0 -208
- package/dist/hub-catalogue/pattern/pattern-sidecar.radical +0 -123
- package/dist/hub-catalogue/pattern/pattern-strangler-fig.radical +0 -227
- package/dist/hub-catalogue/pattern/pattern-transactional-outbox.radical +0 -209
- package/dist/hub-catalogue/requirement/req-accessibility.radical +0 -48
- package/dist/hub-catalogue/requirement/req-ai-autonomous-resolution.radical +0 -51
- package/dist/hub-catalogue/requirement/req-ai-groundedness.radical +0 -45
- package/dist/hub-catalogue/requirement/req-ai-human-handoff.radical +0 -46
- package/dist/hub-catalogue/requirement/req-alerting.radical +0 -52
- package/dist/hub-catalogue/requirement/req-api-response-time.radical +0 -51
- package/dist/hub-catalogue/requirement/req-api-standard.radical +0 -45
- package/dist/hub-catalogue/requirement/req-audit-logging.radical +0 -43
- package/dist/hub-catalogue/requirement/req-auth-response-time.radical +0 -45
- package/dist/hub-catalogue/requirement/req-auth.radical +0 -43
- package/dist/hub-catalogue/requirement/req-autoscaling.radical +0 -62
- package/dist/hub-catalogue/requirement/req-availability.radical +0 -50
- package/dist/hub-catalogue/requirement/req-backward-compatibility.radical +0 -46
- package/dist/hub-catalogue/requirement/req-batch-job-completion.radical +0 -50
- package/dist/hub-catalogue/requirement/req-carbon-efficiency.radical +0 -64
- package/dist/hub-catalogue/requirement/req-centralised-logging.radical +0 -45
- package/dist/hub-catalogue/requirement/req-ci-pipeline-time.radical +0 -43
- package/dist/hub-catalogue/requirement/req-code-complexity.radical +0 -43
- package/dist/hub-catalogue/requirement/req-config-propagation.radical +0 -45
- package/dist/hub-catalogue/requirement/req-data-integrity.radical +0 -35
- package/dist/hub-catalogue/requirement/req-data-retention.radical +0 -44
- package/dist/hub-catalogue/requirement/req-db-query-response.radical +0 -44
- package/dist/hub-catalogue/requirement/req-disaster-recovery.radical +0 -59
- package/dist/hub-catalogue/requirement/req-distributed-tracing.radical +0 -45
- package/dist/hub-catalogue/requirement/req-encryption.radical +0 -49
- package/dist/hub-catalogue/requirement/req-error-rate.radical +0 -45
- package/dist/hub-catalogue/requirement/req-error-recovery.radical +0 -34
- package/dist/hub-catalogue/requirement/req-event-schema-compatibility.radical +0 -37
- package/dist/hub-catalogue/requirement/req-fail-safe-default.radical +0 -55
- package/dist/hub-catalogue/requirement/req-fast-startup-graceful-shutdown.radical +0 -69
- package/dist/hub-catalogue/requirement/req-gdpr-erasure.radical +0 -44
- package/dist/hub-catalogue/requirement/req-graceful-degradation.radical +0 -39
- package/dist/hub-catalogue/requirement/req-health-checks.radical +0 -43
- package/dist/hub-catalogue/requirement/req-iac.radical +0 -36
- package/dist/hub-catalogue/requirement/req-idempotency.radical +0 -47
- package/dist/hub-catalogue/requirement/req-input-validation.radical +0 -37
- package/dist/hub-catalogue/requirement/req-least-privilege.radical +0 -47
- package/dist/hub-catalogue/requirement/req-ledger-immutability.radical +0 -38
- package/dist/hub-catalogue/requirement/req-mfa.radical +0 -36
- package/dist/hub-catalogue/requirement/req-ml-extraction-accuracy.radical +0 -42
- package/dist/hub-catalogue/requirement/req-onboarding-time.radical +0 -42
- package/dist/hub-catalogue/requirement/req-page-load-time.radical +0 -59
- package/dist/hub-catalogue/requirement/req-payout-latency.radical +0 -46
- package/dist/hub-catalogue/requirement/req-presence-latency.radical +0 -46
- package/dist/hub-catalogue/requirement/req-rate-limiting.radical +0 -45
- package/dist/hub-catalogue/requirement/req-report-generation.radical +0 -44
- package/dist/hub-catalogue/requirement/req-resource-efficiency.radical +0 -64
- package/dist/hub-catalogue/requirement/req-resource-headroom.radical +0 -53
- package/dist/hub-catalogue/requirement/req-resource-isolation.radical +0 -37
- package/dist/hub-catalogue/requirement/req-search-response-time.radical +0 -44
- package/dist/hub-catalogue/requirement/req-secrets-management.radical +0 -45
- package/dist/hub-catalogue/requirement/req-task-success-rate.radical +0 -42
- package/dist/hub-catalogue/requirement/req-test-coverage.radical +0 -42
- package/dist/hub-catalogue/requirement/req-throughput.radical +0 -55
- package/dist/hub-catalogue/requirement/req-vulnerability-scanning.radical +0 -52
- package/dist/hub-catalogue/requirement/req-zero-downtime-deploy.radical +0 -39
|
@@ -0,0 +1,1153 @@
|
|
|
1
|
+
{
|
|
2
|
+
"hub": {
|
|
3
|
+
"id": "concern-rate-limiting",
|
|
4
|
+
"category": "concern",
|
|
5
|
+
"name": "Rate limiting and abuse",
|
|
6
|
+
"description": "Entry points from outside: how much one caller may ask, how it is counted and where, how oversized and automated requests are stopped, and who can reach it at all.",
|
|
7
|
+
"tags": [
|
|
8
|
+
"security",
|
|
9
|
+
"rate-limiting",
|
|
10
|
+
"abuse",
|
|
11
|
+
"availability",
|
|
12
|
+
"bots",
|
|
13
|
+
"api"
|
|
14
|
+
],
|
|
15
|
+
"requiredMetamodel": "c4-ddd-governance-builtin",
|
|
16
|
+
"concern": {
|
|
17
|
+
"id": "rate-limiting",
|
|
18
|
+
"trigger": "LIST RELATIONS WHERE (source.type = \"person\" OR source.external = true) AND target.external != true AND (target.type = \"system\" OR target.type = \"container\" OR target.type = \"webapp\" OR target.type = \"component\")",
|
|
19
|
+
"applyTo": "target",
|
|
20
|
+
"why": "these elements take requests from outside, so how much one caller may ask, and what stops abuse, has to be decided.",
|
|
21
|
+
"group": "security"
|
|
22
|
+
},
|
|
23
|
+
"sources": [
|
|
24
|
+
{
|
|
25
|
+
"title": "OWASP API Security Top 10 2023, API4:2023 Unrestricted Resource Consumption",
|
|
26
|
+
"url": "https://owasp.org/API-Security/editions/2023/en/0xa4-unrestricted-resource-consumption/"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"title": "RFC 6585, Additional HTTP Status Codes (4. 429 Too Many Requests)",
|
|
30
|
+
"url": "https://www.rfc-editor.org/rfc/rfc6585"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"title": "RFC 9110, HTTP Semantics (10.2.3 Retry-After, 15.5.14 413 Content Too Large)",
|
|
34
|
+
"url": "https://www.rfc-editor.org/rfc/rfc9110"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"title": "OWASP Denial of Service Cheat Sheet",
|
|
38
|
+
"url": "https://cheatsheetseries.owasp.org/cheatsheets/Denial_of_Service_Cheat_Sheet.html"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"title": "OWASP Automated Threats to Web Applications",
|
|
42
|
+
"url": "https://owasp.org/www-project-automated-threats-to-web-applications/"
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"title": "IETF draft, RateLimit header fields for HTTP",
|
|
46
|
+
"url": "https://datatracker.ietf.org/doc/draft-ietf-httpapi-ratelimit-headers/"
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"templateParams": [
|
|
50
|
+
{
|
|
51
|
+
"key": "EXPOSURE",
|
|
52
|
+
"title": "Exposure",
|
|
53
|
+
"label": "Who can reach it?",
|
|
54
|
+
"hint": "Anything on the internet is probed and scraped within hours of going live; what is not reachable cannot be flooded.",
|
|
55
|
+
"defaultValue": "internet",
|
|
56
|
+
"options": [
|
|
57
|
+
{
|
|
58
|
+
"value": "internet",
|
|
59
|
+
"label": "anyone on the internet",
|
|
60
|
+
"description": "Anonymous people and bots reach it. Pick it for public web apps, sign-up and sign-in pages and public APIs; it needs volumetric protection at the edge and protection of costly operations."
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"value": "partners",
|
|
64
|
+
"label": "known partners and our signed-in users",
|
|
65
|
+
"description": "Every request carries a partner key or a user's credential, checked at the edge. Pick it for B2B APIs and back offices; limits can be agreed per partner."
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"value": "internal",
|
|
69
|
+
"label": "only our own network",
|
|
70
|
+
"description": "No public address; only our own systems call it. Pick it when the model shows callers only from inside; limits still stop a runaway internal caller."
|
|
71
|
+
}
|
|
72
|
+
]
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"key": "KEY",
|
|
76
|
+
"title": "Limit key",
|
|
77
|
+
"label": "What is a caller counted by?",
|
|
78
|
+
"hint": "The key decides who shares a limit: too coarse and an office shares one, too fine and an attacker rotates it.",
|
|
79
|
+
"defaultValue": "account",
|
|
80
|
+
"options": [
|
|
81
|
+
{
|
|
82
|
+
"value": "account",
|
|
83
|
+
"label": "its account or API key, else its source address",
|
|
84
|
+
"description": "Signed-in callers by account, anonymous ones by address with a lower limit. Pick it when most traffic is signed in and some pages are public."
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"value": "apikey",
|
|
88
|
+
"label": "its API key",
|
|
89
|
+
"description": "Each calling system by its key, with limits agreed per key; requests without a valid key are refused before counting. Pick it for machine-to-machine APIs."
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"value": "ip",
|
|
93
|
+
"label": "its source address",
|
|
94
|
+
"description": "IPv4 per address, IPv6 per /64. Pick it only when callers are anonymous; offices and mobile carriers share addresses, so allow-list the known ones."
|
|
95
|
+
}
|
|
96
|
+
]
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"key": "ALGORITHM",
|
|
100
|
+
"title": "Algorithm",
|
|
101
|
+
"label": "How are requests counted?",
|
|
102
|
+
"hint": "The algorithm decides whether bursts are allowed and how exact the limit is at the edge of a window.",
|
|
103
|
+
"defaultValue": "token-bucket",
|
|
104
|
+
"options": [
|
|
105
|
+
{
|
|
106
|
+
"value": "token-bucket",
|
|
107
|
+
"label": "a token bucket",
|
|
108
|
+
"description": "A steady rate plus a burst allowance. Pick it when real clients send in bursts (a page loading 20 resources, a batch job); AWS API Gateway, Envoy and ASP.NET Core offer it."
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"value": "sliding-window",
|
|
112
|
+
"label": "a sliding window",
|
|
113
|
+
"description": "No 60 seconds may hold more than the limit, wherever they start. Pick it when the limit protects a fixed capacity (a partner's backend, a licence) and must not be exceeded at window edges."
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
"value": "fixed-window",
|
|
117
|
+
"label": "a fixed window per minute",
|
|
118
|
+
"description": "A counter per calendar minute, reset at its start; cheapest to run, but a caller can send twice the limit across a minute boundary. Pick it for quotas (per day, per month) and simple per-minute limits."
|
|
119
|
+
}
|
|
120
|
+
]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"key": "WHERE",
|
|
124
|
+
"title": "Where enforced",
|
|
125
|
+
"label": "Where is the limit enforced?",
|
|
126
|
+
"hint": "The earlier a request is refused, the less it costs; the later, the more the limit knows about who is calling.",
|
|
127
|
+
"defaultValue": "gateway",
|
|
128
|
+
"options": [
|
|
129
|
+
{
|
|
130
|
+
"value": "gateway",
|
|
131
|
+
"label": "at the API gateway",
|
|
132
|
+
"description": "Kong, NGINX, Envoy, AWS API Gateway or Azure API Management in front of the element, keyed on the token or API key it validates. Pick it when there is a gateway in the path, which most APIs have."
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
"value": "waf",
|
|
136
|
+
"label": "at the edge WAF or CDN",
|
|
137
|
+
"description": "Cloudflare, AWS WAF, Azure Front Door or Akamai rate rules before traffic reaches the network. Pick it for public web traffic and floods; counts are approximate and keyed mostly on addresses and headers."
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
"value": "app",
|
|
141
|
+
"label": "in the application",
|
|
142
|
+
"description": "Middleware in the element with counters shared in Redis. Pick it when the limit depends on business data (plan, tenant, operation cost) that only the element knows."
|
|
143
|
+
}
|
|
144
|
+
]
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"key": "BOTS",
|
|
148
|
+
"title": "Bots",
|
|
149
|
+
"label": "How are automated callers stopped on costly operations?",
|
|
150
|
+
"hint": "Credential stuffing, fake sign-ups and scraping stay under per-caller limits by spreading over many addresses; they need their own protection.",
|
|
151
|
+
"defaultValue": "challenge",
|
|
152
|
+
"options": [
|
|
153
|
+
{
|
|
154
|
+
"value": "challenge",
|
|
155
|
+
"label": "a challenge after repeated attempts",
|
|
156
|
+
"description": "Cloudflare Turnstile, hCaptcha or reCAPTCHA after a source repeats a costly operation. Pick it for public sign-in, sign-up and contact forms without a bot-management product."
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"value": "managed",
|
|
160
|
+
"label": "managed bot detection at the edge",
|
|
161
|
+
"description": "Cloudflare Bot Management, AWS WAF Bot Control or Akamai Bot Manager score every request. Pick it for high-value public targets (retail, tickets, finance) facing distributed bots."
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"value": "none",
|
|
165
|
+
"label": "costly operations only for identified callers",
|
|
166
|
+
"description": "No bot product; costly operations sit behind sign-in or a partner key. Pick it for partner and internal APIs, where every caller is known."
|
|
167
|
+
}
|
|
168
|
+
]
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"key": "LIMIT_PER_MIN",
|
|
172
|
+
"label": "How many requests a minute may one caller make?",
|
|
173
|
+
"defaultValue": "600",
|
|
174
|
+
"type": "number"
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"key": "BURST",
|
|
178
|
+
"label": "How many requests may a caller send at once above that (token bucket)?",
|
|
179
|
+
"defaultValue": "100",
|
|
180
|
+
"type": "number"
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
"key": "ANON_LIMIT_PER_MIN",
|
|
184
|
+
"label": "How many requests a minute may one anonymous source address make?",
|
|
185
|
+
"defaultValue": "60",
|
|
186
|
+
"type": "number"
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
"key": "MAX_BODY_KB",
|
|
190
|
+
"label": "What is the largest request body accepted (KB)?",
|
|
191
|
+
"defaultValue": "1024",
|
|
192
|
+
"type": "number"
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
"key": "MAX_PAGE_ITEMS",
|
|
196
|
+
"label": "How many items may one page of results hold at most?",
|
|
197
|
+
"defaultValue": "100",
|
|
198
|
+
"type": "number"
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
"key": "COSTLY_OPS",
|
|
202
|
+
"label": "Which operations are costly or attractive to bots?",
|
|
203
|
+
"defaultValue": "sign-up, sign-in, password reset, search"
|
|
204
|
+
}
|
|
205
|
+
]
|
|
206
|
+
},
|
|
207
|
+
"nodes": [
|
|
208
|
+
{
|
|
209
|
+
"id": "need",
|
|
210
|
+
"type": "need",
|
|
211
|
+
"label": "No caller takes it down",
|
|
212
|
+
"x": 0,
|
|
213
|
+
"y": 0,
|
|
214
|
+
"kind": "brief",
|
|
215
|
+
"source": "Hub concern pack: Rate limiting and abuse",
|
|
216
|
+
"description": "The element takes requests from outside. One caller, by mistake or on purpose, can send enough to slow it for everyone; bots try passwords, create accounts and scrape data; oversized requests and pages use up memory; and costly operations run up bills because nothing limits them. Real users behind a shared address must not be locked out on the way."
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"id": "req-limit",
|
|
220
|
+
"type": "requirement",
|
|
221
|
+
"label": "Callers limited",
|
|
222
|
+
"x": 260,
|
|
223
|
+
"y": 0,
|
|
224
|
+
"ears_type": "unwanted-behaviour",
|
|
225
|
+
"unwanted_condition": "one caller, counted by {{KEY}}, sends more than {{LIMIT_PER_MIN}} requests a minute",
|
|
226
|
+
"action": "answer the excess with 429 and a Retry-After header, without raising other callers' 95th percentile response time by more than 10 %",
|
|
227
|
+
"rationale": "A fair share each: a misbehaving caller slows only itself, and 429 with Retry-After tells a well-behaved client when to come back (OWASP API4:2023; RFC 6585 4; RFC 9110 10.2.3)."
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
"id": "req-size",
|
|
231
|
+
"type": "requirement",
|
|
232
|
+
"label": "Oversized requests refused",
|
|
233
|
+
"x": 260,
|
|
234
|
+
"y": 130,
|
|
235
|
+
"ears_type": "unwanted-behaviour",
|
|
236
|
+
"unwanted_condition": "a request body is larger than {{MAX_BODY_KB}} KB or than its operation allows",
|
|
237
|
+
"action": "refuse it with 413 before reading more than that limit",
|
|
238
|
+
"rationale": "Reading first and checking later is the exhaustion; the limit belongs in the first component that reads the body (OWASP API4:2023, maximum request size; RFC 9110 15.5.14)."
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
"id": "req-pages",
|
|
242
|
+
"type": "requirement",
|
|
243
|
+
"label": "Pages bounded",
|
|
244
|
+
"x": 260,
|
|
245
|
+
"y": 260,
|
|
246
|
+
"ears_type": "ubiquitous",
|
|
247
|
+
"action": "return at most {{MAX_PAGE_ITEMS}} items per page of results, and refuse a larger page size with 400",
|
|
248
|
+
"rationale": "One request asking for everything is a flood in a single call (OWASP API4:2023, maximum number of records per page)."
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
"id": "req-token-bucket",
|
|
252
|
+
"type": "requirement",
|
|
253
|
+
"label": "Bursts allowed, rate kept",
|
|
254
|
+
"x": 260,
|
|
255
|
+
"y": 390,
|
|
256
|
+
"ears_type": "ubiquitous",
|
|
257
|
+
"action": "let each caller send up to {{BURST}} requests at once above its steady rate, refill its allowance at {{LIMIT_PER_MIN}} requests a minute, and refuse requests while the allowance is empty",
|
|
258
|
+
"rationale": "Real clients send in bursts; a bucket admits them without letting the sustained rate exceed the limit (OWASP Denial of Service Cheat Sheet).",
|
|
259
|
+
"hubWhen": {
|
|
260
|
+
"ALGORITHM": [
|
|
261
|
+
"token-bucket"
|
|
262
|
+
]
|
|
263
|
+
}
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
"id": "req-sliding-window",
|
|
267
|
+
"type": "requirement",
|
|
268
|
+
"label": "No window over the limit",
|
|
269
|
+
"x": 260,
|
|
270
|
+
"y": 520,
|
|
271
|
+
"ears_type": "ubiquitous",
|
|
272
|
+
"action": "count each caller's requests over a sliding 60-second window, so that no 60 seconds hold more than {{LIMIT_PER_MIN}} accepted requests from it, window edges included",
|
|
273
|
+
"rationale": "A fixed window lets a caller send twice the limit across its boundary; a sliding window keeps the limit wherever the minute starts (OWASP Denial of Service Cheat Sheet).",
|
|
274
|
+
"hubWhen": {
|
|
275
|
+
"ALGORITHM": [
|
|
276
|
+
"sliding-window"
|
|
277
|
+
]
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
"id": "req-fixed-window",
|
|
282
|
+
"type": "requirement",
|
|
283
|
+
"label": "Quota per minute shown",
|
|
284
|
+
"x": 260,
|
|
285
|
+
"y": 650,
|
|
286
|
+
"ears_type": "ubiquitous",
|
|
287
|
+
"action": "accept at most {{LIMIT_PER_MIN}} requests per caller in each calendar minute, and return the limit, the requests remaining and the seconds to reset with every response",
|
|
288
|
+
"rationale": "A fixed window is cheap and predictable; showing the remaining quota lets clients pace themselves instead of hitting 429 (IETF RateLimit header fields draft).",
|
|
289
|
+
"hubWhen": {
|
|
290
|
+
"ALGORITHM": [
|
|
291
|
+
"fixed-window"
|
|
292
|
+
]
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
"id": "req-key-account",
|
|
297
|
+
"type": "requirement",
|
|
298
|
+
"label": "Anonymous callers limited lower",
|
|
299
|
+
"x": 260,
|
|
300
|
+
"y": 780,
|
|
301
|
+
"ears_type": "event-driven",
|
|
302
|
+
"trigger": "a request arrives without a credential",
|
|
303
|
+
"action": "count it by its source address (IPv6 by /64) and limit that address to {{ANON_LIMIT_PER_MIN}} requests a minute, apart from the limits of signed-in callers",
|
|
304
|
+
"rationale": "Anonymous traffic has no account to count by; a separate, lower limit keeps it from using up what signed-in users need (OWASP API4:2023).",
|
|
305
|
+
"hubWhen": {
|
|
306
|
+
"KEY": [
|
|
307
|
+
"account"
|
|
308
|
+
]
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
"id": "req-key-apikey",
|
|
313
|
+
"type": "requirement",
|
|
314
|
+
"label": "Keyless calls refused first",
|
|
315
|
+
"x": 260,
|
|
316
|
+
"y": 910,
|
|
317
|
+
"ears_type": "unwanted-behaviour",
|
|
318
|
+
"unwanted_condition": "a request carries no valid API key",
|
|
319
|
+
"action": "refuse it with 401 before it counts against any key's limit, and limit such requests to {{ANON_LIMIT_PER_MIN}} a minute per source address",
|
|
320
|
+
"rationale": "If invalid keys counted against valid ones, anyone could spend a partner's quota; limiting failures by address slows key guessing (OWASP API4:2023, API2:2023).",
|
|
321
|
+
"hubWhen": {
|
|
322
|
+
"KEY": [
|
|
323
|
+
"apikey"
|
|
324
|
+
]
|
|
325
|
+
}
|
|
326
|
+
},
|
|
327
|
+
{
|
|
328
|
+
"id": "req-key-ip",
|
|
329
|
+
"type": "requirement",
|
|
330
|
+
"label": "Addresses counted fairly",
|
|
331
|
+
"x": 260,
|
|
332
|
+
"y": 1040,
|
|
333
|
+
"ears_type": "ubiquitous",
|
|
334
|
+
"action": "count IPv4 callers per address and IPv6 callers per /64 prefix, take the address only from the trusted proxy's header, and give the addresses on an allow-list of known shared egress (offices, partners) their own higher limits",
|
|
335
|
+
"rationale": "An address taken from any X-Forwarded-For value can be forged, and an IPv6 host owns a whole /64; shared addresses need room or real users are locked out (OWASP Denial of Service Cheat Sheet).",
|
|
336
|
+
"hubWhen": {
|
|
337
|
+
"KEY": [
|
|
338
|
+
"ip"
|
|
339
|
+
]
|
|
340
|
+
}
|
|
341
|
+
},
|
|
342
|
+
{
|
|
343
|
+
"id": "req-shared-counters",
|
|
344
|
+
"type": "requirement",
|
|
345
|
+
"label": "One limit across instances",
|
|
346
|
+
"x": 260,
|
|
347
|
+
"y": 1170,
|
|
348
|
+
"ears_type": "state-driven",
|
|
349
|
+
"precondition": "the element runs on more than one instance",
|
|
350
|
+
"action": "keep the counters in one shared store, so that the element as a whole accepts no more than {{LIMIT_PER_MIN}} requests a minute from one caller, within 10 %, and fall back to a per-instance limit rather than none when the store is unreachable",
|
|
351
|
+
"rationale": "A limit counted per instance multiplies with every instance added; failing open would turn a store outage into an open door (OWASP Denial of Service Cheat Sheet).",
|
|
352
|
+
"hubWhen": {
|
|
353
|
+
"WHERE": [
|
|
354
|
+
"app"
|
|
355
|
+
]
|
|
356
|
+
}
|
|
357
|
+
},
|
|
358
|
+
{
|
|
359
|
+
"id": "req-bots-challenge",
|
|
360
|
+
"type": "requirement",
|
|
361
|
+
"label": "Repeated costly calls challenged",
|
|
362
|
+
"x": 260,
|
|
363
|
+
"y": 1300,
|
|
364
|
+
"ears_type": "unwanted-behaviour",
|
|
365
|
+
"unwanted_condition": "one source calls one of {{COSTLY_OPS}} more than 10 times in 10 minutes",
|
|
366
|
+
"action": "ask for a challenge (Turnstile, hCaptcha or reCAPTCHA) before going on, and never for the first attempt",
|
|
367
|
+
"rationale": "Bots go for what costs us or helps them; a challenge after repetition stops automation without taxing real users (OWASP Automated Threats OAT-007 Credential Cracking, OAT-008 Credential Stuffing, OAT-019 Account Creation).",
|
|
368
|
+
"hubWhen": {
|
|
369
|
+
"BOTS": [
|
|
370
|
+
"challenge"
|
|
371
|
+
]
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
{
|
|
375
|
+
"id": "req-bots-managed",
|
|
376
|
+
"type": "requirement",
|
|
377
|
+
"label": "Automated traffic stopped at the edge",
|
|
378
|
+
"x": 260,
|
|
379
|
+
"y": 1430,
|
|
380
|
+
"ears_type": "unwanted-behaviour",
|
|
381
|
+
"unwanted_condition": "a request to one of {{COSTLY_OPS}} is scored as automated by the edge's bot detection",
|
|
382
|
+
"action": "block or challenge it at the edge before it reaches the element, letting verified bots (search engines, monitoring) through, and report the blocked share every day",
|
|
383
|
+
"rationale": "Distributed bots stay under every per-caller limit; detection on many signals at once is what catches them (OWASP Automated Threats to Web Applications).",
|
|
384
|
+
"hubWhen": {
|
|
385
|
+
"BOTS": [
|
|
386
|
+
"managed"
|
|
387
|
+
]
|
|
388
|
+
}
|
|
389
|
+
},
|
|
390
|
+
{
|
|
391
|
+
"id": "req-bots-none",
|
|
392
|
+
"type": "requirement",
|
|
393
|
+
"label": "Costly operations need identity",
|
|
394
|
+
"x": 260,
|
|
395
|
+
"y": 1560,
|
|
396
|
+
"ears_type": "ubiquitous",
|
|
397
|
+
"action": "offer {{COSTLY_OPS}} only to callers with a valid account or partner key, so that each can be counted and blocked by who it is",
|
|
398
|
+
"rationale": "Without bot protection, the only defence for a costly operation is that nobody anonymous can reach it (OWASP API6:2023 Unrestricted Access to Sensitive Business Flows).",
|
|
399
|
+
"hubWhen": {
|
|
400
|
+
"BOTS": [
|
|
401
|
+
"none"
|
|
402
|
+
]
|
|
403
|
+
}
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
"id": "req-internet",
|
|
407
|
+
"type": "requirement",
|
|
408
|
+
"label": "Floods absorbed at the edge",
|
|
409
|
+
"x": 260,
|
|
410
|
+
"y": 1690,
|
|
411
|
+
"ears_type": "ubiquitous",
|
|
412
|
+
"action": "accept internet traffic only through the provider's edge with volumetric DDoS protection, and refuse connections to the origin from anywhere else",
|
|
413
|
+
"rationale": "A flood measured in gigabits cannot be limited by the element it is aimed at; an origin reachable directly bypasses every edge rule (OWASP Denial of Service Cheat Sheet).",
|
|
414
|
+
"hubWhen": {
|
|
415
|
+
"EXPOSURE": [
|
|
416
|
+
"internet"
|
|
417
|
+
]
|
|
418
|
+
}
|
|
419
|
+
},
|
|
420
|
+
{
|
|
421
|
+
"id": "req-partners",
|
|
422
|
+
"type": "requirement",
|
|
423
|
+
"label": "Limits per partner",
|
|
424
|
+
"x": 260,
|
|
425
|
+
"y": 1820,
|
|
426
|
+
"ears_type": "state-driven",
|
|
427
|
+
"precondition": "a partner has used more than 80 % of its agreed limit for 15 minutes",
|
|
428
|
+
"action": "alert the partner's owner on our side, so that the limit is raised by agreement or the partner is told before it is refused",
|
|
429
|
+
"rationale": "Limits per partner are agreements, not just defences; a partner that hits its limit unannounced is an outage for its users (OWASP API4:2023).",
|
|
430
|
+
"hubWhen": {
|
|
431
|
+
"EXPOSURE": [
|
|
432
|
+
"partners"
|
|
433
|
+
]
|
|
434
|
+
}
|
|
435
|
+
},
|
|
436
|
+
{
|
|
437
|
+
"id": "req-internal",
|
|
438
|
+
"type": "requirement",
|
|
439
|
+
"label": "Reachable only inside",
|
|
440
|
+
"x": 260,
|
|
441
|
+
"y": 1950,
|
|
442
|
+
"ears_type": "ubiquitous",
|
|
443
|
+
"action": "accept connections only from our own network, with no public address and no route from the internet",
|
|
444
|
+
"rationale": "Not reachable is the strongest limit; the decision records it so that exposing the element later is a decision too.",
|
|
445
|
+
"hubWhen": {
|
|
446
|
+
"EXPOSURE": [
|
|
447
|
+
"internal"
|
|
448
|
+
]
|
|
449
|
+
}
|
|
450
|
+
},
|
|
451
|
+
{
|
|
452
|
+
"id": "sc-limit",
|
|
453
|
+
"type": "scenario",
|
|
454
|
+
"label": "Excess refused",
|
|
455
|
+
"x": 520,
|
|
456
|
+
"y": 0,
|
|
457
|
+
"given": "one caller and ten others at normal load",
|
|
458
|
+
"when": "the one sends {{LIMIT_PER_MIN}} requests and then 100 more within a minute",
|
|
459
|
+
"then": "the extra requests get 429 with Retry-After, and the others' 95th percentile stays within 10 % of normal"
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
"id": "sc-size",
|
|
463
|
+
"type": "scenario",
|
|
464
|
+
"label": "Large body refused",
|
|
465
|
+
"x": 520,
|
|
466
|
+
"y": 130,
|
|
467
|
+
"given": "an operation that accepts {{MAX_BODY_KB}} KB at most",
|
|
468
|
+
"when": "a 100 MB body is sent",
|
|
469
|
+
"then": "it is refused with 413 and the element's memory does not grow by more than the limit"
|
|
470
|
+
},
|
|
471
|
+
{
|
|
472
|
+
"id": "sc-pages",
|
|
473
|
+
"type": "scenario",
|
|
474
|
+
"label": "Page size capped",
|
|
475
|
+
"x": 520,
|
|
476
|
+
"y": 260,
|
|
477
|
+
"given": "a list of 10 000 items",
|
|
478
|
+
"when": "a caller asks for a page of 10 000",
|
|
479
|
+
"then": "the request is refused with 400, and a request without a page size gets at most {{MAX_PAGE_ITEMS}} items"
|
|
480
|
+
},
|
|
481
|
+
{
|
|
482
|
+
"id": "sc-token-bucket",
|
|
483
|
+
"type": "scenario",
|
|
484
|
+
"label": "Burst admitted",
|
|
485
|
+
"x": 520,
|
|
486
|
+
"y": 390,
|
|
487
|
+
"given": "a caller that has sent nothing for a minute",
|
|
488
|
+
"when": "it sends {{BURST}} requests at once and then keeps sending at twice its rate",
|
|
489
|
+
"then": "the burst is accepted, and afterwards requests above {{LIMIT_PER_MIN}} a minute get 429",
|
|
490
|
+
"hubWhen": {
|
|
491
|
+
"ALGORITHM": [
|
|
492
|
+
"token-bucket"
|
|
493
|
+
]
|
|
494
|
+
}
|
|
495
|
+
},
|
|
496
|
+
{
|
|
497
|
+
"id": "sc-sliding-window",
|
|
498
|
+
"type": "scenario",
|
|
499
|
+
"label": "Edge burst refused",
|
|
500
|
+
"x": 520,
|
|
501
|
+
"y": 520,
|
|
502
|
+
"given": "a caller",
|
|
503
|
+
"when": "it sends {{LIMIT_PER_MIN}} requests in the last second of one minute and as many in the first second of the next",
|
|
504
|
+
"then": "the second batch gets 429",
|
|
505
|
+
"hubWhen": {
|
|
506
|
+
"ALGORITHM": [
|
|
507
|
+
"sliding-window"
|
|
508
|
+
]
|
|
509
|
+
}
|
|
510
|
+
},
|
|
511
|
+
{
|
|
512
|
+
"id": "sc-fixed-window",
|
|
513
|
+
"type": "scenario",
|
|
514
|
+
"label": "Quota visible",
|
|
515
|
+
"x": 520,
|
|
516
|
+
"y": 650,
|
|
517
|
+
"given": "a caller that has made 10 requests this minute",
|
|
518
|
+
"when": "it makes another",
|
|
519
|
+
"then": "the response says the limit is {{LIMIT_PER_MIN}}, how many remain and when the window resets",
|
|
520
|
+
"hubWhen": {
|
|
521
|
+
"ALGORITHM": [
|
|
522
|
+
"fixed-window"
|
|
523
|
+
]
|
|
524
|
+
}
|
|
525
|
+
},
|
|
526
|
+
{
|
|
527
|
+
"id": "sc-key-account",
|
|
528
|
+
"type": "scenario",
|
|
529
|
+
"label": "Anonymous flood",
|
|
530
|
+
"x": 520,
|
|
531
|
+
"y": 780,
|
|
532
|
+
"given": "a source address without a credential and a signed-in user",
|
|
533
|
+
"when": "the address sends {{ANON_LIMIT_PER_MIN}} requests and 10 more within a minute",
|
|
534
|
+
"then": "the 10 get 429 and the signed-in user's requests are unaffected",
|
|
535
|
+
"hubWhen": {
|
|
536
|
+
"KEY": [
|
|
537
|
+
"account"
|
|
538
|
+
]
|
|
539
|
+
}
|
|
540
|
+
},
|
|
541
|
+
{
|
|
542
|
+
"id": "sc-key-apikey",
|
|
543
|
+
"type": "scenario",
|
|
544
|
+
"label": "Invalid key ignored",
|
|
545
|
+
"x": 520,
|
|
546
|
+
"y": 910,
|
|
547
|
+
"given": "a partner's key with its limit almost used",
|
|
548
|
+
"when": "another source sends 1 000 requests naming that key with a wrong secret",
|
|
549
|
+
"then": "they are refused with 401, the partner's remaining limit does not change, and the source is limited after {{ANON_LIMIT_PER_MIN}}",
|
|
550
|
+
"hubWhen": {
|
|
551
|
+
"KEY": [
|
|
552
|
+
"apikey"
|
|
553
|
+
]
|
|
554
|
+
}
|
|
555
|
+
},
|
|
556
|
+
{
|
|
557
|
+
"id": "sc-key-ip",
|
|
558
|
+
"type": "scenario",
|
|
559
|
+
"label": "Forged header ignored",
|
|
560
|
+
"x": 520,
|
|
561
|
+
"y": 1040,
|
|
562
|
+
"given": "a caller over its limit",
|
|
563
|
+
"when": "it sends requests with a different X-Forwarded-For value each time, and then from other addresses in its /64",
|
|
564
|
+
"then": "they are all counted against the same caller and refused",
|
|
565
|
+
"hubWhen": {
|
|
566
|
+
"KEY": [
|
|
567
|
+
"ip"
|
|
568
|
+
]
|
|
569
|
+
}
|
|
570
|
+
},
|
|
571
|
+
{
|
|
572
|
+
"id": "sc-shared-counters",
|
|
573
|
+
"type": "scenario",
|
|
574
|
+
"label": "Limit holds on four instances",
|
|
575
|
+
"x": 520,
|
|
576
|
+
"y": 1170,
|
|
577
|
+
"given": "four instances behind a load balancer",
|
|
578
|
+
"when": "one caller sends twice {{LIMIT_PER_MIN}} requests in a minute spread over all four",
|
|
579
|
+
"then": "no more than {{LIMIT_PER_MIN}} plus 10 % are accepted in total",
|
|
580
|
+
"hubWhen": {
|
|
581
|
+
"WHERE": [
|
|
582
|
+
"app"
|
|
583
|
+
]
|
|
584
|
+
}
|
|
585
|
+
},
|
|
586
|
+
{
|
|
587
|
+
"id": "sc-bots-challenge",
|
|
588
|
+
"type": "scenario",
|
|
589
|
+
"label": "Bot challenged",
|
|
590
|
+
"x": 520,
|
|
591
|
+
"y": 1300,
|
|
592
|
+
"given": "one source",
|
|
593
|
+
"when": "it calls the first of {{COSTLY_OPS}} 11 times in 10 minutes",
|
|
594
|
+
"then": "the 11th attempt is answered with a challenge, and a new source's first attempt is not",
|
|
595
|
+
"hubWhen": {
|
|
596
|
+
"BOTS": [
|
|
597
|
+
"challenge"
|
|
598
|
+
]
|
|
599
|
+
}
|
|
600
|
+
},
|
|
601
|
+
{
|
|
602
|
+
"id": "sc-bots-managed",
|
|
603
|
+
"type": "scenario",
|
|
604
|
+
"label": "Headless browser stopped",
|
|
605
|
+
"x": 520,
|
|
606
|
+
"y": 1430,
|
|
607
|
+
"given": "the edge's bot detection in blocking mode",
|
|
608
|
+
"when": "a headless browser script calls the first of {{COSTLY_OPS}} from 50 addresses",
|
|
609
|
+
"then": "its requests are challenged or blocked at the edge and none reach the element",
|
|
610
|
+
"hubWhen": {
|
|
611
|
+
"BOTS": [
|
|
612
|
+
"managed"
|
|
613
|
+
]
|
|
614
|
+
}
|
|
615
|
+
},
|
|
616
|
+
{
|
|
617
|
+
"id": "sc-bots-none",
|
|
618
|
+
"type": "scenario",
|
|
619
|
+
"label": "Anonymous costly call refused",
|
|
620
|
+
"x": 520,
|
|
621
|
+
"y": 1560,
|
|
622
|
+
"given": "a caller without a credential",
|
|
623
|
+
"when": "it calls the first of {{COSTLY_OPS}}",
|
|
624
|
+
"then": "it is refused with 401",
|
|
625
|
+
"hubWhen": {
|
|
626
|
+
"BOTS": [
|
|
627
|
+
"none"
|
|
628
|
+
]
|
|
629
|
+
}
|
|
630
|
+
},
|
|
631
|
+
{
|
|
632
|
+
"id": "sc-internet",
|
|
633
|
+
"type": "scenario",
|
|
634
|
+
"label": "Origin hidden",
|
|
635
|
+
"x": 520,
|
|
636
|
+
"y": 1690,
|
|
637
|
+
"given": "the element behind its edge",
|
|
638
|
+
"when": "its origin address is called directly from the internet",
|
|
639
|
+
"then": "the connection is refused",
|
|
640
|
+
"hubWhen": {
|
|
641
|
+
"EXPOSURE": [
|
|
642
|
+
"internet"
|
|
643
|
+
]
|
|
644
|
+
}
|
|
645
|
+
},
|
|
646
|
+
{
|
|
647
|
+
"id": "sc-partners",
|
|
648
|
+
"type": "scenario",
|
|
649
|
+
"label": "Near the limit",
|
|
650
|
+
"x": 520,
|
|
651
|
+
"y": 1820,
|
|
652
|
+
"given": "a partner with an agreed limit",
|
|
653
|
+
"when": "it runs at 85 % of it for 15 minutes",
|
|
654
|
+
"then": "its owner on our side is alerted",
|
|
655
|
+
"hubWhen": {
|
|
656
|
+
"EXPOSURE": [
|
|
657
|
+
"partners"
|
|
658
|
+
]
|
|
659
|
+
}
|
|
660
|
+
},
|
|
661
|
+
{
|
|
662
|
+
"id": "sc-internal",
|
|
663
|
+
"type": "scenario",
|
|
664
|
+
"label": "Closed from outside",
|
|
665
|
+
"x": 520,
|
|
666
|
+
"y": 1950,
|
|
667
|
+
"given": "the element deployed",
|
|
668
|
+
"when": "its addresses and ports are scanned from outside the network",
|
|
669
|
+
"then": "none answers",
|
|
670
|
+
"hubWhen": {
|
|
671
|
+
"EXPOSURE": [
|
|
672
|
+
"internal"
|
|
673
|
+
]
|
|
674
|
+
}
|
|
675
|
+
},
|
|
676
|
+
{
|
|
677
|
+
"id": "adr-gateway",
|
|
678
|
+
"type": "adr",
|
|
679
|
+
"label": "Limits at the API gateway",
|
|
680
|
+
"x": 780,
|
|
681
|
+
"y": 0,
|
|
682
|
+
"concern": "rate-limiting",
|
|
683
|
+
"status": "accepted",
|
|
684
|
+
"date": "",
|
|
685
|
+
"context": "This element takes requests from people or other systems outside it. The forces: one caller, by mistake (a retry loop, a bad deploy) or on purpose, can use up capacity meant for all; bots guess passwords, create accounts, scrape data and run up the bill of costly operations (messages sent, searches, third-party calls); a request or a page can be large enough to exhaust memory before it is refused; limits that are too tight, or keyed on an address shared by an office or a mobile carrier, lock out real users; and a limit counted on one instance of many is no limit at all.",
|
|
686
|
+
"decision": "Requests pass an API gateway that limits each caller, counted by {{KEY}}, to {{LIMIT_PER_MIN}} requests a minute using {{ALGORITHM}}, refuses bodies over {{MAX_BODY_KB}} KB, and answers the excess with 429 and Retry-After; counters are shared by all gateway nodes. The element is reachable by {{EXPOSURE}}; bots on costly operations: {{BOTS}}. Choosing the gateway: the one already in the path. Match the algorithm: AWS API Gateway (usage plans) and Envoy's local rate limit are token buckets, NGINX limit_req a leaky bucket with a burst, Kong's open-source rate-limiting plugin fixed windows (sliding windows in Kong Enterprise and Azure API Management's rate-limit-by-key). Judge by whether it can key on the validated token's subject or the API key, share counters across nodes (Redis, a global rate limit service) and set limits per caller.",
|
|
687
|
+
"consequences": "• One place for every route's limits, applied before the element spends anything.\n• The gateway must see the caller's identity: it validates tokens or keys itself.\n• Limits that depend on business data (plan, tenant) need the gateway to read it, or a second limit in the element.\n• Limits need tuning from real traffic; start in log-only mode for a week.",
|
|
688
|
+
"alternatives": "1. At the edge WAF: earlier and cheaper, but approximate and keyed mostly on addresses.\n2. In the application: knows the business, but a request has already reached the element.\n3. Rely on autoscaling: pays for abuse instead of stopping it.",
|
|
689
|
+
"hubWhen": {
|
|
690
|
+
"WHERE": [
|
|
691
|
+
"gateway"
|
|
692
|
+
]
|
|
693
|
+
}
|
|
694
|
+
},
|
|
695
|
+
{
|
|
696
|
+
"id": "adr-waf",
|
|
697
|
+
"type": "adr",
|
|
698
|
+
"label": "Limits at the edge",
|
|
699
|
+
"x": 780,
|
|
700
|
+
"y": 130,
|
|
701
|
+
"concern": "rate-limiting",
|
|
702
|
+
"status": "accepted",
|
|
703
|
+
"date": "",
|
|
704
|
+
"context": "This element takes requests from people or other systems outside it. The forces: one caller, by mistake (a retry loop, a bad deploy) or on purpose, can use up capacity meant for all; bots guess passwords, create accounts, scrape data and run up the bill of costly operations (messages sent, searches, third-party calls); a request or a page can be large enough to exhaust memory before it is refused; limits that are too tight, or keyed on an address shared by an office or a mobile carrier, lock out real users; and a limit counted on one instance of many is no limit at all.",
|
|
705
|
+
"decision": "Rate rules at the edge WAF or CDN limit each caller, counted by {{KEY}}, to {{LIMIT_PER_MIN}} requests a minute using {{ALGORITHM}} as closely as the product allows, refuse bodies over {{MAX_BODY_KB}} KB, and answer the excess with 429 and Retry-After; the origin accepts traffic only from the edge. The element is reachable by {{EXPOSURE}}; bots on costly operations: {{BOTS}}. Choosing the product: Cloudflare WAF rate limiting rules, AWS WAF rate-based rules (with CloudFront or an ALB), Azure Front Door WAF rate limit rules or Akamai; judge by the keys it can count on (address, header, cookie, JWT claim), the shortest window it supports, how fast it starts blocking, and its price per million requests.",
|
|
706
|
+
"consequences": "• Floods are refused before they reach our network or our bill.\n• Counts are approximate and lag by seconds: the limit is a ceiling, not an exact figure.\n• Keys are mostly addresses and headers; per-account limits need the edge to read a token claim or a second limit further in.\n• The edge provider is on every request's path.",
|
|
707
|
+
"alternatives": "1. At the API gateway: exact, keyed on the validated caller, but after traffic entered our network.\n2. In the application: knows the business, latest of all.",
|
|
708
|
+
"hubWhen": {
|
|
709
|
+
"WHERE": [
|
|
710
|
+
"waf"
|
|
711
|
+
]
|
|
712
|
+
}
|
|
713
|
+
},
|
|
714
|
+
{
|
|
715
|
+
"id": "adr-app",
|
|
716
|
+
"type": "adr",
|
|
717
|
+
"label": "Limits in the application",
|
|
718
|
+
"x": 780,
|
|
719
|
+
"y": 260,
|
|
720
|
+
"concern": "rate-limiting",
|
|
721
|
+
"status": "accepted",
|
|
722
|
+
"date": "",
|
|
723
|
+
"context": "This element takes requests from people or other systems outside it. The forces: one caller, by mistake (a retry loop, a bad deploy) or on purpose, can use up capacity meant for all; bots guess passwords, create accounts, scrape data and run up the bill of costly operations (messages sent, searches, third-party calls); a request or a page can be large enough to exhaust memory before it is refused; limits that are too tight, or keyed on an address shared by an office or a mobile carrier, lock out real users; and a limit counted on one instance of many is no limit at all.",
|
|
724
|
+
"decision": "The element limits each caller, counted by {{KEY}}, to {{LIMIT_PER_MIN}} requests a minute using {{ALGORITHM}}, in middleware that runs before any handler, with counters in a shared Redis; bodies over {{MAX_BODY_KB}} KB are refused by the server's own limit. The excess gets 429 and Retry-After. The element is reachable by {{EXPOSURE}}; bots on costly operations: {{BOTS}}. Choosing the library: the framework's own (ASP.NET Core rate limiting, Spring Cloud Gateway RequestRateLimiter) or a maintained one with a Redis store (Bucket4j for Java, express-rate-limit with rate-limit-redis for Node, django-ratelimit for Python); judge by its algorithms, atomic shared counters and per-route configuration.",
|
|
725
|
+
"consequences": "• Limits can follow business data: plan, tenant, operation cost.\n• A request has already reached the element when it is refused: floods still need protection in front.\n• Redis is on the request path; when it is unreachable, the per-instance fallback limits less exactly.",
|
|
726
|
+
"alternatives": "1. At the API gateway: before the element, but blind to business data.\n2. At the edge WAF: earliest and cheapest, approximate.",
|
|
727
|
+
"hubWhen": {
|
|
728
|
+
"WHERE": [
|
|
729
|
+
"app"
|
|
730
|
+
]
|
|
731
|
+
}
|
|
732
|
+
},
|
|
733
|
+
{
|
|
734
|
+
"id": "adr-internal",
|
|
735
|
+
"type": "adr",
|
|
736
|
+
"label": "Not reachable from outside",
|
|
737
|
+
"x": 780,
|
|
738
|
+
"y": 390,
|
|
739
|
+
"concern": "rate-limiting",
|
|
740
|
+
"status": "accepted",
|
|
741
|
+
"date": "",
|
|
742
|
+
"context": "This element takes requests from people or other systems outside it. The forces: one caller, by mistake (a retry loop, a bad deploy) or on purpose, can use up capacity meant for all; bots guess passwords, create accounts, scrape data and run up the bill of costly operations (messages sent, searches, third-party calls); a request or a page can be large enough to exhaust memory before it is refused; limits that are too tight, or keyed on an address shared by an office or a mobile carrier, lock out real users; and a limit counted on one instance of many is no limit at all.",
|
|
743
|
+
"decision": "The element accepts connections only from our own network: no public address, security groups or network policies admit only the internal callers listed in the model. Exposing it later supersedes this decision and brings the edge protection the internet needs.",
|
|
744
|
+
"consequences": "• Nothing outside can flood or scrape it.\n• Internal callers are still limited, against retry storms and runaway jobs.\n• Every new caller needs a network rule, which shows up in review.",
|
|
745
|
+
"alternatives": "1. Public with limits: needed only if outside callers appear.\n2. Reachable through a VPN for partners: closer to the partners option than to this one.",
|
|
746
|
+
"hubWhen": {
|
|
747
|
+
"EXPOSURE": [
|
|
748
|
+
"internal"
|
|
749
|
+
]
|
|
750
|
+
}
|
|
751
|
+
},
|
|
752
|
+
{
|
|
753
|
+
"id": "ff-noisy",
|
|
754
|
+
"type": "fitness-fn",
|
|
755
|
+
"label": "Noisy caller contained",
|
|
756
|
+
"x": 1040,
|
|
757
|
+
"y": 0,
|
|
758
|
+
"category": "operational",
|
|
759
|
+
"threshold": "With one caller at 10 times {{LIMIT_PER_MIN}} requests a minute, other callers' 95th percentile stays within 10 % of the baseline and at least 99 % of the flood's excess gets 429 with Retry-After",
|
|
760
|
+
"description": "A load test in the staging environment runs normal traffic from several callers and a flood from one, and compares the others' response times with a baseline run without the flood.\n\nTool: Grafana k6\n\n```js\nimport http from 'k6/http'\nimport { check } from 'k6'\n\nconst LIMIT = {{LIMIT_PER_MIN}}\nconst BASELINE_P95 = Number(__ENV.BASELINE_P95_MS)\n\nexport const options = {\n scenarios: {\n normal: { executor: 'constant-arrival-rate', rate: 20, timeUnit: '1s', duration: '3m', preAllocatedVUs: 50, env: { KEY: 'normal' } },\n flood: { executor: 'constant-arrival-rate', rate: LIMIT * 10, timeUnit: '1m', duration: '3m', preAllocatedVUs: 200, env: { KEY: 'flood' } },\n },\n thresholds: {\n 'http_req_duration{scenario:normal}': [`p(95)<${BASELINE_P95 * 1.1}`],\n 'checks{scenario:flood}': ['rate>0.89'], // 90 % of the flood is excess\n },\n}\n\nexport default function () {\n const res = http.get(`${__ENV.BASE_URL}/orders`, { headers: { Authorization: `Bearer ${__ENV['TOKEN_' + __ENV.KEY]}` } })\n if (__ENV.KEY === 'flood') check(res, { 'limited with Retry-After': (r) => r.status === 429 && !!r.headers['Retry-After'] })\n}\n```"
|
|
761
|
+
},
|
|
762
|
+
{
|
|
763
|
+
"id": "ff-body",
|
|
764
|
+
"type": "fitness-fn",
|
|
765
|
+
"label": "Oversized bodies refused",
|
|
766
|
+
"x": 1040,
|
|
767
|
+
"y": 130,
|
|
768
|
+
"category": "structural",
|
|
769
|
+
"threshold": "A body of 100 times {{MAX_BODY_KB}} KB is answered with 413 on 100 % of the element's write operations",
|
|
770
|
+
"description": "A smoke test after each deployment sends an oversized body to each write operation and expects 413, which fails when a new route or a proxy change drops the size limit.\n\nTool: curl in the deployment pipeline\n\n```bash\nsize_kb=$(( {{MAX_BODY_KB}} * 100 ))\nfor route in $(cat write-routes.txt); do\n code=$(head -c \"${size_kb}K\" /dev/zero | curl -s -o /dev/null -w '%{http_code}' \\\n -X POST -H 'Content-Type: application/json' --data-binary @- \"$BASE_URL$route\")\n [ \"$code\" = 413 ] || { echo \"$route answered $code to an oversized body\"; exit 1; }\ndone\n```"
|
|
771
|
+
},
|
|
772
|
+
{
|
|
773
|
+
"id": "ff-gateway",
|
|
774
|
+
"type": "fitness-fn",
|
|
775
|
+
"label": "Every route limited",
|
|
776
|
+
"x": 1040,
|
|
777
|
+
"y": 260,
|
|
778
|
+
"category": "structural",
|
|
779
|
+
"threshold": "0 gateway services without a rate-limiting plugin; 0 limits above {{LIMIT_PER_MIN}} a minute without an exception recorded",
|
|
780
|
+
"description": "A Conftest policy over the gateway's declarative configuration (Kong decK file) fails the pull request when a service has no rate limit, or one higher than agreed.\n\nTool: Conftest (Open Policy Agent) over the Kong decK configuration\n\n```rego\npackage main\n\nimport rego.v1\n\nlimited(s) if { some p in s.plugins; p.name in {\"rate-limiting\", \"rate-limiting-advanced\"} }\nglobal if { some p in input.plugins; p.name in {\"rate-limiting\", \"rate-limiting-advanced\"} }\n\ndeny contains msg if {\n not global\n some s in input.services\n not limited(s)\n msg := sprintf(\"service %s has no rate limit\", [s.name])\n}\n\ndeny contains msg if {\n some s in input.services\n some p in s.plugins\n p.name == \"rate-limiting\"\n p.config.minute > {{LIMIT_PER_MIN}}\n msg := sprintf(\"service %s allows %d a minute\", [s.name, p.config.minute])\n}\n```",
|
|
781
|
+
"hubWhen": {
|
|
782
|
+
"WHERE": [
|
|
783
|
+
"gateway"
|
|
784
|
+
]
|
|
785
|
+
}
|
|
786
|
+
},
|
|
787
|
+
{
|
|
788
|
+
"id": "ff-waf",
|
|
789
|
+
"type": "fitness-fn",
|
|
790
|
+
"label": "Edge rate rule present",
|
|
791
|
+
"x": 1040,
|
|
792
|
+
"y": 390,
|
|
793
|
+
"category": "structural",
|
|
794
|
+
"threshold": "Every web ACL in front of the element holds a rate-based rule in blocking mode; 0 plan changes that remove it",
|
|
795
|
+
"description": "A Conftest policy over the Terraform plan fails when a WAF web ACL has no rate-based rule that blocks, so the edge limit cannot disappear in a refactoring.\n\nTool: Conftest (Open Policy Agent) over terraform show -json\n\n```rego\npackage main\n\nimport rego.v1\n\nrate_rule(acl) if {\n some r in acl.rule\n some s in r.statement\n count(s.rate_based_statement) > 0\n some a in r.action\n count(a.block) > 0\n}\n\ndeny contains msg if {\n some rc in input.resource_changes\n rc.type == \"aws_wafv2_web_acl\"\n not rate_rule(rc.change.after)\n msg := sprintf(\"%s has no blocking rate-based rule\", [rc.address])\n}\n```",
|
|
796
|
+
"hubWhen": {
|
|
797
|
+
"WHERE": [
|
|
798
|
+
"waf"
|
|
799
|
+
]
|
|
800
|
+
}
|
|
801
|
+
},
|
|
802
|
+
{
|
|
803
|
+
"id": "ff-app",
|
|
804
|
+
"type": "fitness-fn",
|
|
805
|
+
"label": "Limit holds across instances",
|
|
806
|
+
"x": 1040,
|
|
807
|
+
"y": 520,
|
|
808
|
+
"category": "structural",
|
|
809
|
+
"threshold": "Against two instances sharing Redis, request {{LIMIT_PER_MIN}} + 1 within a minute gets 429 with Retry-After; another caller's request still succeeds",
|
|
810
|
+
"description": "An integration test starts two instances of the element with a Redis container, spreads one caller's requests over both, and expects the limit to hold for the pair.\n\nTool: Vitest with supertest and Testcontainers (Redis)\n\n```ts\nit('limits one caller across instances', async () => {\n const [a, b] = await startInstances(2, { redisUrl: redis.getConnectionUrl() })\n for (let i = 0; i < {{LIMIT_PER_MIN}}; i++) await request(i % 2 ? a : b).get('/orders').set(auth(caller)).expect(200)\n const res = await request(a).get('/orders').set(auth(caller))\n expect(res.status).toBe(429)\n expect(Number(res.headers['retry-after'])).toBeGreaterThan(0)\n await request(b).get('/orders').set(auth(otherCaller)).expect(200)\n})\n```",
|
|
811
|
+
"hubWhen": {
|
|
812
|
+
"WHERE": [
|
|
813
|
+
"app"
|
|
814
|
+
]
|
|
815
|
+
}
|
|
816
|
+
},
|
|
817
|
+
{
|
|
818
|
+
"id": "ff-bots-challenge",
|
|
819
|
+
"type": "fitness-fn",
|
|
820
|
+
"label": "Repeated sign-in challenged",
|
|
821
|
+
"x": 1040,
|
|
822
|
+
"y": 650,
|
|
823
|
+
"category": "structural",
|
|
824
|
+
"threshold": "The 11th attempt at a costly operation from one source within 10 minutes shows a challenge; the 1st attempt from a new source never does",
|
|
825
|
+
"description": "An end-to-end test repeats the first costly operation from one browser context and expects the challenge widget on the 11th attempt, and none in a fresh context.\n\nTool: Playwright\n\n```ts\ntest('repeated sign-in is challenged', async ({ page, browser }) => {\n for (let i = 0; i < 11; i++) {\n await page.goto('/sign-in')\n await page.getByLabel('Email').fill('someone@example.com')\n await page.getByLabel('Password').fill(`wrong-${i}`)\n await page.getByRole('button', { name: 'Sign in' }).click()\n }\n await expect(page.locator('iframe[src*=\"challenges.cloudflare.com\"]')).toBeVisible()\n const fresh = await (await browser.newContext()).newPage()\n await fresh.goto('/sign-in')\n await expect(fresh.locator('iframe[src*=\"challenges.cloudflare.com\"]')).toHaveCount(0)\n})\n```",
|
|
826
|
+
"hubWhen": {
|
|
827
|
+
"BOTS": [
|
|
828
|
+
"challenge"
|
|
829
|
+
]
|
|
830
|
+
}
|
|
831
|
+
},
|
|
832
|
+
{
|
|
833
|
+
"id": "ff-bots-managed",
|
|
834
|
+
"type": "fitness-fn",
|
|
835
|
+
"label": "Bot control enabled",
|
|
836
|
+
"x": 1040,
|
|
837
|
+
"y": 780,
|
|
838
|
+
"category": "structural",
|
|
839
|
+
"threshold": "The web ACL in front of the element holds the managed bot rule group, not in count-only mode",
|
|
840
|
+
"description": "A Conftest policy over the Terraform plan fails when the edge's managed bot rule group is missing or overridden to count, which would let bots through silently.\n\nTool: Conftest (Open Policy Agent) over terraform show -json, for AWS WAF Bot Control\n\n```rego\npackage main\n\nimport rego.v1\n\nbot_control(acl) if {\n some r in acl.rule\n some s in r.statement\n some m in s.managed_rule_group_statement\n m.name == \"AWSManagedRulesBotControlRuleSet\"\n some o in r.override_action\n count(o.none) > 0\n}\n\ndeny contains msg if {\n some rc in input.resource_changes\n rc.type == \"aws_wafv2_web_acl\"\n not bot_control(rc.change.after)\n msg := sprintf(\"%s does not enforce AWS WAF Bot Control\", [rc.address])\n}\n```",
|
|
841
|
+
"hubWhen": {
|
|
842
|
+
"BOTS": [
|
|
843
|
+
"managed"
|
|
844
|
+
]
|
|
845
|
+
}
|
|
846
|
+
},
|
|
847
|
+
{
|
|
848
|
+
"id": "ff-closed",
|
|
849
|
+
"type": "fitness-fn",
|
|
850
|
+
"label": "Closed from outside",
|
|
851
|
+
"x": 1040,
|
|
852
|
+
"y": 910,
|
|
853
|
+
"category": "operational",
|
|
854
|
+
"threshold": "0 ports of the element answer from outside the network",
|
|
855
|
+
"description": "A scheduled scan from a runner outside the network tries every port of the element's addresses and fails on any that answers.\n\nTool: Nmap\n\n```bash\nnmap -Pn -p- --open -oG scan.txt $ELEMENT_ADDRESSES\nif grep -q '/open/' scan.txt; then\n echo \"reachable from outside:\"; grep '/open/' scan.txt; exit 1\nfi\n```",
|
|
856
|
+
"hubWhen": {
|
|
857
|
+
"EXPOSURE": [
|
|
858
|
+
"internal"
|
|
859
|
+
]
|
|
860
|
+
}
|
|
861
|
+
}
|
|
862
|
+
],
|
|
863
|
+
"relations": [
|
|
864
|
+
{
|
|
865
|
+
"id": "req-limit--derives--need",
|
|
866
|
+
"sourceId": "req-limit",
|
|
867
|
+
"targetId": "need",
|
|
868
|
+
"relationType": "derives"
|
|
869
|
+
},
|
|
870
|
+
{
|
|
871
|
+
"id": "req-size--derives--need",
|
|
872
|
+
"sourceId": "req-size",
|
|
873
|
+
"targetId": "need",
|
|
874
|
+
"relationType": "derives"
|
|
875
|
+
},
|
|
876
|
+
{
|
|
877
|
+
"id": "req-pages--derives--need",
|
|
878
|
+
"sourceId": "req-pages",
|
|
879
|
+
"targetId": "need",
|
|
880
|
+
"relationType": "derives"
|
|
881
|
+
},
|
|
882
|
+
{
|
|
883
|
+
"id": "req-token-bucket--derives--need",
|
|
884
|
+
"sourceId": "req-token-bucket",
|
|
885
|
+
"targetId": "need",
|
|
886
|
+
"relationType": "derives"
|
|
887
|
+
},
|
|
888
|
+
{
|
|
889
|
+
"id": "req-sliding-window--derives--need",
|
|
890
|
+
"sourceId": "req-sliding-window",
|
|
891
|
+
"targetId": "need",
|
|
892
|
+
"relationType": "derives"
|
|
893
|
+
},
|
|
894
|
+
{
|
|
895
|
+
"id": "req-fixed-window--derives--need",
|
|
896
|
+
"sourceId": "req-fixed-window",
|
|
897
|
+
"targetId": "need",
|
|
898
|
+
"relationType": "derives"
|
|
899
|
+
},
|
|
900
|
+
{
|
|
901
|
+
"id": "req-key-account--derives--need",
|
|
902
|
+
"sourceId": "req-key-account",
|
|
903
|
+
"targetId": "need",
|
|
904
|
+
"relationType": "derives"
|
|
905
|
+
},
|
|
906
|
+
{
|
|
907
|
+
"id": "req-key-apikey--derives--need",
|
|
908
|
+
"sourceId": "req-key-apikey",
|
|
909
|
+
"targetId": "need",
|
|
910
|
+
"relationType": "derives"
|
|
911
|
+
},
|
|
912
|
+
{
|
|
913
|
+
"id": "req-key-ip--derives--need",
|
|
914
|
+
"sourceId": "req-key-ip",
|
|
915
|
+
"targetId": "need",
|
|
916
|
+
"relationType": "derives"
|
|
917
|
+
},
|
|
918
|
+
{
|
|
919
|
+
"id": "req-shared-counters--derives--need",
|
|
920
|
+
"sourceId": "req-shared-counters",
|
|
921
|
+
"targetId": "need",
|
|
922
|
+
"relationType": "derives"
|
|
923
|
+
},
|
|
924
|
+
{
|
|
925
|
+
"id": "req-bots-challenge--derives--need",
|
|
926
|
+
"sourceId": "req-bots-challenge",
|
|
927
|
+
"targetId": "need",
|
|
928
|
+
"relationType": "derives"
|
|
929
|
+
},
|
|
930
|
+
{
|
|
931
|
+
"id": "req-bots-managed--derives--need",
|
|
932
|
+
"sourceId": "req-bots-managed",
|
|
933
|
+
"targetId": "need",
|
|
934
|
+
"relationType": "derives"
|
|
935
|
+
},
|
|
936
|
+
{
|
|
937
|
+
"id": "req-bots-none--derives--need",
|
|
938
|
+
"sourceId": "req-bots-none",
|
|
939
|
+
"targetId": "need",
|
|
940
|
+
"relationType": "derives"
|
|
941
|
+
},
|
|
942
|
+
{
|
|
943
|
+
"id": "req-internet--derives--need",
|
|
944
|
+
"sourceId": "req-internet",
|
|
945
|
+
"targetId": "need",
|
|
946
|
+
"relationType": "derives"
|
|
947
|
+
},
|
|
948
|
+
{
|
|
949
|
+
"id": "req-partners--derives--need",
|
|
950
|
+
"sourceId": "req-partners",
|
|
951
|
+
"targetId": "need",
|
|
952
|
+
"relationType": "derives"
|
|
953
|
+
},
|
|
954
|
+
{
|
|
955
|
+
"id": "req-internal--derives--need",
|
|
956
|
+
"sourceId": "req-internal",
|
|
957
|
+
"targetId": "need",
|
|
958
|
+
"relationType": "derives"
|
|
959
|
+
},
|
|
960
|
+
{
|
|
961
|
+
"id": "sc-limit--verifies--req-limit",
|
|
962
|
+
"sourceId": "sc-limit",
|
|
963
|
+
"targetId": "req-limit",
|
|
964
|
+
"relationType": "verifies"
|
|
965
|
+
},
|
|
966
|
+
{
|
|
967
|
+
"id": "sc-size--verifies--req-size",
|
|
968
|
+
"sourceId": "sc-size",
|
|
969
|
+
"targetId": "req-size",
|
|
970
|
+
"relationType": "verifies"
|
|
971
|
+
},
|
|
972
|
+
{
|
|
973
|
+
"id": "sc-pages--verifies--req-pages",
|
|
974
|
+
"sourceId": "sc-pages",
|
|
975
|
+
"targetId": "req-pages",
|
|
976
|
+
"relationType": "verifies"
|
|
977
|
+
},
|
|
978
|
+
{
|
|
979
|
+
"id": "sc-token-bucket--verifies--req-token-bucket",
|
|
980
|
+
"sourceId": "sc-token-bucket",
|
|
981
|
+
"targetId": "req-token-bucket",
|
|
982
|
+
"relationType": "verifies"
|
|
983
|
+
},
|
|
984
|
+
{
|
|
985
|
+
"id": "sc-sliding-window--verifies--req-sliding-window",
|
|
986
|
+
"sourceId": "sc-sliding-window",
|
|
987
|
+
"targetId": "req-sliding-window",
|
|
988
|
+
"relationType": "verifies"
|
|
989
|
+
},
|
|
990
|
+
{
|
|
991
|
+
"id": "sc-fixed-window--verifies--req-fixed-window",
|
|
992
|
+
"sourceId": "sc-fixed-window",
|
|
993
|
+
"targetId": "req-fixed-window",
|
|
994
|
+
"relationType": "verifies"
|
|
995
|
+
},
|
|
996
|
+
{
|
|
997
|
+
"id": "sc-key-account--verifies--req-key-account",
|
|
998
|
+
"sourceId": "sc-key-account",
|
|
999
|
+
"targetId": "req-key-account",
|
|
1000
|
+
"relationType": "verifies"
|
|
1001
|
+
},
|
|
1002
|
+
{
|
|
1003
|
+
"id": "sc-key-apikey--verifies--req-key-apikey",
|
|
1004
|
+
"sourceId": "sc-key-apikey",
|
|
1005
|
+
"targetId": "req-key-apikey",
|
|
1006
|
+
"relationType": "verifies"
|
|
1007
|
+
},
|
|
1008
|
+
{
|
|
1009
|
+
"id": "sc-key-ip--verifies--req-key-ip",
|
|
1010
|
+
"sourceId": "sc-key-ip",
|
|
1011
|
+
"targetId": "req-key-ip",
|
|
1012
|
+
"relationType": "verifies"
|
|
1013
|
+
},
|
|
1014
|
+
{
|
|
1015
|
+
"id": "sc-shared-counters--verifies--req-shared-counters",
|
|
1016
|
+
"sourceId": "sc-shared-counters",
|
|
1017
|
+
"targetId": "req-shared-counters",
|
|
1018
|
+
"relationType": "verifies"
|
|
1019
|
+
},
|
|
1020
|
+
{
|
|
1021
|
+
"id": "sc-bots-challenge--verifies--req-bots-challenge",
|
|
1022
|
+
"sourceId": "sc-bots-challenge",
|
|
1023
|
+
"targetId": "req-bots-challenge",
|
|
1024
|
+
"relationType": "verifies"
|
|
1025
|
+
},
|
|
1026
|
+
{
|
|
1027
|
+
"id": "sc-bots-managed--verifies--req-bots-managed",
|
|
1028
|
+
"sourceId": "sc-bots-managed",
|
|
1029
|
+
"targetId": "req-bots-managed",
|
|
1030
|
+
"relationType": "verifies"
|
|
1031
|
+
},
|
|
1032
|
+
{
|
|
1033
|
+
"id": "sc-bots-none--verifies--req-bots-none",
|
|
1034
|
+
"sourceId": "sc-bots-none",
|
|
1035
|
+
"targetId": "req-bots-none",
|
|
1036
|
+
"relationType": "verifies"
|
|
1037
|
+
},
|
|
1038
|
+
{
|
|
1039
|
+
"id": "sc-internet--verifies--req-internet",
|
|
1040
|
+
"sourceId": "sc-internet",
|
|
1041
|
+
"targetId": "req-internet",
|
|
1042
|
+
"relationType": "verifies"
|
|
1043
|
+
},
|
|
1044
|
+
{
|
|
1045
|
+
"id": "sc-partners--verifies--req-partners",
|
|
1046
|
+
"sourceId": "sc-partners",
|
|
1047
|
+
"targetId": "req-partners",
|
|
1048
|
+
"relationType": "verifies"
|
|
1049
|
+
},
|
|
1050
|
+
{
|
|
1051
|
+
"id": "sc-internal--verifies--req-internal",
|
|
1052
|
+
"sourceId": "sc-internal",
|
|
1053
|
+
"targetId": "req-internal",
|
|
1054
|
+
"relationType": "verifies"
|
|
1055
|
+
},
|
|
1056
|
+
{
|
|
1057
|
+
"id": "ff-noisy--implements--adr-gateway",
|
|
1058
|
+
"sourceId": "ff-noisy",
|
|
1059
|
+
"targetId": "adr-gateway",
|
|
1060
|
+
"relationType": "implements"
|
|
1061
|
+
},
|
|
1062
|
+
{
|
|
1063
|
+
"id": "ff-noisy--implements--adr-waf",
|
|
1064
|
+
"sourceId": "ff-noisy",
|
|
1065
|
+
"targetId": "adr-waf",
|
|
1066
|
+
"relationType": "implements"
|
|
1067
|
+
},
|
|
1068
|
+
{
|
|
1069
|
+
"id": "ff-noisy--implements--adr-app",
|
|
1070
|
+
"sourceId": "ff-noisy",
|
|
1071
|
+
"targetId": "adr-app",
|
|
1072
|
+
"relationType": "implements"
|
|
1073
|
+
},
|
|
1074
|
+
{
|
|
1075
|
+
"id": "ff-body--implements--adr-gateway",
|
|
1076
|
+
"sourceId": "ff-body",
|
|
1077
|
+
"targetId": "adr-gateway",
|
|
1078
|
+
"relationType": "implements"
|
|
1079
|
+
},
|
|
1080
|
+
{
|
|
1081
|
+
"id": "ff-body--implements--adr-waf",
|
|
1082
|
+
"sourceId": "ff-body",
|
|
1083
|
+
"targetId": "adr-waf",
|
|
1084
|
+
"relationType": "implements"
|
|
1085
|
+
},
|
|
1086
|
+
{
|
|
1087
|
+
"id": "ff-body--implements--adr-app",
|
|
1088
|
+
"sourceId": "ff-body",
|
|
1089
|
+
"targetId": "adr-app",
|
|
1090
|
+
"relationType": "implements"
|
|
1091
|
+
},
|
|
1092
|
+
{
|
|
1093
|
+
"id": "ff-gateway--implements--adr-gateway",
|
|
1094
|
+
"sourceId": "ff-gateway",
|
|
1095
|
+
"targetId": "adr-gateway",
|
|
1096
|
+
"relationType": "implements"
|
|
1097
|
+
},
|
|
1098
|
+
{
|
|
1099
|
+
"id": "ff-waf--implements--adr-waf",
|
|
1100
|
+
"sourceId": "ff-waf",
|
|
1101
|
+
"targetId": "adr-waf",
|
|
1102
|
+
"relationType": "implements"
|
|
1103
|
+
},
|
|
1104
|
+
{
|
|
1105
|
+
"id": "ff-app--implements--adr-app",
|
|
1106
|
+
"sourceId": "ff-app",
|
|
1107
|
+
"targetId": "adr-app",
|
|
1108
|
+
"relationType": "implements"
|
|
1109
|
+
},
|
|
1110
|
+
{
|
|
1111
|
+
"id": "ff-bots-challenge--implements--adr-gateway",
|
|
1112
|
+
"sourceId": "ff-bots-challenge",
|
|
1113
|
+
"targetId": "adr-gateway",
|
|
1114
|
+
"relationType": "implements"
|
|
1115
|
+
},
|
|
1116
|
+
{
|
|
1117
|
+
"id": "ff-bots-challenge--implements--adr-waf",
|
|
1118
|
+
"sourceId": "ff-bots-challenge",
|
|
1119
|
+
"targetId": "adr-waf",
|
|
1120
|
+
"relationType": "implements"
|
|
1121
|
+
},
|
|
1122
|
+
{
|
|
1123
|
+
"id": "ff-bots-challenge--implements--adr-app",
|
|
1124
|
+
"sourceId": "ff-bots-challenge",
|
|
1125
|
+
"targetId": "adr-app",
|
|
1126
|
+
"relationType": "implements"
|
|
1127
|
+
},
|
|
1128
|
+
{
|
|
1129
|
+
"id": "ff-bots-managed--implements--adr-gateway",
|
|
1130
|
+
"sourceId": "ff-bots-managed",
|
|
1131
|
+
"targetId": "adr-gateway",
|
|
1132
|
+
"relationType": "implements"
|
|
1133
|
+
},
|
|
1134
|
+
{
|
|
1135
|
+
"id": "ff-bots-managed--implements--adr-waf",
|
|
1136
|
+
"sourceId": "ff-bots-managed",
|
|
1137
|
+
"targetId": "adr-waf",
|
|
1138
|
+
"relationType": "implements"
|
|
1139
|
+
},
|
|
1140
|
+
{
|
|
1141
|
+
"id": "ff-bots-managed--implements--adr-app",
|
|
1142
|
+
"sourceId": "ff-bots-managed",
|
|
1143
|
+
"targetId": "adr-app",
|
|
1144
|
+
"relationType": "implements"
|
|
1145
|
+
},
|
|
1146
|
+
{
|
|
1147
|
+
"id": "ff-closed--implements--adr-internal",
|
|
1148
|
+
"sourceId": "ff-closed",
|
|
1149
|
+
"targetId": "adr-internal",
|
|
1150
|
+
"relationType": "implements"
|
|
1151
|
+
}
|
|
1152
|
+
]
|
|
1153
|
+
}
|