wstunnel
wstunnel copied to clipboard
Configuration file
Describe the feature
I want to be able to run wstunnel [server | client] --configuration wstunnel.conf
- wstunnel.conf can contain port mappings and other configurations
- changing wstunnel.conf leads to configuration reload (Like
--tls-certificateand--tls-private-keyfile change does)
Describe the reason for such feature
Command line has a limit, which matters if you map many ports (multiple -L or -R arguments) Use case: mapping range of ports to a different range of ports
Describe alternatives you've considered
An alternative feature that may help is to allow mapping of port ranges
Hello,
For port-mapping you can already do it by using the restriction config https://github.com/erebe/wstunnel/blob/main/restrictions.yaml#L54
Is there a way to pass http-upgrade-path-prefix and restrict-http-upgrade-path-prefix from Configuration file?
You can set restrict-http-upgrade-path-prefix with https://github.com/erebe/wstunnel/blob/main/restrictions.yaml#L12
Does anyone know how to specify multiple --restrict-to DEST:PORT options in config file?
This is an example of how I'm using wstunnel in reverse tunnel mode with multiple tunnels each with separate credential and port:
restrictions:
- name: device1
description: device1
match:
- !PathPrefix "^apassword$"
allow:
- !ReverseTunnel
protocol:
- Tcp
port:
- 26667
- name: device2
description: device2
match:
- !PathPrefix "^anotherpassword$"
allow:
- !ReverseTunnel
protocol:
- Tcp
port:
- 19716