Skip to content

Conversation

XSAM
Copy link

@XSAM XSAM commented Nov 15, 2019

I want to implement an SSH server to forward a remote server's port to local (aka local forward), then I found an example called remoteforward, and it uses LocalPortForwardingCallback setting.

When I try to use the example to bind local port and use curl to request,

ssh -L 0.0.0.0:8080:example.com:80 localhost -p 2222
curl localhost:8080

Got error

channel 2: open failed: unknown channel type: unsupported channel type

Then I found it cannot be used in local forward, and the LocalPortForwardingCallback in this example kinda useless and bring some confuse.

So I remove the LocalPortForwardingCallback in remoteforward example and add a new example called localforward

@XSAM XSAM force-pushed the chore/localforward-example branch from 401d120 to 0b90efa Compare November 15, 2019 10:58
@dcb9
Copy link

dcb9 commented Apr 19, 2023

@XSAM Thanks! Helped me a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants