Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What do you use it for? #4

Open
jzabroski opened this issue Mar 12, 2019 · 1 comment
Open

What do you use it for? #4

jzabroski opened this issue Mar 12, 2019 · 1 comment

Comments

@jzabroski
Copy link

Just curious

@nicodeslandes
Copy link
Owner

nicodeslandes commented Mar 13, 2019

I've used it on multiple occasions, where I've had to bridge traffic from one place to another for various reasons.

Here are a few use cases I came across:

  • SSL Off-loading
    I had a project where we had to connect to a client's web api which was using HTTPS, but with an invalid certificate. The problem was that our ReactNative app would refuse to connect to it because certificate validation couldn't be turned off. I hosted a TcpMux instance in Azure which would connect to the remote HTTPS endpoint, and expose the API as HTTP.

  • Network routing through a VPN-enabled device
    This is why I created TcpMux in the 1st place. I had a laptop that was configured to access some resources through a VPN. I used TcpMux on that machine to expose a Tcp Port that allowed me to access those resource from my home machine. I suppose socat does this on Linux. But implementing it in C# was a lot more fun :).

  • Investigating and working around SSL issues in .NET
    In this instance, we had a .NET app on Windows that refused to connect to an HTTPS endpoint. I investigated the issue by runnning TcpMux locally (with logging and SSL re-encryption enabled) to connect to the remote endpoint and expose a local HTTPS endpoint, and configured the app to go through it. That allowed us to use the app while we were investigating the issue (which turned to be a TLS 1.2 bug in .NET Core).

  • Working around firewall restriction on machine
    This a classic one. Say you have a PC where the firewall only allows traffic through port 8080, but you've got an app that only expose traffic on port 1234. You can run TcpMux to open port 8080 and redirect traffic to port 1234. You also get the additional option to monitor the traffic by logging all requests in and out.

  • Convert HTTPS to HTTP, or vice-versa
    TcpMux allows you to "turn" an HTTP endpoint into HTTPS, or the opposite. Can be useful if a particular client has restriction one way or the other.

That's all I can think of for now. Let me know if you have other ideas! :)

@nicodeslandes nicodeslandes pinned this issue Jan 28, 2020
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

No branches or pull requests

2 participants