Repository navigation
Expand file tree
/
Copy pathBappDescription.html
More file actions
45 lines (42 loc) · 2.98 KB
/
Copy pathBappDescription.html
File metadata and controls
45 lines (42 loc) · 2.98 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<p>
Decodes and re-encodes gRPC-Web request and response bodies in the message editor, without needing the target's
<code class="InlineCode">.proto</code> schema. gRPC-Web bodies are protobuf wrapped in length-prefixed frames, and
<code class="InlineCode">application/grpc-web-text</code> bodies are base64 on top of that, so they arrive as an
opaque blob that ordinary testing techniques do not reach. This extension unwraps the framing, infers a type for
every protobuf field, and shows the result as editable JSON. Edits are re-encoded on the way out, so a payload can
be tampered with in Proxy, Repeater and Intruder like any other request body.
</p>
<h2>Features</h2>
<ul>
<li>Adds a decoded gRPC-Web tab to requests and responses, with the payload as JSON and an editable type definition
alongside it.</li>
<li>Guesses a type for each field from the wire format, and lists the other readings the same bytes would allow, so
an ambiguous field can be reinterpreted without trial and error.</li>
<li>Handles every frame in a body, including the multiple data frames of a server-streaming response and the trailer
frame that closes it.</li>
<li>Inflates and re-deflates gzip-compressed frames.</li>
<li>Supports proto3 packed repeated fields, which are indistinguishable from a bytes field on the wire.</li>
<li>Extracts service routes and message field definitions from generated gRPC-Web JavaScript, revealing methods that
no part of the application's UI calls.</li>
<li>Exports those findings as JSON, CSV, a reconstructed <code class="InlineCode">.proto</code> for <code
class="InlineCode">protoc</code> or <code class="InlineCode">grpcurl</code>, or as type definitions that
make payloads decode with their real field names.</li>
<li>Supports <code class="InlineCode">application/grpc-web-text</code>, <code
class="InlineCode">application/grpc-web-text+proto</code>, <code
class="InlineCode">application/grpc-web+proto</code> and <code
class="InlineCode">application/grpc-web</code>.</li>
</ul>
<h2>Usage</h2>
<ol>
<li>Send a gRPC-Web request through Burp and open the Decoded gRPC-Web tab in Repeater. Field names are not carried
on the wire, so fields appear by number until you name them in the type definition.</li>
<li>Edit the payload as JSON, then switch back to the raw view. The body and <code
class="InlineCode">Content-Length</code> are re-encoded for you.</li>
<li>Right-click the response containing the site's gRPC-Web JavaScript bundle and choose Analyze gRPC-Web Endpoints
to recover the real field names and numbers.</li>
<li>Export those results as type definitions and paste them into the Type Definition tab, which makes every
subsequent payload readable.</li>
</ol>
<p>For a walkthrough of testing gRPC-Web, see
<a href="https://github.com/nxenon/grpc-pentest-suite">https://github.com/nxenon/grpc-pentest-suite</a>.
</p>