socket.localAddress


远程客户端连接的本地 IP 地址的字符串表示形式。 例如,在监听 '0.0.0.0' 的服务器中,如果客户端连接到 '192.168.1.1',则 socket.localAddress 的值将是 '192.168.1.1'

The string representation of the local IP address the remote client is connecting on. For example, in a server listening on '0.0.0.0', if a client connects on '192.168.1.1', the value of socket.localAddress would be '192.168.1.1'.