Open Bug 1634388 Opened 4 years ago Updated 3 years ago

Copy as curl encode special chars as hex digits

Categories

(DevTools :: Netmonitor, defect, P3)

75 Branch
defect

Tracking

(Not tracked)

People

(Reporter: erdnaxeli, Unassigned)

References

(Blocks 1 open bug)

Details

User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0

Steps to reproduce:

  • go to https://petstore.swagger.io/#/pet/addPet
  • click on try it out
  • change the name to "éà"
  • open the network inspection tool
  • run the request
  • on the inspection tool, right click on the POST that has just shown
  • select copy > copy as curl

Actual results:

Here is the result that was copied:

curl 'https://petstore.swagger.io/v2/pet' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0' -H 'Accept: application/json' -H 'Accept-Language: fr,fr-FR;q=0.8,en-US;q=0.5,en;q=0.3' --compressed -H 'Referer: https://petstore.swagger.io/' -H 'Content-Type: application/json' -H 'Origin: https://petstore.swagger.io' -H 'DNT: 1' -H 'Connection: keep-alive' --data $'{\n  "id": 0,\n  "category": {\n    "id": 0,\n    "name": "\xe9\xe0"\n  },\n  "name": "doggie",\n  "photoUrls": [\n    "string"\n  ],\n  "tags": [\n    {\n      "id": 0,\n      "name": "string"\n    }\n  ],\n  "status": "available"\n}'

We can note that the name is "name": "\xe9\xe0"\.

Expected results:

I would expect the name to be "name": "éà".

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Netmonitor
Product: Firefox → DevTools

Because this bug's Severity has not been changed from the default since it was filed, and it's Priority is -- (non,) indicating it has has not been previously triaged, the bug's Severity is being updated to -- (default, untriaged.)

Severity: normal → --

Thanks for the report!

Blocks: curl
Severity: -- → S3
Priority: -- → P3

The severity field is not set for this bug.
:Honza, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(odvarko)

Severity field properly set now.

Honza

Flags: needinfo?(odvarko)

Bug still exist in newest Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1731809

Status: UNCONFIRMED → NEW
Ever confirmed: true
You need to log in before you can comment on or make changes to this bug.