I don't think the default takes Proxies or IP's behind LAN's into consideration. Here's a function that can easily be used in config.php to grab the absolute IP of the user. Thanks to NuLime for the function.
Code:
function fetch_remote_address() {
$_SERVER = $GLOBALS['HTTP_SERVER_VARS'];
# Record basic remote address.
$remote_address = $_SERVER['REMOTE_ADDR'];
# Take proxies into consideration or IPs behind a LAN.
if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) && $_SERVER['HTTP_X_FORWARDED_FOR'] != 'unknown' && $_SERVER['HTTP_X_FORWARDED_FOR'] != $_SERVER['REMOTE_ADDR']) {
$HXFF_temp = preg_replace('/, ?unknown/i','',$_SERVER['HTTP_X_FORWARDED_FOR']); // Remove any trailing 'unknowns'.
$remote_address .= ','.$HXFF_temp;
}
if (isset($_SERVER['HTTP_CLIENT_IP']) && $_SERVER['HTTP_CLIENT_IP'] != 'unknown' && $_SERVER['HTTP_CLIENT_IP'] != $_SERVER['HTTP_X_FORWARDED_FOR'] && $_SERVER['HTTP_CLIENT_IP'] != $_SERVER['REMOTE_ADDR']) {
$HCI_temp = preg_replace('/, ?unknown/i','',$_SERVER['HTTP_CLIENT_IP']); // Remove any trailing 'unknowns'.
$remote_address .= ','.$HCI_temp;
}
return $remote_address;
}