bruno
bruno copied to clipboard
Proxy port in URI
Hello,
I try to use bruno 1.6.1 in a windows10 professional environment (mitm proxy https, Web Gateway, firewall...). I send all my traffic through a local http proxy :
"proxy": {
"enabled": true,
"protocol": "http",
"hostname": "127.0.0.1",
"port": 31280,
"auth": {
"enabled": false,
"username": "",
"password": ""
},
"bypassProxy": ""
}
When I try to get https request :
meta {
name: simple get
type: http
seq: 1
}
get {
url: https://reqres.in/api/users
body: none
auth: none
}
bruno send bad, he add the proxy port to the uri hostname https://reqres.in:31280/api/users
and get error Error invoking remote method 'send-http-request': Error: socket hang up
Frame 68: 304 bytes on wire (2432 bits), 304 bytes captured (2432 bits) on interface \Device\NPF_Loopback, id 7
Internet Protocol Version 4, Src: localhost (127.0.0.1), Dst: localhost (127.0.0.1)
Transmission Control Protocol, Src Port: 50914 (50914), Dst Port: 31280 (31280), Seq: 1, Ack: 1, Len: 260
Hypertext Transfer Protocol
GET https://reqres.in:31280/api/users HTTP/1.1\r\n
Accept: application/json, text/plain, */*\r\n
request-start-time: 1706195677467\r\n
User-Agent: axios/1.5.1\r\n
Accept-Encoding: gzip, compress, deflate, br\r\n
host: reqres.in\r\n
Proxy-Connection: close\r\n
Connection: close\r\n
\r\n
[Full request URI: https://reqres.in:31280/api/users]
[HTTP request 1/1]
I got the same with http request : GET http://reqres.in:31280/api/users HTTP/1.1\r\n
I very much appreciate your app and wish it the success it deserves
Kind regards,
I experience similar issues, but the problem is not just the port. The authority part "https://reqres.in" should be in the host header and the GET method should only contain the path. Like this:
GET /api/users HTTP/1.1
Host: reqres.in
...
I am using Bruno version 1.7.1
Issue still persists in 1.10.0
Some CNTLM logs to illustrate the issue:
Bruno:
******* Round 1 C: 4 *******
Reading headers (4)...
HEAD: GET https://api.mistral.ai:3128/v1/models HTTP/1.1
Curl:
******* Round 1 C: 4 *******
Reading headers (4)...
HEAD: CONNECT api.mistral.ai:443 HTTP/1.1
Also: The DevTools don't show anything in the network tab for these requests.
Can someone acknowledge this and maybe give some insights/roadmap?
I have the same issue.
I made a bug report to http-proxy lib (https://github.com/TooTallNate/proxy-agents/issues/298) I made a PR #1883
Please test this PR and confirm it's the same issue and that the PR fixes the bug for you. I made a release for my convenience here: https://github.com/samuel-deal-tisseo/bruno/releases/tag/v1.12.3-sam But you should try the PR itself for security reasons
Thank you
Hello,
I will try with the 1.12.3-sam version, it's good for me :
Thanks !
Great to here that :) I hope It will be merged upstream soon
Tried both 1.18.0 Windows and Linux. Having the same issue.
Windows proxy log:
Linux proxy log:
Having the same issue on version 1.24.0 on Linux.
Proxy is correctly contacted, but the proxy port is added to the original request when it shouldn't.
Same issue here in Windows with version 1.26.1