wcf获取客户端IP,端口 var context = OperationContext.Current; var properties = context.IncomingMessageProperties; //获取传进的消息属性 var endpoint = properties[RemoteEndpointMessageProperty.Name] as RemoteEndpointMessageProperty; //获取消息发送的远程终结点IP和端口 string UserLogin