Sending real ip address in websocketd.
parent
80b98e3ba6
commit
9912ef8a5e
|
@ -224,8 +224,7 @@ def websocket_client_connection(client)
|
|||
# message = IPC::Message.from_json(JSON).to_packet
|
||||
# => JSON has to include these attributes: mtype, utype, payload
|
||||
# message = IPC::Message.new mtype, utype, payload
|
||||
remote_address = client.remote_address.address
|
||||
message = IPC::Message.new sfd, 1, 1.to_u8, "{\"ipaddress\": \"#{remote_address}\"}"
|
||||
message = IPC::Message.new sfd, 1, 1.to_u8, "{\"ipaddress\": \"#{real_ip_address}\"}"
|
||||
if Context.print_messages
|
||||
Baguette::Log.info "to trackingd: #{message.to_s}"
|
||||
end
|
||||
|
|
Reference in New Issue