Package burp.mcp.server
Class AccessGate
java.lang.Object
burp.mcp.server.AccessGate
Evaluates permission policy and Burp target scope for a tool call and
resolves "prompt" outcomes through the operator UI via
ApprovalManager.
Decision protocol: gated calls wait up to the configured approval window
for an operator decision. If the operator answers in time the call is
allowed or denied immediately; otherwise the caller receives an
APPROVAL_PENDING result and can retry the identical call while the
request stays queued for its TTL.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic final classOutcome of a gate evaluation.static interfaceConfig seams so tests can pin enforcement without the McpConfig singleton. -
Constructor Summary
ConstructorsConstructorDescriptionAccessGate(burp.api.montoya.MontoyaApi api, PermissionManager permissions, ApprovalManager approvals) AccessGate(burp.api.montoya.MontoyaApi api, PermissionManager permissions, ApprovalManager approvals, AccessGate.Settings settings) -
Method Summary
Modifier and TypeMethodDescriptionEvaluate a tool call.voidCancel every queued approval; called when the server stops.static StringLowercase scheme://host[:port], default ports omitted; null when unparsable.
-
Constructor Details
-
AccessGate
public AccessGate(burp.api.montoya.MontoyaApi api, PermissionManager permissions, ApprovalManager approvals) -
AccessGate
public AccessGate(burp.api.montoya.MontoyaApi api, PermissionManager permissions, ApprovalManager approvals, AccessGate.Settings settings)
-
-
Method Details
-
check
public AccessGate.Result check(String clientIp, String toolName, Map<String, Object> args, List<String> targets) Evaluate a tool call.- Parameters:
clientIp- caller identity so retries match the same pending requesttoolName- canonical tool nameargs- tool arguments (used only for the fingerprint/summary)targets- target URLs derived fromTargetedTool
-
onServerStop
public void onServerStop()Cancel every queued approval; called when the server stops. -
originOf
Lowercase scheme://host[:port], default ports omitted; null when unparsable.
-