APIsec for Axum

What middleBrick covers

  • Black-box scanning with no agents or SDKs
  • Risk scoring aligned to OWASP API Top 10
  • Authenticated scans for Bearer and API key
  • OpenAPI 3.x and Swagger 2.0 analysis
  • LLM/AI adversarial prompt testing
  • Continuous monitoring and diff detection

APIsec for Axum overview

APIsec is a self-service API security scanner that assesses public endpoints and authenticated Axum services. Submit an API URL and receive a risk score from A to F with prioritized findings. The scanner performs black-box requests only, using read-safe methods (GET and HEAD) and text-only POST for LLM probes, completing a scan in under a minute.

Axum-specific detection considerations

Axum applications often rely on middleware for routing, authentication, and error handling. APIsec detects mismatches between declared security schemes and runtime behavior, such as missing guards on admin routes, leaked role or permission fields in JSON responses, and verbose error payloads that expose stack traces. It checks for CORS wildcard configurations that allow credentials, dangerous HTTP methods enabled via axum-extra, and debug or health endpoints reachable in production-like scans. Findings are mapped to OWASP API Top 10 (2023) and aligned with security controls described in SOC 2 Type II and PCI-DSS 4.0.

Authenticated scanning with Axum

For authenticated scans at the Starter tier and above, APIsec supports Bearer tokens, API keys, Basic auth, and cookie-based sessions. Before scanning, a domain verification gate confirms ownership via DNS TXT record or an HTTP well-known file, ensuring only the domain owner can submit credentials. When credentials are provided, the scanner sends only a restricted header allowlist: Authorization, X-API-Key, Cookie, and X-Custom-*. This approach supports continuous monitoring for Axum APIs, including scheduled rescans and diff detection to highlight new findings or resolved issues across scans.

OpenAPI and spec-aware analysis

APIsec parses OpenAPI 3.0, 3.1, and Swagger 2.0 documents for Axum-based services, resolving recursive $ref references. It cross-references the specification against runtime responses to identify undefined security schemes, over-exposed sensitive fields, deprecated operations, and missing pagination. This helps surface integration points that may not be actively monitored and supports audit evidence for controls relevant to compliance frameworks. The scanner also detects mismatches between declared response schemas and actual payloads, including unexpected PII or API key formats such as AWS, Stripe, GitHub, and Slack patterns.

LLM and AI security probing

APIsec includes an LLM / AI security scan that runs 18 adversarial probes across three tiers: Quick, Standard, and Deep. Probes target system prompt extraction, instruction override, DAN and roleplay jailbreaks, data exfiltration attempts, cost exploitation, encoding bypasses (base64/ROT13), translation-embedded injection, few-shot poisoning, markdown injection, multi-turn manipulation, indirect prompt injection, token smuggling, tool abuse, nested instruction injection, and PII extraction. These checks help identify prompt-injection surfaces and model-manipulation risks in Axum services that expose generative endpoints or inference interfaces.

Frequently Asked Questions

Does APIsec integrate directly with Axum source code or CI pipelines?
APIsec is a black-box scanner that does not require code access, SDKs, or agents. It integrates via the CLI, GitHub Action, MCP Server, or API client, allowing insertion into Axum CI/CD workflows without modifying application code.
Can authenticated scans validate my Axum auth middleware configuration?
Yes. Authenticated scans verify ownership through a domain gate and then exercise your auth middleware using allowed headers, detecting issues such as missing role checks, misconfigured JWT validation, or overly permissive CORS rules.
What compliance mappings does APIsec provide for Axum APIs?
Findings map directly to OWASP API Top 10 (2023), and the platform supports alignment with security controls described in SOC 2 Type II and PCI-DSS 4.0. For other frameworks, it surfaces findings relevant to audit evidence or helps prepare documentation.
How are scan results presented for Axum services?
Results appear in the web dashboard with risk scores, prioritized findings, and remediation guidance. You can download branded compliance PDFs, track score trends over time, and configure email or Slack alerts for new detections.
Does APIsec test for runtime vulnerabilities like SQLi or command injection against Axum endpoints?
No. APIsec does not perform active SQL injection or command injection testing, as those require intrusive payloads outside its scope. It focuses on configuration, exposure, and logic-layer issues observable through read-safe requests.