ZAP provider actor: typed API control, scope, scan jobs, and alerts #21
Labels
No labels
bug
documentation
duplicate
enhancement
feature
good first issue
help wanted
invalid
question
refactor
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
nsaspy/hackmode#21
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Goal
Promote OWASP ZAP from a Nyxt proxy toggle into a supervised Hackmode provider with typed commands/results.
The current Nyxt
zap-modeonly forwards a buffer throughlocalhost:8080. Keep proxy routing as a client concern; put reusable ZAP API semantics here.Provider boundary
Implement a ZAP adapter/provider actor using the official ZAP REST API with configurable endpoint and API key loaded from a secret reference/environment, never source control.
Initial operations:
Represent long work as Hackmode jobs with IDs/status/cancellation rather than blocking calls.
Safety / scope invariant
Active scanning is never inferred from the current browser URL alone.
Before an active scan can start:
inScopeOnly/context restriction must be used where supported.No Internet-wide fan-out or implicit expansion to sibling hosts.
Typed outputs
Normalize ZAP data into provider result types first. Then emit canonical Hackmode assets/findings through existing protocols, preserving:
Reliability
Tests
Use a fake ZAP transport for deterministic tests plus an optional local ZAP integration fixture.
Required proofs:
References
Official ZAP API supports REST control for spider, passive/active scanning and alert retrieval; action endpoints require an API key in normal secured setups.
Architecture update from operator direction / #133: retain the ZAP provider for ZAP-native API semantics (health, contexts, passive alerts, spider and explicitly scoped active-scan jobs), but do not make ZAP a second raw HTTP capture authority. Configure ZAP outbound/upstream traffic through the operation-scoped mitmproxy/IPX service where supported, then link ZAP-specific alerts/findings back to canonical HTTP exchange evidence when correlation is available.
This keeps ZAP control useful while avoiding duplicate proxy-history persistence.