View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0011128 | Taler | merchant backend | public | 2026-02-21 02:14 | 2026-02-21 02:14 |
| Reporter | Windfisch | Assigned To | |||
| Priority | normal | Severity | minor | Reproducibility | have not tried |
| Status | new | Resolution | open | ||
| Product Version | 1.4 | ||||
| Summary | 0011128: Binary garbage on PATCH /instances/foo/private with *_delay==0 | ||||
| Description | When PATCHing a /instances/foo/private endpoint with either default_{pay,refund,wire_transfer}_delay set to 0, the HTTP request returns binary garbage. The response seems to be the desired (error) response, but zlib-compressed. Apparently some response header is not set which indicates to curl that the response is actually compressed, so curl won't uncompress it. tested with v1.4.1-dev.1 | ||||
| Steps To Reproduce | Create a "stonks2" merchant instance. Update the settings once, capture the PATCH request in the browser and "copy as cURL", which yields something similar to below: WIRE=0; PAY=60; REFUND=60; curl 'https://backend.w.icmp.camp/instances/stonks2/private' -X PATCH -H 'Accept-Encoding: gzip, deflate, br, zstd' -H 'Content-Type: application/json' -H 'Authorization: Bearer secret-token:REDACTED' --data-raw '{"default_pay_delay":{"d_us":'$PAY'000000},"default_refund_delay":{"d_us":'$REFUND'000000},"default_wire_transfer_delay":{"d_us":'$WIRE'000000},"use_stefan":false,"name":"stonks2","email_validated":false,"phone_validated":false,"merchant_pub":"GE04TYN95S5CWNBBN3GWK3W2SM0WKRBSQ6X3A4MPT4KQ02JD4A40","address":{},"jurisdiction":{},"default_wire_transfer_rounding_interval":"NONE","auth":{"method":"token"}}' ; echo results in binary garbage. when piped through `file -`, file reports "zlib compressed data" WIRE=0; PAY=60; REFUND=60; curl 'https://backend.w.icmp.camp/instances/stonks2/private' -X PATCH -H 'Accept-Encoding: gzip, deflate, br, zstd' -H 'Content-Type: application/json' -H 'Authorization: Bearer secret-token:EYADCF1E372W34G3CZ36EQJNPTPQA7PM9AQX8V6B7W8CXVENT8ZG' --data-raw '{"default_pay_delay":{"d_us":'$PAY'000000},"default_refund_delay":{"d_us":'$REFUND'000000},"default_wire_transfer_delay":{"d_us":'$WIRE'000000},"use_stefan":false,"name":"stonks2","email_validated":false,"phone_validated":false,"merchant_pub":"GE04TYN95S5CWNBBN3GWK3W2SM0WKRBSQ6X3A4MPT4KQ02JD4A40","address":{},"jurisdiction":{},"default_wire_transfer_rounding_interval":"NONE","auth":{"method":"token"}}' | zlib-flate -uncompress % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 557 100 170 100 387 1303 2968 --:--:-- --:--:-- --:--:-- 4284 { "code": 22, "hint": "The JSON in the client's request was malformed. This is likely a bug in the client implementation. Check if you are using the latest available version and/or file a report with the developers." } Note how the binary data actually uncompresses to a reasonable JSON response. The problem does not occur when removing the Accept-Encoding header. | ||||
| Tags | No tags attached. | ||||
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2026-02-21 02:14 | Windfisch | New Issue |