correct ip and log referer