Skip to content

Add request id to proxy history and a get_proxy_http_history_by_id tool - #111

Open
redteam10it wants to merge 1 commit into
PortSwigger:mainfrom
redteam10it:feat/proxy-history-request-id
Open

Add request id to proxy history and a get_proxy_http_history_by_id tool#111
redteam10it wants to merge 1 commit into
PortSwigger:mainfrom
redteam10it:feat/proxy-history-request-id

Conversation

@redteam10it

Copy link
Copy Markdown

Summary

get_proxy_http_history only addresses items by list offset, so there's no way to point at a specific request by the number Burp shows in Proxy > HTTP history. The usual workaround (offset = id - 1) falls apart as soon as the history is filtered or items are dropped.

  • Serialized proxy history items now include their Burp request id (from ProxyHttpRequestResponse.id()). The field is nullable and omitted for request/responses that don't originate from proxy history (e.g. scanner issues), so their output is unchanged.
  • New get_proxy_http_history_by_id tool returns a single history item by that id, using the same data-access permission check as the other history tools.

Closes #30.

Test plan

  • ./gradlew test passes
  • New tests: lookup returns the matching item and exposes its id; an unknown id returns a not-found message

Proxy HTTP history items can only be referenced by list offset, so an MCP
client cannot point to a specific request the way a user does in Burp's UI
(by its request number). This addresses PortSwigger#30.

- Expose the Burp request id on serialized proxy history items (the number
  shown in Proxy > HTTP history). The field is nullable and omitted for
  request/responses that don't come from proxy history, so existing output
  is unchanged for those.
- Add get_proxy_http_history_by_id, which returns a single history item by
  that id, with the same data-access permission check as the other history
  tools.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add request ID parameter to get_proxy_http_history

1 participant