Score:0

Can't Get ProxyPass User IP Address

cn flag

JAVASCRIPT

websocket = new WebSocket("wss://site.com/game_play/");
....

PHP

$socket = socket_create(AF_INET, SOCK_STREAM, SOL_TCP);
....
$size=socket_recvfrom($socket_new,$input,65535,0,$ipaddress,$port);
echo "Received [$input] ($size bytes) from IP $ipaddress Port $port\n";

APACHE

ProxyPass /game_play/ ws://site.com:8090/server.php
ProxyPassReverse /game_play/ ws://site.com:8090/server.php

START SERVER - SSH: php server.php

Error: User ip address should be returned; server ip address is returning.

Note: Returns X-FORWARDED-FOR in the header. However, this is not safe.

If I'm not wrong, they said that RemoteIPHeader ( mod_remoteip ) would be the solution. But I think I made a mistake, it didn't work even though I tried.

Thanks

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.