ProxymanApp / ProxymanApp/Proxyman

[BUG] Export to HAR doesn't include request body

Open
#1,614 6 comments 0 reactions 1 assignee View on GitHub

@NghiaTranUIT is already working on this.

Since Apr 26, 2023.

✅ Done bug
Dominant language
No language data
Stars
7k
Forks
237
PR merge metrics
No merged PRs in 30d

Description

Description

I am exporting a whole flow to .HAR in order to programatically analyse them.
I've found that a specific request does not includes the request body in the generated .HAR.

Steps to Reproduce

  1. Download and open this Proxyman log file
    proxyman_export_bug_repro.proxymanlogv2.zip

  2. Confirm that the post body of the request is visible

image
  1. Export to a HAR file
  2. Open the exported HAR file in a text editor
  3. Look at the following path: .log.entries[0].request. There is no body even though it's visible in the Proxyman log.
HAR file
{
  "log": {
    "version": "1.2",
    "creator": { "name": "Proxyman", "version": "4.6.1" },
    "entries": [
      {
        "time": 185.87184143066406,
        "_isHTTPS": true,
        "_webSocketMessages": null,
        "_remoteDeviceIP": "192.168.1.100",
        "timings": {
          "connect": 1,
          "send": -1,
          "dns": -1,
          "ssl": -1,
          "wait": -1,
          "blocked": -1,
          "receive": -1
        },
        "_serverAddress": "35.186.224.25",
        "_isIntercepted": true,
        "_id": "7831",
        "serverIPAddress": "35.186.224.25",
        "_name": "7831",
        "_clientAddress": "192.168.1.100",
        "_clientBundlePath": null,
        "request": {
          "method": "POST",
          "bodySize": 156,
          "headersSize": 248,
          "cookies": [],
          "headers": [
            { "name": "Accept", "value": "application/x-protobuf" },
            {
              "name": "User-Agent",
              "value": "Spotify/8.6.58 Android/33 (sdk_gphone64_arm64)"
            },
            { "name": "Content-Type", "value": "application/x-protobuf" },
            { "name": "Content-Length", "value": "156" },
            { "name": "Host", "value": "clienttoken.spotify.com" },
            { "name": "Connection", "value": "Keep-Alive" },
            { "name": "Accept-Encoding", "value": "gzip" }
          ],
          "queryString": [],
          "httpVersion": "HTTP/1.1",
          "url": "https://clienttoken.spotify.com/v1/clienttoken"
        },
        "_serverPort": 443,
        "_clientName": null,
        "_clientPort": 52078,
        "response": {
          "status": 200,
          "content": {
            "size": 374,
            "mimeType": "application/x-protobuf",
            "encoding": "base64",
            "text": "CAIa8QIKxAJBQUNER0hMWjlPTlpoZ0lOY3ZNOXNtMURGdFQ0Ti9oUUZScHRCZUFHR2JwNWFtRXlaVGRXT3R6M0dla3Q3SnNDS1Q1VHFVdTRtcWJoYmN1d0piYVNyMFZQSGIyMHNnbFRmd1NoZE1sZmJuOUdEaTZGMytJbVJTOTdnS3hWMkhnKzFxbk5lUVQ4NUpmNm5HWGZGTEVwZnJpU2xqRGhkLy8rNWJHbDd2MFFSVndxUG8xN3JpdUovRVhtM1lWSzh0ZVkzWnJJQjR3aWJjeDB4KzZuVGtuVnBiSlk1VXg4WG1KVVVSZ0hHZmhSaVg5aGVIMDIwa0FBcHc1MlltNVIvUk5ES0UrcGNyVzREZ3ZlM3NzY1R0TzFQRXFFS0h3TGhxQldiRHoxdml1OENtbTlYdXdPcHJiREtudXZMMWd2dGtWTGFOdz0SKAgDIiQIFBIgRjlDNTY0QTkyMDRCMTQ2MDY1RjRFN0YyOTYzOEIzODU="
          },
          "bodySize": 374,
          "headersSize": 366,
          "cookies": [],
          "statusText": "OK",
          "headers": [
            { "name": "content-type", "value": "application/x-protobuf" },
            { "name": "cache-control", "value": "private, max-age=0" },
            { "name": "content-encoding", "value": "gzip" },
            {
              "name": "strict-transport-security",
              "value": "max-age=31536000"
            },
            { "name": "x-content-type-options", "value": "nosniff" },
            { "name": "date", "value": "Sat, 22 Apr 2023 14:47:39 GMT" },
            { "name": "server", "value": "envoy" },
            { "name": "Via", "value": "HTTP/2 edgeproxy, 1.1 google" },
            {
              "name": "Alt-Svc",
              "value": "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000"
            },
            { "name": "Transfer-Encoding", "value": "chunked" }
          ],
          "httpVersion": "HTTP/1.1",
          "redirectURL": ""
        },
        "comment": "",
        "startedDateTime": "2023-04-22T15:47:39.910+01:00",
        "cache": {}
      }
    ]
  }
}

Current Behavior

Some POST requests get their body suppressed when exported to HAR

Expected Behavior

This POST request gets their body exported to HAR correctly

Environment

  • App version: Proxyman 4.6.1 (46010)
  • macOS version: macOS Ventura (13.2.1)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.