0

I have a linux machine, with multiple ip-adresses configured. I create a connection with the following code.

        ws = new WebSocket(Adress);
        ws.Origin = Origin;

        ws.OnOpen += OnOpen;
        ws.OnError += OnError;
        ws.OnMessage += OnMessageReceived;
        ws.OnClose += OnClose;

        ws.ConnectAsync();

This works all fine, but how can i determine the ip adress, which websocket-sharp is using to connect to a server?

michidk
  • 351
  • 1
  • 4
  • 18
  • From a cmd.exe window type : ipconfig/all. Each Ethernet card in a windows PC will have a different IP. IPCONFIG will give all the address. It is better to connect to the computer name if DCHP is enabled. DCHP periodically change IP addresses, but computer name is always the same. – jdweng Dec 26 '15 at 15:40

1 Answers1

0

To set the local adress you have to modify the websocket-sharp library, because this functionality isn't supported right now.

michidk
  • 351
  • 1
  • 4
  • 18