kingfisher/crates/kingfisher-rules/data/rules/mastra.yml
2026-04-14 12:52:27 -07:00

37 lines
1 KiB
YAML

rules:
- name: Mastra Memory Gateway API Key
id: kingfisher.mastra.1
pattern: |
(?x)
\b
(
msk_[A-Za-z0-9]{32}(?:[A-Za-z0-9]{16}){0,2}
)
\b
pattern_requirements:
min_digits: 4
min_lowercase: 4
min_uppercase: 4
min_entropy: 3.5
confidence: medium
examples:
- 'MASTRA_API_KEY="msk_7fKp2Rz9Qa4Vn8Lm3Tx6Yc5Bg1Hd0JsW"'
- 'Authorization: Bearer msk_P7rT2mK9vL4qN8sX6cA3dF5gH1jZ0QaB'
references:
- https://gateway.mastra.ai/docs
- https://gateway.mastra.ai/docs/models
validation:
type: Http
content:
request:
method: GET
url: https://gateway-api.mastra.ai/v1/models
headers:
Authorization: "Bearer {{ TOKEN }}"
Accept: application/json
response_matcher:
- report_response: true
- type: StatusMatch
status: [200]
- type: JsonValid
# Mastra Memory Gateway docs do not document a public API-key revocation endpoint.