get ip using request object