How do I determine the remote IP Address of a connected socket?
I have a RemoteEndPoint object I can access and well as its AddressFamily member.
How do I utilize these to find the ip address?
Thanks!
Currently trying
IPAddress.Parse( testSocket.Address.Address.ToString() ).ToString();
and getting 1.0.0.127 instead of 127.0.0.1 for localhost end points. Is this normal?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…