midori icon indicating copy to clipboard operation
midori copied to clipboard

Is midori missing a server_name parameter similar to what's inside nginx?

Open xiangzha0 opened this issue 3 years ago • 1 comments

I am very lucky to have stumbled upon midori,which free me up from dnat and bring more new features like websocket/h2/quic relay to me

During my use of midori, I encountered a little trouble

I want to use midori to forward traffic to nginx on an intranet for debugging

Because the nginx is configured with server_name, midori is denied when using IP and port access in remote below is my config file content: { "dns_mode": "ipv4_then_ipv6", "endpoints": [{ "listen": { "addr": "0.0.0.0:443", "net": "tcp", "trans": { "proto": "ws", "path": "/ws" } }, "remote": { "addr": "10.49.2.67:443", "net": "tcp", "trans": { "proto": "ws", "path": "/ws" }, "tls": { "sni": "my.server.com", "skip_verify": false, "enable_early_data": true, "roots":"firefox" } } } ] }

I couldn't find something similar to the server_name parameter that can be configured in midori such as "remote": { "addr": "10.49.2.67:443", "server_name":"my.server.com", "net": "tcp", "trans": { "proto": "ws", "path": "/ws" }

I tried to use the domain name in midori, and added the mapping entry between the domain name and the target intranet IP in the hosts file, and I was able to access it normally. Although this can temporarily solve some problems, it is always inconvenient and has some additional side effects

Would you evaluate and consider adding a parameter similar to server_name in midori?

xiangzha0 avatar Jan 26 '22 02:01 xiangzha0

Add host header could solve the problem. I'm considering to introduce a new option to make it possible for users to customize http headers.

zephyrchien avatar Jan 26 '22 12:01 zephyrchien