OYIon / LiveSharp

Public repository for the LiveSharp project
96 stars 4 forks source link

Please allow for specifying IP address to bind to #108

Closed hiredgunhouse closed 3 years ago

hiredgunhouse commented 3 years ago

I need to specify which network interface (IP address) LiveSharp should bind and connect to.

Why? I have a few network interfaces and while LiveSharp server starts fine the app when starting is not able to connect due to permission issue. This is what I see in my Debug Output window in Rider:

Connecting to 10.10.80.103:58540
error: Connection exception: System.AggregateException: One or more errors occurred. (An attempt was made to access a socket in a way forbidden by its access permissions. 10.10.80.103:58540)
 ---> System.Net.Internals.SocketExceptionFactory+ExtendedSocketException (10013): An attempt was made to access a socket in a way forbidden by its access permissions. 10.10.80.103:58540
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw(Exception source)
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)
   --- End of inner exception stack trace ---

My laptop is heavily controlled by a bunch of security software and thus I would need to specify that LiveSharp binds to localhost which btw could be the default behavior anyway. Please consider that small feature and prioritize if possible, I have been waiting over 5 years for a tool like that to appear and cannot wait to start using it, please, please, pretty please, so excited about LiveSharp that I would be happy to pay many times more for it. Another plea, don't let MS buy and kill or destroy you like they did with Alive.

ionoy commented 3 years ago

Hello @hiredgunhouse

Thanks for the feedback. I have already implemented this feature, but it's not public yet.

You can use the build I shared in the LiveSharp channel https://gitter.im/LiveSharp/Lobby on Nov 26

Also uploading it here to be safe: LiveSharp.1.6.36.zip

You can then define LiveSharpServerIp attribute in the livesharp.dashboard.cs:

[assembly: LiveSharpServerIp("x.x.x.x")]

The plan is to stick with developing it myself, even though it's a lot of work for me alone. But at least I don't have to answer to anybody when adding new features, which is great.

hiredgunhouse commented 3 years ago

Thank you, that works.